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

SOLUTIONS OF HIGHER ORDER LINEAR ODE

WITH CONSTANT COEFFICIENTS

Non-homogeneous Linear Differential Equations


with Constant Coefficients
METHOD OF UNDETERMINED COEFFICIENTS (MUC)
AND
METHOD OF VARIATION OF PARAMETERS (MVP)

Prepared By: ERVDatul


Non-homogeneous LDE with Constant Coefficients
 General Form: 𝝓 𝑫 𝒚 = 𝒇(𝒙) where 𝒇 𝒙 ≠ 𝟎
 Standard/Complete Solution:
y  yc  y p
 Steps in Solving for y
1) Solve for 𝒚𝒄 by setting 𝒇 𝒙 = 𝟎 or 𝝓 𝑫 𝒚 = 𝟎
2) Solve for 𝒚𝒑 either by
a)Method of Undetermined Coefficients (MUC)
b) Method of Variation of Parameters (MVP)
3) Obtain the complete solution by adding 𝒚𝒄 and 𝒚𝒑 : 𝒚 = 𝒚𝒄 + 𝒚𝒑
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 applies whenever 𝒇 𝒙 is a linear combination of three types of functions:
1) a polynomial in 𝒙
2) an exponential function 𝒆𝒌𝒙
3) trigonometric function 𝐜𝐨𝐬 𝒌𝒙 or 𝐬𝐢𝐧 𝒌𝒙
 Fundamental forms of 𝒚𝒑 based on the form of 𝒇(𝒙)

𝒇 𝒙 Fundamental Forms of 𝒚𝒑
𝛼(𝑐𝑜𝑛𝑠𝑡𝑎𝑛𝑡) 𝐴
𝛼𝑥 𝑛 𝐴0 + 𝐴1 𝑥 + ⋯ + 𝐴𝑛−1 𝑥 𝑛−1 + 𝐴𝑛 𝑥 𝑛
𝛼 cos 𝑘𝑥
𝐴 cos 𝑘𝑥 + 𝐵 sin 𝑘𝑥
𝛼 sin 𝑘𝑥
𝛼𝑒 𝑘𝑥 𝐴𝑒 𝑘𝑥
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 General Steps
1) Check whether 𝒇(𝒙) is composed of terms listed in the table.
2) Solve for the roots of 𝝓 𝒎 = 𝟎 and set-up 𝒚𝒄 .
3) Set-up 𝒚𝒑 based on the form of 𝒇(𝒙).
Note: If 𝒇(𝒙) is a multi-function or a combination of the three types of function
previously mentioned, treat each term or function individually in setting up 𝒚𝒑 .
4) Check the terms in 𝒚𝒄 if they are duplicated in 𝒚𝒑 ; if there are any, then multiply
the next sufficient power of 𝒙 to 𝒚𝒑 to eliminate duplication.
5) Check for duplication in 𝒚𝒑 , combine like terms under one constant to eliminate
duplication.
6) Solve for 𝝓 𝑫 𝒚𝒑 and then equate to 𝒇 𝒙 or ( 𝝓 𝑫 𝒚𝒑 = 𝒇 𝒙 .
7) Solve for the constants.
8) Substitute the constants to 𝒚𝒑 .
9) Obtain the complete solution by adding 𝒚𝒄 and 𝒚𝒑 : 𝒚 = 𝒚𝒄 + 𝒚𝒑
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
𝑑2 𝑦 𝑑𝑦
 Example 1: Given: +3 + 2𝑦 = 4𝑥 2
𝑑𝑥 2 𝑑𝑥
Required: General/Complete Solution
Solution
 Complementary function 𝑦𝑐 :
Auxiliary Equation: 𝑚2 + 3𝑚 + 2 = 0
Roots: 𝑚 = −1, −2
𝒚𝒄 = 𝑪𝟏 𝒆−𝒙 + 𝑪𝟐 𝒆−𝟐𝒙
 Particular Integral 𝑦𝑝 :
𝑓 𝑥 = 4𝑥 2
Look for the corresponding fundamental form of 𝑦𝑝 based on the table
𝑦𝑝 = 𝐴 + 𝐵𝑥 + 𝐶𝑥 2
So that,
𝑦𝑝 ′ = 𝐵 + 2𝐶𝑥 and 𝑦𝑝 ′′ = 2𝐶
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
𝑑2 𝑦 𝑑𝑦
 Example 1: Given: +3 + 2𝑦 = 4𝑥 2
