1st Order Differential Equations-Student

You might also like

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

1st Lecture Advanced Engineering Mathematics Dr.

Mahmoud Zaggout

Ordinary Differential Equations (ODEs)

1. 1st order Differential Equations


The general equation takes the form:
𝑓(𝑥, 𝑦, 𝑦′) = 0
𝑦′ = 𝑓(𝑥, 𝑦)
𝑀(𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0
Any function 𝑦 = Ø(𝑥) explicit form
Ø(𝑥, 𝑦) = 0 implicit form
Satisfying the initial value problem 𝑦′ = 𝑓(𝑥, 𝑦) and 𝑦(𝑥₀) = 𝑦₀ is called the solution. The
DE of first order and first degree may be divided into:

1.1. Variables Separable


If the DE 𝑀 (𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0 can be written in the following form
𝑀(𝑥)𝑑𝑥 + 𝑁(𝑦)𝑑𝑦 = 0
It is said to be separable and the solution will be

∫ 𝑀(𝑥)𝑑𝑥 + ∫ 𝑁(𝑦)𝑑𝑦 = 𝑐

Example (1)
Solve the following Differential equations:
1) (𝟏 + 𝒙)𝒅𝒚 − 𝒚𝒅𝒙 = 𝟎

𝑑𝑦 𝑑𝑥
− =0
𝑦 1+𝑥
𝑑𝑦 𝑑𝑥
∫ −∫ =𝑐
𝑦 1+𝑥
𝐿𝑛(𝑦) − 𝑙𝑛│1 + 𝑥│ = 𝑐
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝒅𝒚 𝒙
2) =– 𝒚(𝟒) = 𝟑
𝒅𝒙 𝒚

𝑦𝑑𝑦 = −𝑥𝑑𝑥
𝑦𝑑𝑦 + 𝑥𝑑𝑥 = 0

∫ 𝑦𝑑𝑦 + ∫ 𝑥𝑑𝑥 = 𝑐

𝑦2 𝑥2
+ =𝑐
2 2
at 𝑦(4) = 3
32 42 25
+ = =𝑐
2 2 2
𝑦 2 𝑥 2 25
+ =
2 2 2
𝑦 2 + 𝑥 2 = 25

3) 𝒙 𝒔𝒊𝒏 𝒙 𝒆−𝒚 𝒅𝒙 − 𝒚𝒅𝒚 = 𝟎

𝑥 𝑠𝑖𝑛 𝑥 𝑑𝑥 − 𝑦𝑒 𝑦 𝑑𝑦 = 0

∫ 𝑥 𝑠𝑖𝑛 𝑥 𝑑𝑥 − ∫ 𝑦𝑒 𝑦 𝑑𝑦 = 𝑐

−𝑥 𝑐𝑜𝑠 𝑥 + 𝑠𝑖𝑛 𝑥 − 𝑦𝑒 𝑦 + 𝑒 𝑦 = 𝑐

4) (𝒆𝒙 + 𝟏)𝒚𝒅𝒚 = (𝒚 + 𝟏)𝒆𝒙 𝒅𝒙

𝑦 𝑒𝑥
𝑑𝑦 = 𝑥 𝑑𝑥
𝑦+1 𝑒 +1
𝑦 𝑒𝑥
∫ 𝑑𝑦 = ∫ 𝑥 𝑑𝑥 + 𝑐
𝑦+1 𝑒 +1
𝑦+1−1 𝑒𝑥
∫ 𝑑𝑦 = ∫ 𝑥 𝑑𝑥 + 𝑐
𝑦+1 𝑒 +1
1 𝑒𝑥
∫ (1 − ) 𝑑𝑦 = ∫ 𝑥 𝑑𝑥 + 𝑐
𝑦+1 𝑒 +1
𝑦 − 𝑙𝑛│𝑦 + 1│ = 𝑙𝑛│ 𝑒 𝑥 + 1│ + 𝑐
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝒅𝒚 𝒅𝒚
5) 𝒚 − 𝒙 = 𝟐 (𝒚𝟐 + )
𝒅𝒙 𝒅𝒙

