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

Chapter Two Differential Equations

Chapter Two
Differential Equations
2-1 Introduction:-
A differential equation is an equation involving one or more derivatives
of an unknown function. The unknown function is denoted by y = y(x). The
order of a differential equation is the order of highest derivative that it
contains. The variable x is called independent variable while y is called
dependent variable. The exponent of the highest-order derivative is called the
degree of the differential equation. For example:

′ 2
𝑑2𝑦 𝑑𝑦
𝑦 = 𝑥 + 5𝑦 𝑜𝑟𝑑𝑒𝑟 (1), − 3 + 5𝑦 = 0 𝑜𝑟𝑑𝑒𝑟 (2)
𝑑𝑥 2 𝑑𝑥
The differential equation which involves one or several derivatives of an
unspecified function y of x, is called ordinary differential equation. The
equation which involve partial derivative with respect to two or more
independent variables, is called the partial differential equation. For example:
6
𝜕4𝑧 𝜕2𝑧
+( ) =𝑥
𝜕𝑥 4 𝜕𝑥𝜕𝑦
An equation which is linear in the dependent variable and its derivatives
is called a linear differential equation. The ordinary linear differential
equation of order n is of the form,
𝑝0 (𝑥)𝑦 (𝑛) + 𝑝1 (𝑥)𝑦 (𝑛−1) + ⋯ + 𝑝𝑛−1 (𝑥)𝑦 ′ + 𝑝𝑛 (𝑥)𝑦 = 𝑟(𝑥) … … (∗)
Then, a differential equation which is not linear is said to be nonlinear
differential equation, i.e. cannot be put in the form (*).
𝑦 ′′ − 4𝑦 ′ − 5𝑦 = 𝑒 3𝑥 𝑙𝑖𝑛𝑒𝑎𝑟, 𝑦 ′′ + sin(𝑦) = 0 𝑛𝑜𝑛𝑙𝑖𝑛𝑒𝑎𝑟
Solution of a differential equation
Solution of DE is a relation between the variables which is free of
derivatives and which satisfies the differential equation identically.

1
Chapter Two Differential Equations

A solution which contains at least one arbitrary constant is called general


solution. For example: 𝑦 = 𝑥 2 + 𝑐1 𝑥 + 𝑐2 has two arbitrary constants and
satisfies the 2nd order DE 𝑦 ′′ = 2.
A solution obtained from the general solution by assigning specific
values to the arbitrary constants is called particular solution. For example:
𝑦 = 𝑥 2 − 3𝑥 + 2 is a particular solution of 𝑦 ′′ = 2 and obtained from
general solution 𝑦 = 𝑥 2 + 𝑐1 𝑥 + 𝑐2 by putting 𝑐1 = −3, 𝑐2 = 2.
A solution which cannot be obtained from the general solution by
assigning specific values to its arbitrary constants is called singular solution.
2
For example: the general solution of 𝑥𝑦 ′ − 𝑦 ′ = 𝑦 is 𝑦 = 𝑐𝑥 − 𝑐 2 .
However, as soon by substituting another solution 𝑦 = 𝑥 2 ⁄4 which cannot be
obtained from the general solution for any constant c. The second solution
𝑦 = 𝑥 2 ⁄4 is a singular solution.

2-2 First-Order Differential Equations:-


2-2-1 Separable First-Order Equations:-
A 1st order separable DE is one that can be written in the form
𝑑𝑦
𝑔(𝑦) = 𝑓(𝑥)
𝑑𝑥
Then 𝑔(𝑦)𝑑𝑦 = 𝑓(𝑥)𝑑𝑥, and by integrating on both sides we obtain the
general solution
∫ 𝑔(𝑦)𝑑𝑦 = ∫ 𝑓(𝑥)𝑑𝑥 + 𝐶
Example:- Find the general solution of
𝑑𝑦 2 + sin (𝑥)
=
𝑑𝑥 3(𝑦 − 1)2
Sol.n:-
3(𝑦 − 1)2 𝑑𝑦 = (2 + sin(𝑥))𝑑𝑥 → ∫ 3(𝑦 − 1)2 𝑑𝑦 = ∫(2 + sin(𝑥))𝑑𝑥 + 𝐶
1
(𝑦 − 1)3 = 2𝑥 − cos(𝑥) + 𝐶 → 𝑦 = (2𝑥 − cos(𝑥) + 𝐶)3 + 1 𝐺. 𝑆.

2
Chapter Two Differential Equations

H.W.
𝑑𝑦
1) (4𝑥 + 𝑥𝑦 2 )𝑑𝑥 + (𝑦 + 𝑥 2 𝑦)𝑑𝑦 = 0 2) 𝑦 ′ − 2𝑦 = 5 3)𝑥 +𝑦 =𝑥
𝑑𝑥

2-2-2 Equations Reducible to Separable Form:-


The 1st order DE which is not separable, can be made separable by a
simple change of variables. For example, the equations of the form
𝑦 𝑦
𝑦 ′ = 𝑔 ( ) , where 𝑔 is any function of , can be reduced to separable form
𝑥 𝑥
𝑦
by substituting 𝑢 = , then
𝑥

𝑦 = 𝑢𝑥 → 𝑦 ′ = 𝑢 + 𝑥𝑢′ → 𝑢 + 𝑥𝑢′ = 𝑔(𝑢)


𝑑𝑢 𝑑𝑥
= … … (∗)
𝑔(𝑢) − 𝑢 𝑥
𝑦
By integration the two sides, then replace 𝑢 by , we obtain the general
𝑥

solution of equation (*) above.


Example:- Solve the equation
𝑑𝑦
𝑥2 = 𝑦 2 + 𝑥𝑦 + 𝑥 2
𝑑𝑥
Sol.n:-
𝑑𝑦 𝑦 2 𝑦 𝑦
= 2 + + 1 → 𝑙𝑒𝑡 = 𝑢 → 𝑦 = 𝑢𝑥 → 𝑦 ′ = 𝑢 + 𝑥𝑢′
𝑑𝑥 𝑥 𝑥 𝑥
𝑑𝑢 𝑑𝑢 𝑑𝑢 𝑑𝑥
∴𝑥 + 𝑢 = 𝑢2 + 𝑢 + 1 → 𝑥 = 𝑢2 + 1 → 2 =
𝑑𝑥 𝑑𝑥 𝑢 +1 𝑥
𝑑𝑢 𝑑𝑥
∫ 2 =∫ + 𝐶 → 𝑡𝑎𝑛−1 (𝑢) = ln(𝑥) + 𝐶 → 𝑢 = tan (ln(𝑥) + 𝐶)
𝑢 +1 𝑥
𝑦
= tan(𝑙𝑛(𝑥) + 𝐶) → 𝑦 = 𝑥 tan(𝑙𝑛(𝑥) + 𝐶) 𝐺. 𝑆.
𝑥
H.W.
𝑑𝑦 𝑦−𝑥
1) = 2) (𝑥 2 + 3𝑦 2 )𝑑𝑥 − 2𝑥𝑦𝑑𝑦 = 0 3) 𝑦 ′ = 𝑒 (2𝑥+𝑦−1) − 2
𝑑𝑥 𝑦+𝑥

3
Chapter Two Differential Equations

2-2-3 Exact Differential Equations:-


