Please Scroll Down to See Forums Below
napsgear
genezapharmateuticals
domestic-supply
puritysourcelabs
UGL OZ
UGFREAK
napsgeargenezapharmateuticals domestic-supplypuritysourcelabsUGL OZUGFREAK

Does anyone know how to plot Fourier series coefficent expansions in Maple?

> periodic:= (x,a,b) -> x - (b-a)*floor((x-a)/(b-a));

> g:= x -> piecewise(x<0, Pi+x, x>0, Pi-x); plot(g(periodic(x,-Pi,Pi)), x=-5..7);

example3.gif


> f:= (x,N) -> (Pi/2)+(4/Pi)*sum(cos((2*k+1)*x)/(2*k+1)^2,k=0..N);

example4.gif


> plot([seq(f(x,n),n=0..3)],x=-5..7); # This draws the graph of the partial sums S_k (k=1,3,5,7) of the given Fourier series

example5.gif


What did you do to piss off Rnch this time?
 
> periodic:= (x,a,b) -> x - (b-a)*floor((x-a)/(b-a));

> g:= x -> piecewise(x<0, Pi+x, x>0, Pi-x); plot(g(periodic(x,-Pi,Pi)), x=-5..7);

> f:= (x,N) -> (Pi/2)+(4/Pi)*sum(cos((2*k+1)*x)/(2*k+1)^2,k=0..N);

> plot([seq(f(x,n),n=0..3)],x=-5..7); # This draws the graph of the partial sums S_k (k=1,3,5,7) of the given Fourier series

Jeez... he's right, too.

Any idea what commands I use to get a 3D animated plot for second order partial differential equations?



:cow:
 
> periodic:= (x,a,b) -> x - (b-a)*floor((x-a)/(b-a));

> g:= x -> piecewise(x<0, Pi+x, x>0, Pi-x); plot(g(periodic(x,-Pi,Pi)), x=-5..7);

example3.gif


> f:= (x,N) -> (Pi/2)+(4/Pi)*sum(cos((2*k+1)*x)/(2*k+1)^2,k=0..N);

example4.gif


> plot([seq(f(x,n),n=0..3)],x=-5..7); # This draws the graph of the partial sums S_k (k=1,3,5,7) of the given Fourier series

example5.gif

Holy hell!

I've always liked you P3, but damn your stock just skyrocketed!

No MO tho... that's where my extra 10% kicks-in. I'm still str8.8
 
Jeez... he's right, too.

Any idea what commands I use to get a 3D animated plot for second order partial differential equations?



:cow:

restart;
with(plots): with(DEtools):
window:=x=-6..6,y=-6..6:
trange:=-10..10:
dif1:= diff(x(t),t) = x(t) +y(t):
dif2:= diff(y(t),t) = 4*x(t) + y(t):
initial:={[x(0)=-2,y(0)=4.5],[x(0)=2,y(0)=-3],[x(0)=2,y(0)=-4.5],[x(0)=-2,y(0)=3]}:
phase:=DEplot([dif1,dif2],[x(t),y(t)], trange, initial, window, stepsize=0.1,linecolor=black):
iso_1:=plot(-x,x=-6..6,color=black,thickness=3):
iso_2:=plot(-4*x,x=-6..6,color=black,thickness=3):
display({phase,iso_1,iso_2});
 
restart;
with(plots): with(DEtools):
window:=x=-6..6,y=-6..6:
trange:=-10..10:
dif1:= diff(x(t),t) = x(t) +y(t):
dif2:= diff(y(t),t) = 4*x(t) + y(t):
initial:={[x(0)=-2,y(0)=4.5],[x(0)=2,y(0)=-3],[x(0)=2,y(0)=-4.5],[x(0)=-2,y(0)=3]}:
phase:=DEplot([dif1,dif2],[x(t),y(t)], trange, initial, window, stepsize=0.1,linecolor=black):
iso_1:=plot(-x,x=-6..6,color=black,thickness=3):
iso_2:=plot(-4*x,x=-6..6,color=black,thickness=3):
display({phase,iso_1,iso_2});


I tried that and it didn't give me an animated plot.

Like, if I wanted to graph the wave equation with given BCs and ICs and see how it moves...



:cow:
 
Top Bottom