𝑑𝑥 2 𝑑𝑥
Solution
 Particular Integral 𝑦𝑝 :
Substitute 𝑦𝑝 , 𝑦𝑝 ′, and 𝑦𝑝 ′′ to 𝝓 𝑫 𝒚𝒑 and then equate to 𝑓 𝑥
𝑑2 𝑦 𝑑𝑦
+ 3 + 2𝑦 = 4𝑥 2 ⟺ (𝐷 2 + 3𝐷 + 2)𝑦 = 4𝑥 2
𝑑𝑥 2 𝑑𝑥
2𝐶 + 3 𝐵 + 2𝐶𝑥 + 2 𝐴 + 𝐵𝑥 + 𝐶𝑥 2 = 4𝑥 2
2𝐴 + 3𝐵 + 2𝐶 + 2𝐵 + 6𝐶 𝑥 + 2𝐶𝑥 2 = 4𝑥 2
Solving for the constants, we solve the following system of equations
𝑥 0 : 2𝐴 + 3𝐵 + 2𝐶 = 0 𝑥 1 : 2𝐵 + 6𝐶 = 0 𝑥 2 : 2𝐶 = 4

𝐴=7 𝐵 = −6 𝐶=2
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
𝑑2 𝑦 𝑑𝑦
 Example 1: Given: +3 + 2𝑦 = 4𝑥 2
𝑑𝑥 2 𝑑𝑥
Solution
 Particular Integral 𝑦𝑝 :
So now we have 𝑦𝑝
𝑦𝑝 = 𝐴 + 𝐵𝑥 + 𝐶𝑥 2
𝑦𝑝 = 7 − 6𝑥 + 2𝑥 2

 General/complete solution is
𝑦 = 𝑦𝑐 + 𝑦𝑝

𝒚 = 𝑪𝟏 𝒆−𝒙 + 𝑪𝟐 𝒆−𝟐𝒙 + 𝟕 − 𝟔𝒙 + 𝟐𝒙𝟐


Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 2: Given: 𝑦 ′′′ + 𝑦 ′′ = 3𝑒 𝑥 + 4𝑥 2
Required: General/Complete Solution
Solution
 Complementary function 𝑦𝑐 :
Auxiliary Equation: 𝑚3 +𝑚2 = 0
Roots: 𝑚 = 0,0, −1
𝒚𝒄 = 𝑪𝟏 + 𝑪𝟐 𝒙 + 𝑪𝟑 𝒆−𝒙
 Particular Integral 𝑦𝑝 :
𝑓 𝑥 = 3𝑒 𝑥 + 4𝑥 2
Look for the corresponding fundamental form of 𝑦𝑝 based on the table
𝑦𝑝 = 𝐴𝑒 𝑥 + 𝐵 + 𝐶𝑥 + 𝐷𝑥 2

Note: Since the part 𝐵 + 𝐶𝑥 + 𝐷𝑥 2 duplicates some terms of 𝑦𝑐 , this must


be multiplied by 𝑥 2 to avoid duplication
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 2: Given: 𝑦 ′′′ + 𝑦 ′′ = 3𝑒 𝑥 + 4𝑥 2
Solution
 Particular Integral 𝑦𝑝 :
𝑦𝑝 = 𝐴𝑒 𝑥 + 𝐵𝑥 2 + 𝐶𝑥 3 + 𝐷𝑥 4
So that,
𝑦𝑝 ′ = 𝐴𝑒 𝑥 + 2𝐵𝑥 + 3𝐶𝑥 2 + 4𝐷𝑥 3
𝑦𝑝 ′′ = 𝐴𝑒 𝑥 + 2𝐵 + 6𝐶𝑥 + 12𝐷𝑥 2
𝑦𝑝 ′′′ = 𝐴𝑒 𝑥 + 6𝐶 + 24𝐷𝑥

Substitute 𝑦𝑝 and its derivatives to 𝝓 𝑫 𝒚𝒑 and then equate to 𝑓 𝑥


𝐴𝑒 𝑥 + 6𝐶 + 24𝐷𝑥 + 𝐴𝑒 𝑥 + 2𝐵 + 6𝐶𝑥 + 12𝐷𝑥 2 = 3𝑒 𝑥 + 4𝑥 2