A first-order DE of the form 𝑀(𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0 is said to be
exact if the left-hand side is the total or exact differentiation of a function
𝑢(𝑥, 𝑦). Therefore, 𝑑𝑢(𝑥, 𝑦) = 0 → 𝑢(𝑥, 𝑦) = 𝐶 is the general solution. The
general solution can be obtained by two methods ( by inspection or by
analysis).
By Inspection
For example: 2𝑥 sin(3𝑦) 𝑑𝑥 + 3𝑥 2 cos (3𝑦)𝑑𝑦 = 0 → 𝑑(𝑥 2 sin(3𝑦)) = 0
∴ 𝑥 2 sin(3𝑦) = 𝐶 𝐺. 𝑆.
By Analysis
𝑀(𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0 → 𝑑𝑢(𝑥, 𝑦) = 0
𝜕𝑢 𝜕𝑢 𝜕𝑢 𝜕𝑢
But 𝑑𝑢 = 𝑑𝑥 + 𝑑𝑦 → = 𝑀(𝑥, 𝑦) … (1) , = 𝑁(𝑥, 𝑦) … (2)
𝜕𝑥 𝜕𝑦 𝜕𝑥 𝜕𝑦

𝜕𝑀(𝑥, 𝑦) 𝜕𝑁(𝑥, 𝑦)
= 𝑇ℎ𝑒 𝐷𝐸 𝑖𝑠 𝑒𝑥𝑎𝑐𝑡
𝜕𝑦 𝜕𝑥
By integrating (1) with respect to x:
𝜕𝑢(𝑥, 𝑦) 𝜕 𝜕𝑘(𝑦)
𝑢(𝑥, 𝑦) = [∫ 𝑀(𝑥, 𝑦)𝑑𝑥] + 𝑘(𝑦) → = [ ∫ 𝑀(𝑥, 𝑦)𝑑𝑥] +
𝜕𝑦 𝜕𝑦 𝜕𝑦
𝜕𝑘(𝑦) 𝜕
∴ = 𝑁(𝑥, 𝑦) − ∫ 𝑀(𝑥, 𝑦)𝑑𝑥]
𝜕𝑦 𝜕𝑦
𝜕
∴ 𝑘(𝑦) = ∫ {𝑁(𝑥, 𝑦) − ∫ 𝑀(𝑥, 𝑦)𝑑𝑥]} 𝑑𝑦
𝜕𝑦
Or by integrating (2) with respect to y:

𝑢(𝑥, 𝑦) = [∫ 𝑁(𝑥, 𝑦)𝑑𝑦] + 𝑘(𝑥)

𝜕
∴ 𝑘(𝑥) = ∫ {𝑀(𝑥, 𝑦) − ∫ 𝑁(𝑥, 𝑦)𝑑𝑦]} 𝑑𝑥
𝜕𝑥
Example:- Solve the equation
(3𝑥 2 𝑦 + 8𝑥𝑦 2 )𝑑𝑥 + (𝑥 3 + 8𝑥 2 𝑦 + 12𝑦 2 )𝑑𝑦 = 0
Sol.n:-
𝑀(𝑥, 𝑦) = 3𝑥 2 𝑦 + 8𝑥𝑦 2 , 𝑁(𝑥, 𝑦) = 𝑥 3 + 8𝑥 2 𝑦 + 12𝑦 2
4
Chapter Two Differential Equations

𝜕𝑀(𝑥, 𝑦) 𝜕𝑁(𝑥, 𝑦)
= 3𝑥 2 + 16𝑥𝑦 , = 3𝑥 2 + 16𝑥𝑦 → 𝐷𝐸 𝑖𝑠 𝑒𝑥𝑎𝑐𝑡
𝜕𝑦 𝜕𝑥

𝑢(𝑥, 𝑦) = [∫ 𝑀(𝑥, 𝑦)𝑑𝑥] + 𝑘(𝑦) = [∫(3𝑥 2 𝑦 + 8𝑥𝑦 2 )𝑑𝑥] + 𝑘(𝑦)

= 𝑥 3 𝑦 + 4𝑥 2 𝑦 2 + 𝑘(𝑦)
𝜕𝑢(𝑥, 𝑦) 𝜕𝑘(𝑦)
= 𝑥 3 + 8𝑥 2 𝑦 + = 𝑁(𝑥, 𝑦) = 𝑥 3 + 8𝑥 2 𝑦 + 12𝑦 2
𝜕𝑦 𝜕𝑦
𝜕𝑘(𝑦)
∴ = 12𝑦 2 → 𝑘(𝑦) = ∫ 12𝑦 2 𝑑𝑦 = 4𝑦 3
𝜕𝑦
𝑢(𝑥, 𝑦) = 𝑥 3 𝑦 + 4𝑥 2 𝑦 2 + 4𝑦 3 → 𝑥 3 𝑦 + 4𝑥 2 𝑦 2 + 4𝑦 3 = 𝐶 𝐺. 𝑆.
H.W.
𝑑𝑦 1+𝑦 2 +3𝑥 2 𝑦
1) (3𝑦 + 𝑒 𝑥 )𝑑𝑥 + (3𝑥 + cos(𝑦))𝑑𝑦 = 0 2) =
𝑑𝑥 1−2𝑥𝑦−𝑥 3

(1+𝑥 2 )
3) 𝑒 𝑥 (𝑦𝑑𝑥 + 𝑑𝑦) + 𝑒 𝑦 (𝑑𝑥 + 𝑥𝑑𝑦) = 0 4) 2𝑥 ln(𝑦) 𝑑𝑥 + 𝑑𝑦 = 0
𝑦

2-2-4 Integrating Factors:-


