First Order IVPs - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


ODE Steps for First Order IVPs

 

Overview

Examples

Overview

• 

This help page gives a few examples of using the command ODESteps to solve first order initial value problems.

• 

See Student[ODEs][ODESteps] for a general description of the command ODESteps and its calling sequence.

Examples

withStudent:-ODEs:

ivp1t2zt+1+zt2t1diffzt,t=0,z3=1

ivp1t2zt+1+zt2t1ⅆⅆtzt=0,z3=1

(1)

ODEStepsivp1

Let's solvet2zt+1+zt2t1ⅆⅆtzt=0,z3=1Highest derivative means the order of the ODE is1ⅆⅆtztSeparate variablesⅆⅆtztzt2zt+1=t2t1Integrate both sides with respect totⅆⅆtztzt2zt+1ⅆt=t2t1ⅆt+C1Evaluate integralzt22zt+lnzt+1=t22tlnt1+C1Use initial conditionz3=112+ln2=152ln2+C1Solve for_C1C1=7+2ln2Substitute_C1=7+2ln2into general solution and simplifyzt22zt+lnzt+1=t22tlnt1+7+2ln2Solution to the IVPzt22zt+lnzt+1=t22tlnt1+7+2ln2

(2)

ivp22xyx9x2+2yx+x2+1diffyx,x=0,y0=1

ivp22xyx9x2+2yx+x2+1ⅆⅆxyx=0,y0=1

(3)

ODEStepsivp2

Let's solve2xyx9x2+2yx+x2+1ⅆⅆxyx=0,y0=1Highest derivative means the order of the ODE is1ⅆⅆxyxCheck if ODE is exactODE is exact if the lhs is the total derivative of aC2functionⅆⅆxFx,yx=0Compute derivative of lhsxFx,y+yFx,yⅆⅆxyx=0Evaluate derivatives2x=2xCondition met, ODE is exactExact ODE implies solution will be of this formFx,y=C1,Mx,y=xFx,y,Nx,y=yFx,ySolve forFx,yby integratingMx,ywith respect toxFx,y=9x2+2xyⅆx+_F1yEvaluate integralFx,y=3x3+x2y+_F1yTake derivative ofFx,ywith respect toyNx,y=yFx,yCompute derivativex2+2y+1=x2+ⅆⅆy_F1yIsolate forⅆⅆy_F1yⅆⅆy_F1y=2y+1Solve for_F1y_F1y=y2+ySubstitute_F1yinto equation forFx,yFx,y=3x3+x2y+y2+ySubstituteFx,yinto the solution of the ODE3x3+x2y+y2+y=C1Solve foryxyx=x2212x4+12x3+2x2+4C1+12,yx=x2212+x4+12x3+2x2+4C1+12Use initial conditiony0=11=124C1+12Solution does not satisfy initial conditionUse initial conditiony0=11=12+4C1+12Solve for_C1C1=2Substitute_C1=2into general solution and simplifyyx=x2212+x4+12x3+2x2+92Solution to the IVPyx=x2212+x4+12x3+2x2+92

(4)

ivp3diffyx,xyxxexpx=0,ya=b

ivp3ⅆⅆxyxyxxⅇx=0,ya=b

(5)

ODEStepsivp3

Let's solveⅆⅆxyxyxxⅇx=0,ya=bHighest derivative means the order of the ODE is1ⅆⅆxyxIsolate the derivativeⅆⅆxyx=yx+xⅇxGroup terms withyxon the lhs of the ODE and the rest on the rhs of the ODEⅆⅆxyxyx=xⅇxThe ODE is linear; multiply by an integrating factorμxμxⅆⅆxyxyx=μxxⅇxAssume the lhs of the ODE is the total derivativeⅆⅆxμxyxμxⅆⅆxyxyx=ⅆⅆxμxyx+μxⅆⅆxyxIsolateⅆⅆxμxⅆⅆxμx=μxSolve to find the integrating factorμx=ⅇxIntegrate both sides with respect toxⅆⅆxμxyxⅆx=μxxⅇxⅆx+C1Evaluate the integral on the lhsμxyx=μxxⅇxⅆx+C1Solve foryxyx=μxxⅇxⅆx+C1μxSubstituteμx=ⅇxyx=ⅇxxⅇxⅆx+C1ⅇxEvaluate the integrals on the rhsyx=x22+C1ⅇxSimplifyyx=ⅇxx2+2C12Use initial conditionya=bb=ⅇaa2+2C12Solve for_C1C1=ⅇaa22b2ⅇaSubstitute_C1=ⅇaa22b2ⅇainto general solution and simplifyyx=ⅇxa2+2ⅇab+x22Solution to the IVPyx=ⅇxa2+2ⅇab+x22

(6)

See Also

diff

Int

Student

Student[ODEs]

Student[ODEs][ODESteps]