Topic 5: Second Order Ordinary Differential Equation

Download as pdf or txt
Download as pdf or txt
You are on page 1of 7

Topic 5:

Second Order Ordinary


Differential Equation
5.1 Second Order Linear ODE
5.2 Solving Homogeneous Second Order ODE with constant coefficients
5.3 Initial and Boundary Value Problems
5.4 Solving Non homogeneous Second Order ODE with constant coefficients
5.4.1 Method of Undetermined Coefficients
5.4.2 Variation of Parameters Method
1
5.1 Second Order Linear ODE
The general form of second order linear ODE is
P ( x) y   Q( x) y   R ( x) y  G ( x)
G ( x)  0 G ( x)  0
Homogeneous second order linear ODE: Non homogeneous second order linear ODE:
P ( x) y   Q( x) y   R ( x) y  0 P ( x) y   Q( x) y   R ( x) y  G ( x)

Example 1: In this course, we will only Example 2 :


learn how to solve second a) y   6 y   9 y  1  x
a) y   3 y   2 y  0
order ODE where the
b) y   6 y   9 y  0 coefficients are constants, i.e. b) y   3 y   2 y  e x
c) x 2 y   4 xy   6 y  0 P(x) = a, Q(x) = b, R(x) = c. c) y   y   2 y  sin 2 x
d) xy   ( x  1) y   y  0 d) y   2 y   y  e x2 ln x
5.2 Solving homogeneous second order ODE of the form ay   by   cy  0

Step 1: Change ay   by   cy  0 into characteristic equation. Step 2: Solve ar 2  br  c  0.


Let y  e rx . So, y   re rx and y   r 2 e rx . Then, Find r by factoring or using
ay   by   cy  0 the quadratic formula:
ar 2 e rx  bre rx  ce rx  0 b  b 2  4ac
r1,2 
e rx ar 2  br  c   0, e rx  0 2a

ar 2  br  c  0  This is characteristic equation


Step 3: The general solution is one of the following three forms:
Case 1b 2  4ac  0 : r1,2 are real and distinct, i.e. r1  r2  y  c1e r1x  c2 e r2 x
Case 2 b 2  4ac  0 : r1,2 are real and equal, i.e. r1  r2  y  c1e r1x  c2 xe r2 x
Case 3b 2  4ac  0 : r1,2 are complex numbers, i.e. r1,2    i  y  e x c1 sin  x  c2 cos
3  x
Example 3: Example 4: Example 5:
y   3 y   2 y  0 y   6 y   9 y  0 y   4 y   6 y  0
Step 1: Write r 2  3r  2  0 r 2  6r  9  0 r 2  4r  6  0
characteristic
equation
Step 2: Find r r 1r  2  0 r  31r  3  0 4  8
r1,2   2  i 2
r1  1, r2  2 r1  3, r2  3 2

Step 3: Write Case 1: Case 2: Case 3:


general y  c1e x  c2 e 2 x y  c1e  c2 xe
3x 3x
y  e2 x

c1 sin  
2 x  c2 cos  2x 
solution

4
5.3 Initial Value Problem

Example 6 : Solve the IVP 2 y   5 y   3 y  0, y 0  3, y  0  4.


Solution:
2 r 2  5r  3  0 Use initial conditions:
2r  3r 1  0 y 0  3  3  c1  c2 (1)
3 3
r1   , r2  1 y  0  4  4   c1  c2 (2)
2 2
The general solution is Solve simultaneaously:
3
 x 1
y  c1e 2
 c2 e x . (1)  (2) : 1   c1  c1  2  3  2  c2  c2  1
2
3  32 x 3
y    c1e  c2 e x  The solution to the IVP is y  2e
 x
2
 e x .
2

5
5.3 Boundary Value Problem

Example 7 : Solve the BVP y   4 y   13 y  0, y 0  2, y  2  1.


Solution:
r 2  4r  13  0
4  36
r1,2   2  3i
2
The general solution is y  e2 x c1 sin 3 x  c2 cos 3 x.
Use initial conditions:
y 0  2  c2  2
 3 3 
y  2  1  1  e c1 sin  2cos   c1  e

 2 2
 The solution to the BVP is y  e2 x e sin 3 x   2cos 3 x .
6
Exercise 1:
1. Solve the following second order ODEs:
a) y   2 y   y  0 b) y   4 y   5 y  0 c) y   4 y   9 y  0

2. Solve the following initial value problems:


a) y   16 y  0, y  2  10, y   2  3
b) y   4 y   4 y  0, y 0  12, y   0   3

3. Solve the boundary value problem y   4 y  0, y 0  2, y  4  10.


Solutions:
1. a) y  c1e x  c2 xe x b) y  c1e5 x  c2 e x 
c) y  e 2 x c1 sin  
5 x  c2 cos  5x 
3
2. a) y  10cos 4 x   sin 4 x  b) y  12e 2 x  27 xe 2 x
4
3. y  2cos 2 x   10sin 2 x  7

You might also like