Sometimes a given DE 𝑀(𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0 is not exact but can be
made exact by multiplied by a suitable function 𝐹(𝑥, 𝑦) ≠ 0 . This function is
then called an integrating factor.
𝑀𝑦 −𝑁𝑥
𝜇(𝑥) = ∫ 𝑑𝑥 function of x only 𝐼𝑓 = 𝑒 𝜇(𝑥)
𝑁
𝑁𝑥 −𝑀𝑦
𝜇(𝑦) = ∫ dy function of y only 𝐼𝑓 = 𝑒 𝜇(𝑦)
𝑀
Example:- Find the general solution of 2𝑑𝑥 + sec(𝑥) cos(𝑦) 𝑑𝑦 = 0.
Sol.n:- Multiplying the DE by cos(𝑥)
𝜕𝑀(𝑥, 𝑦) 𝜕𝑁(𝑥, 𝑦)
2 cos(𝑥) 𝑑𝑥 + cos(𝑦) = 0 → = =0
𝜕𝑦 𝜕𝑥

𝑢(𝑥, 𝑦) = [∫ 2 cos(𝑥) 𝑑𝑥] + 𝑘(𝑦) = 2 sin(𝑥) + 𝑘(𝑦)

𝜕𝑢 𝜕𝑘(𝑦)
= 𝑁(𝑥, 𝑦) = cos(𝑦) = → 𝑘(𝑦) = sin(𝑦) + 𝑐1
𝜕𝑦 𝜕𝑦
∴ 𝑢(𝑥, 𝑦) = 2 sin(𝑥) + sin(𝑦) + 𝑐1 → 2 sin(𝑥) + sin(𝑦) = 𝐾 𝐺. 𝑆.

5
Chapter Two Differential Equations

H.W.
1) 𝑥𝑑𝑦 − 𝑦𝑑𝑥 = 0 2) 𝑥𝑐𝑜𝑠ℎ(𝑦)𝑑𝑦 − sinh(𝑦) 𝑑𝑥 = 0 3)2𝑑𝑥 − 𝑒 𝑦−𝑥 𝑑𝑦 = 0
4) 𝑥𝑦 ′ + 𝑦 = 𝑥𝑦𝑦 ′ 5) 𝑦 ′ (𝑥𝑦 − 𝑦) = 1 6) 𝑦 = (𝑦𝑒 𝑦 − 2𝑥)𝑦 ′
7) 𝑦 − 𝑥𝑦 = 𝑦𝑦 ′ 8) (𝑥𝑦 2 + 𝑦) + (𝑥 2 𝑦 − 𝑥)𝑦 ′ = 0
9) 3(𝑦 4 + 1)𝑑𝑥 + 4𝑥𝑦 3 𝑑𝑦 = 0 10) 2𝑦𝑑𝑥 + (3𝑦 − 2𝑥)𝑑𝑦 = 0
2-2-5 Linear Differential Equations:-
A first-order DE is said to be linear if it can be written as:
𝑦 ′ + 𝑓(𝑥)𝑦 = 𝑟(𝑥)
• If r(x) = 0, the DE is said to be homogeneous linear DE
• If r(x)  0, the DE is said to be non-homogeneous linear DE
2-2-5-1 Homogeneous Linear DE
It can be solve by separating variables,
𝑑𝑦 𝑑𝑦
+ 𝑓(𝑥)𝑦 = 0 → ∫ = − ∫ 𝑓(𝑥)𝑑𝑥 + 𝑐 → ln(𝑦) = − ∫ 𝑓(𝑥)𝑑𝑥 + 𝑐
𝑑𝑥 𝑦
𝑦(𝑥) = 𝑒 − ∫ 𝑓(𝑥)𝑑𝑥 𝑒 𝑐 → 𝑦(𝑥) = 𝑘𝑣(𝑥) 𝐺. 𝑆. , 𝑤ℎ𝑒𝑟𝑒 𝑣(𝑥) = 𝑒 − ∫ 𝑓(𝑥)𝑑𝑥
2-2-5-2 Non-Homogeneous Linear DE
There are two methods to solve this type of DE:
By Integrating Factor
𝑦 ′ + 𝑓(𝑥)𝑦 = 𝑟(𝑥) → 𝑑𝑦 + {𝑓(𝑥)𝑦 − 𝑟(𝑥)}𝑑𝑥 = 0 … (1)
𝜕𝑀 𝜕𝑁
𝑀(𝑥, 𝑦) = 𝑓(𝑥)𝑦 − 𝑟(𝑥) , 𝑁(𝑥, 𝑦) = 1 → = 𝑓(𝑥), = 0 → 𝑛𝑜𝑡 𝑒𝑥𝑎𝑐𝑡
𝜕𝑦 𝜕𝑥
Multiplying (1) by integrating factor to convert DE to exact:
𝐹(𝑥)𝑑𝑦 + 𝐹(𝑥){𝑓(𝑥)𝑦 − 𝑟(𝑥)}𝑑𝑥 = 0
𝜕𝑀 𝜕𝑁 𝜕𝐹(𝑥) 𝜕𝐹(𝑥)
= 𝐹(𝑥)𝑓(𝑥) , = → = 𝑓(𝑥)𝑑𝑥 →
𝜕𝑦 𝜕𝑥 𝜕𝑥 𝐹(𝑥)

ln(𝐹(𝑥)) = ∫ 𝑓(𝑥)𝑑𝑥 → 𝐹(𝑥) = 𝑒 ∫ 𝑓(𝑥)𝑑𝑥 𝐼. 𝐹.

Or 𝐹(𝑥) = 𝑒 ℎ(𝑥) , where ℎ(𝑥) = ∫ 𝑓(𝑥)𝑑𝑥


𝑑
∴ 𝑒 ℎ(𝑥) (𝑦 ′ + 𝑓(𝑥)𝑦) = 𝑒 ℎ(𝑥) 𝑟(𝑥) → (𝑦𝑒 ℎ(𝑥) ) = 𝑒 ℎ(𝑥) 𝑟(𝑥)
𝑑𝑥
6
Chapter Two Differential Equations

𝑦𝑒 ℎ(𝑥) = ∫ 𝑒 ℎ(𝑥) 𝑟(𝑥)𝑑𝑥 + 𝑐 → 𝑦(𝑥) = 𝑒 −ℎ(𝑥) [∫ 𝑒 ℎ(𝑥) 𝑟(𝑥)𝑑𝑥 + 𝑐]

∴ 𝑦(𝑥) = [𝑒 −ℎ(𝑥) ∫ 𝑒 ℎ(𝑥) 𝑟(𝑥)𝑑𝑥] + 𝑐𝑒 −ℎ(𝑥) = 𝑦𝑝 (𝑥) + 𝑦ℎ (𝑥) 𝐺. 𝑆.

Where 𝑦𝑝 (𝑥): particular solution, 𝑦ℎ (𝑥): homogeneous solution


Example:- Find the general solution of 𝑦 ′ − 𝑦 = 𝑒 2𝑥
Sol.n:-
𝐹(𝑥) = 𝑒 ∫ 𝑓(𝑥)𝑑𝑥 = 𝑒 ∫ −𝑑𝑥 = 𝑒 −𝑥 = 𝑒 ℎ(𝑥)
𝑦𝑝 (𝑥) = 𝑒 𝑥 ∫ 𝑒 −𝑥 𝑒 2𝑥 𝑑𝑥 = 𝑒 2𝑥 , 𝑦ℎ (𝑥) = 𝑐𝑒 𝑥 → 𝑦(𝑥) = 𝑒 2𝑥 + 𝑐𝑒 𝑥 𝐺. 𝑆.
By Variation of Parameters
𝑦 ′ + 𝑓(𝑥)𝑦 = 𝑟(𝑥) … (1)
𝑙𝑒𝑡 𝑟(𝑥) = 0 𝑠𝑜 𝑡ℎ𝑎𝑡 𝑣(𝑥) = 𝑒 − ∫ 𝑓(𝑥)𝑑𝑥 → 𝑐𝑣(𝑥) 𝑡ℎ𝑒 𝐺. 𝑆. 𝑜𝑓 ℎ𝑜𝑚. 𝑒𝑞𝑢.
To solve non-homogeneous, the attempt consists replacing the constant c by a
variable u(x) [By Laxgrange]
∴ 𝑦(𝑥) = 𝑢(𝑥)𝑣(𝑥) … (2) → 𝑦 ′ = 𝑢𝑣 ′ + 𝑢′ 𝑣 … (3)
From (2) and (3) into (1):
𝑢𝑣 ′ + 𝑢′ 𝑣 + 𝑓(𝑥)[𝑢𝑣] = 𝑟(𝑥) → 𝑢′ 𝑣 + 𝑢[𝑣 ′ + 𝑓(𝑥)𝑣] = 𝑟(𝑥)
Since cv(x) is the solution of homogeneous → 𝑢[𝑣 ′ + 𝑓(𝑥)𝑣] = 0
𝑑𝑢 𝑟(𝑥) 𝑟(𝑥)
𝑢′ 𝑣 = 𝑟(𝑥) → = → 𝑢(𝑥) = ∫ 𝑑𝑥 + 𝑐
𝑑𝑥 𝑣(𝑥) 𝑣(𝑥)
𝑟(𝑥)
∴ 𝑦(𝑥) = 𝑣(𝑥) ∫ 𝑑𝑥 + 𝑐𝑣(𝑥) = 𝑦𝑝 (𝑥) + 𝑦ℎ (𝑥) 𝐺. 𝑆.
𝑣(𝑥)
2
Example:- Solve 𝑦 ′ − 𝑦 = 𝑥 2 cos(3𝑥)
𝑥
2 2)
Sol.n:- 𝑣(𝑥) = 𝑒 − ∫ 𝑓(𝑥)𝑑𝑥 = 𝑒 − ∫ −𝑥𝑑𝑥 = 𝑒 2 ln(𝑥) = 𝑒 ln (𝑥 = 𝑥2

2
𝑥 2 cos(3𝑥) 𝑥2
𝑦(𝑥) = 𝑥 ∫ 2
𝑑𝑥 + 𝑐𝑥 = sin(3𝑥) + 𝑐𝑥 2
2
𝐺. 𝑆.
𝑥 3
H.W.
1) 𝑥𝑦 ′ + (1 − 𝑥)𝑦 = 𝑥𝑒 𝑥 2) (𝑥 2 − 1)𝑦 ′ + 2y = (𝑥 + 1)2
3) 𝑦 ′ + 𝑦 = cos(𝑒 𝑥 ) 4) 𝑦 ′ + 𝑦 𝑡𝑎𝑛(𝑥) = sec(𝑥)