2𝐴𝑒 𝑥 + 2𝐵 + 6𝐶 + 6𝐶 + 24𝐷 𝑥 + 12𝐷𝑥 2 = 3𝑒 𝑥 + 4𝑥 2


Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 2: Given: 𝑦 ′′′ + 𝑦 ′′ = 3𝑒 𝑥 + 4𝑥 2
Solution
 Particular Integral 𝑦𝑝 :
Solving for the constants, we solve the following system of equations
𝑒 𝑥 : 2𝐴 = 3 𝑥 1 : 6𝐶 + 24𝐷 = 0
𝑥 0 : 2𝐵 + 6𝐶 = 0 𝑥 2 : 12𝐷 = 4
3 4 1
𝐴= 𝐵=4 𝐶=− 𝐷=
2 3 3
So now we have 𝑦𝑝
𝟑 𝒙 𝟐
𝟒 𝟑 𝟏 𝟒
𝑦𝑝 = 𝐴𝑒 𝑥 + 𝐵𝑥 2 + 𝐶𝑥 3 + 𝐷𝑥 4 ⟺ 𝒚𝒑 = 𝒆 + 𝟒𝒙 − 𝒙 + 𝒙
𝟐 𝟑 𝟑
 Finally, the general/complete solution is
𝟑 𝟒 𝟏
𝒚 = 𝒚𝒄 + 𝒚𝒑 = 𝑪𝟏 + 𝑪𝟐 𝒙 + 𝑪𝟑 𝒆−𝒙 + 𝒆𝒙 + 𝟒𝒙𝟐 − 𝒙𝟑 + 𝒙𝟒
𝟐 𝟑 𝟑
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 3: Given: 𝑦 ′′ + 𝑦 = 𝑥 cos 𝑥 − cos 𝑥
Required: General/Complete Solution
Solution
 Complementary function 𝑦𝑐 :
Auxiliary Equation: 𝑚2 + 1 = 0
Roots: 𝑚 = ±𝑖
𝒚𝒄 = 𝑪𝟏 𝐜𝐨𝐬 𝒙 + 𝑪𝟐 𝐬𝐢𝐧 𝒙
 Particular Integral 𝑦𝑝 :
𝑓 𝑥 = 𝑥 cos 𝑥 − cos 𝑥
Look for the corresponding fundamental form of 𝑦𝑝 based on the table
𝑦𝑝 = 𝐴 + 𝐵𝑥 𝐶 cos 𝑥 + 𝐷 sin 𝑥 + 𝐸 cos 𝑥 + 𝐹 sin 𝑥
Note: Since the part 𝐸 cos 𝑥 + 𝐹 sin 𝑥 duplicates some terms of 𝑦𝑐 , this must
be multiplied by 𝑥 to avoid duplication
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 3: Given: 𝑦 ′′ + 𝑦 = 𝑥 cos 𝑥 − cos 𝑥
Solution
 Particular Integral 𝑦𝑝 :

𝑦𝑝 = 𝐴 + 𝐵𝑥 𝐶 cos 𝑥 + 𝐷 sin 𝑥 + 𝑥 𝐸 cos 𝑥 + 𝐹 sin 𝑥


Note: Since the part 𝐴 + 𝐵𝑥 𝐶 cos 𝑥 + 𝐷 sin 𝑥 duplicates also some
terms of 𝑦𝑐 , this must be multiplied by 𝑥 to avoid duplication
𝑦𝑝 = 𝑥 𝐴 + 𝐵𝑥 𝐶 cos 𝑥 + 𝐷 sin 𝑥 + 𝑥 𝐸 cos 𝑥 + 𝐹 sin 𝑥
𝑦𝑝 = 𝑥 𝐴 + 𝐵𝑥 𝐶 cos 𝑥 + 𝐷 sin 𝑥 + 𝐸 cos 𝑥 + 𝐹 sin 𝑥
𝑦𝑝 = 𝑥 𝐴𝐶 cos 𝑥 + 𝐴𝐷 sin 𝑥 + 𝐵𝐶𝑥 cos 𝑥 + 𝐵𝐷𝑥 sin 𝑥 + 𝐸 cos 𝑥 + 𝐹 sin 𝑥

𝑦𝑝 = 𝐺𝑥 cos 𝑥 + 𝐻𝑥 sin 𝑥 + 𝐼𝑥 2 cos 𝑥 + 𝐽𝑥 2 sin 𝑥


Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 3: Given: 𝑦 ′′ + 𝑦 = 𝑥 cos 𝑥 − cos 𝑥
Solution
 Particular Integral 𝑦𝑝 :
