{VERSION 3 0 "IBM INTEL NT" "3.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 }{CSTYLE "" -1 256 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 } {PSTYLE "Normal" -1 0 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 256 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }} {SECT 0 {EXCHG {PARA 256 "" 0 "" {TEXT 256 33 "Non-Autonomous Systems \+ Simulation" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 43 "Restart Maple and load the DEtools package." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart:" }} }{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 14 "with(DEtools):" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 38 "Define r. h.s. of the dynamical system." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "f:=y(t):g:=-k*y(t)-x(t)^3+B* cos(z):h:=1:" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 21 "Set parameter values." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "k:=0.1:B:=2:" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 30 "Define di fferential equations." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "de1:= diff(x(t),t)=f:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de2 := diff(y(t),t)=g:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de3 := diff(z(t),t)=h:" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 23 "and initi al conditions." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 19 "ics:=[[0,1,0,0]]: " }}}{EXCHG {PARA 0 "" 0 " " {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 21 "Plot the trajectories" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 96 "DEplot([de1,de2,de3],[x(t),y(t),z(t)],t=300..400,ics,stepsize= 0.05,scene=[x,y],linecolour=blue);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 126 "Repeat for other values of B. \+ Notice that sometimes we need to use more than one initial condition t o obtain an accurate plot." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 5 "B:=5:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 23 "de1:= diff(x(t),t) = f:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de2 := diff(y(t),t)=g:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de3 := diff(z(t),t)=h:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "ics:=[[0,1,0,0],[0,-1,0,0]]: " }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 102 "DEplot([de1,de2,de3],[x(t),y(t),z(t)],t=300.. 400,ics,stepsize=0.05,scene=[x,y],linecolour=[blue,red]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 5 "B:=9:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 23 "de1:= diff(x(t),t) = f:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de2 := diff(y(t),t)=g:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de3 := diff(z(t),t)=h:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "ics:=[[0,1,0,0],[0,-1,0,0]]: " }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 102 "DEplot([de1,de2,de3],[x(t),y(t),z(t)],t=300.. 400,ics,stepsize=0.05,scene=[x,y],linecolour=[blue,red]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 6 "B:=10:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 23 "de1:= diff(x(t),t) = f:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de2 := diff(y(t),t)=g:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "de3 := diff(z(t),t)=h:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "ics:=[[0,1,0,0],[0,-1,0,0]]: " }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 102 "DEplot([de1,de2,de3],[x(t),y(t),z(t)],t=300.. 400,ics,stepsize=0.05,scene=[x,y],linecolour=[blue,red]);" }}}}{MARK " 34" 0 }{VIEWOPTS 1 1 0 1 1 1803 }