7
Chapter Two Differential Equations

2-2-6 Bernulli Equation:-


The form of this equation is
𝑑𝑦
+ 𝑓(𝑥)𝑦 = 𝑔(𝑥)𝑦 𝑎 , 𝑎 ∶ 𝑟𝑒𝑎𝑙 𝑛𝑢𝑚𝑏𝑒𝑟
𝑑𝑥
• If a = 0 : Bernulli equation constant into linear non-homogeneous DE
• If a  0 : Bernulli equation constant into linear homogeneous DE
Otherwise
𝑑𝑦 𝑑𝑤 𝑑𝑦
𝑦 −𝑎 + 𝑓(𝑥)𝑦1−𝑎 = 𝑔(𝑥) → 𝑙𝑒𝑡 𝑦1−𝑎 = 𝑤 → = (1 − 𝑎)𝑦 −𝑎
𝑑𝑥 𝑑𝑥 𝑑𝑥
1 𝑑𝑤
→ + 𝑓(𝑥)𝑤 = 𝑔(𝑥)
(1 − 𝑎) 𝑑𝑥
𝑑𝑤
𝑜𝑟 + (1 − 𝑎)𝑓(𝑥)𝑤 = (1 − 𝑎)𝑔(𝑥) 𝑙𝑖𝑛𝑒𝑎𝑟 𝐷𝐸(𝑛𝑜𝑛 − ℎ𝑜𝑚. )
𝑑𝑥
sin(𝑥)
Example:- Solve 𝑦 ′ = 𝑦[3 − − 𝑦]
2+cos(𝑥)
sin(𝑥) sin(𝑥)
Sol.n:- 𝑦 ′ − [3 − ] 𝑦 = −𝑦 2 → 𝑦 −2 𝑦 ′ − [3 − ] 𝑦 −1 = −1
2+cos(𝑥) 2+cos(𝑥)

Let 𝑦 −1 = 𝑤 → −𝑦 −2 𝑦 ′ = 𝑤 ′
sin(𝑥) sin(𝑥)
−𝑤 ′ − [3 − ] 𝑤 = −1 → 𝑤 ′ + [3 − ]𝑤 = 1
2 + cos(𝑥) 2 + cos(𝑥)
H.W.: Complete the solution

2-3 Second-Order Differential Equations:-


Second-order linear DE can be written as:
𝑦 ′′ + 𝑓(𝑥)𝑦 ′ + 𝑔(𝑥)𝑦 = 𝑟(𝑥) … (∗)
• If f(x) and g(x) are constants, DE with constant coefficients. Otherwise,
DE with variable coefficients
• If r(x) = 0, homogeneous form
• If r(x)  0, non-homogeneous form

8
Chapter Two Differential Equations

2-3-1 Homogeneous Second-Order DE with Constant Coefficients:-


It can be written as 𝑦 ′′ + 𝑎𝑦 ′ + 𝑏𝑦 = 0 … (1)
Let the solution of equ. (1) is 𝑦 = 𝑒 𝜆𝑥 → 𝑦 ′ = 𝜆𝑒 𝜆𝑥 → 𝑦 ′′ = 𝜆2 𝑒 𝜆𝑥
𝜆2 𝑒 𝜆𝑥 + 𝑎𝜆𝑒 𝜆𝑥 + 𝑏𝑒 𝜆𝑥 = 0 → 𝑒 𝜆𝑥 (𝜆2 + 𝑎𝜆 + 𝑏) = 0
𝑒 𝜆𝑥 ≠ 0 → (𝜆2 + 𝑎𝜆 + 𝑏) = 0 … (2) characteristics equ. or auxiliary equ.
1 1
𝜆1 = [−𝑎 + √𝑎2 − 4𝑏] , 𝜆2 = [−𝑎 − √𝑎2 − 4𝑏]
2 2
Case 1 Two Distinct Real Roots (𝑎2 > 4𝑏)
In this case 𝜆1 , 𝜆2 are both real, 𝜆1 ≠ 𝜆2
𝑦(𝑥) = 𝑘1 𝑦1 (𝑥) + 𝑘2 𝑦2 (𝑥) = 𝑘1 𝑒 𝜆1𝑥 + 𝑘2 𝑒 𝜆2𝑥 𝐺. 𝑆.
Case 2 Two Complex Conjugate Roots (4𝑏 > 𝑎2 )
1 1
𝜆1 = [−𝑎 + 𝑗√4𝑏 − 𝑎2 ] , 𝜆2 = [−𝑎 − 𝑗√4𝑏 − 𝑎2 ]
2 2
−𝑎 1
∴ 𝜆1 = 𝛼 + 𝑗𝛽 , 𝜆2 = 𝛼 − 𝑗𝛽 where 𝜆1 = , 𝜆2 = √4𝑏 − 𝑎2
2 2

𝑦1 (𝑥) = 𝑒 𝜆1𝑥 = 𝑒 (𝛼+𝑗𝛽)𝑥 = 𝑒 𝛼𝑥 𝑒 𝑗𝛽𝑥 = 𝑒 𝛼𝑥 [cos(𝛽𝑥) + 𝑗𝑠𝑖𝑛(𝛽𝑥)]


𝑦2 (𝑥) = 𝑒 𝛼𝑥 [cos(𝛽𝑥) − 𝑗𝑠𝑖𝑛(𝛽𝑥)] , where 𝑒 ±𝑗𝜃 = cos (𝜃) ± 𝑗𝑠𝑖𝑛(𝜃)
𝑦(𝑥) = 𝑘1 𝑒 𝛼𝑥 cos(𝛽𝑥) + 𝑘2 𝑒 𝛼𝑥 sin(𝛽𝑥) 𝐺. 𝑆.
Case 3 Real Double Roots (𝑎2 = 4𝑏)
−𝑎 −𝑎
𝜆1 = 𝜆2 = → 𝑦1 (𝑥) = 𝑒 𝜆1𝑥 = 𝑒 2 𝑥
2
The second solution can be obtained by using the variation of parameters
𝑦2 (𝑥) = 𝑢(𝑥)𝑦1 (𝑥) → 𝑦2 ′ = 𝑢𝑦1 ′ + 𝑢′ 𝑦1 → 𝑦2 ′′ = 𝑢𝑦1 ′′ + 2𝑢′ 𝑦1 ′ + 𝑢′′ 𝑦1
Into equ. (1):
𝑢𝑦1 ′′ + 2𝑢′ 𝑦1 ′ + 𝑢′′ 𝑦1 + 𝑎[𝑢𝑦1 ′ + 𝑢′ 𝑦1 ] + 𝑏𝑢𝑦1 = 0
𝑢[𝑦1 ′′ + 𝑎𝑦1 ′ + 𝑏𝑦1 ] + 𝑢′ [2𝑦1 ′ + 𝑎𝑦1 ] + 𝑢′′ 𝑦1 = 0
𝑦1 ′′ + 𝑎𝑦1 ′ + 𝑏𝑦1 = 0 because 𝑦1 is the first solution of the DE and satisfies
the equation
−𝑎 −𝑎𝑥 −𝑎 −𝑎 −𝑎
2𝑦1 ′ + 𝑎𝑦1 = 2 ( 𝑒 2 ) + 𝑎𝑒 2 𝑥 = −𝑎𝑒 2 𝑥 + 𝑎𝑒 2 𝑥 = 0
2

