3-1-5.mws

3-1 Construct the graph of sin(x) with x raging in [0,2]

> plot(sin(x),x=0..2*Pi,scaling=constrained);

[Maple Plot]

3-2 Draw a circle given by the parametric equations

x=cos(t), y=sin(t) ,t=[0,2 Pi ]

> plot([cos(t),sin(t),t=0..2*Pi],scaling=constrained,axes=none);

[Maple Plot]

µo ®i ÃD

> animate([r*cos(u),r*sin(u),u=0..2*Pi],r=0..1,frames=50,axes=none,scaling=constrained,title="animate of a circle----press the botton of the mouse");

[Maple Plot]

> plot([cos(3*t),sin(4*t),t=0..2*Pi],scaling=constrained,axes=none);

[Maple Plot]

> plot(cos(t),t=0..2*Pi,coords=polar,scaling=constrained);

[Maple Plot]

> plot(cos(2*t),t=0..2*Pi,coords=polar,scaling=constrained);

[Maple Plot]

> plot(cos(3*t),t=0..2*Pi,coords=polar,scaling=constrained,axes=none,color=blue);

[Maple Plot]

3-3 Draw the graphs of the first six Chebyshev polynomials in the interval [-1,1]

> plot([cos(t),cos(2*t),t=0..2*Pi],scaling=constrained,color=green);

[Maple Plot]

> plot([[cos(t),cos(n*t),t=0..2*Pi]$n=1..6],scaling=constrained,title="Beauty");

[Maple Plot]

> m:=[cos(x),cos(n*x),x=0..Pi];

m := [cos(x), cos(n*x), x = 0 .. Pi]

> plot({m$n=1..6},axes=none,scaling=constrained);

[Maple Plot]

The graph of Chebyshve Polynomial

> ?T

> with(orthopoly);

[G, H, L, P, T, U]

> T(2,x);

2*x^2-1

> T(3,x);

4*x^3-3*x

> with(numapprox);

[chebdeg, chebmult, chebpade, chebsort, chebyshev, ...
[chebdeg, chebmult, chebpade, chebsort, chebyshev, ...

> P:=chebyshev(cos(x),x);

P := .7651976865*T(0,x)-.2298069699*T(2,x)+.4953277...
P := .7651976865*T(0,x)-.2298069699*T(2,x)+.4953277...

> plot(P,x=-2..2,color=pink);

[Maple Plot]

> a1:=plot(P,x=-4.5..4.5,color=green):

> a1;

[Maple Plot]

> a2:=plot(cos(t),t=-4.5..4.5,color=blue):

> a2;

[Maple Plot]

> with(plots);

Warning, the name changecoords has been redefined

[animate, animate3d, animatecurve, changecoords, co...
[animate, animate3d, animatecurve, changecoords, co...
[animate, animate3d, animatecurve, changecoords, co...
[animate, animate3d, animatecurve, changecoords, co...
[animate, animate3d, animatecurve, changecoords, co...
[animate, animate3d, animatecurve, changecoords, co...

> display(a1,a2);

[Maple Plot]

3-4Draw the pretty leaf

> w:=1+cos(t)/2: z:=t/6-sin(2*t)/12: x:=w*cos(z): y:=w*sin(z):

> plot([x,y,t=0..12*Pi],axes=none,scaling=constrained);

[Maple Plot]

3-5 Draw the graphs of the polynomials given by the binomial expansions

m := [x, binomial(100,k)*x^(100-k)*(1-x)^k, x = 0 ....

> restart;

> m:=[x,binomial(100,k)*x^(100-k)*(1-x)^k,x=0..1];

m := [x, binomial(100,k)*x^(100-k)*(1-x)^k, x = 0 ....

> plot({m$k=0..100},axes=none);

[Maple Plot]