So that,
𝑦𝑝′ = 𝐺 −𝑥 sin 𝑥 + cos 𝑥 + 𝐻 𝑥 cos 𝑥 + sin 𝑥
+𝐼 −𝑥 2 sin 𝑥 + 2𝑥 cos 𝑥 + 𝐽 𝑥 2 cos 𝑥 + 2𝑥 sin 𝑥

𝑦𝑝′ = 𝐺 cos 𝑥 + 𝐻 sin 𝑥 + 2𝐼 + 𝐻 𝑥 cos 𝑥


+ 2𝐽 − 𝐺 𝑥 sin 𝑥 + 𝐽𝑥 2 cos 𝑥 − 𝐼𝑥 2 sin 𝑥

𝑦𝑝′′ = −𝐺 sin 𝑥 + 𝐻 cos 𝑥 + 2𝐼 + 𝐻 −𝑥 sin 𝑥 + cos 𝑥


+ 2𝐽 − 𝐺 𝑥 cos 𝑥 + sin 𝑥 + 𝐽 −𝑥 2 sin 𝑥 + 2𝑥 cos 𝑥 − 𝐼 𝑥 2 cos 𝑥 + 2𝑥 sin 𝑥

𝑦𝑝′′ = 2𝐼 + 2𝐻 cos 𝑥 + 2𝐽 − 2𝐺 sin x + 4𝐽 − 𝐺 𝑥 cos 𝑥


+ 4𝐼 − 𝐻 𝑥 sin 𝑥 − 𝐼𝑥 2 cos 𝑥 − 𝐽𝑥 2 sin 𝑥
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 3: Given: 𝑦 ′′ + 𝑦 = 𝑥 cos 𝑥 − cos 𝑥
Solution
 Particular Integral 𝑦𝑝 :
Substitute 𝑦𝑝 and its derivatives to the differential equation,
ሾ 2𝐼 + 2𝐻 cos 𝑥 + 2𝐽 − 2𝐺 sin 𝑥 + 4𝐽 − 𝐺 𝑥 cos 𝑥 + 4𝐼 − 𝐻 𝑥 sin 𝑥 − 𝐼𝑥 2 cos 𝑥
− 𝐽𝑥 2 sin 𝑥 ሿ + 𝐺𝑥 cos 𝑥 + 𝐻𝑥 sin 𝑥 + 𝐼𝑥 2 cos 𝑥 + 𝐽𝑥 2 sin 𝑥 = 𝑥 cos 𝑥 − cos 𝑥

2𝐼 + 2𝐻 cos 𝑥 + 2𝐽 − 2𝐺 sin 𝑥 + 4𝐽𝑥 cos 𝑥 + 4𝐼 𝑥 sin 𝑥 = 𝑥 cos 𝑥 − cos 𝑥

Solving the following system of equation would give the constants,


cos 𝑥 : 2𝐼 + 2𝐻 = −1 𝑥 cos 𝑥 : 4𝐽 = 1
sin 𝑥 : 2𝐽 − 2𝐺 = 0 𝑥 sin 𝑥 : 4𝐼 = 0
1 1 1
𝐺= 𝐻=− 𝐼=0 𝐽=
4 2 4
Non-homogeneous LDE with Constant Coefficients
 Method of Undetermined Coefficients (MUC)
 Example 3: Given: 𝑦 ′′ + 𝑦 = 𝑥 cos 𝑥 − cos 𝑥
Solution
 Particular Integral 𝑦𝑝 :
So now we have 𝑦𝑝
𝑦𝑝 = 𝐺𝑥 cos 𝑥 + 𝐻𝑥 sin 𝑥 + 𝐼𝑥 2 cos 𝑥 + 𝐽𝑥 2 sin 𝑥
𝟏 𝟏 𝟏 𝟐
𝒚𝒑 = 𝒙 𝐜𝐨𝐬 𝒙 − 𝒙 𝐬𝐢𝐧 𝒙 + 𝒙 𝐬𝐢𝐧 𝒙
𝟒 𝟐 𝟒
 Finally, the general/complete solution is
