Adams Chapter 17
Adams Chapter 17
Ordinary
Differential Equations
''
, , In order to solve this differential equation you look
at it until the solution occurs to you.
''
, , Science is a differential equation. Religion is a
boundary condition.
d2x
m-2 = F(t).
dt
dm
- = km(t),
dt
Remark This method for solving the nonhomogeneous equation is called the method
of variation of parameters. It is completely general and extends to higher-order
equations in a reasonable way, but it can be computationally somewhat difficult. We
would not likely have been able to "guess" the form of the particular solution in the
above example, so we could not have used the method discussed earlier in this section
to solve this equation.
Maple Calculations
Maple has a dsolve routine for solving (some) differential equations and initial-value
problems. This routine takes as input a DE and, if desired, initial conditions for it. We
illustrate for the equation y" + 2y' + 5y = 25t + 20 (assuming that the independent
variable is t):
> DE := (D@@2)(y)(t)+2*D(y)(t)+5*y(t)=25*t+20;
DE:= D C2l (y)(t) + 2D(y)(t) + Sy(t) = 25t + 20
> dsolve(DE, y(t));
y(t) = e C -t) sin(2t) _C2 + e < -t) cos(2t) _CJ + 2 + St
Note Maple's use of _CI and _C2 for arbitrary constants. For an initial-value problem
we supply the DE and its initial conditions to dsolve as a single list or set argument
enclosed in square brackets or braces:
> dsolve( [DE, y(0)=3, D(y)(0)=-2), y(t));
y(t) = -3e ( -t) sin(2t) + e C -t) cos(2t) + 2 + St
You might think that this output indicates that y has been defined as a function oft and
you can find a decimal value for, say, y(l) by giving the input eval f(y( 1)). But
this won't work. In fact, the output of the dsolve is just an equation with left side the
symbol y (t ). We can, however, use this output to define y as a function oft as follows:
> y := unapply(op(2,%),t);
y := t -+ -3e ( -t) sin(2t) + e C -t) cos(2t) + 2 + St
The op(2,%) in the unapp 1 y command refers to the second operand of the previous
result (i.e., the right side of equation output from the dsolve). unapply(f,t)
converts an expression f to a function oft. To confirm:
> evalf(y( 1));
5.843372646
EXE R C I S ES 17 .6
Find general solutions for the nonhomogeneous equations in 14. Repeat Exercise 4 using the method of variation of
Exercises 1-12 by the method of undetermined coefficients. parameters.
1. y" + y' -2y =I 2. y" + y' -2y =X 15. Find a particular solution of the form y = Ax 2 for the Euler
equation x 2 y" + xy' - y = x 2 , and hence obtain the general
3. y" + y I -2y = e-x 4. y" + y' -2y = ex solution of this equation on the interval (0, oo).
16. For what values of r can the Euler equation
5. y" + 2y' + Sy = x2 6. y" + 4y = x2 x 2 y" + xy' - y = xr be solved by the method of Exercise
7. y" - y' - 6y = e- 2x 8. y" + 4y' + 4y = e-lx 15? Find a particular solution for each such r.
17. Try to guess the form of a particular solution for
9. y" + 2y' + 2y = ex sin x 10. y" + 2y' + 2y = e-x sinx x 2 y" + xy' - y = x, and hence obtain the general solution
for this equation on the interval (0, oo).
11. y" + y' = 4 + 2x + e-x 12. y" + 2y' + y = xe-x
13. Repeat Exercise 3 using the method of variation of
parameters.