% m54_bernstein.m - Chebyshev series and Bernstein ellipses f = chebfun('1./(1+25*x.^2)'); subplot(1,3,1), plot(f), ylim([-1 2]) subplot(1,3,2), plotcoeffs(f,'linewidth',.6), grid on subplot(1,3,3), plotregion(f), xlim([-1.4 1.4]), axis equal, grid on hold on, plot([-.2i .2i],'.r') rho = (1+sqrt(26))/5; kk = 0:length(f); subplot(1,3,2), hold on, plot(kk,rho.^(-kk),'--r')