9
Chapter Two Differential Equations

𝑢′′ 𝑦1 = 0 → 𝑦1 ≠ 0 → 𝑢′′ = 0 → 𝑢 = 𝑐1 𝑥 + 𝑐2 → 𝑦2 = (𝑐1 𝑥 + 𝑐2 )𝑦1


−𝑎
𝑥
∴ 𝑦(𝑥) = (𝑘1 𝑥 + 𝑘2 )𝑒 2 𝐺. 𝑆.
Example:- Solve 𝑦 ′′ + 𝑦 ′ − 2𝑦 = 0
Sol.n:- 𝑦 = 𝑒 𝜆𝑥 → 𝑦 ′ = 𝜆𝑒 𝜆𝑥 → 𝑦 ′′ = 𝜆2 𝑒 𝜆𝑥
𝜆2 + 𝜆 − 2 = 0 → (𝜆 + 2)(𝜆 − 1) = 0 → 𝜆1 = −2, 𝜆2 = 1
𝑦(𝑥) = 𝑘1 𝑒 −2𝑥 + 𝑘2 𝑒 𝑥 𝐺. 𝑆.
Example:- Solve 𝑦 ′′ − 2𝑦 ′ + 10𝑦 = 0
Sol.n:- 𝑦 = 𝑒 𝜆𝑥 → 𝑦 ′ = 𝜆𝑒 𝜆𝑥 → 𝑦 ′′ = 𝜆2 𝑒 𝜆𝑥
𝜆2 − 2𝜆 + 10 = 0 → 𝜆1,2 = 1 ± 𝑗3
𝑦(𝑥) = 𝑘1 𝑒 𝑥 cos(3𝑥) + 𝑘2 𝑒 𝑥 sin(3𝑥) 𝐺. 𝑆.
Example:- Solve 𝑦 ′′ + 8𝑦 ′ + 16𝑦 = 0
Sol.n:- 𝑦 = 𝑒 𝜆𝑥 → 𝑦 ′ = 𝜆𝑒 𝜆𝑥 → 𝑦 ′′ = 𝜆2 𝑒 𝜆𝑥
𝜆2 + 8𝜆 + 16 = 0 → (𝜆 + 4)(𝜆 + 4) = 0 → 𝜆1 = 𝜆2 = −4
𝑦(𝑥) = (𝑘1 𝑥 + 𝑘2 )𝑒 −4𝑥 𝐺. 𝑆.
H.W. 1) 𝑦 ′′ − 𝑦 ′ − 6𝑦 = 0 2) 𝑦 ′′ − 4𝑦 ′ + 4𝑦 = 0
Note By an operator we mean a transformation which transforms a function
into another function.
Let the operator D denote differentiation with respect to x, then;
𝑑 𝑑𝑦
𝐷= → 𝐷𝑦 = = 𝑦 ′ → 𝐷(𝑥 2 ) = 2𝑥
𝑑𝑥 𝑑𝑥

𝐷(𝐷𝑦) = 𝐷(𝑦 ′ ) = 𝐷2 𝑦 → 𝐷𝑛 𝑦 = 𝑦 (𝑛)


2-3-2 Homogeneous Second-Order DE with Variable Coefficients:-
𝑥 2 𝑦 ′′ + 𝑎𝑥𝑦 ′ + 𝑏𝑦 = 0 … (1) 𝐶𝑎𝑢𝑐ℎ𝑦 𝑒𝑞𝑢. 𝑜𝑟 𝐸𝑢𝑙𝑒𝑟 𝑒𝑞𝑢.
𝑦′ 𝑦
𝑦 + 𝑎 + 𝑏 2 = 0 → 𝑙𝑒𝑡 𝑦 = 𝑥 𝑚 → 𝑦 ′ = 𝑚𝑥 𝑚−1
′′
𝑥 𝑥
→ 𝑦 ′′ = 𝑚(𝑚 − 1)𝑥 𝑚−2
Into equ.(1) → 𝑥 2 [𝑚(𝑚 − 1)𝑥 𝑚−2 ] + 𝑎𝑥[𝑚𝑥 𝑚−1 ] + 𝑏𝑥 𝑚 = 0
𝑚(𝑚 − 1)𝑥 𝑚 + 𝑎𝑚𝑥 𝑚 + 𝑏𝑥 𝑚 = 0 → 𝑥 𝑚 [𝑚2 − 𝑚 + 𝑎𝑚 + 𝑏] = 0
𝑚2 + (𝑎 − 1)𝑚 + 𝑏 = 0 𝑐ℎ𝑎𝑟𝑎𝑐𝑡𝑒𝑟𝑖𝑠𝑡𝑖𝑐𝑠 𝑒𝑞𝑢.
10
Chapter Two Differential Equations