𝟏 𝟏 𝟏 𝟐
𝒚 = 𝒚𝒄 + 𝒚𝒑 = 𝑪𝟏 𝐜𝐨𝐬 𝒙 + 𝑪𝟐 𝐬𝐢𝐧 𝒙 + 𝒙 𝐜𝐨𝐬 𝒙 − 𝒙 𝐬𝐢𝐧 𝒙 + 𝒙 𝐬𝐢𝐧 𝒙
𝟒 𝟐 𝟒
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 applied to any linear differential equation of any order with constant or
variable coefficients for which the 𝒚𝒄 is known where
𝒚𝒄 = 𝒄𝟏 𝒚𝟏 + 𝒄𝟐 𝒚𝟐 + 𝒄𝟑 𝒚𝟑 + ⋯ + 𝒄𝒏 𝒚𝒏

 The basic idea of MVP is to write the particular solution 𝒚𝒑 in the same
manner as the complementary function 𝒚𝒄 and replace the constants, or
parameters, 𝒄𝟏 ,𝒄𝟐 ,𝒄𝟑 , ⋯, 𝒄𝒏 with variables 𝒗𝟏 ,𝒗𝟐 , 𝒗𝟑 ⋯, 𝒗𝒏 , which
are functions of 𝒙, such that
𝒚𝒑 = 𝒗𝟏 𝒚𝟏 + 𝒗𝟐 𝒚𝟐 + 𝒗𝟑 𝒚𝟑 + ⋯ + 𝒗𝒏 𝒚𝒏

 General Solution:
𝒚 = 𝒚𝒄 + 𝒚𝒑
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 General Steps
1. Solve for 𝒚𝒄
2. Set-up 𝒚𝒑 based on 𝒚𝒄 by replacing the arbitrary constants, 𝑐s, of 𝒚𝒄 by functions of
𝑣s (which are functions of 𝑥).
3. Obtain the equations for solving the 𝑣s by differentiating as many times as the order
of the D.E. After each differentiation, except in the last differentiation, set the sum of
all terms containing derivatives of 𝑣s equal to zero. For the last differentiation, set the
𝒇(𝒙)
sum of its terms equal to where 𝒂𝒏 is the coefficient of the highest derivative
𝒂𝒏
(𝑫𝒏 ) of the D.E.
𝑣1 ′𝑦1 + 𝑣2 ′𝑦2 + 𝑣3 ′𝑦3 + ⋯ + 𝑣𝑛 ′𝑦𝑛 = 0
𝑣1 ′𝑦1 ′ + 𝑣2 ′𝑦2 ′ + 𝑣3 ′𝑦3 ′ + ⋯ + 𝑣𝑛 ′𝑦𝑛 ′ = 0
𝑣1 ′𝑦1 ′′ + 𝑣2 ′𝑦2 ′′ + 𝑣3 ′𝑦3 ′′ + ⋯ + 𝑣𝑛 ′𝑦𝑛 ′′ = 0

𝑣1 ′𝑦1 𝑛−2 + 𝑣2 ′𝑦2 𝑛−2 + 𝑣3 ′𝑦3 𝑛−2 + ⋯ + 𝑣𝑛 ′𝑦𝑛 (𝑛−2) = 0
𝑛−1 𝑛−1 𝑛−1 (𝑛−1)
𝑓(𝑥)
𝑣1 ′𝑦1 + 𝑣2 ′𝑦2 + 𝑣3 ′𝑦3 + ⋯ + 𝑣𝑛 ′𝑦𝑛 =
𝑎𝑛
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 General Steps
In Matrix Form,
𝒚𝟏 𝒚𝟐 𝒚𝟑 ⋯ 𝒚𝒏 𝒗𝟏 ′ 𝟎
𝒚𝟏 ′ 𝒚𝟐 ′ 𝒚𝟑 ′ … 𝒚𝒏 ′ 𝒗𝟐 ′ 𝟎
𝒚𝟏 ′′ 𝒚𝟐 ′′ 𝒚𝟑 ′′ ⋯ 𝒚𝒏 ′′ 𝒗𝟑 ′ 𝟎
⋮ ⋮ ⋮ ⋮ ⋮ =
⋮ ⋮
𝒚𝟏 (𝒏−𝟐) 𝒚𝟐 (𝒏−𝟐) 𝒚𝟑 (𝒏−𝟐) ⋯ 𝒚𝒏 (𝒏−𝟐) 𝒗𝒏−𝟏 ′ 𝟎
𝒚𝟏 (𝒏−𝟏) 𝒚𝟐 (𝒏−𝟏) 𝒚𝟑 (𝒏−𝟏) ⋯ 𝒚𝒏 (𝒏−𝟏) 𝒗𝒏 ′ 𝒇(𝒙)/𝒂𝒏
4. Solve for 𝑣1 ′, 𝑣2 ′, 𝑣3 ′, …, 𝑣𝑛 ′, where 𝑛 is the order of the D.E., using Cramer’s
Rule, Elimination or Subtraction.
5. Obtain 𝑣1 , 𝑣2 , 𝑣3 , …, 𝑣𝑛 by integration and then substitute in 𝒚𝒑 .
6. Obtain the complete solution by adding 𝒚𝒄 and 𝒚𝒑 : 𝒚 = 𝒚𝒄 + 𝒚𝒑
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 Example 1: Given: 𝑦 ′′ + 𝑦 = tan 𝑥
Required: General/Complete Solution
Solution
 Complementary function 𝑦𝑐 :
