function y=Horner(p,x);
% HORNER Evaluates a polynomial
%   y=Horner(p,x) evaluates the polynomial 
%   y=p(1)*x^(n-1)+p(2)*x^(n-2)+...+p(n-1)*x+p(n)

n=length(p);
y=0;
for i=1:n
  y=y*x+p(i);
end
