<?xml version="1.0" encoding="UTF-8"?>
<Worksheet><Version major="6" minor="1"/><View-Properties><Zoom percentage="100"/></View-Properties><Styles><Layout alignment="centred" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="_pstyle259" rightmargin="0.0" spaceabove="0.0" spacebelow="0.0"/><Layout alignment="left" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="Heading 1" rightmargin="0.0" spaceabove="8.0" spacebelow="4.0"/><Layout alignment="centred" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="_pstyle262" rightmargin="0.0" spaceabove="0.0" spacebelow="0.0"/><Layout alignment="centred" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="_pstyle261" rightmargin="0.0" spaceabove="0.0" spacebelow="0.0"/><Layout alignment="centred" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="_pstyle260" rightmargin="0.0" spaceabove="0.0" spacebelow="0.0"/><Layout alignment="left" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="Normal" rightmargin="0.0" spaceabove="0.0" spacebelow="0.0"/><Layout alignment="centred" firstindent="0.0" leftmargin="0.0" linebreak="space" linespacing="0.0" name="Normal257" rightmargin="0.0" spaceabove="0.0" spacebelow="0.0"/><Font background="[0,0,0]" bold="true" executable="true" family="Monospaced" foreground="[255,0,0]" name="Maple Input"/><Font background="[0,0,0]" family="Times New Roman" name="2D Comment" underline="false"/><Font background="[0,0,0]" bold="false" family="Times New Roman" foreground="[0,128,128]" italic="false" name="Hyperlink" size="12" subscript="false" superscript="false" underline="true"/><Font background="[0,0,0]" bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="Normal257" readonly="false" size="12" underline="false"/><Font background="[0,0,0]" italic="true" name="_cstyle259"/><Font background="[0,0,0]" italic="true" name="_cstyle258"/><Font background="[0,0,0]" italic="true" name="_cstyle257"/><Font background="[0,0,0]" name="_cstyle256" underline="true"/><Font background="[0,0,0]" bold="true" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="Heading 1" readonly="false" size="18" underline="false"/><Font background="[0,0,0]" bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="_pstyle262" readonly="false" size="12" underline="false"/><Font background="[0,0,0]" bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="_pstyle261" readonly="false" size="12" underline="false"/><Font background="[0,0,0]" bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="_pstyle260" readonly="false" size="12" underline="false"/><Font background="[0,0,0]" bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="Normal" readonly="false" size="12" underline="false"/><Font background="[0,0,0]" italic="true" name="_cstyle265"/><Font background="[0,0,0]" italic="true" name="_cstyle264"/><Font background="[0,0,0]" family="Times New Roman" name="Page Number" underline="false"/><Font background="[0,0,0]" italic="true" name="_cstyle263"/><Font background="[0,0,0]" bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" name="_pstyle259" readonly="false" size="12" underline="false"/><Font background="[0,0,0]" italic="true" name="_cstyle262"/><Font background="[0,0,0]" italic="true" name="_cstyle261"/><Font background="[0,0,0]" italic="true" name="_cstyle260"/></Styles><Page-Numbers enabled="false" first-number="1" first-numbered-page="1" horizontal-location="right" style="Page Number" vertical-location="bottom"/><Group><Input><Text-field layout="Normal257" style="Normal257"/><Text-field layout="Normal257" style="Normal257">ORDINARY DIFFERENTIAL EQUATIONS POWERTOOL</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal257" style="Normal257">Lesson 4 -- First-Order Linear Equations</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal257" style="Hyperlink"><Hyperlink executable="false" hyperlink="true" linktarget="http://www.math.sc.edu/~meade/" style="Hyperlink">Prof. Douglas B. Meade</Hyperlink></Text-field><Text-field layout="Normal257" style="Hyperlink"><Hyperlink executable="false" hyperlink="true" linktarget="http://www.math.sc.edu/~IMI/" style="Hyperlink">Industrial Mathematics Institute</Hyperlink></Text-field><Text-field layout="Normal257" style="Hyperlink"><Hyperlink executable="false" hyperlink="true" linktarget="http://www.math.sc.edu/" style="Hyperlink">Department of Mathematics</Hyperlink></Text-field><Text-field layout="Normal257" style="Hyperlink"><Hyperlink executable="false" hyperlink="true" linktarget="http://www.sc.edu/" style="Hyperlink">University of South Carolina</Hyperlink></Text-field><Text-field layout="Normal257" style="Normal257">Columbia, SC 29208
</Text-field><Text-field layout="Normal257" style="Normal257">URL:   <Hyperlink executable="false" hyperlink="true" linktarget="http://www.math.sc.edu/~meade/" style="Hyperlink">http://www.math.sc.edu/~meade/</Hyperlink></Text-field><Text-field layout="Normal257" style="Normal257">E-mail: <Hyperlink executable="false" hyperlink="true" linktarget="mailto:meade@math.sc.edu" style="Hyperlink">meade@math.sc.edu</Hyperlink></Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal257" style="Normal257"><Font encoding="ISO8859-1">Copyright \251  2001  by Douglas B. Meade</Font></Text-field><Text-field layout="Normal257" style="Normal257">All rights reserved</Text-field><Text-field layout="Normal257" style="Normal257"/><Text-field layout="Normal257" style="Normal257">-------------------------------------------------------------------</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Section collapsed="true"><Title><Text-field layout="Heading 1" style="Heading 1">Outline of Lesson 4</Text-field></Title><Group><Input><Text-field layout="Normal" style="Normal"><Hyperlink executable="false" hyperlink="true" linktarget="Wks:#4.A" style="Hyperlink">4.A</Hyperlink> Structure of Solutiosn to Linear ODEs</Text-field><Text-field layout="Normal" style="Normal"><Hyperlink executable="false" hyperlink="true" linktarget="Wks:#4.B" style="Hyperlink">4.B</Hyperlink> Integrating Factor for a First-Order Linear ODE</Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group></Section><Section collapsed="true"><Title><Text-field layout="Heading 1" style="Heading 1">Initialization</Text-field></Title><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">restart;</Font></Text-field><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">with( DEtools ):</Font></Text-field><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">with( plots ):</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group></Section><Section collapsed="true"><Title><Text-field bookmark="4.A" layout="Heading 1" style="Heading 1">4.A Structure of Solutions to Linear ODEs</Text-field></Title><Group><Input><Text-field layout="Normal" style="Normal">The general <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle257" underline="false">first</Font>-<Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle258" underline="false">order</Font> <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle259" underline="false">linear</Font> ODE is</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">lin_ode := diff( x(t), t ) + p(t) * x(t) = f(t);</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The dependent function <Equation input-equation="x(t);" style="2D Comment">NiMtJSJ4RzYjJSJ0Rw==</Equation> and its first derivative, <Equation input-equation="dx/dt;" style="2D Comment">NiMqJiUjZHhHIiIiJSNkdEchIiI=</Equation>, appear linearly, that is, appear as a linear combination with variable coefficients.  Note that, in general, this is <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" italic="false" size="12" style="_cstyle256">not</Font> a separable ODE, as Maple shows via</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odeadvisor( lin_ode, [separable] );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">If <Equation input-equation="p(t)" style="2D Comment">NiMtJSJwRzYjJSJ0Rw==</Equation> and <Equation input-equation="f(t)" style="2D Comment">NiMtJSJmRzYjJSJ0Rw==</Equation> are both constants, then the ODE <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle260" underline="false">is</Font> separable, in which case the solution can be found as in <Hyperlink executable="false" hyperlink="true" linktarget="Wks:Lesson03.mw" style="Hyperlink">Lesson 3</Hyperlink>. </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">The constant-coefficient linear equation</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">lin_ode_const := subs( p(t)=a, f(t)=b, lin_ode );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">is verified separable by Maple via</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odeadvisor( lin_ode_const, [separable] );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">Maple's solution process can be seen with</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">infolevel[dsolve] := 3:</Font></Text-field><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">lin_ode_const_soln := dsolve( lin_ode_const, x(t) );</Font></Text-field><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">infolevel[dsolve] := 0:</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The structure of this solution is important. The term involving the constant of integration, that is, the term</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">soln_h := x(t) = coeff(rhs(lin_ode_const_soln),_C1);</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">is a solution of the homogenous ODE (i.e., <Equation input-equation="b=0" style="2D Comment">NiMvJSJiRyIiIQ==</Equation>).  This is verified via</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odetest( soln_h, subs( b=0, lin_ode_const ) );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The constant term, namely,</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">soln_p := x(t) = subs( _C1=0, rhs(lin_ode_const_soln) );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">is a solution to the non-homogeneous ODE, as is seen via</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odetest( soln_p, lin_ode_const );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">Any solution that satisfies the full ODE is called a <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle261" underline="false">particular</Font> <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle262" underline="false">solution</Font>. It is a general property of linear equations that the general solution can be written as the sum of the general solution to the homogeneous equation and any (particular)  solution to the non-homogeneous equation. This structure will appear again when linear equations of higher-order, and linear systems of first-order ODEs are studied.</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group></Section><Section collapsed="true"><Title><Text-field bookmark="4.B" layout="Heading 1" style="Heading 1">4.B Integrating Factor for a First-Order Linear ODE</Text-field></Title><Group><Input><Text-field layout="Normal" style="Normal">Knowledge of the structure of solutions to linear ODEs is important, but does not provide too much information about finding solutions to the general first-order linear ODE</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="_pstyle259" style="_pstyle259"><Equation input-equation="dx/dt+p(t)*x(t) = f(t);" style="2D Comment">NiMvLCYqJiUjZHhHIiIiJSNkdEchIiJGJyomLSUicEc2IyUidEdGJy0lInhHRi1GJ0YnLSUiZkdGLQ==</Equation> </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">A procedure for solving the first-order linear ODE consists of finding an <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle263" underline="false">integrating</Font> <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle264" underline="false">factor</Font>, <Equation input-equation="mu(t)" style="2D Comment">NiMtJSNtdUc2IyUidEc=</Equation>, for the ODE. An integrating factor is a function <Equation input-equation="mu(t)" style="2D Comment">NiMtJSNtdUc2IyUidEc=</Equation> that, upon multiplication against the left-hand side of the equation, renders the product an exact derivative.  Thus, the integrating factor <Equation input-equation="mu(t);" style="2D Comment">NiMtJSNtdUc2IyUidEc=</Equation> is characterized by the property that</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="_pstyle260" style="_pstyle260"><Equation input-equation="(`x'`(t)+p(t)*x(t))*mu(t) = d/dt;" style="2D Comment">NiMvKiYsJi0lI3gnRzYjJSJ0RyIiIiomLSUicEdGKEYqLSUieEdGKEYqRipGKi0lI211R0YoRioqJiUiZEdGKiUjZHRHISIi</Equation> <Equation input-equation="``(mu(t)*x(t));" style="2D Comment">NiMtJSFHNiMqJi0lI211RzYjJSJ0RyIiIi0lInhHRilGKw==</Equation> </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">In other words, <Equation input-equation="mu(t);" style="2D Comment">NiMtJSNtdUc2IyUidEc=</Equation> is a factor that allows the left-hand side of the ODE to be written as the derivative of the product <Equation input-equation="mu(t)*x(t);" style="2D Comment">NiMqJi0lI211RzYjJSJ0RyIiIi0lInhHRiZGKA==</Equation>. </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">The general formula for the integrating factor for the first-order linear ODE is</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal257" style="Normal257"> <Equation input-equation="mu(t) = exp( int( p(t), t ) )" style="2D Comment">NiMvLSUjbXVHNiMlInRHLSUkZXhwRzYjLSUkaW50RzYkLSUicEdGJkYn</Equation>.</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">Multiplication of the ODE by this factor leads to an equation of the form</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal257" style="Normal257"><Equation input-equation="diff( X(t), t ) = F(t)" style="2D Comment">NiMvLSUlZGlmZkc2JC0lIlhHNiMlInRHRiotJSJGR0Yp</Equation> </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">where <Equation input-equation="X(t) = mu(t)*x(t)" style="2D Comment">NiMvLSUiWEc2IyUidEcqJi0lI211R0YmIiIiLSUieEdGJkYr</Equation> and <Equation input-equation="F(t) = mu(t)*f(t)" style="2D Comment">NiMvLSUiRkc2IyUidEcqJi0lI211R0YmIiIiLSUiZkdGJkYr</Equation>. The explicit general solution of this equation can be found by direct integration to be</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal257" style="Normal257"><Equation input-equation="X(t)" style="2D Comment">NiMtJSJYRzYjJSJ0Rw==</Equation> = <Equation input-equation="Int( diff(X(t), t ), t )" style="2D Comment">NiMtJSRJbnRHNiQtJSVkaWZmRzYkLSUiWEc2IyUidEdGLEYs</Equation> = <Equation input-equation="Int( F(t), t ) + C" style="2D Comment">NiMsJi0lJEludEc2JC0lIkZHNiMlInRHRioiIiIlIkNHRis=</Equation>.</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">Thus, </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="_pstyle261" style="_pstyle261"><Equation input-equation="x(t)*mu(t) = int(f(t)*mu(t),t)+C;" style="2D Comment">NiMvKiYtJSJ4RzYjJSJ0RyIiIi0lI211R0YnRiksJi0lJGludEc2JComLSUiZkdGJ0YpRipGKUYoRiklIkNHRik=</Equation> </Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">and the solution to the original ODE is found using</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="_pstyle262" style="_pstyle262"> <Equation input-equation="x(t) = X(t)/mu(t)" style="2D Comment">NiMvLSUieEc2IyUidEcqJi0lIlhHRiYiIiItJSNtdUdGJiEiIg==</Equation> = <Equation input-equation="(int(f(t)*mu(t),t)+C)/mu(t);" style="2D Comment">NiMqJiwmLSUkaW50RzYkKiYtJSJmRzYjJSJ0RyIiIi0lI211R0YrRi1GLEYtJSJDR0YtRi1GLiEiIg==</Equation> = <Equation input-equation="exp(-int(p,t))*int(f(t)*exp(int(p,t)),t)+C*exp(-int(p,t));" style="2D Comment">NiMsJiomLSUkZXhwRzYjLCQtJSRpbnRHNiQlInBHJSJ0RyEiIiIiIi1GKjYkKiYtJSJmRzYjRi1GLy1GJjYjRilGL0YtRi9GLyomJSJDR0YvRiVGL0Yv</Equation></Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">Instead of focusing on the general formula, implement the solution <Font bold="false" executable="false" family="Times New Roman" foreground="[0,0,0]" size="12" style="_cstyle265" underline="false">process</Font> for each specific problem.</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">For example, consider the specific first-order linear ODE</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">lin_ode1 := diff( x(t), t ) + x(t)/(t+1) = ln(t)/(t+1);</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">In this problem, <Equation input-equation="p(t)=1/(t+1)" style="2D Comment">NiMvLSUicEc2IyUidEcqJiIiIkYpLCZGJ0YpRilGKSEiIg==</Equation> and <Equation input-equation="f(t) = ln(t)/(t+1)" style="2D Comment">NiMvLSUiZkc2IyUidEcqJi0lI2xuR0YmIiIiLCZGJ0YrRitGKyEiIg==</Equation>. Thus, the integrating factor is</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">int_fact := mu(t) = exp( Int( 1/(t+1), t ) );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">which evaluates to</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">int_fact1 := value( int_fact );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The <Hyperlink executable="false" hyperlink="true" linktarget="Help:DEtools" style="Hyperlink">DEtools</Hyperlink> package contains <Hyperlink executable="false" hyperlink="true" linktarget="Help:DEtools,intfactor" style="Hyperlink">intfactor</Hyperlink>, a procedure that will find an integrating factor for problems of this type.  It gives</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">intfactor( lin_ode1 );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">which is exactly what was obtained above.</Text-field><Text-field layout="Normal" style="Normal"/><Text-field layout="Normal" style="Normal">Multiplication of the ODE by this integrating factor yields</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">ode2 := subs( int_fact1, mu(t)*lin_ode1 );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">While this equation is rather complicated, the definition of the integrating factor allows us to replace the left-hand side with the single derivative</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">ode3 := subs( int_fact1, Diff( mu(t)*x(t), t ) ) = rhs(ode2);</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">Maple cannot make this transformation in the "forward" direction, but can verify it "in reverse."  Simply evaluate the derivative on the left to obtain</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">expand(convert(ode3,diff));</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">which compares favorably with </Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">simplify(ode2);</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The equation </Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">ode3;</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">can be solved by direct integration, that is, by antidifferentiation of both sides.  The result is</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">int_ode3 := map(Int, ode3, t );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The left-hand side is trivial to evaluate, and Maple does a fine job with the right-hand side.  After evaluating these indefinite integrals and adding the constant of integration, the result is</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">q1 := subs( int_fact1, mu(t)*x(t) ) = int( rhs(ode3), t ) + C;</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">The explicit general solution to the given first-order linear ODE is therefore</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">expl_soln := op(solve( q1, {x(t)} ));</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">That this solution satisfies the original differential equation is confirmed with</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odetest( expl_soln, lin_ode1 );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">To emphasize the structure of this solution, the homogeneous and particular solutions are respectively</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">soln_h := x(t) = coeff( rhs(expl_soln), C );</Font></Text-field><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">soln_p := x(t) = subs( C=0, rhs(expl_soln));</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Group><Input><Text-field layout="Normal" style="Normal">as confirmed by</Text-field><Text-field layout="Normal" style="Normal"/></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odetest( soln_h, lhs(lin_ode1)=0 );</Font></Text-field><Text-field layout="Normal" prompt="&gt; " style="Maple Input"><Font italic="false" size="12" underline="false">odetest( soln_p, lin_ode1 );</Font></Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group></Section><Group><Input><Text-field layout="Normal" style="Normal">[Back to <Hyperlink executable="false" hyperlink="true" linktarget="Wks:Lesson00.mw" style="Hyperlink">ODE Powertool Table of Contents</Hyperlink>]</Text-field></Input></Group><Group><Input><Text-field layout="Normal" prompt="&gt; " style="Maple Input"/></Input></Group><Text-field/><Text-field/><Text-field/><Text-field/><Text-field/></Worksheet>