𝑑𝑦
𝑦 − 2𝑦 2 = (𝑥 + 2)
𝑑𝑥
𝑑𝑦 𝑑𝑥
2
=
(𝑦 − 2𝑦 ) (𝑥 + 2)
𝑑𝑦 𝑑𝑥
∫ = ∫ +𝑐
(𝑦 − 2𝑦 2 ) (𝑥 + 2)
Using the partial fractions
1 1 𝐴 𝐵 𝐴(1 − 2𝑦 ) + 𝐵𝑦
= = + =
(𝑦 − 2𝑦 2 ) 𝑦(1 − 2𝑦 ) 𝑦 (1 − 2𝑦 ) (𝑦 − 2𝑦 2 )
𝐴(1 − 2𝑦) + 𝐵𝑦 = 1
𝑦𝑖𝑒𝑙𝑑𝑠
At 𝑦=0 → 𝐴=1
𝑦𝑖𝑒𝑙𝑑𝑠
𝑦 = 0.5 → 𝐵=2
1 2 1
∫ 𝑑𝑦 + ∫ 𝑑𝑦 = ∫ 𝑑𝑥 + 𝑐
𝑦 (1 − 2𝑦) (𝑥 + 2)
𝑙𝑛(𝑦) − 𝑙𝑛│1 − 2𝑦│ = 𝑙𝑛│𝑥 + 2│ + 𝑐

1.2. Homogeneous Equation


The function 𝑦′ = 𝑓(𝑥, 𝑦) is said to be homo. if
𝑓(𝜆𝑥, 𝜆𝑦) = 𝜆𝑛 𝑓(𝑥, 𝑦)
where 𝑛 is the degree of homogeneity.

Example (2)
Determine the homogenous function of the following:
1) 𝒇(𝒙, 𝒚) = 𝒙 − 𝟑√𝒙𝒚 + 𝟓𝒚

𝑓(𝜆𝑥, 𝜆𝑦) = 𝜆𝑥 − 3√𝜆𝑥𝜆𝑦 + 5𝜆𝑦


= 𝜆(𝑥 − 3√𝑥𝑦 + 5𝑦)
= 𝜆1 𝑓(𝑥, 𝑦)
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

It is homo. function of degree 1

2) 𝒇(𝒙, 𝒚) = 𝒙𝟐 + 𝒚𝟐 + 𝟏
𝑓(𝜆𝑥, 𝜆𝑦) = 𝜆2 𝑥 2 + 𝜆2 𝑦 2 + 1
≠ 𝜆𝑓(𝑥, 𝑦)
It is not homo. Function

3) 𝒙𝟐 𝒅𝒚 + (𝒙𝒚 − 𝒚𝟐 )𝒅𝒙 = 𝟎

𝑑𝑦 𝑦 2 − 𝑥𝑦
= = 𝑓(𝑥, 𝑦)
𝑑𝑥 𝑥2
𝜆2 𝑦 2 − 𝜆𝑥𝜆𝑦
𝑓(𝜆𝑥, 𝜆𝑦) =
𝜆2 𝑥 2
𝜆2 (𝑦 2 − 𝑥𝑦)
=
𝜆2 𝑥 2
(𝑦 2 − 𝑥𝑦)
=
𝑥2
= 𝜆0 𝑓(𝑥, 𝑦)
It is homo function of degree 0.

Note:
If the DE is homo. of zero degree it may converted to separable equation by introducing
a new variable as following:
i. assume 𝑦 = 𝑣𝑥
𝑑𝑦 𝑑𝑣
=𝑣+𝑥
𝑑𝑥 𝑑𝑥
ii. 𝑥 = 𝑣𝑦
𝑑𝑥 𝑑𝑣
=𝑣+𝑦
𝑑𝑦 𝑑𝑦

