apr19-maple.mw

> restart: with(plots): with(stats):

Warning, the name changecoords has been redefined

> f:= (mu,sigma) ->
        1/(sigma*sqrt(2*Pi))*exp( - (x-mu)^2/(2*sigma^2) );


F:= (mu,sigma) ->

        stats[statevalf,cdf,normald[mu,sigma]](x);

f := proc (mu, sigma) options operator, arrow; exp(-1/2*(x-mu)^2/sigma^2)/(sigma*sqrt(2*Pi)) end proc

F := proc (mu, sigma) options operator, arrow; stats[statevalf, cdf, normald[mu, sigma]](x) end proc

> tk:=2:

> # changing the standard deviation
xrange:= -8..8:

p1:= plot( f(0,1) , x=xrange, color=black, thickness=tk):

p2:= plot( f(0,2) , x=xrange, color=red, thickness=tk ):

p3:= plot( f(0,3) , x=xrange, color=green, thickness=tk ):

p4:= plot( f(0,4) , x=xrange, color=blue, thickness=tk ):

display(p1, p2, p3, p4);

[Plot]

> # changing the mean
xrange:= -4..6:

p1:= plot( f(0,1) , x=xrange, color=black, thickness=tk ):

p2:= plot( f(2,1) , x=xrange, color=red, thickness=tk ):

p3:= plot( f(4,1) , x=xrange, color=green, thickness=tk ):

display(p1, p2, p3);

[Plot]

> # see the pdf and cdf
xrange:= -3..3:

yrange:= 0..1:

p1:= plot( f(0,1), x=xrange, y=yrange, color=black, thickness=tk ):

P1:= plot( F(0,1), x=xrange, y=yrange, color=red, thickness=tk ):

display(p1);

display(p1, P1);

[Plot]

[Plot]

>