Auxiliary Equation: 𝑚2 + 1 = 0
Roots: 𝑚 = ±𝑖
𝒚𝒄 = 𝑪𝟏 𝒄𝒐𝒔 𝒙 + 𝑪𝟐 𝒔𝒊𝒏 𝒙
 Particular Integral 𝑦𝑝 :
Set-up 𝒚𝒑 based on𝒚𝒄 ,
𝑦𝑝 = 𝑣1 cos 𝑥 + 𝑣2 sin 𝑥 Note: 𝑦𝑝 = 𝑣1 𝑦1 + 𝑣2 𝑦2
Set-up equations for solving the 𝑣s,
𝟏 𝑣1 ′𝑦1 + 𝑣2 ′𝑦2 = 0 ⟶ 𝟏 𝒗𝟏 ′ 𝐜𝐨𝐬 𝒙 + 𝒗𝟐 ′ 𝐬𝐢𝐧 𝒙 = 𝟎
𝟐 𝑣1 ′𝑦1 ′ + 𝑣2 ′𝑦2 ′ = 𝑓(𝑥)/𝑎𝑛 ⟶ 𝟐 𝒗𝟏 ′ −𝐬𝐢𝐧 𝒙 + 𝒗𝟐 ′ 𝐜𝐨𝐬 𝒙 = 𝐭𝐚𝐧 𝒙
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 Example 1: Given: 𝑦 ′′ + 𝑦 = tan 𝑥
Solution
In matrix form, 𝐜𝐨𝐬 𝒙 𝐬𝐢𝐧 𝒙 𝒗𝟏 ′ 𝟎
=
−𝐬𝐢𝐧 𝒙 𝐜𝐨𝐬 𝒙 𝒗𝟐 ′ 𝐭𝐚𝐧 𝒙
By Cramer’s Rule,
0 sin 𝑥 cos 𝑥 0
𝑣1 ′ = tan 𝑥 cos 𝑥 𝑣2 ′ = −sin 𝑥 tan 𝑥
cos 𝑥 sin 𝑥 cos 𝑥 sin 𝑥
−sin 𝑥 cos 𝑥 −sin 𝑥 cos 𝑥
sin2 𝑥
𝑣1 ′ = − sin 𝑥 tan 𝑥 = − = cos 𝑥 − sec 𝑥
cos 𝑥
𝒗𝟏 = 𝐬𝐢𝐧 𝒙 − 𝐥𝐧 𝐬𝐞𝐜 𝒙 + 𝐭𝐚𝐧 𝒙

𝑣2 ′ = cos 𝑥 tan 𝑥 = sin 𝑥


𝒗𝟐 = − 𝐜𝐨𝐬 𝒙
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 Example 1: Given: 𝑦 ′′ + 𝑦 = tan 𝑥
Solution
So, now we have 𝒚𝒑 as
𝑦𝑝 = 𝑣1 cos 𝑥 + 𝑣2 sin 𝑥
𝑦𝑝 = sin 𝑥 − ln sec 𝑥 + tan 𝑥 cos 𝑥 + − cos 𝑥 sin 𝑥

𝒚𝒑 = − 𝐜𝐨𝐬 𝒙 𝐥𝐧 𝐬𝐞𝐜 𝒙 + 𝐭𝐚𝐧 𝒙

Finally, the general/complete solution is


