Sample Maple worksheet illustrating series summation and graphing. By Sterl Phinney 2/13/2004.

We wish to expand terms of the geometric series Sum_k=1,n x^k, and compare it to 1/(1-x) for various n:]

> Geomser := (x,n) -> Sum(x^k,k=0..n);

Geomser := proc (x, n) options operator, arrow; Sum...

We now compare the two functions for n=7, with the series in blue and 1/(1-x) in red.

> plot([Geomser(x,7),1/(1-x)],x=0..1, y=0..5,linestyle=[1,4],color=[blue,red]);

[Maple Plot]

We now compare the fractional error residuals, making the small values visible by using a logarithmic vertical axis:

> with(plots):

Warning, the name changecoords has been redefined

> logplot((1/(1-x) - Geomser(x,7))*(1-x),x=0..1,y=10^(-6)..1,labels=[x,`fractional residual`]);

[Maple Plot]

Now just a warning about plotting points and display resolution:

> plot(sin(53*2*Pi*x),x=0..1,resolution=50,numpoints=50, adaptive=false);

[Maple Plot]

> plot(sin(53*2*Pi*x),x=0..1,resolution=800,numpoints=800, adaptive=false);

[Maple Plot]

Those two preceeding graphs are supposed to be of the same function...! Hope this was helpful.

>