Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations FURTHER ORDINARY DIFFERENTIAL EQUATIONS Learning objectives: 1. Solve 1st order linear differential equations using variables separable method (Unit 2). 2. Solve 1st order linear differential equations using the integrating factor method (be able to find general solutions and solve initial value problems). 3. Know meanings of: 4. Solve 2nd order homogeneous ordinary differential equations with constant coefficients. (be able to find general solutions and solve initial value problems). 5. Find the general solution in the three cases where the roots of the auxiliary equation: (i) are real and distinct (ii) coincide (are equal) [A/B] (iii) are complex conjugates [A/B] (be able to solve initial value problems). 6. Solve 2nd order non-homogeneous ordinary differential equations with constant coefficients, using the auxiliary equation and particular integral method. 2nd order linear differential equations with constant coefficients homogeneous non-homogeneous auxiliary equation complementary function particular integral. Page 1 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations First Order Differential Equations – Variables Separable [from Unit 2] This method was covered in Unit 2 as part of “Integration”. This is the most straightforward method for solving first order differential equations so always check to see if it can be employed. We need to be able to get all of the “y” bits on one side and all of the “x” bits on the other side. Examples: dy 3x 2 dx y 1. y dy 3x 2 dx y dy 3x 2 dx 2. y2 3 x3 c 2 3 y 2x3 c An object is cooling according to “Newton’s Law of Cooling” i.e. the rate of change of temperature is proportional to the temperature difference between the object and its surroundings. (a) (b) (c) Write down a differential equation describing this situation. When T = 50oC, dT 0 16o C per sec . Determine the constant of proportion. dt Find the rule for T. (d) If the temperature of the object is 70oC at time t = 0 and the temperature of the surroundings, Ts, remains constant at 40oC, find the particular solution. (e) Assuming the temperature of the surroundings remains constant, calculate how much the temperature of the object has fallen after 1 minute. Solutions: 2(a) Let T = the temperature of the object and Ts = the temperature of the surroundings (which we will consider to be constant). Hence, 2(b) dT T T s dt dT k (T TS ). dt dT k (T T ) S dt 0 16 k (50 TS ) k 0 16 50 TS Page 2 of 21 Bridge of Don Academy – Department of Mathematics 2(c) dT 0 16 (T T ) S dt 50 TS 1 dT 0 16 dt T TS 50 TS 1 dT 0 16 dt T TS 50 TS ln(T TS ) 0 16 t C 50 TS T TS e 016 t C 50TS T TS Ae T Ae 2(d) Advanced Higher: Unit 3 – Further Differential Equations let A eC 016 t 50TS 016 t 50TS TS When T = 70, t = 0 and Ts = 40 T Ae 016 t 50TS TS 70 Ae0 40 A 70 40 30 Hence, T 30e T 30e 2(e) 016 t 50 40 0.016t 40 40 t = 60 T 30e0.016t 40 30e0.01660 40 51 5 Therefore, the temperature of the object after 1 minute is 515oC. Hence the temperature has fallen by 70 – 515 = 185oC. Page 3 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations The Integrating Factor A first order linear differential equation is of the form dy P( x) y Q( x) dx To solve, we use an integrating factor, e P ( x ) dx . We multiply each side of the differential equation by the integrating factor and, using the product rule, we can then solve the equation. P( x)dx . Step 1: Identify P(x) and work out Step 2: P ( x ) dx State the integrating factor e and simplify it as necessary. Step 3: Multiply both sides of the differential equation by the integrating factor. Step 4: P ( x ) dx The left hand side of the differential equation is always d e y . dx The right hand side is Q(x) e Step 5: P ( x ) dx and we then calculate the integral of this. Examples: 3. Find the general solution of x dy 2y 4 . dx x First, divide through by x to get the standard form of a first order linear differential equation dy 2 y 42 dx x x P( x ) 2 x integrating factor = e 2x dx e2ln x eln x 2 x2 Multiply both sides by x 2 dy x 2 2 y x 2 42 dx x x x2 d x2 y 4 dx x 2 y 4 dx x y 4x c y 4 c2 x x 2 Page 4 of 21 Bridge of Don Academy – Department of Mathematics 4. Advanced Higher: Unit 3 – Further Differential Equations dy 2x 1 2 y . dx Find the general solution of Rearrange to give standard form: P(x) = integrating factor = Multiply both sides by [N.B. e 2 x (1 2 x) dx 1 e 2 x (1 2 x) 1 e 2 x c 2 2 by using integration by parts] 5. Find the particular solution of x dy 2 y 1 given that, when x = 1, y = 2. dx x dy 2 y 12 dx x x P( x ) 2 x integrating factor e x 2 dx e 2 ln x eln x x 2 2 Multiply both sides by x 2 dy x 2 2 y x 2 12 dx x x x2 d x2 y 1 dx x2 y x c y 1 c2 x x Substitute in values x = 1, y = 2 to get c = 1 y 1 12 x x Now try: Page 114, Exercise 1 – questions 3e, 3j, 4 Page 116, Exercise 2 – questions 1d, 3, 6, 7 Page 5 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations Second Order Linear Differential Equations A second order linear differential equation is of the form a d2y dy b cy Q( x ) . 2 dx dx Let us study the HOMOGENEOUS case first, this means that in the above equation Q(x) = 0, therefore a d2y dy b cy 0 . 2 dx dx The general solution to such an equation will include two arbitrary constants, A and B. This gives us the auxiliary equation am2 + bm + c = 0 with roots m1 and m2. The general solution will be of the form y Aem x Bem x . 1 2 To solve a homogeneous second order linear differential equation: Step 1: Create an auxiliary equation. Step 2: Solve the auxiliary equation. There are three scenarios: (i) roots are real and distinct, m1 and m2 (ii) roots coincide, m1 = m2 i.e. roots are equal, m (iii) roots are complex conjugates, p qi. Step 3: State the general solution. Scenario (i): General solution is of the form y Aem x Bem x Scenario (ii): General solution is of the form y Aemx Bxemx Scenario (iii): General solution is of the form y e px (C cos qx D sin qx) 1 2 Examples: 6. Find the general solution to 4 d 2 y dy 5y 0 . dx dx 2 4m 2 m 5 0 Auxiliary equation is (4m 5)(m 1) 0 m 5 4 or m 1 Roots are real and distinct so general solution is 5x y Ae 4 Be x where A and B are arbitrary constants. Page 6 of 21 Bridge of Don Academy – Department of Mathematics 7. Find the general solution to 9 Advanced Higher: Unit 3 – Further Differential Equations d2y dy 24 16 y 0 . 2 dx dx Auxiliary equation is Roots are equal so general solution is y = 8. Find the general solution to Auxiliary equation is where A and B are arbitrary constants. d2y dy 2 2y 0 . 2 dx dx m 2 2m 2 0 2 x b b 4ac 2a Roots are complex conjugates so general solution is y = A and B are arbitrary constants. 9. Find the general solution to where d2y dy 2 5y 0 . 2 dx dx Auxiliary equation is Roots are _________________ so general solution is Now try: Page 122, Exercise 5A – question 2b Page 122, Exercise 5B – questions 1a, 1c, 1e, 1f, 2, 3 Page 7 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations Now we will take a look at NON-HOMOGENEOUS second order linear differential equations which are of the form d2y dy a 2 b cy Q( x ) dx dx where Q(x) 0. To solve these, we begin in the same way as the homogeneous case Step 1: Step 2: Step 3: then Step 4: Step 5: Step 6: Create an auxiliary equation. Solve the auxiliary equation (3 scenarios). State the general solution complementary function (3 scenarios). Substitute the particular integral (*see below) into the original equation. Equate coefficients to get the particular integral (*see below). State the general solution = complementary function + particular integral * To decide on the form of the particular integral – see note on page 9. Examples: 10. Find the general solution of d 2 y dy 12 y x given that the particular integral is of the dx dx 2 form y = Cx + D. Auxiliary equation is m 2 m 12 0 (m 4)(m 3) 0 m 4 or m 3 Roots are real and distinct therefore complementary function is y Ae4 x Be3x We know that the particular integral is of the form y = Cx + D, so dy C and dx d2y 0. dx 2 Substituting back into the original equation gives 0 C 12 Cx D x 12Cx C 12D x and so by equating coefficients 12C 1 and C 12D 0 C 1 and D 1 12 144 Hence, the general solution is y Ae4 x Be3x 1 x 1 . 12 144 Now try: Page 124, Exercise 6 – questions 2c, 2d Page 8 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations Finding the Particular Integral for non-homogeneous second order linear differential equations This is best found by inspection (and should be relatively easily found). Then use substitution to find any arbitrary constants. 1. Try the same form as Q(x). 2. If this is the same form as either term of the complementary function then try xQ(x). 3. If this is the same form as either term of the complementary function then try x2Q(x). The most common are listed below: A. If f(x) = polynomial in x of degree n then use y = Cxn + Dxn-1 + …. + x0 (but note, if m = 0 is a root of the auxiliary function increase n by 1 and for double roots increase n by 2). B(i). If f(x) = expression involving ex then use y = Cex (but note, if is a root of the auxiliary equation try y = Cxex and, if is a double root then try y = Cx2ex). (ii). If f(x) = expression involving xex then use y = Cxex + Dex (but note, if is a root of the auxiliary equation try y = Cx2ex + Dxex and, if is a double root then try y = Cx3ex + Dx2ex). C. Highly unlikely to be in exam. If f(x) = expression involving sinx or/and cosx then use y = C sinx + D cosx (but note, if complementary function is of the form Asinx + Bcosx then use y = Cx sinx + Dx cosx). D. If f(x) = a mixture of the above then try a similar mixture (although this is unlikely to come up in the exam). Highly unlikely to be in exam. Page 9 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations Examples: 11. Find the general solution of d2y dy 6 8 y 22 cos x . 2 dx dx Auxiliary function is Roots are real and distinct so Complementary function is m 2 6m 8 0 (m 4)(m 2) 0 m 4 or m 2 y Ae4 x Be2 x Particular integral: Q(x) = 22cos x so consider y = C sin x + D cos x [not the same form as comp. funcn so good to go] y C sin x D cos x, so dy d2y C cos x D sin x and C sin x D cos x dx dx 2 Substituting this into the original equation gives C sin x D cos x 6 C cos x D sin x 8 C sin x D cos x 22 cos x (7C 6D) sin x (7 D 6C ) cos x 22 cos x 7C 6D 0 and 7D 6C 22 then solve these simultaneous equations to get C 132 and D 154 85 85 part. intg. is y 1 132 sin x 154 cos x 85 Hence, the general solution is y Ae4 x Be2 x 1 132sin x 154 cos x . 85 Page 10 of 21 Bridge of Don Academy – Department of Mathematics 12. Find the general solution of Advanced Higher: Unit 3 – Further Differential Equations d2y dy 8 16 y 6e 4 x . 2 dx dx Page 11 of 21 Bridge of Don Academy – Department of Mathematics 13. Find the general solution of Advanced Higher: Unit 3 – Further Differential Equations d2y 16 y 4 x 2 . 2 dx Page 12 of 21 Bridge of Don Academy – Department of Mathematics 14. Advanced Higher: Unit 3 – Further Differential Equations The acceleration, a ms-2, of a particle in a straight line is given by a = – 4x + 2 cos 2t, where x is the displacement at time t seconds. At time t = 0, x = 0 and the velocity v = 0. (a) By finding the particular solution to an appropriate differential equation, find a formula for the displacement x. (b) Find an approximate value for the time when velocity is first equal to zero. Now try: Page 126, Exercise 7A – questions 1h, 2, 3a, 3e Page 127, Exercise 7B – questions 1b, 1d, 1e, 3 Page 128, Review – questions 2, 8, 9, 10, 11 Page 13 of 21 Bridge of Don Academy – Department of Mathematics Advanced Higher: Unit 3 – Further Differential Equations Further examples (from SQA exams): 15. Find the general solution of the following differential equation: dy y x, dx x x 0. 4 Page 14 of 21 Bridge of Don Academy – Department of Mathematics 16. Advanced Higher: Unit 3 – Further Differential Equations Find the general solution of the following differential equation: d2y dy 2 3 y 6x 1 . 2 dx dx 5 Page 15 of 21 Bridge of Don Academy – Department of Mathematics 17. Advanced Higher: Unit 3 – Further Differential Equations Find the general solution of the following differential equation d2y dy 2 5 y 4cos x . 2 dx dx 6 Hence detrmine the solution which satisfies y(0) 0 and y(0) 1 . 4 Page 16 of 21 Bridge of Don Academy – Department of Mathematics 18. Advanced Higher: Unit 3 – Further Differential Equations Solve the differential equation d2y dy 4 4 y ex , 2 dx dx given that y 2 and dy 1 , when x 0 . dx 10 Page 17 of 21 Bridge of Don Academy – Department of Mathematics 19. (a) Advanced Higher: Unit 3 – Further Differential Equations A mathematical biologist believes that the differential equation dy 3 y x 4 models a process. Find the general solution of the dx differential equation. x Given that y 2 when x 1 , find the particular solution, expressing y in tems of x. 5 2 (b) The biologist subsequently decides that a better model is given by the dy 3x x 4 . differential equation y dx Given that y 2 when x 1 , obtain y in tems of x. 4 Page 18 of 21 Bridge of Don Academy – Department of Mathematics 20. Advanced Higher: Unit 3 – Further Differential Equations Obtain the general solution of the differential equation d2y dy 3 2 y 20sin x . 2 dx dx 7 Hence find the particular solution for which y 0 and dy 0 when x 0. dx 3 Page 19 of 21 Bridge of Don Academy – Department of Mathematics 21. Given that x 2e y dy 1 dx Advanced Higher: Unit 3 – Further Differential Equations and y 0 when x 1 , find y in terms of x. 4 Page 20 of 21 Bridge of Don Academy – Department of Mathematics 22. (a) Advanced Higher: Unit 3 – Further Differential Equations Solve the differential equation ( x 1) dy 3 y ( x 1) 4 dx given that y 16 when x 1 , expressing the answer in the form y f ( x) . 6 (b) Hence find the area enclosed by the graphs of y f ( x) , y (1 x) and the x-axis. 4 4 Page 21 of 21