Example (3)
Solve the following DEs :
1) 𝒙𝒚′ = 𝒚 + 𝒙𝒆𝒚⁄𝒙
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝑑𝑦 (𝑦 + 𝑥𝑒 𝑦⁄𝑥 )
=
𝑑𝑥 𝑥
It is homo. of degree 0 and therefore let us assume that
𝑦 = 𝑣𝑥
𝑑𝑦 𝑑𝑣
=𝑣+𝑥
𝑑𝑥 𝑑𝑥
𝑑𝑣 (𝑣𝑥 + 𝑥𝑒 𝑣𝑥⁄𝑥 )
𝑣+𝑥 =
𝑑𝑥 𝑥
𝑑𝑣
𝑣+ 𝑥 = 𝑣 + 𝑒𝑣
𝑑𝑥
𝑑𝑣
𝑥 = 𝑒𝑣
𝑑𝑥
𝑑𝑥
𝑒 −𝑣 𝑑𝑣 =
𝑥
𝑑𝑥
∫ 𝑒 −𝑣 𝑑𝑣 = ∫ +𝑐
𝑥
−𝑒 −𝑣 = ln(𝑥) + 𝑐
−𝑒 −𝑦⁄𝑥 = ln(𝑥) + 𝑐

2) (𝟐√𝒙𝒚 − 𝒚)𝒅𝒙 − 𝒙𝒅𝒚 = 𝟎

𝑑𝑦 2√𝑥𝑦 − 𝑦
=
𝑑𝑥 𝑥
It is homo of degree 0 and assume that
𝑦 = 𝑣𝑥
𝑑𝑦 𝑑𝑣
=𝑣+𝑥
𝑑𝑥 𝑑𝑥
𝑑𝑣 2√𝑥𝑣𝑥 − 𝑣𝑥
𝑣+𝑥 = = 2√𝑣 − 𝑣
𝑑𝑥 𝑥
𝑑𝑣
𝑥 = 2√𝑣 − 2𝑣
𝑑𝑥
𝑑𝑣 𝑑𝑥
=
2√𝑣 − 2𝑣 𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝑑𝑣 𝑑𝑥
∫ =∫ +𝑐
2√𝑣 − 2𝑣 𝑥
1
2 𝑣 𝑑𝑥
∫ √ 𝑑𝑣 = ∫ +𝑐
1 − √𝑣 𝑥
−𝑙𝑛|1 − √𝑣| = 𝑙𝑛(𝑥) + 𝑐
𝑦
−𝑙𝑛 |1 − √ | = 𝑙𝑛(𝑥) + 𝑐
𝑥

3) 𝟐𝒙𝟑 𝒚𝒅𝒙 + (𝒙𝟒 + 𝒚𝟒 )𝒅𝒚 = 𝟎

𝑑𝑦 −2𝑥 3 𝑦
= 4
𝑑𝑥 𝑥 + 𝑦 4
Let assume that
𝑦 = 𝑣𝑥
𝑑𝑦 𝑑𝑣
=𝑣+𝑥
𝑑𝑥 𝑑𝑥
𝑑𝑣 −2𝑥 3 𝑣𝑥 −2𝑣
𝑣+𝑥 = 4 4 4
=
𝑑𝑥 𝑥 + 𝑣 𝑥 1 + 𝑣4
𝑑𝑣 −3𝑣 − 𝑣 5
𝑥 =
𝑑𝑥 1 + 𝑣4
𝑑𝑣 −3𝑣 − 𝑣 5
𝑥 =
𝑑𝑥 1 + 𝑣4
1 + 𝑣4 𝑑𝑥
𝑑𝑣 =
−3𝑣 − 𝑣 5 𝑥
1 + 𝑣4 𝑑𝑥
∫ 𝑑𝑣 = ∫ +𝑐
−3𝑣 − 𝑣 5 𝑥
1+𝑣 4
The integration∫ 𝑑𝑣 is difficult to solve. Therefore, the assumption will be changed
−3𝑣−𝑣 5

into
𝑥 = 𝑣𝑦
𝑑𝑥 𝑑𝑣
=𝑣+𝑦
𝑑𝑦 𝑑𝑦
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝑑𝑣 𝑣 4𝑦4 + 𝑦4 𝑣4 + 1
𝑣+𝑦 =− = −
𝑑𝑦 2𝑣 3 𝑦 3 𝑦 2𝑣 3
𝑑𝑣 𝑣 4 + 1 3𝑣 4 + 1
𝑦 = − 𝑣 = −
𝑑𝑦 −2𝑣 3 2𝑣 3
2𝑣 3 𝑑𝑦
− 4
𝑑𝑣 =
3𝑣 + 1 𝑦
2𝑣 3 𝑑𝑦
−∫ 4
𝑑𝑣 = ∫ +𝑐
3𝑣 + 1 𝑦
1
− 𝑙𝑛|3𝑣 4 + 1| = 𝑙𝑛(𝑦) + 𝑐
6
1 𝑥4
− 𝑙𝑛 |3 4 + 1| = 𝑙𝑛(𝑦) + 𝑐
6 𝑦