𝒚 = 𝒚𝒄 + 𝒚𝒑 = 𝑪𝟏 𝐜𝐨𝐬 𝒙 + 𝑪𝟐 𝐬𝐢𝐧 𝒙 − 𝐜𝐨𝐬 𝒙 𝐥𝐧 𝐬𝐞𝐜 𝒙 + 𝐭𝐚𝐧 𝒙
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
𝑑2 𝑦 𝑑𝑦
 Example 2: Given: −4 + 4𝑦 = 𝑥 + 1 𝑒 2𝑥
𝑑𝑥 2 𝑑𝑥
Required: General/Complete Solution
Solution
 Complementary function 𝑦𝑐 :
Auxiliary Equation: 𝑚2 − 4𝑚 + 4 = 0 Roots: 𝑚 = 2, 2

𝒚𝒄 = 𝑪𝟏 𝒆𝟐𝒙 + 𝑪𝟐 𝒙𝒆𝟐𝒙
 Particular Integral 𝑦𝑝 :
Set-up 𝒚𝒑 based on𝒚𝒄 ,
𝑦𝑝 = 𝑣1 𝑒 2𝑥 + 𝑣2 𝑥𝑒 2𝑥
Set-up equations for solving the 𝑣s,
𝟏 𝒗𝟏 ′𝒆𝟐𝒙 + 𝒗𝟐 ′𝒙𝒆𝟐𝒙 = 𝟎
𝟐 𝒗𝟏 ′𝟐𝒆𝟐𝒙 + 𝒗𝟐 ′ 𝟐𝒙𝒆𝟐𝒙 + 𝒆𝟐𝒙 = 𝒙 + 𝟏 𝒆𝟐𝒙
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
𝑑2 𝑦 𝑑𝑦
 Example 2: Given: −4 + 4𝑦 = 𝑥 + 1 𝑒 2𝑥
𝑑𝑥 2 𝑑𝑥
Solution
In matrix form, 𝒆𝟐𝒙 𝒙𝒆𝟐𝒙 𝒗𝟏 ′ 𝟎
=
𝟐𝒆 𝟐𝒙 𝟐𝒙
𝟐𝒙𝒆 + 𝒆 𝟐𝒙 𝒗 𝟐 ′ 𝒙 + 𝟏 𝒆𝟐𝒙
By Cramer’s Rule,
0 𝑥𝑒 2𝑥 𝑒 2𝑥 0
𝑥 + 1 𝑒 2𝑥 2𝑥𝑒 2𝑥 + 𝑒 2𝑥 2𝑒 2𝑥 𝑥 + 1 𝑒 2𝑥
𝑣1 ′ = 𝑣2 ′ = 2𝑥
𝑒 2𝑥 𝑥𝑒 2𝑥 𝑒 𝑥𝑒 2𝑥
2𝑒 2𝑥 2𝑥𝑒 2𝑥 + 𝑒 2𝑥 2𝑒 2𝑥 2𝑥𝑒 2𝑥 + 𝑒 2𝑥

𝑣1 ′ = −𝑥 2 − 𝑥 𝑣2 ′ = 𝑥 + 1
𝒙𝟑 𝒙𝟐 𝒙𝟐
𝒗𝟏 = − − 𝒗𝟐 = +𝒙
𝟑 𝟐 𝟐
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
𝑑2 𝑦 𝑑𝑦
 Example 2: Given: −4 + 4𝑦 = 𝑥 + 1 𝑒 2𝑥
𝑑𝑥 2 𝑑𝑥
Solution
So, now we have 𝒚𝒑 as
𝑦𝑝 = 𝑣1 𝑒 2𝑥 + 𝑣2 𝑥𝑒 2𝑥
𝑥 3 𝑥 2 2𝑥 𝑥2
𝑦𝑝 = − − 𝑒 + + 𝑥 𝑥𝑒 2𝑥
3 2 2

𝒙𝟑 𝒙𝟐 𝟐𝒙
𝒚𝒑 = + 𝒆
𝟔 𝟐

Finally, the general/complete solution is


𝟑 𝟐
𝒙 𝒙
𝒚 = 𝒚𝒄 + 𝒚𝒑 = 𝑪𝟏 𝒆𝟐𝒙 + 𝑪𝟐 𝒙𝒆𝟐𝒙 + + 𝒆𝟐𝒙
𝟔 𝟐
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 Example 3: Given: 𝐷2 − 2𝐷 + 10 𝑦 = 9𝑒 −𝑥 sec 3𝑥
Required: General/Complete Solution
Solution
 Complementary function 𝑦𝑐 :
