function ynew=polysamp(x,y,n);
%function ynew=polysamp(x,y,n);
coef=polyfit(x,y,n);
ynew=polyval(coef,x);
