%Sample from p 176 of the text: x=[-1;2;3]; y=[5;-7;-5]; A=edm(x,x); c=A\y; xx=linspace(-2,4); %xx is 1 x 100 v=edm(xx',x); %v is 100 x 3 yy=v*c; plot(x,y,'r*',xx,yy);