Auxiliary Equation: 𝑚2 + 2𝑚 + 10 = 0 Roots: 𝑚 = −1 ± 3𝑖
𝑦𝑐 = 𝑒 −𝑥 𝐶1 cos 3𝑥 + 𝐶2 sin 3𝑥 = 𝑪𝟏 𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 + 𝑪𝟐 𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙
 Particular Integral 𝑦𝑝 :
Set-up 𝒚𝒑 based on𝒚𝒄 ,
𝑦𝑝 = 𝑣1 𝑒 −𝑥 cos 3𝑥 + 𝑣2 𝑒 −𝑥 sin 3𝑥
Set-up equations for solving the 𝑣s,
𝟏 𝒗𝟏 ′ 𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 + 𝒗𝟐 ′𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙 = 𝟎
𝟐 𝒗𝟏 ′ 𝒆−𝒙 −𝟑 𝐬𝐢𝐧 𝟑𝒙 + −𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 + 𝒗𝟐 ′ሾ𝒆−𝒙 𝟑 𝐜𝐨𝐬 𝟑𝒙
+ −𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙ሿ = 𝟗𝒆−𝒙 𝐬𝐞𝐜 𝟑𝒙
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 Example 3: Given: 𝐷2 − 2𝐷 + 10 𝑦 = 9𝑒 −𝑥 sec 3𝑥
Solution
In matrix form,
𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙 𝒗𝟏 ′ 𝟎
=
𝒆−𝒙 −𝟑 𝐬𝐢𝐧 𝟑𝐱 + −𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 𝒆−𝒙 𝟑 𝐜𝐨𝐬 𝟑𝒙 + −𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙 𝒗𝟐 ′ 𝟗𝒆−𝒙 𝐬𝐞𝐜 𝟑𝒙

By Cramer’s Rule,
0 𝑒 −𝑥 sin 3𝑥
9𝑒 −𝑥 sec 3𝑥 𝑒 −𝑥 3 cos 3𝑥 + −𝑒 −𝑥 sin 3𝑥
𝑣1 ′ =
𝑒 −𝑥 cos 3𝑥 𝑒 −𝑥 sin 3𝑥
𝑒 −𝑥 −3 sin 3𝑥 + −𝑒 −𝑥 cos 3𝑥 𝑒 −𝑥 3 cos 3𝑥 + −𝑒 −𝑥 sin 3𝑥

𝑒 −𝑥 cos 3𝑥 0
𝑒 −𝑥 −3 sin 3𝑥 + −𝑒 −𝑥 cos 3𝑥 9𝑒 −𝑥 sec 3𝑥
𝑣2 ′ =
𝑒 −𝑥 cos 3𝑥 𝑒 −𝑥 sin 3𝑥
𝑒 −𝑥 −3 sin 3𝑥 + −𝑒 −𝑥 cos 3𝑥 𝑒 −𝑥 3 cos 3𝑥 + −𝑒 −𝑥 sin 3𝑥
Non-homogeneous LDE with Constant Coefficients
 Method of Variation of Parameters (MVP)
 Example 3: Given: 𝐷2 − 2𝐷 + 10 𝑦 = 9𝑒 −𝑥 sec 3𝑥
Solution
−9sin 3𝑥 sec 3𝑥 sin 3𝑥 9cos 3𝑥 sec 3𝑥
𝑣1′ = = −3 𝑣2 ′ = = 3
3 cos 3𝑥 3
𝒗𝟏 = 𝐥𝐧 𝐜𝐨𝐬 𝟑𝒙 𝒗𝟐 = 𝟑𝒙

So, now we have 𝒚𝒑 as


𝑦𝑝 = 𝑣1 cos 𝑥 + 𝑣2 sin 𝑥
𝒚𝒑 = 𝐥𝐧 𝐜𝐨𝐬 𝟑𝒙 𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 + 𝟑𝒙𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙

Finally, the general/complete solution is


𝒚 = 𝒚𝒄 + 𝒚𝒑 = 𝑪𝟏 𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 + 𝑪𝟐 𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙
+ 𝐥𝐧 𝐜𝐨𝐬 𝟑𝒙 𝒆−𝒙 𝐜𝐨𝐬 𝟑𝒙 + 𝟑𝒙𝒆−𝒙 𝐬𝐢𝐧 𝟑𝒙

You might also like