clear all
m=20;
%noiselevel=3;
noiselevel=0;
for n=2:9
    x7(n-1)=n;
        
     for i=1:50
       a_demo_least_1
       xPol(i)=polynomialLeastErrorNormalized;
     %       zSp(i)=splineLeastErrorNormalized;
      end

       xPolynomial(n-1)=mean(xPol);
      %    zSpline(n-1)=mean(zSp);
		     
     end
			      
      plot(x7,xPolynomial,'dr')
     %hold on
     %plot(z,zSpline,'r')
     xlabel('m')
      ylabel('normalized least square error')