1.3. Exact Equation


The DE 𝑀(𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0 is said to be an exact DE if :
𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥
and

Ø1 = ∫ 𝑀(𝑥, 𝑦)𝑑𝑥

Ø2 = ∫ 𝑁(𝑥, 𝑦)𝑑𝑦

The solution is
Ø = Ø1 + 𝑡𝑒𝑟𝑚𝑠 𝑜𝑓 Ø2 𝑤ℎ𝑖𝑐ℎ 𝑖𝑛 𝑦 𝑜𝑛𝑙𝑦 = 𝑐
Or
Ø = Ø2 + 𝑡𝑒𝑟𝑚𝑠 𝑜𝑓 Ø1 𝑤ℎ𝑖𝑐ℎ 𝑖𝑛 𝑥 𝑜𝑛𝑙𝑦 = 𝑐

Example (4)
Solve the following DEs:
1) (𝟐𝒙 − 𝟓𝒚)𝒅𝒙 + (𝟑𝒚𝟐 − 𝟓𝒙)𝒅𝒚 = 𝟎

𝑀 = 2𝑥 − 5𝑦 𝑁 = 3𝑦 2 − 5𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝜕𝑀 𝜕𝑁
= −5 = −5
𝜕𝑦 𝜕𝑥
𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥
It is an exact equation

Ø1 = ∫ 𝑀(𝑥, 𝑦)𝑑𝑥

= ∫(2𝑥 − 5𝑦)𝑑𝑥

= 𝑥 2 − 5𝑥𝑦

Ø2 = ∫ 𝑁(𝑥, 𝑦)𝑑𝑦

= ∫(3𝑦 2 − 5𝑥)𝑑𝑦

= 𝑦 3 − 5𝑥𝑦
Ø = 𝑥 2 − 5𝑥𝑦 + 𝑦 3 = 𝑐

2) (𝒄𝒐𝒔 𝒙 𝒔𝒊𝒏 𝒙 − 𝒙𝒚𝟐 )𝒅𝒙 + 𝒚(𝟏 − 𝒙𝟐 )𝒅𝒚 = 𝟎

𝑀 = 𝑐𝑜𝑠 𝑥 𝑠𝑖𝑛 𝑥 − 𝑥𝑦 2 𝑁 = 𝑦(1 − 𝑥 2 )


𝜕𝑀 𝜕𝑁
= −2𝑥𝑦 = −2𝑥𝑦
𝜕𝑦 𝜕𝑥
𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥
It is an exact equation

Ø1 = ∫ 𝑀(𝑥, 𝑦)𝑑𝑥

= ∫(𝑐𝑜𝑠(𝑥)𝑠𝑖𝑛(𝑥) − 𝑥𝑦 2 )𝑑𝑥

𝑠𝑖𝑛2 𝑥 𝑥 2 𝑦 2
= −
2 2

Ø2 = ∫ 𝑁(𝑥, 𝑦)𝑑𝑦
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

= ∫ 𝑦(1 − 𝑥 2 )𝑑𝑦

𝑦2 𝑦2𝑥2
= −
2 2
𝑠𝑖𝑛2 𝑥 𝑥 2 𝑦 2 𝑦 2
Ø= − + =𝑐
2 2 2

3) (𝒆𝟐𝒚 − 𝒚𝒄𝒐𝒔(𝒙𝒚))𝒅𝒙 + (𝟐𝒙𝒆𝟐𝒚 − 𝒙𝒄𝒐𝒔(𝒙𝒚) + 𝟐𝒚)𝒅𝒚 = 𝟎

