Problem Set 2 (2) 2
Problem Set 2 (2) 2
PROBLEM SET 2
Recall: The differential equations in the form of 𝒚′ + 𝒑(𝒙)𝒚 = 𝒈(𝒙)𝒚𝒏 are called as Bernoulli equations.
Bernoulli equations can be reduced to linear differential equations via 𝒖 = 𝒚𝟏−𝒏 substitution.
Recall: The differential equations in the form of 𝒚′ = 𝒒𝟎 (𝒙) + 𝒒𝟏 (𝒙)𝒚 + 𝒒𝟐 (𝒙)𝒚𝟐 are called as Riccati equations.
For Riccati equations, general solution is obtained via 𝒚 = 𝒚𝟏 + 𝒖 substitution.
The obtained differential equation 𝑢′ = 𝑥 −1 𝑢 + 𝑥 −3 𝑢2 is a Bernoulli equation. Therefore, the 𝑧 = 𝑢1−2 = 𝑢−1
substitution can be used to convert the equation into a linear differential equation.
𝑧 = 𝑢−1 ⇒ 𝑧 ′ = (𝑢−1 )′ = −𝑢−2 𝑢′
⇒ 𝑧 ′ = −𝑢−2 (𝑥 −1 𝑢 + 𝑥 −3 𝑢2 ) = −𝑥 −1 𝑢−1 − 𝑥 −3
𝑧=𝑢−1
⇒ 𝒛′ + 𝒙−𝟏 𝒛 = −𝒙−𝟑
⇒ ∫ 𝑑𝑥𝑧 = − ∫ 𝑥 −2 𝑑𝑥 ⇒ 𝑥𝑧 = 𝑥 −1 + 𝑐
⇒ 𝒛 = 𝒙−𝟐 + 𝒙−𝟏 𝒄
𝑢=𝑧 −1
⇒ 𝑢−1 = 𝑥 −2 + 𝑥 −1 𝑐
1
⇒ 𝑢=
𝑥 −2 + 𝑥 −1 𝑐
𝒙𝟐
⇒ 𝒖=
𝟏 + 𝒙𝒄
Recall: The differential equations in the form of 𝒚′′ + 𝒑𝒚′ + 𝒒𝒚 = 𝟎 are called second order linear homogeneous
equations with constant coefficients. The general solution for these equations is obtained based on the roots of
characteristic (auxiliary) quadratic equation 𝒌𝟐 + 𝒑𝒌 + 𝒒 = 𝟎.
The roots of the characteristic equation 𝑘1 and 𝑘2 are real and distinct (where the discriminant of the equation
Δ > 0). In this case, the general solution will be directly written as follows.
𝑦 = 𝑐1 𝑒 𝑘1𝑥 + 𝑐2 𝑒 𝑘2𝑥
⇒ 𝒚 = 𝒄𝟏 𝒆𝒙 + 𝒄𝟐 𝒆𝟓𝒙
Recall: The differential equations in the form of 𝒚′′ + 𝒑𝒚′ + 𝒒𝒚 = 𝟎 are called second order linear homogeneous
equations with constant coefficients. The general solution for these equations is obtained based on the roots of
characteristic (auxiliary) quadratic equation 𝒌𝟐 + 𝒑𝒌 + 𝒒 = 𝟎.
The characteristic equation has one real second order (repeated) root 𝑘1,2 (where the discriminant of the equation
Δ = 0). In this case, the general solution will be written as follows.
𝑦 = 𝑐1 𝑒 𝑘1,2𝑥 + 𝑐2 𝑥𝑒 𝑘1,2 𝑥
⇒ 𝒚 = 𝒄𝟏 𝒆𝟑𝒙 + 𝒄𝟐 𝒙𝒆𝟑𝒙
5. Solve the differential equation 𝒚′′ − 𝟒𝒚′ + 𝟓𝒚 = 𝟎.
Recall: The differential equations in the form of 𝒚′′ + 𝒑𝒚′ + 𝒒𝒚 = 𝟎 are called second order linear homogeneous
equations with constant coefficients. The general solution for these equations is obtained based on the roots of
characteristic (auxiliary) quadratic equation 𝒌𝟐 + 𝒑𝒌 + 𝒒 = 𝟎.
The roots of the characteristic equation can be obtained via discriminant method as follows.
Δ = (−4)2 − 4 ⋅ 1 ⋅ 5 = 16 − 20
⇒ 𝚫 = −𝟒
⇒ 𝒌𝟏 = 𝟐 + 𝒊, 𝒌𝟐 = 𝟐 − 𝒊
The roots of the characteristic equation 𝑘1 and 𝑘2 are complex conjugate (where the discriminant of the equation
Δ < 0). In this case, the general solution will be written as follows.
𝑦 = 𝑐1 𝑒 𝑘1𝑥 + 𝑐2 𝑒 𝑘2𝑥
⇒ 𝑦 = 𝑒 2𝑥 (𝑐1 𝑒 𝑖𝑥 + 𝑐2 𝑒 −𝑖𝑥 )
The complex exponentials can be handled using the Euler’s formula 𝑒 𝑖𝜃 = cos(𝜃) + sin(𝜃) (and its variant
𝑒 −𝑖𝜃 = cos(𝜃) − sin(𝜃)) below.
Recall: The differential equations in the form of 𝒑(𝒙)𝒚′′ + 𝒒(𝒙)𝒚′ + 𝒓(𝒙)𝒚 = 𝟎 are called second order linear
homogeneous differential equations with nonconstant coefficients. The general solution for these equations can
be obtained by reduction of order method (if there is already a known solution).
Since 𝑦1 = 𝑥 −1 is one given solution, the second solution can be written in form of 𝒚𝟐 = 𝒗(𝒙)𝒚𝟏 . So, the second
solution and its derivatives are written below.
𝑦2 = 𝑣𝑦1 = 𝑣𝑥 −1
𝑦2′ = 𝑣 ′ 𝑥 −1 − 𝑣𝑥 −2
𝑦2′′ = 𝑣 ′′ 𝑥 −1 − 𝑣 ′ 𝑥 −2 − 𝑣 ′ 𝑥 −2 + 2𝑣𝑥 −3 = 𝑣 ′′ 𝑥 −1 − 2𝑣 ′ 𝑥 −2 + 2𝑣𝑥 −3
Substitutions 𝑣 ′ = 𝑤 and 𝑣 ′′ = 𝑤′ will reduce the obtained linear equation into the first order.
3
2𝑥𝑣 ′′ − 3𝑣 ′ = 0 ⇒ 2𝑥𝑤 ′ − 3𝑤 = 0 ⇒ 𝑤 ′ = 𝑥 −1 𝑤
2
𝑑𝑤 3 −1 𝑑𝑤 3 𝑑𝑥 3 𝟑
⇒ = 𝑥 𝑤 ⇒ ∫ = ∫ ⇒ ln|𝑤| = ln|𝑥| ⇒ 𝒘 = 𝒌𝟏 𝒙𝟐
𝑑𝑥 2 𝑤 2 𝑥 2
3 3 𝟐 𝟓
⇒ 𝑣 ′ = 𝑘1 𝑥 2 ⇒ ∫ 𝑑𝑣 = 𝑘1 ∫ 𝑥 2 𝑑𝑥 ⇒ 𝒗 = 𝒌𝟏 𝒙𝟐 + 𝒌𝟐
𝟓
𝟓
5
The constants can be chosen arbitrarily as 𝑘1 = 2 and 𝑘2 = 0 for simplification as 𝒗 = 𝒙𝟐 . Then, by plugging 𝑣
and 𝑦1 terms into 𝑦2 = 𝑣𝑦1 equation, the second solution is obtained below.
5 𝟑
𝑦2 = 𝑣𝑦1 = 𝑥 2 𝑥 −1 ⇒ 𝒚𝟐 = 𝒙𝟐
Finally, the general solution for the original differential equation can be written as follows.
𝑦 = 𝑐1 𝑦1 + 𝑐2 𝑦2
⇒ 𝒚 = 𝒄𝟏 𝒙−𝟏 + 𝒄𝟐 𝒙𝟑/𝟐
7. Find general solution for the differential equation 𝒚′′ − 𝟓𝒚′ + 𝟒𝒚 = 𝒆𝟒𝒙 + 𝐬𝐢𝐧(𝒙).
Recall: The differential equations in the form of 𝒚′′ + 𝒑𝒚′ + 𝒒𝒚 = 𝒈(𝒙) are called second order linear
nonhomogeneous differential equations with constant coefficients. For these equations, the general solution can
be obtained via undetermined coefficients method.
Note: Where the general solution 𝑦 is the superposition of complementary solution 𝑦𝑐 (for homogeneous part)
and particular solution 𝑦𝑝 (for nonhomogeneous part) as 𝒚 = 𝒚𝒄 + 𝒚𝒑 .
First, the complementary solution can be found easily by factorization of the characteristic equation.
𝑦 ′′ − 5𝑦 ′ + 4𝑦 = 0 ⇒ 𝑘 2 − 5𝑘 + 4 = (𝑘 − 1) ⋅ (𝑘 − 4) = 0 ⇒ 𝒌𝟏 = 𝟏, 𝒌𝟐 = 𝟒 (distinct real roots)
⇒ 𝒚𝒄 = 𝒄𝟏 𝒆𝒙 + 𝒄𝟐 𝒆𝟒𝒙
𝑦𝑝1 is the particular solution for 𝒚′′ − 𝟓𝒚′ + 𝟒𝒚 = 𝒆𝟒𝒙 . So, 𝑦𝑝1 will be in exponential form; however, 𝐴𝑒 4𝑥 is
already in the complementary solution. Thus, 𝒚𝒑𝟏 = 𝑨𝒙𝒆𝟒𝒙 is chosen. Then, 𝐴 can be calculated by plugging 𝑦𝑝1
and its derivatives into the equation.
𝑦𝑝1 = 𝐴𝑥𝑒 4𝑥 ⇒ 𝑦𝑝′ 1 = 𝐴𝑒 4𝑥 + 4𝐴𝑥𝑒 4𝑥 ⇒ 𝑦𝑝′′1 = 8𝐴𝑒 4𝑥 + 16𝐴𝑥𝑒 4𝑥
𝑦𝑝′′1 − 5𝑦𝑝′ 1 + 4𝑦𝑝1 = 8𝐴𝑒 4𝑥 + 16𝐴𝑥𝑒 4𝑥 − 5 ⋅ (𝐴𝑒 4𝑥 + 4𝐴𝑥𝑒 4𝑥 ) + 4𝐴𝑥𝑒 4𝑥 = 𝑒 4𝑥
𝟏
⇒ (8 − 5) ⋅ 𝐴𝑒 4𝑥 + (16 − 20 + 4) ⋅ 𝐴𝑥𝑒 4𝑥 = 𝑒 4𝑥 ⇒ 3𝐴𝑒 4𝑥 = 𝑒 4𝑥 ⇒ 3𝐴 = 1 ⇒ 𝑨 =
𝟑
𝟏 𝟒𝒙
𝒚𝒑𝟏 = 𝒙𝒆
𝟑
𝑦𝑝2 is the particular solution for 𝒚′′ − 𝟓𝒚′ + 𝟒𝒚 = 𝐬𝐢𝐧(𝒙) . So, 𝒚𝒑𝟐 = 𝑨 𝐜𝐨𝐬(𝒙) + 𝑩 𝐬𝐢𝐧(𝒙) is chosen. Then, 𝐴
and B can be calculated by plugging 𝑦𝑝2 and its derivatives into the equation.
𝑦𝑝2 = 𝐴 cos(𝑥) + 𝐵 sin(𝑥) ⇒ 𝑦𝑝′ 2 = −𝐴 sin(𝑥) + 𝐵 cos(𝑥) ⇒ 𝑦𝑝′′2 = −𝐴 cos(𝑥) − 𝐵 sin(𝑥)
𝑦𝑝′′2 − 5𝑦𝑝′ 2 + 4𝑦𝑝2 = sin(𝑥)
⇒ −𝐴 cos(𝑥) − 𝐵 sin(𝑥) − 5 ⋅ (−𝐴 sin(𝑥) + 𝐵 cos(𝑥)) + 4 ⋅ (𝐴 cos(𝑥) + 𝐵 sin(𝑥)) = sin(𝑥)
3𝐴 − 5𝐵 = 0
⇒ (3𝐴 − 5𝐵) ⋅ cos(𝑥) + (5𝐴 + 3𝐵) ⋅ sin(𝑥) = sin(𝑥) ⇒ {
5𝐴 + 3𝐵 = 1
3 3 34 𝟓 𝟑
⇒ 𝐵 = 𝐴 ⇒ 5𝐴 + 3𝐵 = 5𝐴 + 3 ⋅ 𝐴 = 𝐴=1 ⇒ 𝑨= ,𝑩 =
5 5 5 𝟑𝟒 𝟑𝟒
𝟓 𝟑
𝒚𝒑𝟐 = 𝐜𝐨𝐬(𝒙) + 𝐬𝐢𝐧(𝒙)
𝟑𝟒 𝟑𝟒
Recall: The differential equations in the form of 𝒚′′ + 𝒑𝒚′ + 𝒒𝒚 = 𝒈(𝒙) are called second order linear
nonhomogeneous differential equations with constant coefficients. The general solution for these equations can
also be obtained by variation of parameters method (if the complementary solution is already known).
First, the complementary solution of the equation can be calculated based on the characteristic equation.
𝑦 ′′ + 𝑦 = 0 ⇒ 𝑘 2 + 1 = 0 ⇒ 𝑘 2 = −1 ⇒ 𝒌𝟏 = 𝒊, 𝒌𝟐 = 𝒌∗𝟏 = −𝒊
𝑦𝑐 = 𝑐1 𝑦1 + 𝑐2 𝑦2 ⇒ 𝒚𝒄 = 𝒄𝟏 𝐜𝐨𝐬(𝒙) + 𝒄𝟐 𝐬𝐢𝐧(𝒙)
Solution can be written as 𝒚 = 𝒖𝟏 𝐜𝐨𝐬(𝒙) + 𝒖𝟐 𝐬𝐢𝐧(𝒙) and its derivative is given below.
𝑦 ′ = 𝑢1′ cos(𝑥) − 𝑢1 sin(𝑥) + 𝑢2′ sin(𝑥) + 𝑢2 cos (𝑥)
Then, assume 𝒖′𝟏 𝐜𝐨𝐬(𝒙) + 𝒖′𝟐 𝐬𝐢𝐧(𝒙) = 𝟎. So, the original differential equation can be rewritten as follows.
𝑦 ′ = −𝑢1 sin(𝑥) + 𝑢2 cos(𝑥)
𝑦 ′′ = −𝑢1′ sin(𝑥) − 𝑢1 cos(𝑥) + 𝑢2′ cos(𝑥) − 𝑢2 sin(𝑥)
𝑦 ′′ + 𝑦 = −𝑢1′ sin(𝑥) − 𝑢1 cos(𝑥) + 𝑢2′ cos(𝑥) − 𝑢2 sin(𝑥) + 𝑢1 cos(𝑥) + 𝑢2 sin(𝑥) = sin(𝑥)
𝒚′′ + 𝒚 = −𝒖′𝟏 𝐬𝐢𝐧(𝒙) + 𝒖′𝟐 𝐜𝐨𝐬(𝒙) = 𝐬𝐢𝐧(𝒙)
Finally, plugging the obtained 𝒖𝟏 and 𝒖𝟐 into the solution 𝒚 = 𝒖𝟏 𝐜𝐨𝐬(𝒙) + 𝒖𝟐 𝐬𝐢𝐧(𝒙).
𝑥 1 1
𝑦 = (− + sin(𝑥) cos(𝑥) + 𝐴) cos(𝑥) + (− cos 2 (𝑥) + 𝐵) sin(𝑥)
2 2 2
𝑥 1 1
⇒ 𝑦 = − cos(𝑥) + sin(𝑥) cos2 (𝑥) + 𝐴 cos(𝑥) − cos2 (𝑥) sin(𝑥) + 𝐵 sin(𝑥)
2 2 2
𝟏
⇒ 𝒚 = 𝑨 𝐜𝐨𝐬(𝒙) + 𝑩 𝐬𝐢𝐧(𝒙) − 𝒙 𝐜𝐨𝐬(𝒙)
𝟐
9. Find the general solution for the differential equation below.
𝒆𝒙
𝒚′′ − 𝟐𝒚′ + 𝒚 =
𝒙𝟐 + 𝟏
Recall: The differential equations in the form of 𝒚′′ + 𝒑𝒚′ + 𝒒𝒚 = 𝒈(𝒙) are called second order linear
nonhomogeneous differential equations with constant coefficients. The general solution for these equations can
also be obtained by variation of parameters method using Wronskian (if the complementary solution is already
known).
First, the complementary solution of the equation can be calculated based on the characteristic equation.
𝑦 ′′ − 2𝑦 ′ + 𝑦 = 0 ⇒ 𝑘 2 − 2𝑘 + 1 = (𝑘 − 1)2 ⇒ 𝒌𝟏,𝟐 = 𝟏 (a repeated root)
⇒ 𝑾(𝒚𝟏 , 𝒚𝟐 ) = 𝒆𝟐𝒙
𝑒 2𝑥 𝑒 2𝑥 𝑥2 + 1 𝑥2 + 1
𝟏
⇒ 𝒚𝒑 = − 𝒆𝒙 𝐥𝐧|𝒙𝟐 + 𝟏| + 𝒙𝒆𝒙 𝐭𝐚𝐧−𝟏 (𝒙)
𝟐
Finally, the general solution for the differential equation is given per 𝑦 = 𝑦𝑐 + 𝑦𝑝 .
𝟏
𝒚 = 𝒄𝟏 𝒆𝒙 + 𝒄𝟐 𝒙𝒆𝒙 − 𝒆𝒙 𝐥𝐧|𝒙𝟐 + 𝟏| + 𝒙𝒆𝒙 𝐭𝐚𝐧−𝟏 (𝒙)
𝟐