Nonhomogeneous linear equations

  • 289 views
Uploaded on

 

More in: Education , Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
289
On Slideshare
0
From Embeds
0
Number of Embeds
0

Actions

Shares
Downloads
11
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Nonhomogeneous Linear Equations In this section we learn how to solve second-order nonhomogeneous linear differential equations with constant coefficients, that is, equations of the form 1 ayЉ ϩ byЈ ϩ cy ෇ G͑x͒ where a, b, and c are constants and G is a continuous function. The related homogeneous equation 2 ayЉ ϩ byЈ ϩ cy ෇ 0 is called the complementary equation and plays an important role in the solution of the original nonhomogeneous equation (1). 3 Theorem The general solution of the nonhomogeneous differential equation (1) can be written as y͑x͒ ෇ yp͑x͒ ϩ yc͑x͒ where yp is a particular solution of Equation 1 and yc is the general solution of the complementary Equation 2. Proof All we have to do is verify that if y is any solution of Equation 1, then y Ϫ yp is a solution of the complementary Equation 2. Indeed a͑y Ϫ yp ͒Љ ϩ b͑y Ϫ yp ͒Ј ϩ c͑y Ϫ yp ͒ ෇ ayЉ Ϫ aypЉ ϩ byЈ Ϫ byp ϩ cy Ϫ cyp Ј ෇ ͑ayЉ ϩ byЈ ϩ cy͒ Ϫ ͑aypЉ ϩ byЈ ϩ cyp ͒ p ෇ t͑x͒ Ϫ t͑x͒ ෇ 0 We know from Additional Topics: Second-Order Linear Differential Equations how to solve the complementary equation. (Recall that the solution is yc ෇ c1 y1 ϩ c2 y2 , where y1 and y2 are linearly independent solutions of Equation 2.) Therefore, Theorem 3 says that we know the general solution of the nonhomogeneous equation as soon as we know a particular solution yp . There are two methods for finding a particular solution: The method of undetermined coefficients is straightforward but works only for a restricted class of functions G. The method of variation of parameters works for every function G but i0s usually more difficult to apply in practice. The Method of Undetermined Coefficients We first illustrate the method of undetermined coefficients for the equation ayЉ ϩ byЈ ϩ cy ෇ G͑x͒ where G͑x) is a polynomial. It is reasonable to guess that there is a particular solution yp that is a polynomial of the same degree as G because if y is a polynomial, then ayЉ ϩ byЈ ϩ cy is also a polynomial. We therefore substitute yp͑x͒ ෇ a polynomial (of the same degree as G ) into the differential equation and determine the coefficients. EXAMPLE 1 Solve the equation yЉ ϩ yЈ Ϫ 2y ෇ x 2. SOLUTION The auxiliary equation of yЉ ϩ yЈ Ϫ 2y ෇ 0 is r 2 ϩ r Ϫ 2 ෇ ͑r Ϫ 1͒͑r ϩ 2͒ ෇ 0 1
  • 2. 2 ■ NONHOMOGENEOUS LINEAR EQUATIONS with roots r ෇ 1, Ϫ2. So the solution of the complementary equation is yc ෇ c1 e x ϩ c2 eϪ2x Since G͑x͒ ෇ x 2 is a polynomial of degree 2, we seek a particular solution of the form yp͑x͒ ෇ Ax 2 ϩ Bx ϩ C Then yp ෇ 2Ax ϩ B and ypЉ ෇ 2A so, substituting into the given differential equation, we Ј have ͑2A͒ ϩ ͑2Ax ϩ B͒ Ϫ 2͑Ax 2 ϩ Bx ϩ C͒ ෇ x 2 or Ϫ2Ax 2 ϩ ͑2A Ϫ 2B͒x ϩ ͑2A ϩ B Ϫ 2C͒ ෇ x 2 Polynomials are equal when their coefficients are equal. Thus Figure 1 shows four solutions of the differential equation in Example 1 in terms of the particular solution yp and the functions f ͑x͒ ෇ e x and t͑x͒ ෇ eϪ2 x. ■ ■ 8 2A Ϫ 2B ෇ 0 2A ϩ B Ϫ 2C ෇ 0 The solution of this system of equations is A ෇ Ϫ1 2 yp+2f+3g yp+3g Ϫ2A ෇ 1 B ෇ Ϫ1 2 C ෇ Ϫ3 4 A particular solution is therefore yp+2f _3 3 yp͑x͒ ෇ Ϫ 1 x 2 Ϫ 1 x Ϫ 3 2 2 4 yp and, by Theorem 3, the general solution is _5 y ෇ yc ϩ yp ෇ c1 e x ϩ c2 eϪ2x Ϫ 1 x 2 Ϫ 1 x Ϫ 3 2 2 4 FIGURE 1 If G͑x͒ (the right side of Equation 1) is of the form Ce k x, where C and k are constants, then we take as a trial solution a function of the same form, yp͑x͒ ෇ Ae k x, because the derivatives of e k x are constant multiples of e k x. EXAMPLE 2 Solve yЉ ϩ 4y ෇ e 3x. SOLUTION The auxiliary equation is r 2 ϩ 4 ෇ 0 with roots Ϯ2i, so the solution of the Figure 2 shows solutions of the differential equation in Example 2 in terms of yp and the functions f ͑x͒ ෇ cos 2x and t͑x͒ ෇ sin 2x. Notice that all solutions approach ϱ as x l ϱ and all solutions resemble sine functions when x is negative. ■ ■ 4 complementary equation is yc͑x͒ ෇ c1 cos 2x ϩ c2 sin 2x For a particular solution we try yp͑x͒ ෇ Ae 3x. Then yp ෇ 3Ae 3x and ypЉ ෇ 9Ae 3x. SubstiЈ tuting into the differential equation, we have 9Ae 3x ϩ 4͑Ae 3x ͒ ෇ e 3x yp+f+g yp+g yp _4 yp+f _2 FIGURE 2 1 so 13Ae 3x ෇ e 3x and A ෇ 13 . Thus, a particular solution is 2 1 yp͑x͒ ෇ 13 e 3x and the general solution is 1 y͑x͒ ෇ c1 cos 2x ϩ c2 sin 2x ϩ 13 e 3x If G͑x͒ is either C cos kx or C sin kx, then, because of the rules for differentiating the sine and cosine functions, we take as a trial particular solution a function of the form yp͑x͒ ෇ A cos kx ϩ B sin kx
  • 3. NONHOMOGENEOUS LINEAR EQUATIONS ■ 3 EXAMPLE 3 Solve yЉ ϩ yЈ Ϫ 2y ෇ sin x. SOLUTION We try a particular solution yp͑x͒ ෇ A cos x ϩ B sin x yp ෇ ϪA sin x ϩ B cos x Ј Then ypЉ ෇ ϪA cos x Ϫ B sin x so substitution in the differential equation gives ͑ϪA cos x Ϫ B sin x͒ ϩ ͑ϪA sin x ϩ B cos x͒ Ϫ 2͑A cos x ϩ B sin x͒ ෇ sin x ͑Ϫ3A ϩ B͒ cos x ϩ ͑ϪA Ϫ 3B͒ sin x ෇ sin x or This is true if Ϫ3A ϩ B ෇ 0 and ϪA Ϫ 3B ෇ 1 The solution of this system is 1 A ෇ Ϫ 10 3 B ෇ Ϫ 10 so a particular solution is 1 3 yp͑x͒ ෇ Ϫ 10 cos x Ϫ 10 sin x In Example 1 we determined that the solution of the complementary equation is yc ෇ c1 e x ϩ c2 eϪ2x. Thus, the general solution of the given equation is 1 y͑x͒ ෇ c1 e x ϩ c2 eϪ2x Ϫ 10 ͑cos x ϩ 3 sin x͒ If G͑x͒ is a product of functions of the preceding types, then we take the trial solution to be a product of functions of the same type. For instance, in solving the differential equation yЉ ϩ 2yЈ ϩ 4y ෇ x cos 3x we would try yp͑x͒ ෇ ͑Ax ϩ B͒ cos 3x ϩ ͑Cx ϩ D͒ sin 3x If G͑x͒ is a sum of functions of these types, we use the easily verified principle of superposition, which says that if yp1 and yp2 are solutions of ayЉ ϩ byЈ ϩ cy ෇ G1͑x͒ ayЉ ϩ byЈ ϩ cy ෇ G2͑x͒ respectively, then yp1 ϩ yp2 is a solution of ayЉ ϩ byЈ ϩ cy ෇ G1͑x͒ ϩ G2͑x͒ EXAMPLE 4 Solve yЉ Ϫ 4y ෇ xe x ϩ cos 2x. SOLUTION The auxiliary equation is r 2 Ϫ 4 ෇ 0 with roots Ϯ2, so the solution of the com- plementary equation is yc͑x͒ ෇ c1 e 2x ϩ c2 eϪ2x. For the equation yЉ Ϫ 4y ෇ xe x we try yp1͑x͒ ෇ ͑Ax ϩ B͒e x Ј Љ Then yp1 ෇ ͑Ax ϩ A ϩ B͒e x, yp1 ෇ ͑Ax ϩ 2A ϩ B͒e x, so substitution in the equation gives ͑Ax ϩ 2A ϩ B͒e x Ϫ 4͑Ax ϩ B͒e x ෇ xe x or ͑Ϫ3Ax ϩ 2A Ϫ 3B͒e x ෇ xe x
  • 4. 4 ■ NONHOMOGENEOUS LINEAR EQUATIONS Thus, Ϫ3A ෇ 1 and 2A Ϫ 3B ෇ 0, so A ෇ Ϫ 1 , B ෇ Ϫ 2 , and 3 9 yp1͑x͒ ෇ (Ϫ 1 x Ϫ 2 )e x 3 9 For the equation yЉ Ϫ 4y ෇ cos 2x, we try yp2͑x͒ ෇ C cos 2x ϩ D sin 2x In Figure 3 we show the particular solution yp ෇ yp1 ϩ yp 2 of the differential equation in Example 4. The other solutions are given in terms of f ͑x͒ ෇ e 2 x and t͑x͒ ෇ eϪ2 x. ■ ■ 5 Substitution gives Ϫ4C cos 2x Ϫ 4D sin 2x Ϫ 4͑C cos 2x ϩ D sin 2x͒ ෇ cos 2x Ϫ8C cos 2x Ϫ 8D sin 2x ෇ cos 2x or yp+2f+g Therefore, Ϫ8C ෇ 1, Ϫ8D ෇ 0, and yp+g yp+f _4 yp2͑x͒ ෇ Ϫ 1 cos 2x 8 1 yp By the superposition principle, the general solution is _2 y ෇ yc ϩ yp1 ϩ yp2 ෇ c1 e 2x ϩ c2 eϪ2x Ϫ ( 1 x ϩ 2 )e x Ϫ 1 cos 2x 3 9 8 FIGURE 3 Finally we note that the recommended trial solution yp sometimes turns out to be a solution of the complementary equation and therefore can’t be a solution of the nonhomogeneous equation. In such cases we multiply the recommended trial solution by x (or by x 2 if necessary) so that no term in yp͑x͒ is a solution of the complementary equation. EXAMPLE 5 Solve yЉ ϩ y ෇ sin x. SOLUTION The auxiliary equation is r 2 ϩ 1 ෇ 0 with roots Ϯi, so the solution of the com- plementary equation is yc͑x͒ ෇ c1 cos x ϩ c2 sin x Ordinarily, we would use the trial solution yp͑x͒ ෇ A cos x ϩ B sin x but we observe that it is a solution of the complementary equation, so instead we try yp͑x͒ ෇ Ax cos x ϩ Bx sin x Then yЈ͑x͒ ෇ A cos x Ϫ Ax sin x ϩ B sin x ϩ Bx cos x p ypЉ͑x͒ ෇ Ϫ2A sin x Ϫ Ax cos x ϩ 2B cos x Ϫ Bx sin x The graphs of four solutions of the differential equation in Example 5 are shown in Figure 4. ■ ■ Substitution in the differential equation gives 4 ypЉ ϩ yp ෇ Ϫ2A sin x ϩ 2B cos x ෇ sin x so A ෇ Ϫ 1 , B ෇ 0, and 2 _2π 2π yp͑x͒ ෇ Ϫ 1 x cos x 2 yp _4 FIGURE 4 The general solution is y͑x͒ ෇ c1 cos x ϩ c2 sin x Ϫ 1 x cos x 2
  • 5. NONHOMOGENEOUS LINEAR EQUATIONS ■ 5 We summarize the method of undetermined coefficients as follows: 1. If G͑x͒ ෇ e kxP͑x͒, where P is a polynomial of degree n, then try yp͑x͒ ෇ e kxQ͑x͒, where Q͑x͒ is an nth-degree polynomial (whose coefficients are determined by substituting in the differential equation.) 2. If G͑x͒ ෇ e kxP͑x͒ cos mx or G͑x͒ ෇ e kxP͑x͒ sin mx, where P is an nth-degree polynomial, then try yp͑x͒ ෇ e kxQ͑x͒ cos mx ϩ e kxR͑x͒ sin mx where Q and R are nth-degree polynomials. Modification: If any term of yp is a solution of the complementary equation, multiply yp by x (or by x 2 if necessary). EXAMPLE 6 Determine the form of the trial solution for the differential equation yЉ Ϫ 4yЈ ϩ 13y ෇ e 2x cos 3x. SOLUTION Here G͑x͒ has the form of part 2 of the summary, where k ෇ 2, m ෇ 3, and P͑x͒ ෇ 1. So, at first glance, the form of the trial solution would be yp͑x͒ ෇ e 2x͑A cos 3x ϩ B sin 3x͒ But the auxiliary equation is r 2 Ϫ 4r ϩ 13 ෇ 0, with roots r ෇ 2 Ϯ 3i, so the solution of the complementary equation is yc͑x͒ ෇ e 2x͑c1 cos 3x ϩ c2 sin 3x͒ This means that we have to multiply the suggested trial solution by x. So, instead, we use yp͑x͒ ෇ xe 2x͑A cos 3x ϩ B sin 3x͒ The Method of Variation of Parameters Suppose we have already solved the homogeneous equation ayЉ ϩ byЈ ϩ cy ෇ 0 and written the solution as 4 y͑x͒ ෇ c1 y1͑x͒ ϩ c2 y2͑x͒ where y1 and y2 are linearly independent solutions. Let’s replace the constants (or parameters) c1 and c2 in Equation 4 by arbitrary functions u1͑x͒ and u2͑x͒. We look for a particular solution of the nonhomogeneous equation ayЉ ϩ byЈ ϩ cy ෇ G͑x͒ of the form 5 yp͑x͒ ෇ u1͑x͒y1͑x͒ ϩ u2͑x͒y2͑x͒ (This method is called variation of parameters because we have varied the parameters c1 and c2 to make them functions.) Differentiating Equation 5, we get 6 yp ෇ ͑u1 y1 ϩ u2 y2 ͒ ϩ ͑u1 y1 ϩ u2 y2 ͒ Ј Ј Ј Ј Ј Since u1 and u2 are arbitrary functions, we can impose two conditions on them. One condition is that yp is a solution of the differential equation; we can choose the other condition so as to simplify our calculations. In view of the expression in Equation 6, let’s impose the condition that 7 Ј Ј u1 y1 ϩ u2 y2 ෇ 0
  • 6. 6 ■ NONHOMOGENEOUS LINEAR EQUATIONS ypЉ ෇ u1 y1 ϩ u2 y2 ϩ u1 y1Љ ϩ u2 y2Љ Ј Ј Ј Ј Then Substituting in the differential equation, we get a͑u1 y1 ϩ u2 y2 ϩ u1 y1Љ ϩ u2 y2Љ͒ ϩ b͑u1 y1 ϩ u2 y2 ͒ ϩ c͑u1 y1 ϩ u2 y2 ͒ ෇ G Ј Ј Ј Ј Ј Ј or 8 u1͑ay1Љ ϩ by1 ϩ cy1 ͒ ϩ u2͑ay2Љ ϩ by2 ϩ cy2 ͒ ϩ a͑u1 y1 ϩ u2 y2 ͒ ෇ G Ј Ј Ј Ј Ј Ј But y1 and y2 are solutions of the complementary equation, so ay1Љ ϩ by1 ϩ cy1 ෇ 0 Ј and ay2Љ ϩ by2 ϩ cy2 ෇ 0 Ј and Equation 8 simplifies to a͑u1 y1 ϩ u2 y2 ͒ ෇ G Ј Ј Ј Ј 9 Equations 7 and 9 form a system of two equations in the unknown functions uЈ and uЈ . 1 2 After solving this system we may be able to integrate to find u1 and u2 and then the particular solution is given by Equation 5. EXAMPLE 7 Solve the equation yЉ ϩ y ෇ tan x, 0 Ͻ x Ͻ ␲ ͞2. SOLUTION The auxiliary equation is r 2 ϩ 1 ෇ 0 with roots Ϯi, so the solution of yЉ ϩ y ෇ 0 is c1 sin x ϩ c2 cos x. Using variation of parameters, we seek a solution of the form yp͑x͒ ෇ u1͑x͒ sin x ϩ u2͑x͒ cos x Then yp ෇ ͑u1 sin x ϩ u2 cos x͒ ϩ ͑u1 cos x Ϫ u2 sin x͒ Ј Ј Ј Set u1 sin x ϩ u2 cos x ෇ 0 Ј Ј 10 Then ypЉ ෇ u1 cos x Ϫ u2 sin x Ϫ u1 sin x Ϫ u2 cos x Ј Ј For yp to be a solution we must have ypЉ ϩ yp ෇ u1 cos x Ϫ u2 sin x ෇ tan x Ј Ј 11 Solving Equations 10 and 11, we get u1͑sin 2x ϩ cos 2x͒ ෇ cos x tan x Ј ■ ■ Figure 5 shows four solutions of the differential equation in Example 7. u1 ෇ sin x Ј 2.5 u1͑x͒ ෇ Ϫcos x (We seek a particular solution, so we don’t need a constant of integration here.) Then, from Equation 10, we obtain 0 yp π 2 u2 ෇ Ϫ Ј sin x sin 2x cos 2x Ϫ 1 u1 ෇ Ϫ Ј ෇ ෇ cos x Ϫ sec x cos x cos x cos x _1 FIGURE 5 So u2͑x͒ ෇ sin x Ϫ ln͑sec x ϩ tan x͒
  • 7. NONHOMOGENEOUS LINEAR EQUATIONS ■ 7 (Note that sec x ϩ tan x Ͼ 0 for 0 Ͻ x Ͻ ␲ ͞2.) Therefore yp͑x͒ ෇ Ϫcos x sin x ϩ ͓sin x Ϫ ln͑sec x ϩ tan x͔͒ cos x ෇ Ϫcos x ln͑sec x ϩ tan x͒ and the general solution is y͑x͒ ෇ c1 sin x ϩ c2 cos x Ϫ cos x ln͑sec x ϩ tan x͒ Exercises A Click here for answers. S 16. yЉ ϩ 3yЈ Ϫ 4 y ෇ ͑x 3 ϩ x͒e x Click here for solutions. 17. yЉ ϩ 2 yЈ ϩ 10 y ෇ x 2eϪx cos 3x 18. yЉ ϩ 4y ෇ e 3x ϩ x sin 2x 1–10 Solve the differential equation or initial-value problem using the method of undetermined coefficients. 1. yЉ ϩ 3yЈ ϩ 2y ෇ x 2. yЉ ϩ 9y ෇ e 2 3. yЉ Ϫ 2yЈ ෇ sin 4x 7. yЉ ϩ y ෇ e x ϩ x 3, y͑0͒ ෇ 2, 8. yЉ Ϫ 4y ෇ e x cos x, y͑0͒ ෇ 2, ■ ■ ■ ■ ■ ■ yЈ͑0͒ ෇ 0 ■ ■ ■ ■ ■ ; 11–12 Graph the particular solution and several other solutions. What characteristics do these solutions have in common? ■ ■ ■ ■ 13 –18 ■ 13. yЉ ϩ 9 y ෇ e ϩ x sin x 2 Ϫx 14. yЉ ϩ 9 yЈ ෇ xe cos ␲ x 15. yЉ ϩ 9 yЈ ෇ 1 ϩ xe 9x ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ 23–28 Solve the differential equation using the method of variation of parameters. 1 1 ϩ eϪx 25. yЉ Ϫ 3yЈ ϩ 2y ෇ ■ ■ ■ ■ ■ Write a trial solution for the method of undetermined coefficients. Do not determine the coefficients. 2x ■ 24. yЉ ϩ y ෇ cot x, 0 Ͻ x Ͻ ␲͞2 12. 2yЉ ϩ 3yЈ ϩ y ෇ 1 ϩ cos 2x ■ ■ 23. yЉ ϩ y ෇ sec x, 0 Ͻ x Ͻ ␲͞2 11. 4yЉ ϩ 5yЈ ϩ y ෇ e x ■ ■ 22. yЉ Ϫ yЈ ෇ e x y͑0͒ ෇ 1, ■ ■ 21. yЉ Ϫ 2yЈ ϩ y ෇ e 2x yЈ͑0͒ ෇ 2 ■ ■ ■ 20. yЉ Ϫ 3yЈ ϩ 2y ෇ sin x yЈ͑0͒ ෇ 1 10. yЉ ϩ yЈ Ϫ 2y ෇ x ϩ sin 2x, ■ 19. yЉ ϩ 4y ෇ x yЈ͑0͒ ෇ 0 y͑0͒ ෇ 1, ■ Solve the differential equation using (a) undetermined coefficients and (b) variation of parameters. 6. yЉ ϩ 2yЈ ϩ y ෇ xeϪx 5. yЉ Ϫ 4yЈ ϩ 5y ෇ e ■ 19–22 4. yЉ ϩ 6yЈ ϩ 9y ෇ 1 ϩ x Ϫx 9. yЉ Ϫ yЈ ෇ xe x, ■ 3x ■ 26. yЉ ϩ 3yЈ ϩ 2y ෇ sin͑e x ͒ 27. yЉ Ϫ y ෇ 1 x eϪ2x x3 28. yЉ ϩ 4yЈ ϩ 4y ෇ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■
  • 8. 8 ■ NONHOMOGENEOUS LINEAR EQUATIONS Answers S Click here for solutions. 1. y ෇ c1 eϪ2x ϩ c2 eϪx ϩ 2 x 2 Ϫ 2 x ϩ 1 3. y ෇ c1 ϩ c2 e 2x ϩ 3 7 4 1 cos 4x Ϫ 20 sin 4x 1 5. y ෇ e ͑c1 cos x ϩ c2 sin x͒ ϩ 10 eϪx 3 11 1 x 7. y ෇ 2 cos x ϩ 2 sin x ϩ 2 e ϩ x 3 Ϫ 6x 1 9. y ෇ e x ( 2 x 2 Ϫ x ϩ 2) 5 11. The solutions are all asymptotic to yp ෇ e x͞10 as x l ϱ. Except for yp , all solutions approach _2 4 yp either ϱ or Ϫϱ as x l Ϫϱ. 1 40 2x _4 13. 15. 17. 19. 21. 23. 25. 27. yp ෇ Ae 2x ϩ ͑Bx 2 ϩ Cx ϩ D͒ cos x ϩ ͑Ex 2 ϩ Fx ϩ G͒ sin x yp ෇ Ax ϩ ͑Bx ϩ C ͒e 9x yp ෇ xeϪx ͓͑Ax 2 ϩ Bx ϩ C ͒ cos 3x ϩ ͑Dx 2 ϩ Ex ϩ F͒ sin 3x͔ y ෇ c1 cos 2x ϩ c2 sin 2x ϩ 1 x 4 y ෇ c1e x ϩ c2 xe x ϩ e 2x y ෇ ͑c1 ϩ x͒ sin x ϩ ͑c2 ϩ ln cos x͒ cos x y ෇ ͓c1 ϩ ln͑1 ϩ eϪx ͔͒e x ϩ ͓c2 Ϫ eϪx ϩ ln͑1 ϩ eϪx ͔͒e 2x y ෇ [c1 Ϫ 1 x ͑e x͞x͒ dx]eϪx ϩ [c2 ϩ 1 x ͑eϪx͞x͒ dx]e x 2 2
  • 9. NONHOMOGENEOUS LINEAR EQUATIONS ■ 9 Solutions: Nonhomogeneous Linear Equations 1. The auxiliary equation is r 2 + 3r + 2 = (r + 2)(r + 1) = 0, so the complementary solution is 0 yc (x) = c1 e−2x + c2 e−x . We try the particular solution yp (x) = Ax2 + Bx + C, so yp = 2Ax + B and 00 yp = 2A. Substituting into the differential equation, we have (2A) + 3(2Ax + B) + 2(Ax2 + Bx + C) = x2 or 2Ax2 + (6A + 2B)x + (2A + 3B + 2C) = x2 . Comparing coefficients gives 2A = 1, 6A + 2B = 0, and 2A + 3B + 2C = 0, so A = 1 , B = − 3 , and C = 2 2 −2x y(x) = yc (x) + yp (x) = c1 e + c2 e −x + 1 2 x 2 − 7 . 4 3 x 2 Thus the general solution is + 7. 4 3. The auxiliary equation is r 2 − 2r = r(r − 2) = 0, so the complementary solution is yc (x) = c1 + c2 e2x . Try the 0 particular solution yp (x) = A cos 4x + B sin 4x, so yp = −4A sin 4x + 4B cos 4x 00 and yp = −16A cos 4x − 16B sin 4x. Substitution into the differential equation gives (−16A cos 4x − 16B sin 4x) − 2(−4A sin 4x + 4B cos 4x) = sin 4x ⇒ (−16A − 8B) cos 4x + (8A − 16B) sin 4x = sin 4x. Then −16A − 8B = 0 and 8A − 16B = 1 1 and B = − 20 . Thus the general solution is y(x) = yc (x) + yp (x) = c1 + c2 e2x + 1 40 cos 4x − 1 20 ⇒ A= 1 40 sin 4x. 5. The auxiliary equation is r 2 − 4r + 5 = 0 with roots r = 2 ± i, so the complementary solution is 0 00 yc (x) = e2x (c1 cos x + c2 sin x). Try yp (x) = Ae−x , so yp = −Ae−x and yp = Ae−x . Substitution gives Ae−x − 4(−Ae−x ) + 5(Ae−x ) = e−x 2x y(x) = e (c1 cos x + c2 sin x) + ⇒ 10Ae−x = e−x ⇒ A= 1 . 10 Thus the general solution is 1 −x e . 10 7. The auxiliary equation is r 2 + 1 = 0 with roots r = ±i, so the complementary solution is 0 00 yc (x) = c1 cos x + c2 sin x. For y00 + y = ex try yp1 (x) = Aex . Then yp1 = yp1 = Aex and substitution gives Aex + Aex = ex A = 1 , so yp1 (x) = 1 ex . For y00 + y = x3 try yp2 (x) = Ax3 + Bx2 + Cx + D. 2 2 ⇒ 0 00 Then yp2 = 3Ax2 + 2Bx + C and yp2 = 6Ax + 2B. Substituting, we have 6Ax + 2B + Ax3 + Bx2 + Cx + D = x3 , so A = 1, B = 0, 6A + C = 0 ⇒ C = −6, and 2B + D = 0 ⇒ D = 0. Thus yp2 (x) = x3 − 6x and the general solution is y(x) = yc (x) + yp1 (x) + yp2 (x) = c1 cos x + c2 sin x + 1 ex + x3 − 6x. But 2 = y(0) = c1 + 2 and 0 = y0 (0) = c2 + y(x) = 3 2 cos x + 11 2 1 2 −6 ⇒ c2 = 11 . 2 1 2 ⇒ c1 = 3 2 Thus the solution to the initial-value problem is sin x + 1 ex + x3 − 6x. 2 9. The auxiliary equation is r 2 − r = 0 with roots r = 0, r = 1 so the complementary solution is yc (x) = c1 + c2 ex . Try yp (x) = x(Ax + B)ex so that no term in yp is a solution of the complementary equation. Then 0 00 yp = (Ax2 + (2A + B)x + B)ex and yp = (Ax2 + (4A + B)x + (2A + 2B))ex . Substitution into the differential equation gives (Ax2 + (4A + B)x + (2A + 2B))ex − (Ax2 + (2A + B)x + B)ex = xex ⇒ ¡ ¢ (2Ax + (2A + B))ex = xex ⇒ A = 1 , B = −1. Thus yp (x) = 1 x2 − x ex and the general solution is 2 2 ¡ ¢ y(x) = c1 + c2 ex + 1 x2 − x ex . But 2 = y(0) = c1 + c2 and 1 = y0 (0) = c2 − 1, so c2 = 2 and c1 = 0. The 2 ¡ ¡ ¢ ¢ solution to the initial-value problem is y(x) = 2ex + 1 x2 − x ex = ex 1 x2 − x + 2 . 2 2
  • 10. 10 ■ NONHOMOGENEOUS LINEAR EQUATIONS 11. yc (x) = c1 e−x/4 + c2 e−x . Try yp (x) = Aex . Then 10Aex = ex , so A = 1 10 and the general solution is y(x) = c1 e−x/4 + c2 e−x + 1 x e . 10 The solutions are all composed of exponential curves and with the exception of the particular solution (which approaches 0 as x → −∞), they all approach either ∞ or −∞ as x → −∞. As x → ∞, all solutions are asymptotic to yp = 1 x e . 10 13. Here yc (x) = c1 cos 3x + c2 sin 3x. For y00 + 9y = e2x try yp1 (x) = Ae2x and for y 00 + 9y = x2 sin x try yp2 (x) = (Bx2 + Cx + D) cos x + (Ex2 + F x + G) sin x. Thus a trial solution is yp (x) = yp1 (x) + yp2 (x) = Ae2x + (Bx2 + Cx + D) cos x + (Ex2 + F x + G) sin x. 15. Here yc (x) = c1 + c2 e−9x . For y 00 + 9y0 = 1 try yp1 (x) = Ax (since y = A is a solution to the complementary equation) and for y 00 + 9y0 = xe9x try yp2 (x) = (Bx + C)e9x . 17. Since yc (x) = e−x (c1 cos 3x + c2 sin 3x) we try yp (x) = x(Ax2 + Bx + C)e−x cos 3x + x(Dx2 + Ex + F )e−x sin 3x (so that no term of yp is a solution of the complementary equation). Note: Solving Equations (7) and (9) in The Method of Variation of Parameters gives u0 = − 1 Gy2 0 0 a (y1 y2 − y2 y1 ) u0 = 2 and Gy1 0 0 a (y1 y2 − y2 y1 ) We will use these equations rather than resolving the system in each of the remaining exercises in this section. 19. (a) The complementary solution is yc (x) = c1 cos 2x + c2 sin 2x. A particular solution is of the form yp (x) = Ax + B. Thus, 4Ax + 4B = x ⇒ A= 1 4 solution is y = yc + yp = c1 cos 2x + c2 sin 2x + 1 x. 4 and B = 0 ⇒ yp (x) = 1 x. Thus, the general 4 (b) In (a), yc (x) = c1 cos 2x + c2 sin 2x, so set y1 = cos 2x, y2 = sin 2x. Then 0 0 y1 y2 − y2 y1 = 2 cos2 2x + 2 sin2 2x = 2 so u0 = − 1 x sin 2x ⇒ 1 2 R ¡ ¢ u1 (x) = − 1 x sin 2x dx = − 1 −x cos 2x + 1 sin 2x [by parts] and u0 = 1 x cos 2x 2 2 4 2 2 R ¡ ¢ ⇒ u2 (x) = 1 x cos 2xdx = 1 x sin 2x + 1 cos 2x [by parts]. Hence 4 2 ¢ ¢ ¡2 ¡ yp (x) = − 1 −x cos 2x + 1 sin 2x cos 2x + 1 x sin 2x + 1 cos 2x sin 2x = 1 x. Thus 4 2 4 2 4 y(x) = yc (x) + yp (x) = c1 cos 2x + c2 sin 2x + 1 x. 4 21. (a) r 2 − r = r(r − 1) = 0 ⇒ r = 0, 1, so the complementary solution is yc (x) = c1 ex + c2 xex . A particular solution is of the form yp (x) = Ae2x . Thus 4Ae2x − 4Ae2x + Ae2x = e2x ⇒ 2x x ⇒ Ae2x = e2x x yp (x) = e . So a general solution is y(x) = yc (x) + yp (x) = c1 e + c2 xe + e2x . ⇒ A=1 0 0 (b) From (a), yc (x) = c1 ex + c2 xex , so set y1 = ex , y2 = xex . Then, y1 y2 − y2 y1 = e2x (1 + x) − xe2x = e2x R x 0 x x and so u1 = −xe ⇒ u1 (x) = − xe dx = −(x − 1)e [by parts] and u0 = ex ⇒ 2 R x u2 (x) = e dx = ex . Hence yp (x) = (1 − x)e2x + xe2x = e2x and the general solution is y(x) = yc (x) + yp (x) = c1 ex + c2 xex + e2x .
  • 11. NONHOMOGENEOUS LINEAR EQUATIONS ■ 11 23. As in Example 6, yc (x) = c1 sin x + c2 cos x, so set y1 = sin x, y2 = cos x. Then sec x cos x 0 0 y1 y2 − y2 y1 = − sin2 x − cos2 x = −1, so u0 = − = 1 ⇒ u1 (x) = x and 1 −1 R sec x sin x u0 = = − tan x ⇒ u2 (x) = − tan xdx = ln |cos x| = ln(cos x) on 0 < x < π . Hence 2 2 −1 yp (x) = x sin x + cos x ln(cos x) and the general solution is y(x) = (c1 + x) sin x + [c2 + ln(cos x)] cos x. 0 0 25. y1 = ex , y2 = e2x and y1 y2 − y2 y1 = e3x . So u0 = 1 Z −e2x e−x =− and −x )e3x (1 + e 1 + e−x e−x ex ex dx = ln(1 + e−x ). u0 = = 3x so 2 1 + e−x (1 + e−x )e3x e + e2x ¶ µ x Z ex e +1 u2 (x) = − e−x = ln(1 + e−x ) − e−x . Hence dx = ln 3x + e2x e ex u1 (x) = − yp (x) = ex ln(1 + e−x ) + e2x [ln(1 + e−x ) − e−x ] and the general solution is y(x) = [c1 + ln(1 + e−x )]ex + [c2 − e−x + ln(1 + e−x )]e2x . ex e−x 0 0 and 27. y1 = e−x , y2 = ex and y1 y2 − y2 y1 = 2. So u0 = − , u0 = 1 2 2x 2x Z x Z −x e e dx + ex dx. Hence the general solution is yp (x) = −e−x 2x 2x µ µ ¶ Z x Z −x ¶ e e y(x) = c1 − dx e−x + c2 + dx ex . 2x 2x