function [xnew,ynew]=polyfit2(x,y,n);
%function [xnew,ynew]=polyfit2(x,y,n);
%              uses polyfit and polyval to fit y(x) with a polynomial of 
%                    order n.  
xnew=min(x):(max(x)-min(x))/100:max(x);
ynew=polyval(polyfit(x,y,n),xnew);
plot(xnew,ynew,x,y,'x')