𝑀 = 𝑒 2𝑦 − 𝑦𝑐𝑜𝑠(𝑥𝑦) 𝑁 = 2𝑥𝑒 2𝑦 − 𝑥𝑐𝑜𝑠(𝑥𝑦) + 2𝑦


𝜕𝑀
= 2𝑒 2𝑦 + 𝑥𝑦𝑠𝑖𝑛(𝑥𝑦) − 𝑐𝑜𝑠(𝑥𝑦)
𝜕𝑦
𝜕𝑁
= 2𝑒 2𝑦 + 𝑥𝑦𝑠𝑖𝑛(𝑥𝑦) − 𝑐𝑜𝑠(𝑥𝑦)
𝜕𝑥
𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥

Ø1 = ∫(𝑒 2𝑦 − 𝑦𝑐𝑜𝑠 (𝑥𝑦))𝑑𝑥

= 𝑥𝑒 2𝑦 − 𝑠𝑖𝑛(𝑥𝑦)

Ø2 = ∫(2𝑥𝑒 2𝑦 − 𝑥𝑐𝑜𝑠 (𝑥𝑦) + 2𝑦)𝑑𝑦

= 𝑥𝑒 2𝑦 − 𝑠𝑖𝑛(𝑥𝑦) + 𝑦 2
∴ Ø = 𝑥𝑒 2𝑦 − 𝑠𝑖𝑛(𝑥𝑦) + 𝑦 2 = 𝑐

1.4. Integrating Factors


Consider the DE
𝑀(𝑥, 𝑦)𝑑𝑥 + 𝑁(𝑥, 𝑦)𝑑𝑦 = 0
It is not an exact DE if
𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
Try to find a function 𝜇, so that the DE
𝜇𝑀(𝑥, 𝑦)𝑑𝑥 + 𝜇𝑁(𝑥, 𝑦)𝑑𝑦 = 0
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

becomes an exact DE , the function 𝜇 is called an integrating factor and it can be calculated
as follows :
i. 𝜇 is a function of 𝑥 only
𝜇(𝑥) = 𝑒 ∫ 𝑓(𝑥)𝑑𝑥
𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
𝑓(𝑥) =
𝑁
ii. 𝜇 is a function of 𝑦 only
𝜇(𝑦) = 𝑒 − ∫ 𝑓(𝑦)𝑑𝑦
𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
𝑓(𝑦) =
𝑀
Example (5)
Find the solution of the following DEs:

1) (𝒙 + 𝒚)𝒅𝒙 + 𝒙𝒍𝒏(𝒙)𝒅𝒚 = 𝟎
𝑀 =𝑥+𝑦 𝑁 = 𝑥𝑙𝑛(𝑥)

𝜕𝑀 𝜕𝑁
=1 = 1 + 𝑙𝑛(𝑥)
𝜕𝑦 𝜕𝑥

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥

It is not exact DE and let us assume 𝜇 is the function of 𝑥 only

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
𝑓 (𝑥) =
𝑁
1 − (1 + 𝑙𝑛(𝑥))
=
𝑥𝑙𝑛(𝑥)
−1
=
𝑥

𝜇(𝑥) = 𝑒 ∫ 𝑓(𝑥)𝑑𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

−1
= 𝑒 ∫ 𝑥 𝑑𝑥

1
=
𝑥
𝜇(𝑥)(𝑥 + 𝑦)𝑑𝑥 + 𝜇(𝑥)𝑥𝑙𝑛(𝑥)𝑑𝑦 = 0

(𝑥 + 𝑦)
𝑑𝑥 + 𝑙𝑛(𝑥)𝑑𝑦 = 0
𝑥
(𝑥 + 𝑦)
𝑀= 𝑁 = 𝑙𝑛(𝑥)
𝑥
𝜕𝑀 1 𝜕𝑁 1
= =
𝜕𝑦 𝑥 𝜕𝑥 𝑥

𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥

It is an exact DE

(𝑥 + 𝑦)
Ø1 = ∫ 𝑑𝑥
𝑥

= 𝑥 + 𝑦𝑙𝑛(𝑥)

Ø2 = ∫ 𝑙𝑛(𝑥) 𝑑𝑦

