function P=polint(n,xx,yy,t);
% Interpolationspolynom med Newtons ansats
  x=xx(1:n); y=yy(1:n);
  xk=ones(size(x));  A=xk;
  for kol=2:n, xk=xk.*(x-x(kol-1)); A=[A xk]; end
  c=A\y;
  yt=zeros(size(t)); 
  for k=n:-1:1, yt=yt.*(t-x(k))+c(k); end
  P=yt; 


