2025 ODE Topic 06 Handout
2025 ODE Topic 06 Handout
dn y dn−1 y dy
a0 n + a1 n−1 + · · · + an−1 + an y = F(x), (1)
dx dx dx
where the coefficients a0 , 0, a1 , . . ., an are real constants and the nonhomogeneous
term F(x) is a function of x (It will be restricted to some specific forms).
The general solution of (1) is given by
y = yc + y p , (2)
where yc is the complementary function, that is, the general solution of the
corresponding homogeneous equation
dn y dn−1 y dy
a0 n + a1 n−1 + · · · + an−1 + an y = 0, (3)
dx dx dx
and y p is a particular solution of (1), that is, any solution of (1) containing no arbitrary
constants.
Method of Undetermined Coefficients
Idea: Make an educated guess of the form of particular solution y p from the form of
nonhomogeneous term F(x) and then determine its coefficients.
The assumed form of the particular solution y p should be a linear combination of all
linearly independent functions that are generated by repeated differentiation of the
nonhomogeneous term F(x).
Rules
I No function in the assumed particular solution y p is a part of the complementary
function yc (Solution of the associated homogeneous differential equation).
I If assumed particular solution y p contains any terms that duplicate terms in the
complementary function yc , then such terms of y p must be multiplied by xk , where
k is the smallest positive integer that eliminates the duplication.
That is, the positive integer k is chosen to be the smallest integer so that no term in y p
is a solution to L(y) = 0.
In case F(x) is a polynomial Pk (x) of degree k, if some terms of Pk (x) are zero/missing,
then also the assumed form of y p must include all terms of a polynomial of degree k.
Case-1: Nonhomogeneous Term F(x) is a Polynomial Pk (x)
Consider
dn y dn−1 y dy
L(y) = a0 n + a1 n−1 + · · · + an−1 + an y = Pk (x),
dx dx dx
where the coefficients a0 , 0, a1 , . . ., an are real constants and the nonhomogeneous
term Pk (x) is a polynomial of degree k.
Assume that the complementary function does not contain the polynomial terms.
y p (x) = A0 + A1 x + · · · + Ak xk .
Note: If some terms of the polynomial Pk (x) are zero/missing, then also the assumed
form of y p must include all terms of a polynomial of degree k.
Now, L(y p ) = Pk (x) yields a system of (k + 1) equations in (k + 1) unknowns A0 , A1 , . . .,
Ak that will be determined by solving it.
Example: Nonhomogeneous Term F(x) is a Polynomial Pk (x)
Find the particular solution y p of y00 + 3y0 + 2y = 3x + 1. Also write its general solution.
Step 1: Finding the Complimentary Function yc
Consider the associated homogeneous equation
y00 + 3y0 + 2y = 0.
7 3
y p (x) = − + x.
4 2
Step 5: Writing the General Solution y
The general solution of the given ODE is
3x 7
y(x) = c1 e −x
+ c2 e −2x
+ − ,
2 4
where c1 and c2 are arbitrary real constants.
Case-2: Nonhomogeneous Term F(x) is an Exponential Function aeαx
Consider
dn y dn−1 y dy
L(y) = a0 n + a1 n−1 + · · · + an−1 + an y = a eαx ,
dx dx dx
where the coefficients a0 , 0, a1 , . . ., an are real constants. Also a and α are real
constants.
Assume that the complementary function does not contain the terms that are scalar
multiples of eαx .
y p (x) = A eαx .
Now, L(y p ) = F yields an equation in the unknown A that will be determined by solving
it.
Example: Nonhomogeneous Term F(x) is an Exponential Function aeαx
Find the particular solution y p of y00 + 3y0 + 2y = e3x . Also write its general solution.
Step 1: Finding the Complimentary Function yc
Consider the associated homogeneous equation
y00 + 3y0 + 2y = 0.
1 3x
y p (x) = e .
20
Step 5: Writing the General Solution y
The general solution of the given ODE is
e3x
y(x) = c1 e −x
+ c2 e
−2x
+ ,
20
where c1 and c2 are arbitrary real constants.
Case-3: Nonhomogeneous Term F(x) is Sine or/and Cosine Functions
Consider
dn y dn−1 y dy
L(y) = a0 n + a1 n−1 + · · · + an−1 + an y = F(x),
dx dx dx
where the coefficients a0 , 0, a1 , . . ., an are real constants and F(x) = a sin(βx) or
F(x) = a cos(βx) or F(x) = a sin(βx) + b cos(βx). Here a, b and β are real constants.
Assume that the complementary function does not contain the terms that are scalar
multiples of cos(βx) and sin(βx).
Now, L(y p ) = F yields an equation in the unknowns A and B that will be determined by
solving it.
Example: Nonhomogeneous Term F(x) is Sine or/and Cosine Functions
Find the particular solution y p of y00 − y0 − y = sin x. Also write its general solution.
Step 1: Finding the Complimentary Function yc
Consider the associated homogeneous equation
y00 − y0 − y = 0.
√
Then, solving
√ the auxiliary equation r2 − r − 1 = 0, we get r = (1 + 5)/2 and
r = (1 − 5)/2.
Therefore, the complementary function yc is given by
√ √
1+ 5 1− 5
yc (x) = c1 e 2 x + c2 e 2 x ,
(−2) 1
y p (x) = sin x + cos x.
5 5
Step 5: Writing the General Solution y
The general solution of the given ODE is
Find the particular solution y p of y00 − y0 − 12y = e4x . Also write its general solution.
Step 1: Finding the Complimentary Function yc
Consider the associated homogeneous equation
y00 − y0 − 12y = 0.
Observe that if y(x) = x e4x , then L(y) = y00 − y0 − 12y = 7e4x , 0. So, we take k = 1.
y p (x) = A x e4x .
Continuation of Previous Slide
x e4x
y p (x) = .
7
Step 5: Writing the General Solution y
The general solution of the given ODE is
x e4x
y(x) = c1 e + c2 e
4x −3x
+ ,
7
where c1 and c2 are arbitrary real constants.
Students to Workout in the Class
Answer:
8 x
y p (x) = − x e .
3
Students to Workout in the Class
Using the method of undetermined coefficients, Find a particular solution of
y000 + y00 = x3 + x + 1.
The complementary function is yc (x) = c1 + c2 x + c3 e−x , where c1 , c2 and c3 are
arbitrary real constants.
Since the nonhomogeneous term F(x) = x3 + x + 1 is a polynomial of degree 3, we
guess the form of y p (x) as
y p (x) = Ax3 + Bx2 + Cx + E.
Observe that 1 and x are part of the complementary function yc (x).
Since L(1) = 0, L(x) = 0 and L(x2 ) , 0, we revise the form of y p (x) as
y p (x) = x Ax + Bx + Cx + E = Ax5 + Bx4 + Cx3 + Ex2 .
2 3 2
Then, the terms in y p (x) that are duplicating in yc (x) got removed. Now, we determine
these coefficients from L(y p ) = x3 + x + 1.
Final Answer:
x5 x4 7 x3
y p (x) = − + − 3x2 .
20 4 6
Annihilator Method
(Method of Undetermined Coefficients by Annihilator Approach)
for
Nonhomogeneous ODEs with Constant
Coefficients
Nonhomogeneous term is Polynomials, Exponential Functions, Sine &
Cosine Functions
Refer:
Pages 141 to 149 of Differential Equations by Dennis G Zill, Cengage Learning, India
Edition.
Page 90 to 94 of An Introduction to Differential Equations by Earl A. Coddington, PHI
Learning Pvt. Ltd. New Delhi, 2011.
Annihilator Method
This method provides a procedure for finding a particular solution y p of
nonhomogeneous linear differential equation L(y) = F with constant coefficients,
where the nonhomogeneous term F is of specific form.
Idea: To solve L(y) = F , we find a linear differential operator M with constant
coefficients which makes M(F) = 0, that is, annihilates F(x). Consequently,
M (L(y)) = 0. It transforms the given nonhomogeneous equation into homogeneous
equation. The form of y p follows automatically once we have found an appropriate
linear differential operator M that annihilates the nonhomogeneous term F(x) in
L(y) = F .
Definition 1
If T is a linear differential operator with constant coefficients, and f : (a, b) ⊆ R → R is
a sufficiently differentiable function on (a, b) such that
Let D = d
dx and f (x) = e x for x ∈ R. Then T := (D − 1) annihilates f (x) on R.
Annihilator Method - Procedure
Consider the nonhomogeneous linear ODE with constant coefficients L(y) = F , where
F consists of finite sums and products of constants, polynomials, eαx , sin(βx) and
cos(βx).
I Step 1: Find the complementary function yc (x), that is, the general solution of
L(y) = 0.
I Step 2: Find the annihilator operator M that annihilates F(x). Then, operate M on
both sides of the nonhomogeneous equation L(y) = F .
I Step 3: Find the general solution Yc (x) of the higher order homogeneous
differential equation M (L(y)) = 0. Note that Yc (x) contains the terms of yc (x) and
some more terms.
I Step 4: Delete from the expression of Yc (x) all those terms that duplicated in yc (x).
Form a linear combination of the remaining terms and that will be the form of a
particular solution y p (x) of L(y) = F .
I Step 5: Substitute y p found in Step 4 into L(y) = F . Match the coefficients of the
various functions on each side of the equality, and solve the resulting system of
equations for the unknown coefficients of y p . Write the final expression of y p .
I Step 6: With the particular solution y p found in Step 5, form the general solution
y = yc + y p of the given nonhomogeneous differential equation L(y) = F .
Annihilator Operators
Find the particular solution y p of y00 + y = e2x + 1. Also write its general solution.
Step 1: Finding the Complimentary Function yc
Consider the associated homogeneous equation
y00 + y = 0.
D(D − 2)(D2 + 1) = 0.
Answer:
1
y p (x) = cos x .
3
Operator Method
for
Nonhomogeneous ODEs with Constant
Coefficients
Nonhomogeneous term is a simple function for integrating it.
Refer:
Page 94 to 101 of An Introduction to Differential Equations by Earl A. Coddington, PHI
Learning Pvt. Ltd. New Delhi, 2011.
Operator Method
This method provides a procedure for finding a particular solution y p of
nonhomogeneous linear differential equation L(y) = F with constant coefficients,
where the nonhomogeneous term F is of specific form (Polynomial, Exponential
function, Sine and Cosine functions).
Consider the n-th order nonhomogeneous linear ODE with constant coefficients
dn y dn−1 y dy
L(y) := n + an−1 n−1 + · · · + a1 + a0 y = F(x),
dx dx dx
where a0 , . . ., an−1 are real constants. Note that one can make the coefficient of the
highest order derivative term of the ODE with constant coefficients as 1.
dk
By denoting Dk = dx k , let
P(r) = (r − r1 )(r − r2 ) · · · (r − rn ).
P(D) = (D−r1 )(D−r2 ) · · · (D−rn ) meaning P(D) = (D−r1 I)(D−r2 I) · · · (D−rn I).
1
y p (x) = F(x).
P(D)
1
P(D) F(x) = F(x).
P(D)
Inverse Operators of D and (D − r)
Observe that Z
Dy p (x) = F(x) =⇒ y p (x) = F(x) dx.
It is natural to define Z
1
F(x) := F(x) dx.
D
Observe that
1
(D − r) y p (x) = F(x), (r is a constant) =⇒ y p (x) = F(x).
D−r
The solution R of the fist order linear ODE (D − r) y p (x) = F(x) is
y p (x) = erx e−rx F(x) dx. Therefore, we define
Z
1
F(x) := erx e−rx F(x) dx.
D−r
Technique 1: Successive Integrations
P(D) y p = F(x),
where P(D) = (D − r1 )(D − r2 ) · · · (D − rn ).
Then
1 1
y p (x) = F(x) = F(x)
P(D) (D − r1 )(D − r2 ) · · · (D − rn )
!!!
1 1 1
= ··· F(x) .
D − r1 D − r2 D − rn
Apply the operators
Z
1
g(x) = erk x e−rk x g(x) dx for k = 1, 2, . . . , n
D − rk
successively and compute y p (x).
Note: The successive integrations are likely to become complicated and
time-consuming.
Example for Successive Integrations Technique
Using the operator method, find a particular solution of y00 − 3y0 + 2y = xe x .
1 A1 A2 An
= + + ··· + .
P(D) (D − r1 ) (D − r2 ) (D − rn )
!
1 A1 A2 An
y p (x) = F(x) = + + ··· + F(x)
P(D) (D − r1 ) (D − r2 ) (D − rn )
1 1 1
= A1 F(x) + A2 F(x) + · · · + An F(x)
(D − r1 ) (D − r2 ) (D − rn )
Z ! Z ! Z !
= A1 er1 x e−r1 x F(x) dx + A2 er2 x e−r2 x F(x) dx + · · · + An ern x e−rn x F(x) dx
Example for Partial Fractions and Integrations Technique
Using the operator method, find a particular solution of y00 − 3y0 + 2y = xe x .
1 1 1
xe x = xe x − xe x
P(D) (D − 2) (D − 1)
Z Z
= e2x e−2x xe x dx − e x e−x xe x dx
Z Z
= e2x xe−x dx − e x x dx
2 x 2
" #
x e x
= e2x −xe−x − e−x − = (−1) e x 1 + x +
2 2
x2
h i
y p (x) = (−1) e 1 + x + 2 is a particular solution of given nonhomogeneous linear
x
ODE.
Operator Method when F(x) = xk
To find a particular solution of P(D)y = xk , where P(D) = Dn + an−1 Dn−1 + · · · + a1 D + a0
with a0 , 0 and k is a positive integer, it is preferable to expand the operator
P(D) = (a0 + a1 D + · · · + an−1 D
1 n−1 + Dn )−1 into power series expansion and operate on
the function xk .
In the power series expansion, it is obvious that terms of the expansion beyond k-th
power of D need not be written, since Dm xk = 0 for all m > k.
To expand into power series, use the Geometric Series.
1 1
= 1 + D + D2 + D3 + · · · and = 1 − D + D2 − D3 + · · ·
1−D 1+D
! " #!−1
1 1 a1 an−1 n−1 1 n
= 1+ D + ··· + D + D
P(D) a0 a0 a0 a0
! " # " #2
1 a1 an−1 n−1 1 n a1 an−1 n−1 1 n
= + + + + + + + + .
1 − D · · · D D D · · · D D · · ·
a0 a0 a0 a0 a0 a0 a0
If a0 = 0 and a1 , 0, then
! " #!−1
1 1 a2 a3 an−1 n−2 1 n−1
= 1+ D + D2 + · · · + D + D .
P(D) a1 D a1 a1 a1 a1
Example for Operator Method when F(x) = xk
P(D) = 1 − 2D2 + D3 .
1 1 1
= = = 1+(2D2
−D3
)+(2D 2
−D3 2
) +(2D2
−D ) +· · ·
3 3
P(D) 1 − 2D2 + D3 1 − (2D2 − D3 )
Let
P(D) = (D − r1 )(D − r2 ) · · · (D − rn ) and F(x) = Aeαx ,
where α and A , 0 are real constants.
1 αx Aeαx
Ae = if P(α) , 0.
P(D) P(α)
Operator Method when F(x) = Aeαx if P(α) = 0
If P(D) = (D − α)k and F(x) = Aeαx , where α and A , 0 are real constants, and k ∈ N,
then
1 αx xk αx
Ae = Ae .
(D − α)k k!
Let P(D) = Dn + an−1 Dn−1 + · · · + a1 D + a0 .
Suppose that α is a root of the auxiliary polynomial
P(r) = rn + an−1 rn−1 + · · · + a1 r + a0 = 0 with multiplicity k. Then P(r) = (r − α)k Q(r),
where Q(α) , 0. Note that P(k) (α) = k! Q(α).
Let
P(D) = (D − α)k Q(D) and F(x) = Aeαx ,
where α and A , 0 are real constants and Q(α) , 0. Note that P(α) = 0. Then
1 αx 1 αx xk Aeαx xk A eαx
Ae = Ae = = .
P(D) (D − α) Q(D)
k k! Q(α) (k)
P (α)
Example for Operator Method when F(x) = Aeαx if P(α) , 0
Using the operator method, find a particular solution of y000 − y00 + y0 + y = 3e−2x .
P(D) = 1 + D − D2 + D3 .
Note that P(−2) = 1 + (−2) − (−2)2 + (−2)3 = −13 , 0.
We know that αx
1 Ae
Aeαx = if P(α) , 0.
P(D) P(α)
Therefore,
1 e−2x e−2x (−3) −2x
3e−2x
= 3 = 3 = e .
P(D) P(−2) (−13) 13
(−3) −2x
y p (x) = 13 e is a particular solution of given nonhomogeneous linear ODE.
Example for Operator Method when F(x) = Aeαx if P(α) = 0
Using the operator method, find a particular solution of (D − 1)(D + 5)(D − 2)3 y = 3e2x .
1 αx xk Aeαx
Ae = .
P(D) k! Q(α)
Therefore
1 x3 3e2x x3 3e2x 1 3 2x
3e =
2x
= = x e .
P(D) 3! Q(2) 6 7 14
y p (x) = 1
14 x3 e2x is a particular solution of given nonhomogeneous linear ODE.
Operator Method when P(D) = φ(D2 ) and F(x) = A sin(αx) or A cos(αx)
(D2 )n A sin(αx) = A (−α2 )n sin(αx) and (D2 )n A cos(αx) = A (−α2 )n cos(αx) for n ∈ N.
Let P(D) = φ(D2 ), where φ(T ) is a polynomial function in D2 .
Let F(x) = A sin(αx) or A cos(αx), where α and A , 0 are real constants such that
P(−α) = φ(−α2 ) , 0. Then,
φ(D2 ) A sin(αx) = A φ(−α2 ) sin(αx)
φ(D2 ) A cos(αx) = A φ(−α2 ) cos(αx)
If φ(−α2 ) , 0, then
1 sin(αx)
A sin(αx) = A
φ(D2 ) φ(−α2 )
1 cos(αx)
A cos(αx) = A
φ(D2 ) φ(−α2 )
Example for Operator Method when P(D) = φ(D2 ) and F(x) = A sin(αx)
or A cos(αx)
φ(D2 )
P(D) = ,
ψ(D)
where φ and ψ are some polynomials with real coefficients.
It gives that
1 ψ(D)
= .
P(D) φ(D2 )
1 sin(αx + β)
A sin(αx + β) = A ,
φ(D )
2 φ(−α )
2
1 cos(αx + β)
A cos(αx + β) = A .
φ(D2 ) φ(−α2 )
γx
(γx)+i(αx+β)
=e cos(αx + β) + i sin(αx + β)
Using the fact that e
I If the nonhomogeneous term is F(x) = eγx cos(αx + β), then we can find its
particular solution as the real part of particular solution of the ODE having
nonhomogeneous term G(x) = e(γx) + i (αx+β) .
I If the nonhomogeneous term is F(x) = eγx sin(αx + β), then we can find its
particular solution as the imaginary part of particular solution of the ODE having
nonhomogeneous term G(x) = e(γx) + i (αx+β) .
Using the operator method, find a particular solution of y00 − y0 + y = e2x cos(x).
Hint:
1 1
= .
P(D) D2 − D + 1
P(2 + i) = (2 + i)2 − (2 + i) + 1 = 2 + 3i , 0.
Using the operator method, find a particular solution of y000 + y00 − y0 − y = cos(2x).
Idea:
1 1 1 (D − 1)
= = .
D + D − D − 1 D + 1 D − 1 (D − 1)
3 2 2 2 2
(−2) cos(2x)
Answer: 25 sin(2x) − 25 .
Other Useful Formulas when F(x) = eαx f (x) or x f (x)
dn y dn−1 y dy
n
+ a n−1 (x) n−1
+ · · · + a1 (x) + a0 (x) y = F(x), (4)
dx dx dx
where a0 (x), a1 (x), . . ., an−1 (x) and F(x) are continuous on an interval I = (a, b) ⊆ R.
Note: The coefficient functions are numbered in reverse order and the coefficient of
highest order term is 1.
The general solution of (4) is given by
where yc (x) is the complementary function and y p (x) is a particular solution of (4).
The complementary function yc (x) is the general solution of corresponding
homogeneous equation
dn y dn−1 y dy
+ a n−1 (x) + · · · + a1 (x) + a0 (x) y = 0. (5)
dxn dx n−1 dx
Continuation of Previous Slide
Let {y1 , y2 , . . . , yn } be a fundamental set of solutions of the corresponding
homogeneous equation (5). Then,
yc (x) = c1 y1 (x) + c2 y2 (x) + · · · + cn yn (x),
where c1 , . . ., cn are arbitrary real constants.
In the method of Variation of Parameters, we seek a particular solution y p (x) of the form
y p (x) = v1 (x)y1 (x) + v2 (x)y2 (x) + · · · + vn (x)yn (x) (6)
and try to determine v1 (x), v2 (x), . . ., vn (x).
Differentiating y p , we get
n
X n
X
y0p = vi y0i + v0i yi .
i=1 i=1
To avoid second and higher order derivatives of vi ’s, we impose the condition
n
X
v0i yi = 0. (7)
i=1
Continuation of Previous Slide
Therefore,
n
X
y0p = vi y0i .
i=1
Again, differentiating y0p , we obatin
n
X n
X
y00p = i +
vi y00 v0i y0i .
i=1 i=1
For the same reason, we impose the condition
n
X
v0i y0i = 0. (8)
i=1
(n−1)
p , . . ., y p
Likewise, on computing y000 , we impose (n − 3) additional conditions involving
v0i ’s as
n
X n
X
i = 0,
v0i y00 ··· , v0i y(n−2)
i = 0. (9)
i=1 i=1
Continuation of Previous Slide
Finally, for the nth condition, use the derived conditions and the fact that L(yc ) = 0 and
L(y p ) = F to obtain
n
X
v0i y(n−1)
i = F. (10)
i=1
y1 v01 + · · · + yn v0n = 0,
y01 v01 + · · · + y0n v0n = 0,
.. .. .. ..
. . . = .
y(n−1)
1 v 0
1 + · · · + y (n−1) 0
n vn = F.
Continuation of Previous Slide
y1 y2 ··· yn
y01 y02 ··· y0n
.. .. .. = W(y1 , . . . , yn )(x) , 0 on (a, b), (11)
. . ··· .
y(n−1)
1 y (n−1)
2 ··· yn(n−1)
F(x) Wk (x)
v0k (x) = , for k = 1, 2, . . . , n, (12)
W(y1 , . . . , yn )(x)
where the determinant Wk (x) is obtained from W(y1 , . . . , yn )(x) by replacing k-th
column by [0, . . . , 0, 1]T .
Continuation of Previous Slide
given that y1 (x) = x2 and y2 (x) = x5 are linearly independent solutions of the
corresponding homogeneous equation.
Answer: Note that x2 y00 − 6x y0 + 10 y = 0 is in the form of Cauchy-Euler equation and
we will study next how to solve the Cauchy-Euler equation. Right now, it is already
given that y1 (x) = x2 and y2 (x) = x5 are its linearly independent solutions.
3 4
y p (x) = −3x − x .
3
2
3 4
y(x) = c1 x + c2 x − 3x − x ,
2 5 3
2
where c1 and c2 are arbitrary real constants.