1 1
𝑚1 = [(1 − 𝑎) + √(1 − 𝑎)2 − 4𝑏] , 𝑚2 = [(1 − 𝑎) − √(1 − 𝑎)2 − 4𝑏]
2 2
Case 1 𝑚1 ≠ 𝑚2 → 𝑦(𝑥) = 𝑘1 𝑥 𝑚1 + 𝑘2 𝑥 𝑚2 𝐺. 𝑆.
(1−𝑎)2
Case 2 𝑚1 = 𝑚2 (double roots) → 𝑏 =
4
1−𝑎 1−𝑎
𝑚1 = → 𝑦1 (𝑥) = 𝑥 = 𝑥 2 )
𝑚1 (
2
𝑦2 (𝑥) = 𝑢(𝑥)𝑦1 (𝑥) → 𝑦2 ′ = 𝑢𝑦1 ′ + 𝑢′ 𝑦1 → 𝑦2 ′′ = 𝑢𝑦1 ′′ + 2𝑢′ 𝑦1 ′ + 𝑢′′ 𝑦1
Into equ. (1):
𝑥 2 [𝑢𝑦1 ′′ + 2𝑢′ 𝑦1 ′ + 𝑢′′ 𝑦1 ] + 𝑎𝑥[𝑢𝑦1 ′ + 𝑢′ 𝑦1 ] + 𝑏𝑢𝑦1 = 0
′′
𝑢[𝑥 2 𝑦1 + 𝑎𝑥𝑦1 ′ + 𝑏𝑦1 ] + 𝑢′ [2𝑥 2 𝑦1 ′ + 𝑎𝑥𝑦1 ] + 𝑥 2 𝑢′′ 𝑦1 = 0
′′
𝑥 2 𝑦1 + 𝑎𝑥𝑦1 ′ + 𝑏𝑦1 because 𝑦1 is the 1st solution of the DE and satisfies the
equation
2 ′
1 − 𝑎 (−1−𝑎) 2 (
1−𝑎
) (
3−𝑎
)
2𝑥 𝑦1 + 𝑎𝑥𝑦1 = 2𝑥 ( )𝑥 2 + 𝑎𝑥𝑥 2 =𝑥 2
2
3−𝑎 5−𝑎 3−𝑎
( ) ( ) ( )
∴𝑥 2 𝑢′ +𝑥 2 𝑢" =0 ÷𝑥 2 𝑢′ → 𝑢′ + 𝑥𝑢′′ = 0
𝑑𝑧 −𝑑𝑥 1
𝑙𝑒𝑡 𝑢′ = 𝑧 → 𝑢′′ = 𝑧 ′ → 𝑧 + 𝑥𝑧 ′ = 0 → = → ln(𝑧) = ln ( )
𝑧 𝑥 𝑥
1 𝑑𝑥 1−𝑎
∴𝑧= = 𝑢′ → 𝑑𝑢 = → 𝑢 = ln(𝑥) → 𝑦2 = ln (𝑥)𝑥 ( 2 )
𝑥 𝑥
1−𝑎
𝑦(𝑥) = 𝑥 ( )
2 [𝑘1 + 𝑘2 ln(𝑥)] 𝐺. 𝑆.

Or
𝑎𝑥 2 𝑦 ′′ + 𝑏𝑥𝑦 ′ + 𝑐𝑦 = 𝑔(𝑥) … (1) 𝐶𝑎𝑢𝑐ℎ𝑦 − 𝐸𝑢𝑙𝑒𝑟 𝐷. 𝐸.
Let 𝑥 = 𝑒 𝑡 ⟹ 𝑡 = 𝑙𝑛(𝑥)
𝑑𝑥 𝑑𝑥
= 𝑒𝑡 ⟹ =𝑥 ………..(1)
𝑑𝑡 𝑑𝑡
𝑑𝑦 𝑑𝑦 𝑑𝑥 𝑑𝑦
= ⟹ = 𝑦′ . 𝑥 = 𝑦̇
𝑑𝑡 𝑑𝑥 𝑑𝑡 𝑑𝑡
𝑑 𝑑𝑦 𝑑
( ) ⟹ (𝑦′ . 𝑥) 2𝑛𝑑 𝐷𝑒𝑟𝑖𝑣𝑎𝑡𝑖𝑣𝑒
𝑑𝑡 𝑑𝑡 𝑑𝑡

11
Chapter Two Differential Equations

𝑑 ′ 𝑑𝑥
(𝑦 . 𝑥 )
𝑑𝑥 𝑑𝑡
𝑦̈ = (𝑦′ + 𝑥 𝑦′′ ). 𝑥 ⟹ 𝑦̈ = (𝑦′ 𝑥 + 𝑥 2 𝑦′′ ) ⟹ 𝑦̈ = 𝑦̇ + 𝑥 2 𝑦′′
𝑥 2 𝑦′′ = 𝑦̈ − 𝑦̇
𝑎(𝑦̈ − 𝑦̇ ) + 𝑏(𝑦̇ ) + 𝑐𝑦 = 𝑔(𝑥)

Example:- Solve (𝑥 2 𝐷2 − 3𝑥𝐷 + 4)𝑦 = 0


Sol.n:- 𝑙𝑒𝑡 𝑦 = 𝑥 𝑚 → 𝑦 ′ = 𝑚𝑥 𝑚−1 → 𝑦 ′′ = 𝑚(𝑚 − 1)𝑥 𝑚−2
𝑥 2 [𝑚(𝑚 − 1)𝑥 𝑚−2 ] − 3𝑥𝑚𝑥 𝑚−1 + 4𝑥 𝑚 = 0
(𝑚2 − 𝑚)𝑥 𝑚 − 3𝑚𝑥 𝑚 + 4𝑥 𝑚 = 0 → 𝑚2 − 4𝑚 + 4 = 0
𝑚1 = 𝑚2 = 2 → 𝑦(𝑥) = 𝑥 2 [𝑘1 + 𝑘2 ln(𝑥)] 𝐺. 𝑆.

Example:- Solve (𝑥 2 𝐷2 − 𝑥𝐷 + 4)𝑦 = 0


Sol.n:- 𝑙𝑒𝑡 𝑦 = 𝑥 𝑚 → 𝑦 ′ = 𝑚𝑥 𝑚−1 → 𝑦 ′′ = 𝑚(𝑚 − 1)𝑥 𝑚−2
𝑥 2 [𝑚(𝑚 − 1)𝑥 𝑚−2 ] − 𝑥𝑚𝑥 𝑚−1 + 4𝑥 𝑚 = 0 → 𝑚2 − 2𝑚 + 4 = 0
(𝑚2 − 𝑚)𝑥 𝑚 − 𝑚𝑥 𝑚 + 4𝑥 𝑚 = 0 → 𝑚2 − 2𝑚 + 4 = 0

𝑚1,2 = 1 ± 𝑗√3 → 𝑦(𝑥) = 𝑘1 𝑥 1+𝑗√3 + 𝑘2 𝑥 1−𝑗√3 𝐺. 𝑆.


Example: Solve 𝑥 2 𝑦 ′′ + 3𝑥𝑦 ′ + 𝑦 = 0
𝑥 = 𝑒𝑡
𝑥 2 𝑦′′ = 𝑦̈ − 𝑦̇ and 𝑦 ′ . 𝑥 = 𝑦̇

𝑦̈ − 𝑦̇ + 3𝑦̇ + 𝑦 = 0 ⟹ 𝑦̈ + 2𝑦̇ + 𝑦 = 0
r1,2=-1
𝑦 = 𝑐1 𝑒 −𝑡 + 𝑐2 𝑡𝑒 −𝑡 ⟹ 𝑐1 𝑒 −𝑙𝑛(𝑥) + 𝑐2 𝑙𝑛(𝑥)𝑒 −𝑙𝑛(𝑥)
𝑐1 𝑐2
𝐺. 𝑠 𝑦 = + 𝑙𝑛(𝑥)
𝑥 𝑥

12
Chapter Two Differential Equations

2-3-3 Non-Homogeneous Linear Second-Order DE:-


𝑦 ′′ + 𝑓(𝑥)𝑦 ′ + 𝑔(𝑥)𝑦 = 𝑟(𝑥) … (1)
Theorem A general solution y(x) of linear non-homogeneous DE is the sum of
a general solution of the corresponding homogeneous equation and all
arbitrary particular solutions.
𝑦(𝑥) = 𝑦ℎ (𝑥) + 𝑦𝑝 (𝑥) → 𝑦 ′ = 𝑦ℎ′ + 𝑦𝑝′ → 𝑦 ′′ = 𝑦ℎ′′ + 𝑦𝑝′′
Into equ.(1)
𝑦ℎ′′ + 𝑦𝑝′′ + 𝑓(𝑥)[𝑦ℎ′ + 𝑦𝑝′ ] + 𝑔(𝑥)[𝑦ℎ + 𝑦𝑝 ] = 𝑟(𝑥)
[𝑦ℎ′′ + 𝑓(𝑥)𝑦ℎ′ + 𝑔(𝑥)𝑦ℎ ] + [𝑦𝑝′′ + 𝑓(𝑥)𝑦𝑝′ + 𝑔(𝑥)𝑦𝑝 ] = 𝑟(𝑥)
𝑦ℎ′′ + 𝑓(𝑥)𝑦ℎ′ + 𝑔(𝑥)𝑦ℎ = 0 because is the homogenous solution of DE
To complete the solution, we can use the following:
Method of undetermined coefficients
This method depends on assuming an expression similar to r(x) containing
unknown coefficients which are to be determined by inserting yp and its
derivatives into equ. (1). yp can be selected as the following:
r(x) yp(x)
𝑘𝑒 𝑝𝑥 𝐴𝑒 𝑝𝑥
𝛼𝑥 𝑛 (𝑛 = 0,1,2, … ) 𝐴𝑛 𝑥 𝑛 + 𝐴𝑛−1 𝑥 𝑛−1 + ⋯ + 𝐴1 𝑥 + 𝐴0
𝑘𝑐𝑜𝑠(𝑞𝑥)
} 𝐴1 𝑐𝑜𝑠(𝑞𝑥) + 𝐴2 𝑠𝑖𝑛(𝑞𝑥)
𝑘𝑠𝑖𝑛(𝑞𝑥)

Example:- Solve 𝑦 ′′ + 4𝑦 ′ + 4𝑦 = 8𝑥 − 10
Sol.n:- 𝜆2 + 4𝜆 + 4 = 0 → (𝜆 + 2)(𝜆 + 2) = 0 → 𝜆1 = 𝜆2 = −2
𝑦ℎ (𝑥) = 𝑘1 𝑒 −2𝑥 + 𝑘2 𝑥𝑒 −2𝑥
Let 𝑦𝑝 (𝑥) = 𝐴1 𝑥 + 𝐴0 → 𝑦𝑝 ′ = 𝐴1 → 𝑦𝑝 ′′ = 0
4𝐴1 + 4𝐴1 𝑥 + 4𝐴0 = 8𝑥 − 10 → 4𝐴1 𝑥 + (4𝐴1 + 4𝐴0 ) = 8𝑥 − 10
4𝐴1 = 8 → 𝐴1 = 2, 4𝐴1 + 4𝐴0 = −10 → 𝐴0 = −4.5
𝑦(𝑥) = 𝑘1 𝑒 −2𝑥 + 𝑘2 𝑥𝑒 −2𝑥 + 2𝑥 − 4.5 𝐺. 𝑆.

13
Chapter Two Differential Equations

Example:- Solve 𝑦 ′′ + 5𝑦 ′ + 4𝑦 = 2 cos(𝑥)


Sol.n:- 𝜆2 + 5𝜆 + 4 = 0 → (𝜆 + 4)(𝜆 + 1) = 0 → 𝜆1 = −4, 𝜆2 = −1
𝑦ℎ (𝑥) = 𝑘1 𝑒 −4𝑥 + 𝑘2 𝑒 −𝑥
Let 𝑦𝑝 (𝑥) = 𝐴1 cos(𝑥) + 𝐴2 sin(𝑥) → 𝑦𝑝 ′ = −𝐴1 sin(𝑥) + 𝐴2 cos(𝑥) →
𝑦𝑝 ′′ = −𝐴1 cos(𝑥) − 𝐴2 sin(𝑥)
−𝐴1 cos(𝑥) − 𝐴2 sin(𝑥) −5𝐴1 sin(𝑥)
+ 5𝐴2 cos(𝑥)+4𝐴1 cos(𝑥) + 4𝐴2 sin(𝑥) = 2 cos(𝑥)
3 5
𝐴1 = , 𝐴2 =
17 17
3 5
𝑦(𝑥) = 𝑘1 𝑒 −4𝑥 + 𝑘2 𝑒 −𝑥 + cos(𝑥) + sin(𝑥) 𝐺. 𝑆.
17 17
H.W. Solve
1) 𝑦 ′′ − 2𝑦 ′ + 𝑦 = 𝑒 𝑥 2) 𝑦 ′′ + 𝑦 ′ − 1 = 3 cos(𝑥) 3) (𝐷2 + 4)𝑦 = 8 sin(2𝑥)
4) 𝑦 ′′ + 3𝑦 ′ + 2𝑦 = 6𝑥𝑒 𝑥 5) 𝑦 ′′ + 9𝑦 = 3𝑥 + 𝑒 𝑥
Modification Rule
Example:- Solve 𝑦 ′′ + 𝑦 = cos(𝑥) + 3 sin(2𝑥)
Sol.n:- 𝜆2 + 1 = 0 → 𝜆1,2 = ±𝑗 → 𝑦ℎ (𝑥) = 𝑘1 cos(𝑥) + 𝑘2 sin(𝑥)
Let 𝑦𝑝 (𝑥) = 𝐴1 cos(𝑥) + 𝐴2 sin(𝑥) + 𝐵1 cos(2𝑥) + 𝐵2 sin(2𝑥)
𝐴1 cos(𝑥) + 𝐴2 sin(𝑥) is a part of homogeneous solution
∴ 𝑦𝑝 (𝑥) = 𝐴1 𝑥 cos(𝑥) + 𝐴2 𝑥 sin(𝑥) + 𝐵1 cos(2𝑥) + 𝐵2 sin(2𝑥)
H.W.: Complete the solution
2-3-4 General Method for Solving Non-Homogeneous Equation
(Variation of Parameters:-
𝑦 ′′ + 𝑓(𝑥)𝑦 ′ + 𝑔(𝑥)𝑦 = 𝑟(𝑥) … (1)
The hom. form 𝑦 ′′ + 𝑓(𝑥)𝑦 ′ + 𝑔(𝑥)𝑦 = 0 → 𝑦ℎ (𝑥) = 𝑘1 𝑦1 (𝑥) + 𝑘2 𝑦2 (𝑥)
Let 𝑦𝑝 (𝑥) = 𝑢(𝑥)𝑦1 (𝑥) + 𝑣(𝑥)𝑦2 (𝑥) →
𝑦𝑝′ = 𝑢′ 𝑦1 + 𝑢𝑦1′ + 𝑣 ′ 𝑦2 + 𝑣𝑦2′ = [𝑢′ 𝑦1 + 𝑣 ′ 𝑦2 ] + 𝑢𝑦1′ + 𝑣𝑦2′
𝑦𝑝′′ = [𝑢′ 𝑦1 + 𝑣 ′ 𝑦2 ]′ + 𝑢′ 𝑦1′ + 𝑢𝑦1′′ + 𝑣 ′ 𝑦2′ + 𝑣𝑦1′′

14
Chapter Two Differential Equations

Into equ. (1)


[𝑢′ 𝑦1 + 𝑣 ′ 𝑦2 ]′ + 𝑢′ 𝑦1′ + 𝑢𝑦1′′ + 𝑣 ′ 𝑦2′ + 𝑣𝑦1′′ + 𝑓[𝑢′ 𝑦1 + 𝑢𝑦1′ + 𝑣 ′ 𝑦2 + 𝑣𝑦2′ ]
+ 𝑔[𝑢𝑦1 + 𝑣𝑦2 ] = 𝑟
𝑢[𝑦1′′ + 𝑓𝑦1′ + 𝑔𝑦1 ] + 𝑣[𝑦2′′ + 𝑓𝑦2′ + 𝑔𝑦2 ] + [𝑢′ 𝑦1 + 𝑣 ′ 𝑦2 ]′ + 𝑢′ 𝑦1′ + 𝑣 ′ 𝑦2′
=𝑟
𝑦1′′ + 𝑓𝑦1′ + 𝑔𝑦1 = 0 and 𝑦2′′ + 𝑓𝑦2′ + 𝑔𝑦2 = 0 because y1 and y2 are solution
of hom. form.
𝑢′ 𝑦1 + 𝑣 ′ 𝑦2 = 0
Choose u and v such that: ′ ′ } … (2)
𝑢 𝑦1 + 𝑣 ′ 𝑦2′ = 𝑟
The solution of the above equation is obtained by Gramer's rule
−𝑦2 𝑟 ′ 𝑦1 𝑟 𝑦1 𝑦2
∴ 𝑢′ = ,𝑣 = 𝑤ℎ𝑒𝑟𝑒 𝑊 = |𝑦 ′ 𝑦 ′ | = 𝑦1 𝑦2′ − 𝑦2 𝑦1′ ; 𝑊 ≠ 0
𝑊 𝑊 1 2

Note If W=0, the functions are linearly dependent


𝑦2 𝑟 𝑦1 𝑟
𝑢 = −∫ 𝑑𝑥 , 𝑣 = ∫ 𝑑𝑥
𝑊 𝑊
𝑦𝑝 (𝑥) = 𝑢(𝑥)𝑦1 (𝑥) + 𝑣(𝑥)𝑦2 (𝑥) → 𝑦(𝑥) = 𝑦ℎ (𝑥) + 𝑦𝑝 (𝑥)
Example:- Solve 𝑦 ′′ + 2𝑦 ′ + 𝑦 = 4𝑒 −𝑥 ln(𝑥)
Sol.n:- 𝑦 ′′ + 2𝑦 ′ + 𝑦 = 0 → 𝜆2 + 2𝜆 + 1 = 0 → (𝜆 + 1)2 = 0
→ 𝜆1,2 = −1
𝑦ℎ (𝑥) = 𝑘1 𝑒 −𝑥 + 𝑘2 𝑥𝑒 −𝑥 → 𝑦1ℎ = 𝑒 −𝑥 , 𝑦2ℎ = 𝑥𝑒 −𝑥
𝑦1 𝑦2 𝑒 −𝑥 𝑥𝑒 −𝑥
𝑊 = |𝑦 ′ 𝑦 ′ | = | −𝑥 | = 𝑒 −2𝑥
1 2 −𝑒 −𝑥𝑒 −𝑥 + 𝑒 −𝑥

−𝑥𝑒 −𝑥 ∗ 4𝑒 −𝑥 ln(𝑥)
𝑢 = = −4𝑥 𝑙𝑛(𝑥) → 𝑢 = 𝑥 2 − 2𝑥 2 ln (𝑥)
𝑒 −2𝑥

𝑒 −𝑥 ∗ 4𝑒 −𝑥 ln(𝑥)
𝑣 = = 4 𝑙𝑛(𝑥) → 𝑣 = 4𝑥 ln(𝑥) − 4𝑥
𝑒 −2𝑥
∴ 𝑦𝑝 = (𝑥 2 − 2𝑥 2 ln(𝑥)) ∗ 𝑒 −𝑥 + (4𝑥 ln(𝑥) − 4𝑥) ∗ 𝑥𝑒 −𝑥
= 𝑥 2 𝑒 −𝑥 [2 ln(𝑥) − 3]
𝑦(𝑥) = 𝑘1 𝑒 −𝑥 + 𝑘2 𝑥𝑒 −𝑥 + 𝑥 2 𝑒 −𝑥 [2 ln(𝑥) − 3] 𝐺. 𝑆.
H.W. 1) 𝑦 ′′ + 4𝑦 = 4 sec(2𝑥) 2) 𝑦 ′′ + 𝑦 = csc(𝑥)

15
Chapter Two Differential Equations

2-3-5 Transformation of DE to Linear with Constant Coefficients:-


This is done by using the assumptions
Example:- Solve 𝑥 2 𝑦 ′′ + 𝑥𝑦 ′ + 4𝑦 = 1
Sol.n:- Let 𝑥 = 𝑒 𝑧 → 𝑧 = ln (𝑥)
𝑑𝑦 𝑑𝑦 𝑑𝑧 𝑑𝑦 𝑑𝑦 𝑑𝑦
𝑦′ = = ∗ = 𝑒 −𝑧 → 𝑥𝑦 ′ = 𝑒 𝑧 ∗ 𝑒 −𝑧 =
𝑑𝑥 𝑑𝑧 𝑑𝑥 𝑑𝑧 𝑑𝑧 𝑑𝑧
𝑑2𝑦 𝑑 𝑑 𝑑𝑦 𝑑 𝑑𝑦 𝑑𝑧 𝑑 𝑑𝑦
𝑦 ′′ = = (𝑦 ′ ) = (𝑒 −𝑧 𝑑𝑧 ) = 𝑑𝑧 (𝑒 −𝑧 𝑑𝑧 ) ∗ 𝑑𝑥 = 𝑒 −𝑧 ∗ 𝑑𝑧 (𝑒 −𝑧 𝑑𝑧 ) =
𝑑𝑥 2 𝑑𝑥 𝑑𝑥
𝑑2𝑦 𝑑𝑦 𝑑2𝑦 𝑑𝑦 𝑑2𝑦 𝑑𝑦
𝑒 −𝑧 ∗ [𝑒 −𝑧 2
− 𝑒 −𝑧 ] = 𝑒 −2𝑧 ∗ [ 2
− ] → 𝑥 2 𝑦 ′′ = −
𝑑𝑧 𝑑𝑧 𝑑𝑧 𝑑𝑧 𝑑𝑧 2 𝑑𝑧

𝑑 2 𝑦 𝑑𝑦 𝑑𝑦 𝑑2𝑦
∴ 2− + + 4𝑦 = 1 → + 4𝑦 = 1
𝑑𝑧 𝑑𝑧 𝑑𝑧 𝑑𝑧 2
1
The general solution is 𝑦(𝑧) = 𝑘1 cos(2𝑧) + 𝑘2 sin(2𝑧) +
4
1
𝑦(𝑥) = 𝑘1 cos(2ln (𝑥)) + 𝑘2 sin(2ln (𝑥)) +
4

2-4 General Linear Differential Equations of Order n:-


𝑑𝑛 𝑦 𝑑 𝑛−1 𝑦 𝑑𝑦
𝑎0 (𝑥) + 𝑎1 (𝑥) + ⋯ + 𝑎𝑛−1 (𝑥) + 𝑎𝑛 (𝑥)𝑦 = 𝑅(𝑥)
𝑑𝑥 𝑛 𝑑𝑥 𝑛−1 𝑑𝑥
𝑥𝑦 ′′ + 3𝑦 ′ − 2𝑥𝑦 = sin(𝑥) 2nd order linear DE
𝑦𝑦 ′′ − 𝑥(𝑦 ′ )2 + 𝑥 2 𝑦 = 𝑒 −𝑥 2nd order non-linear DE

Example:- Solve 𝑦 ′′′ − 2𝑦 ′′ − 𝑦 ′ + 2𝑦 = 0


Sol.n:- let 𝑦 = 𝑒 𝜆𝑥
𝜆3 − 2𝜆2 − 𝜆 + 2 = 0 → 𝜆2 (𝜆 − 2) − (𝜆 − 2) = 0 → (𝜆2 − 1)(𝜆 − 2) = 0
(𝜆 − 1)(𝜆 + 1)(𝜆 − 2) = 0 → 𝜆1 = 1, 𝜆1 = −1, 𝜆1 = 2
𝑦(𝑥) = 𝑘1 𝑒 𝑥 + 𝑘2 𝑒 −𝑥 + 𝑘3 𝑒 2𝑥
Example:- Solve 𝑦 (5) − 3𝑦 (4) + 3𝑦 ′′′ − 𝑦 ′′ = 0
Sol.n:- let 𝑦 = 𝑒 𝜆𝑥
𝜆5 − 3𝜆4 + 3𝜆3 − 𝜆2 = 0 → 𝜆2 [𝜆3 − 3𝜆2 + 3𝜆 − 1] = 0 → 𝜆2 (𝜆 − 1)3 = 0
16
Chapter Two Differential Equations

𝜆1 = 𝜆2 = 0, 𝜆3 = 𝜆4 = 𝜆5 = 1
𝑦(𝑥) = 𝑘1 + 𝑘2 𝑥 + 𝑘3 𝑒 𝑥 + 𝑘4 𝑥𝑒 𝑥 + 𝑘5 𝑥 2 𝑒 𝑥
H.W.
1) 𝑦 (4) − 𝑦 = 0 2) (𝐷5 − 𝐷2 − 𝐷 + 1)𝑦 = 0
3) (𝐷 − 7)(2𝐷2 + 5𝐷 + 2)𝑦 = 0 4) (𝐷3 − 3𝐷2 + 9𝐷 + 13)𝑦 = 0

17

You might also like