= 𝑦𝑙𝑛(𝑥)

Ø = 𝑥 + 𝑦𝑙𝑛(𝑥) = 𝑐

2) 𝟔𝒙𝒚𝒅𝒙 + (𝟒𝒚 + 𝟗𝒙𝟐 )𝒅𝒚 = 𝟎

𝑀 = 6𝑥𝑦 𝑁 = 4𝑦 + 9𝑥 2

𝜕𝑀 𝜕𝑁
= 6𝑥 = 18𝑥
𝜕𝑦 𝜕𝑥

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

It is not exact DE., assume that 𝜇 is the function of 𝑥 only

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
𝑓 (𝑥) =
𝑁
6𝑥 − 18𝑥
=
4𝑦 + 9𝑥 2

−12𝑥
=
4𝑦 + 9𝑥 2

This assumption is not correct. Therefore, let us choose 𝜇 as a function of 𝑦 only

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
𝑓(𝑦) =
𝑀
6𝑥 − 18𝑥
=
6𝑥𝑦

−12𝑥
=
6𝑥𝑦

−2
=
𝑦

𝜇(𝑦) = 𝑒 − ∫ 𝑓(𝑦)𝑑𝑦
−2
−∫ 𝑑𝑦
=𝑒 𝑦

= 𝑦2

𝜇(𝑦)(𝑥 + 𝑦)𝑑𝑥 + 𝜇(𝑦)𝑥𝑙𝑛(𝑥)𝑑𝑦 = 0

6𝑥𝑦 3 𝑑𝑥 + (4𝑦 3 + 9𝑥 2 𝑦 2 )𝑑𝑦 = 0

𝑀 = 6𝑥𝑦 3 𝑁 = 4𝑦 3 + 9𝑥 2 𝑦 2

𝜕𝑀 𝜕𝑁
= 18𝑥𝑦 2 = 18𝑥𝑦 2
𝜕𝑦 𝜕𝑥

𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

It is an exact DE

Ø1 = ∫ 6𝑥𝑦 3 𝑑𝑥

= 3𝑥 2 𝑦 3

Ø2 = ∫(4𝑦 3 + 9𝑥 2 𝑦 2 )𝑑𝑦

= 𝑦 4 + 3𝑥 2 𝑦 3

Ø = 𝑦 4 + 3𝑥 2 𝑦 3 = 𝑐

3) 𝒚(𝒙 + 𝒚 + 𝟏)𝒅𝒙 + (𝒙 + 𝟐𝒚)𝒅𝒚 = 𝟎


(𝑥𝑦 + 𝑦 2 + 𝑦)𝑑𝑥 + (𝑥 + 2𝑦)𝑑𝑦 = 0

𝑀 = 𝑥𝑦 + 𝑦 2 + 𝑦 𝑁 = 𝑥 + 2𝑦

𝜕𝑀 𝜕𝑁
= 𝑥 + 2𝑦 + 1 =1
𝜕𝑦 𝜕𝑥

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥

It is not exact DE., assume that 𝜇 is the function of 𝑥 only

𝜕𝑀 𝜕𝑁

𝜕𝑦 𝜕𝑥
( )
𝑓 𝑥 =
𝑁
𝑥 + 2𝑦 + 1 − 1
=
𝑥 + 2𝑦

=1

𝜇(𝑥) = 𝑒 ∫ 𝑓(𝑥)𝑑𝑥

= 𝑒 ∫ 𝑑𝑥

= 𝑒𝑥

𝜇 (𝑥)(𝑥𝑦 + 𝑦 2 + 𝑦)𝑑𝑥 + 𝜇(𝑥)(𝑥 + 2𝑦)𝑑𝑦 = 0


1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝑒 𝑥 (𝑥𝑦 + 𝑦 2 + 𝑦)𝑑𝑥 + 𝑒 𝑥 (𝑥 + 2𝑦)𝑑𝑦 = 0


𝑀 = 𝑒 𝑥 (𝑥𝑦 + 𝑦 2 + 𝑦) 𝑁 = 𝑒 𝑥 (𝑥 + 2𝑦)

𝜕𝑀 𝜕𝑁
= 𝑒 𝑥 (𝑥 + 2𝑦 + 1) = 𝑒 𝑥 (𝑥 + 2𝑦 + 1)
𝜕𝑦 𝜕𝑥

𝜕𝑀 𝜕𝑁
=
𝜕𝑦 𝜕𝑥

It is an exact DE

Ø1 = ∫ 𝑒 𝑥 (𝑥𝑦 + 𝑦 2 + 𝑦)𝑑𝑥

= ∫ 𝑥𝑒 𝑥 𝑦𝑑𝑥 + ∫ 𝑒 𝑥 𝑦 2 𝑑𝑥 + ∫ 𝑒 𝑥 𝑦𝑑𝑥

= 𝑥𝑒 𝑥 𝑦 + 𝑒 𝑥 𝑦 2

Ø2 = ∫ 𝑒 𝑥 (𝑥 + 2𝑦)𝑑𝑦

= 𝑥𝑒 𝑥 𝑦 + 𝑒 𝑥 𝑦 2

Ø = 𝑥𝑒 𝑥 𝑦 + 𝑒 𝑥 𝑦 2 = 𝑐

1.5. Linear Differential Equation


It takes the general form

𝑦′ + 𝑃(𝑥)𝑦 = 𝑄(𝑥)

The solution of linear DE is

1
𝑦= [∫ 𝜇𝑄(𝑥)𝑑𝑥 + 𝑐]
𝜇

𝜇 = 𝑒 ∫ 𝑃(𝑥)𝑑𝑥

Examples (6)
Find the solution of the DEs:
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

1) 𝒙𝒚′ − 𝟒𝒚 = 𝒙𝟔 𝒆𝒙
4
𝑦′ − 𝑦 = 𝑥 5 𝑒 𝑥
𝑥
4
𝑃(𝑥) = − 𝑄(𝑥) = 𝑥 5 𝑒 𝑥
𝑥

𝜇 = 𝑒 ∫ 𝑃(𝑥)𝑑𝑥
4
= 𝑒 ∫ −𝑥𝑑𝑥

1
=
𝑥4
1
𝑦= [∫ 𝜇𝑄(𝑥)𝑑𝑥 + 𝑐]
𝜇
1 5 𝑥
= 𝑥 4 [∫ 𝑥 𝑒 𝑑𝑥 + 𝑐]
𝑥4

= 𝑥 4 [∫ 𝑥𝑒 𝑥 𝑑𝑥 + 𝑐]

𝑦 = 𝑥 4 [𝑥𝑒 𝑥 − 𝑒 𝑥 + 𝑐 ]

𝟏 𝟎≤𝒙≤𝟏
2) 𝒚 + 𝒚 = 𝒇(𝒙)

𝒇(𝒙) = {
𝒙 𝒙>𝟏
𝑦′ + 𝑦 = 1 0≤𝑥≤1

𝑃(𝑥) = 1 𝑄(𝑥) = 1

𝜇 = 𝑒 ∫ 𝑑𝑥

= 𝑒𝑥

1
𝑦= [∫ 𝑒 𝑥 𝑑𝑥 + 𝑐]
𝑒𝑥
1
= [𝑒 𝑥 + 𝑐 ]
𝑒𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

𝑦′ + 𝑦 = 𝑥 𝑥>1

𝑃(𝑥) = 1 𝑄(𝑥) = 𝑥

𝜇 = 𝑒 ∫ 𝑑𝑥

= 𝑒𝑥

1
𝑦= [∫ 𝑥𝑒 𝑥 𝑑𝑥 + 𝑐]
𝑒𝑥
1
[𝑒 𝑥 + 𝑐 ] 𝑎𝑡 0 ≤ 𝑥 ≤ 1
𝑒𝑥
∴𝑦={
1
[𝑥𝑒 𝑥 − 𝑒 𝑥 + 𝑐 ] 𝑎𝑡 𝑥 > 1
𝑒𝑥

1.6. Bernoulli’s Equation


The Bernoulli’s equation takes the general form

𝑦 ′ + 𝑃(𝑥)𝑦 = 𝑄(𝑥)𝑦 𝑛

it is nonlinear and we can make it a linear equation by the following steps :

1 ′ 1
𝑛
𝑦 + 𝑛 𝑃(𝑥)𝑦 = 𝑄(𝑥)
𝑦 𝑦

1 ′
𝑦 + 𝑃(𝑥)𝑦1−𝑛 = 𝑄(𝑥)
𝑦𝑛

Assume that 𝑣 = 𝑦1−𝑛

𝑑𝑣 𝑑𝑦
= (1 – 𝑛) 𝑦 −𝑛
𝑑𝑥 𝑑𝑥
1 1
𝑣 ′ = 𝑛 𝑦′
1−𝑛 𝑦

1
𝑣 ′ + 𝑃(𝑥)𝑣 = 𝑄(𝑥)
1−𝑛
𝑣 ′ + (1 − 𝑛)𝑃(𝑥)𝑣 = (1 − 𝑛)𝑄(𝑥)

𝜇 = 𝑒 ∫(1−𝑛)𝑃(𝑥)𝑑𝑥
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

1
𝑣= [∫ 𝜇(1 − 𝑛)𝑄(𝑥)𝑑𝑥 + 𝑐]
𝜇
1
𝑦1−𝑛 = [∫ 𝜇(1 − 𝑛)𝑄(𝑥)𝑑𝑥 + 𝑐]
𝜇
1
1−𝑛
1
𝑦 = [ [∫ 𝜇(1 − 𝑛)𝑄(𝑥)𝑑𝑥 + 𝑐]]
𝜇

Examples (7)
Find the solution of the following DEs:

1) 𝒚′ + 𝒙−𝟏 𝒚 = 𝒙𝒚𝟐
1
𝑃(𝑥) = 𝑥 −1 = 𝑄(𝑥) = 𝑥 𝑛=2
𝑥

𝜇 = 𝑒 ∫(1−𝑛)𝑃(𝑥)𝑑𝑥
1
(1−2) 𝑑𝑥
= 𝑒∫ 𝑥

= 𝑒 − ln(𝑥)

1
=
𝑥
1
1−𝑛
1
𝑦 = [ [∫ 𝜇(1 − 𝑛)𝑄(𝑥)𝑑𝑥 + 𝑐]]
𝜇

1
1 1−2
𝑦 = [𝑥 [∫ (1 − 2)𝑥𝑑𝑥 + 𝑐]]
𝑥
−1
= [𝑥 [− ∫ 𝑑𝑥 + 𝑐]]

= [𝑐𝑥 − 𝑥 2 ]−1
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

1
=
𝑐𝑥 − 𝑥 2

𝒚 𝒚
2) 𝒚′ + 𝒙 𝒍𝒏(𝒚) = 𝒙𝟐 (𝐥𝐧(𝒚))𝟐

1 1 1
𝑦′ + 𝑙𝑛(𝑦) = 2 (𝑙𝑛(𝑦))2
𝑦 𝑥 𝑥

Let us assume that

𝑣 = 𝑙𝑛(𝑦)

1
𝑣′ = 𝑦′
𝑦

1 1
𝑣′ + 𝑣 = 2 𝑣 2
𝑥 𝑥

1 1
𝑃(𝑥) = 𝑄(𝑥) = 𝑛=2
𝑥 𝑥2
1
(1−2) 𝑑𝑥
𝜇 = 𝑒∫ 𝑥

= 𝑒 − 𝑙𝑛(𝑥)

1
=
𝑥
1
1 1 1−2
𝑣 = [𝑥 [∫ (1 − 2) 2 𝑑𝑥 + 𝑐]]
𝑥 𝑥
−1
−3
= [𝑥 [− ∫ 𝑥 𝑑𝑥 + 𝑐]]

−1
1
= [𝑥 [ 𝑥 −2 + 𝑐]]
2
−1
1
= [𝑐𝑥 + 𝑥 −1 ]
2
1st Lecture Advanced Engineering Mathematics Dr. Mahmoud Zaggout

1 −1 −1
𝑙𝑛(𝑦) = [𝑐𝑥 + 𝑥 ]
2
1 −1 −1
𝑦 = 𝑒 [𝑐𝑥+2𝑥 ]

You might also like