{VERSION 5 0 "IBM INTEL NT" "5.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 1 }{CSTYLE "2D Math" -1 2 "Times" 0 1 0 0 0 0 0 0 2 0 0 0 0 0 0 1 }{CSTYLE "2D Output" 2 20 "" 0 1 0 0 255 1 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 256 "" 0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 0 }{PSTYLE "Normal " -1 0 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "Maple Output" -1 11 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 3 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "Maple Output" -1 12 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 3 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "Maple Plot" -1 13 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "Title" -1 18 1 {CSTYLE "" -1 -1 "Times" 1 18 0 0 0 1 2 1 1 2 2 2 1 1 1 1 }3 1 0 0 12 12 1 0 1 0 2 2 19 1 }{PSTYLE "Author" -1 19 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 8 8 1 0 1 0 2 2 0 1 }} {SECT 0 {EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 18 "" 0 "" {TEXT -1 43 "Solving Second Order Differential Equations" }}{PARA 19 "" 0 " " {TEXT -1 8 "Math 308" }}{PARA 0 "" 0 "" {TEXT -1 187 "This Maple ses sion contains examples that show how to solve certain second order con stant coefficient differential equations in Maple. Also, at the end, \+ the \"subs\" command is introduced." }}{PARA 0 "" 0 "" {TEXT -1 0 "" } }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 40 "First, we solve the homogeneous \+ equation" }}{PARA 0 "" 0 "" {TEXT -1 22 " y'' + 2y' + 5y = 0." }} {PARA 0 "" 0 "" {TEXT -1 30 "We'll call the equation \"eq1\":" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 52 "eq1 := diff(y(t),t,t) + 2*di ff(y(t),t) + 5*y(t) = 0;" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%$eq1G/,( -%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\"\"#\"\"\"*&F1F2-F(6$F*F-F2F2*&\"\"& F2F*F2F2\"\"!" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 283 "We use the \"ds olve\" command to solve the differential equation. In its basic form, this command takes two arguments. The first is the differential equa tion, and the second is the function to be found. We'll use the \"rhs \" command to save the actual solution in the variable \"sol1\":" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "sol1 := rhs(dsolve(eq1,y(t)) );" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%%sol1G,&*(%$_C1G\"\"\"-%$expG6 #,$%\"tG!\"\"F(-%$sinG6#,$F-\"\"#F(F(*(%$_C2GF(F)F(-%$cosGF1F(F(" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 66 "The two expressions _C1 and _C2 ar e Maple's \"arbitrary constants\"." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 96 "That was easy enough. How do we specify \+ initial conditions? Consider the initial value problem" }}{PARA 0 "" 0 "" {TEXT -1 41 " y'' + 2y' + 5y = 0, y(0)=3, y'(0)=-5." }}{PARA 0 "" 0 "" {TEXT -1 321 "We use the \"dsolve\" command again, but we no w make a list of the equation and the initial conditions. The first i nitial condition, y(0) =3, is written in Maple just as it is here. Ho wever, to enter the initial value of y', we can not simply write y'(0) =-5. The single quote ' has a special meaning in Maple, and it is " } {TEXT 256 3 "not" }{TEXT -1 381 " a derivative. Instead, we use the \+ \"D\" operator. The operator \"D\" is another way to specify the deri vative of a function. The derivative y'(t) can be expressed in Maple \+ as D(y)(t). \"D(y)\" means \"the derivative of y\", so \"D(y)(t)\" me ans \"the derivative of y evaluated at t\". To specify the initial co ndition y'(0)=-5, we use \"D(y)(0)=-5\". We use this in the following command:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 53 "sol1ivp := rhs (dsolve(\{eq1,y(0)=3,D(y)(0)=-5\},y(t)));" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%(sol1ivpG,&*&-%$expG6#,$%\"tG!\"\"\"\"\"-%$sinG6#,$F+ \"\"#F-F,*(\"\"$F-F'F--%$cosGF0F-F-" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 215 "Note that the first argument to \"dsolve\" is a list of three \+ elements: \{eq1,y(0)=3,D(y)(0)=-5\}. This is the initial value proble m to be solved. As before, the second argument is just y(t), the func tion to be found." }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 18 "Plot the sol ution." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 39 "plot(sol1ivp,t=-1 ..6,labels=[\"t\",\"y\"]);" }}{PARA 13 "" 1 "" {GLPLOT2D 316 208 208 {PLOTDATA 2 "6%-%'CURVESG6$7_p7$$!\"\"\"\"!$!3h?il#zk)=#*!#=7$$!3)omT5 !\\F4)*F-$!3Y+!*[axYSeF-7$$!3xLL3-)\\&='*F-$!3[[2&e!=4yDF-7$$!3l+]7.Z# yU*F-$\"3oau.;M%ym&!#>7$$!3Umm;/'*4P#*F-$\"33611sp%Hf$F-7$$!3?K$3_]uj/ *F-$\"3-2mC8'R%*\\'F-7$$!33***\\iS\\c&))F-$\"3MkqF:^b&G*F-7$$!3'fm\"H2 V#\\m)F-$\"3+006eF3&>\"!#<7$$!3%GLL$3#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" 1 2 0 1 10 0 2 9 1 4 2 1.000000 45.000000 45.000000 0 0 "Curve 1" } }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 39 "Now let's try a nonhomogeneous \+ example:" }}{PARA 0 "" 0 "" {TEXT -1 29 " y'' + 2y' + 5y = 3sin(2t). " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 61 "eq2 := diff(y(t),t,t) + 2*diff(y(t),t) + 5*y(t) = 3*sin(2*t);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%$eq2G/,(-%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\"\"#\"\"\"*&F1F2-F(6 $F*F-F2F2*&\"\"&F2F*F2F2,$-%$sinG6#,$F-F1\"\"$" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 42 "Use \"dsolve\" to find the general solution." }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "sol2 := dsolve(eq2,y(t));" } }{PARA 11 "" 1 "" {XPPMATH 20 "6#>%%sol2G/-%\"yG6#%\"tG,**(-%$expG6#,$ F)!\"\"\"\"\"-%$sinG6#,$F)\"\"#F1%$_C2GF1F1*(F,F1-%$cosGF4F1%$_C1GF1F1 *&#\"\"$\"# " 0 "" {MPLTEXT 1 0 53 "sol2ivp := rhs(dsolve(\{eq2,y(0)=3,D(y)(0)=-5\},y(t)));" }} {PARA 11 "" 1 "" {XPPMATH 20 "6#>%(sol2ivpG,**&-%$expG6#,$%\"tG!\"\"\" \"\"-%$sinG6#,$F+\"\"#F-#!#9\"#<*(#\"#jF5F-F'F--%$cosGF0F-F-*&#\"\"$F5 F-F.F-F-*&#\"#7F5F-F9F-F," }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "plot(sol2ivp,t=0..15);" }}{PARA 13 "" 1 "" {GLPLOT2D 323 212 212 {PLOTDATA 2 "6%-%'CURVESG6$7ct7$$\"\"!F)$\"\"$F)7$$\"3%)***\\iSmp3%!#> $\"3Uqq'og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cJ.1f8Fe[m $\"35&4nl^k@\"[F;7$$\"39+]i&3ucP\"Fe[m$\"3***Q^xPU\"HjF;7$$\"33](oa&Q5 $Q\"Fe[m$\"37@@0y)z2z'F;7$$\"3-+DJDO`!R\"Fe[m$\"3-vg'zw[F5(F;7$$\"3!\\ PM-^[UR\"Fe[m$\"3T()H1Y_K+sF;7$$\"3'*\\i:&RjzR\"Fe[m$\"3cTU')HJ " 0 "" {MPLTEXT 1 0 62 "eq3 := diff(y (t),t,t) + diff(y(t),t) + 2*y(t) = t^2*cos(4*t); " }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%$eq3G/,(-%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\"\"#\"\"\"- F(6$F*F-F2*&F1F2F*F2F2*&)F-F1F2-%$cosG6#,$F-\"\"%F2" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "sol3 := rhs(dsolve(eq3,y(t)));" }}{PARA 12 "" 1 "" {XPPMATH 20 "6#>%%sol3G,**(-%$expG6#,$%\"tG#!\"\"\"\"#\"\" \"-%$sinG6#,$*&-%%sqrtG6#\"\"(F/F+F/#F/F.F/%$_C2GF/F/*(F'F/-%$cosGF2F/ %$_C1GF/F/*(#F/\"'3bfF/,(F+\"&G6%\"&14\"F-*&\"&O7\"F/)F+F.F/F/F/-F16#, $F+\"\"%F/F/*(F@F/-F=FIF/,(F+\"&u*=*&\"&E$RF/FGF/F-\"&Bh\"F/F/F/" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 166 "Look carefully at the above solut ion; you should be able to determine which terms are part of the homog eneous solution, and which are part of the particular solution." }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 93 "Let's solve the problem with initi al conditions y(0)=0 and y'(0)=0, and then plot the result." }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 52 "sol3ivp := rhs(dsolve(\{eq3, y(0)=0,D(y)(0)=0\},y(t)));" }}{PARA 12 "" 1 "" {XPPMATH 20 "6#>%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$$\"37]7.[_\\Y 6F^em$\"3fHBA#>ZUg&FB7$$\"3/++v@Rm\\6F^em$\"3)H%)>&GQ3okFB7$$\"3)***\\ (=dHd:\"F^em$\"3+ha(fwRk%yFB7$$\"3%******>A&zh6F^em$\"3of'yBVG.z)FB7$$ \"3-+D1Z!G[;\"F^em$\"3'f]dY]:z2*FB7$$\"33+]7s3'y;\"F^em$\"38Ds*=**oXB* FB7$$\"37]il%Gx$p6F^em$\"3)3w(G4\\ci#*FB7$$\"39+v=(p$*3<\"F^em$\"39(\\ h]x#fc#*FB7$$\"3+](=(4,Ts6F^em$\"3rN7Rwm\\;#*FB7$$\"3/++DAl#R<\"F^em$ \"30v8*G.YA9*FB7$$\"3)**\\(o\"*[W!=\"F^em$\"3DOJ_Jr*)Q%)FB7$$\"35+]7hK 'p=\"F^em$\"3v)=/Y'\\fVrFB7$$\"3;]P%eWA->\"F^em$\"35fvvmd(fH'FB7$$\"31 +DcI;[$>\"F^em$\"3TKZF!HS;L&FB7$$\"3%*\\7G:3u'>\"F^em$\"3++U'\\;hdE%FB 7$$\"#7F)$\"3)oMX[(eT:JFB-%'COLOURG6&%$RGBG$\"#5!\"\"F(F(-%+AXESLABELS G6$Q\"t6\"Q!F`fn-%%VIEWG6$;F(Faen%(DEFAULTG" 1 2 0 1 10 0 2 9 1 4 2 1.000000 45.000000 45.000000 0 0 "Curve 1" }}}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 63 "Maple can solve differential equations that contain param eters:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 49 "eq4 := diff(y(t), t,t)+ 4*diff(y(t),t)+k*y(t) = 0;" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>% $eq4G/,(-%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\"\"#\"\"\"*&\"\"%F2-F(6$F*F- F2F2*&%\"kGF2F*F2F2\"\"!" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "sol4 := rhs(dsolve(eq4,y(t)));" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%% sol4G,&*&%$_C1G\"\"\"-%$expG6#*&,&!\"#F(*$-%%sqrtG6#,&%\"kG!\"\"\"\"%F (F(F(F(%\"tGF(F(F(*&%$_C2GF(-F*6#*&,&F.F(F/F5F(F7F(F(F(" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 413 "Note, however, that Maple has only given the solution that we expect when k < 4. If k=4, then Maple's solutio n is not complete (it is missing the term t*exp(-2t)), and if k < 4, M aple's answer will become complex-valued (and we want real-valued solu tions). If Maple knows the numerical value of k, it will give the cor rect form of the answer. To show this, I'll first introduce a useful \+ function called \"subs\"." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT -1 138 "The \"subs\" command (short for \"substitute\") a llows you to replace variables in an expression with other variables o r values. For example:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 28 " p := x^3+4*x^2-x*y + y^2 +1;" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%\"pG ,,*$)%\"xG\"\"$\"\"\"F**&\"\"%F*)F(\"\"#F*F**&F(F*%\"yGF*!\"\"*$)F0F.F *F*F*F*" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 80 "To find the value of t his expression when x=3, we can use the following command:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "subs(x=3,p);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#,(\"#k\"\"\"*&\"\"$F%%\"yGF%!\"\"*$)F(\"\"#F%F%" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 188 "The last argument of \"subs\" is \+ the expression in which to make the substitutions. The other argument s have the form variable=value. More than one subsitution can be give n in the command:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 16 "subs(x =3,y=5,p);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#\"#u" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 102 "Now we'll use the \"subs\" command to create cop ies of eq4 with several different numerical values of k." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "eq4a := subs(k=1,eq4);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%%eq4aG/,(-%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\" \"#\"\"\"*&\"\"%F2-F(6$F*F-F2F2F*F2\"\"!" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 18 "dsolve(eq4a,y(t));" }}{PARA 11 "" 1 "" {XPPMATH 20 "6 #/-%\"yG6#%\"tG,&*&%$_C1G\"\"\"-%$expG6#*&,&!\"#F+*$-%%sqrtG6#\"\"$F+F +F+F'F+F+F+*&%$_C2GF+-F-6#,$*&,&\"\"#F+F2F+F+F'F+!\"\"F+F+" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "eq4b := subs(k=4,eq4);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%%eq4bG/,(-%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\" \"#\"\"\"*&\"\"%F2-F(6$F*F-F2F2*&F4F2F*F2F2\"\"!" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 18 "dsolve(eq4b,y(t));" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#/-%\"yG6#%\"tG,&*&%$_C1G\"\"\"-%$expG6#,$F'!\"#F+F+*(%$ _C2GF+F,F+F'F+F+" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 47 "Notice that M aple gave the correct answer here." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 22 "eq4c := subs(k=8,eq4);" }}{PARA 11 "" 1 "" {XPPMATH 20 "6#>%%eq4cG/,(-%%diffG6$-%\"yG6#%\"tG-%\"$G6$F-\"\"#\"\"\"*&\"\"%F2 -F(6$F*F-F2F2*&\"\")F2F*F2F2\"\"!" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 18 "dsolve(eq4c,y(t));" }}{PARA 11 "" 1 "" {XPPMATH 20 "6 #/-%\"yG6#%\"tG,&*(%$_C1G\"\"\"-%$expG6#,$F'!\"#F+-%$sinG6#,$F'\"\"#F+ F+*(%$_C2GF+F,F+-%$cosGF3F+F+" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 51 " And here it gave the correct, real-valued solution." }}}}{MARK "9 1 0 " 2 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }