ode-lecture-notes
ode-lecture-notes
Course content
• First order differential equations: solution by separation of variables, homogeneous, exact and
integrating factor.
• Second order linear equations: homogeneous with constant and variable coefficients, using inverse
differential operators, variation of parameters.
• Sets: elements, specification, finite and infinite, universal, empty and disjoint. Subsets. Venn
diagram: union, intersection, complement, difference, number of elements and logical arguments.
• Boolean algebra: truth values, logical equivalence, truth tables, NOT, OR and AND operators,
and their applications to electric circuits.
References
[1] Calculus With Analytic Geometry (5th edition) by Larson Roland E., Hostetler Robert P., and
Bruce H. Edwards
[3] Swift R. J., & Wirkus S. (2014). A Course in Ordinary Differential Equations, 2nd Edition, 807 p,
Published by Chapman and Hall/C, ISBN-13: 978-1466509085.
[4] Noonburg, V. W. (2014). Ordinary Differential Equations: From Calculus to Dynamical Systems,
334 p, Published by Mathematical Association of America, ISBN-13: 978-1939512048.
Lecture 1
∂z ∂z
+ = 2(x + y) (2)
∂x ∂y
There are two types of differential equations: ODE and PDE.
Definition 1.3 (Ordinary differential equation (ODE)). An ODE is a differential equation which
contains derivative(s) of a function which depends on only one independent variable. For example,
equation (1) is an ODE since it contains ordinary derivatives.
Definition 1.4 (Partial differential equation (PDE)). A PDE is a differential equation which
contains derivative(s) of a function which depends on more than one independent variable. For
example, equation (2) is a PDE since it contains partial derivatives. Other examples of PDEs are:
∂u ∂2u
= α2 2 (1D heat equation)
∂t ∂x
∂2 u 2
2∂ u
= c (1D wave equation)
∂t2 ∂x2
∂2 u ∂2u ∂2 u
+ 2 + = 0 (Laplace equation)
∂x2 ∂y ∂z 2
Exercise:
Determine the order and degree of the following differential equations.
d4 y d2 y
(a) − − 6y = 0.
dx4 dx2
( )4 )5
d2 y dy
(
(b) − + 3y = ex .
dx2 dx
Definition 1.7 (Linear ordinary differential equation). A linear ODE of order n in the dependent
variable y and independent variable x is one which can be expressed in the form
dn y dn−1 y dn−2 y d2 y dy
an (x) + an−1 (x) + an−2 (x) + · · · + a2 (x) + a1 (x) + a0 (x)y = F̃ (x), (4)
dxn dxn−1 dxn−2 dx2 dx
where an (x) ̸= 0 and which is such that
(ii) No product of the dependent variable, y, and/or its derivatives are present.
(iii) No transcendental functions of the dependent variable, y, and its derivatives occur. For example,
cos(y), ln y or ey is absent.
d2 y dy
2
−7 − 3y = 0 (linear equation with constant coefficient)
dx dx
d4 y 3
2d y
2
3d y
x − x + x − e−x y = cos(x) (linear equation with variable coefficient)
dx4 dx3 dx2
→ Note: trigonometric, exponential, and logarithmic functions are called transcendental functions.
A differential equation that does not satisfy all the three conditions above is called nonlinear
d2 y dy
differential equation. For example, the equation 2
+ xy + y 2 = ex is nonlinear because of the
dx dx
dy d2 y
terms xy and y 2 . Similarly, the equation + cos(y) = 0 is nonlinear because cos(y) is a
dx dx2
transcendental function of y.
Exercise:
Classify the following ODEs into linear or nonlinear, giving reasons.
)2
d2 y dy
(
(a) 2
−7 − 4y = 0.
dx dx
d3 y dy
(b) −5 + 6y 2 = 9.
dx3 dx
)2
d2 y dy
(
(c) x 2
+ x −y − 3y 2 = 0.
dx dx
Example(s):
A curve is defined by the condition that at each point the slope is 2 times the sum of the coordinates.
Form an ODE from the information given.
Solution
∆y dy
The general slope/gradient of the curve is defined by lim ≡ . Thus, from the given
∆x→0 ∆x dx
dy
information, we have = 2 (x + y), which is the required ODE.
dx
Example(s):
Powdered milk is being transformed to liquid milk at a rate that is directly proportional to the
unconverted milk. If originally there was 30kg of powdered milk. Find the ODE describing this
information.
Solution
Let y kg be the mass of converted milk at any time t. Thus, the mass of unconverted milk at time t
dy dy
is (30 − y) kg. From the given statement, we have ∝ (30 − y) ⇒ = k(30 − y), where k is a
dt dt
constant of proportionality.
From equation (5), the constants 3 and 4 are defined constants while a, b and c are undefined constants.
Thus, a, b and c are called arbitrary constants.
Definition 1.9 (Essential arbitrary constant). Arbitrary constants are said to be essential if they
cannot be reduced to a lower number of constants. For example, equation (5) can be simplified as
The arbitrary constants, a, b and c , in equation (5) are not all essential constants because they can be
reduced to 2 constants by replacing (b + c) with another constant d, as shown in equation (6). Hence,
there are only 2 essential arbitrary constants, i.e., a and d in equation (6).
Definition 1.10 (Primitive). A primitive is a function which involves essential arbitrary constants.
For example, the function (6) is called a primitive.
→ Note: to obtain a differential equation from a primitive, we differentiate the given primitive a
number of times equal to the number of essential arbitrary constants then manipulate algebraically
the derivatives to eliminate the essential arbitrary constants.
→ Note: a primitive involving n essential arbitrary constants gives rise to a differential equation of
order n.
Example(s):
Obtain a differential equation associated with the following primitives
Solution
Since we have two essential arbitrary constants, we differentiate the given primitive 2 times.
Thus,
y = Ax2 + a2 x ⇒ y ′ = 2Ax + B and y ′′ = 2A
1
⇒ A = y ′′ and B = y ′ − 2Ax = y ′ − xy ′′
2
Substituting in the given primitive yields
x2 ′′ d2 y dy
y + x y ′ − xy ′′ x2 y ′′ − 2xy ′ + 2y = 0 or x2
( )
y= ⇒ − 2x + 2y = 0
2 dx2 dx
Solution
Since we have two essential arbitrary constants, we differentiate the given primitive 2 times.
d2 y
⇒ y ′′ = −4y or + 4y = 0
dx2
(c) y = Ae2x + Be−3x .
Solution
Since we have two essential arbitrary constants, we differentiate the given primitive 2 times.
Thus,
y ′′ + y ′ − 6y = 0
Alternatively, equations (i), (ii) and (iii) can be written in matrix form as
e2x e−3x −y A 0
2x
2e −3e−3x −y ′ B = 0
4e2x 9e−3x −y ′′ 1 0
The above matrix is a homogeneous system of equations in the unknowns A and B. To obtain a
non-trivial solution (i.e., for A ̸= 0 and B ̸= 0), the determinant of the coefficient matrix should
be equal to zero. That is, ø ø
ø e2x e−3x −y øø
ø
ø 2x
ø2e −3e−3x −y ′ ø = 0
ø
ø 2x
ø4e 9e−3x −y ′′ ø
ø
Exercise:
Solution
Since we have two essential arbitrary constants, we need to differentiate the given primitive 2
times. Now,
y = e2x (A cos x + B sin x) ⇒ ye−2x = A cos x + B sin x
Differentiating implicitly, using product rule on the left hand side, yields
Definition 1.11 (General solution). A general solution of an ODE is the primitive associated with
the given differential equation. The number of essential arbitrary constants in the solution should be
equal to the order of the given differential equation. For example, the primitive y = mx + c is a general
solution of the equation y ′′ = 0, where m and c are essential arbitrary constants (parameters). The
function y = mx + c is a family of straight lines on the xy-plane.
Definition 1.12 (Particular solution). A particular solution of an ODE is obtained from the general
solution by assigning numerical values to the essential arbitrary constants. For example, if we are
given the initial conditions, say y(0) = 3 and y ′ (0) = 4, then we would get the particular solution as
y = 4x + 3. The function y = 4x + 3 is a single straight line on the xy-plane.
Example(s):
1. Show that y = e2x and y = e−3x are both solutions to the differential equation defined by
d2 y dy
2
+ − 6y = 0 − − − (∗)
dx dx
Solution
dy d2 y
From y = e2x − − − (i) ⇒ = 2e2x and = 4e2x . Substituting these derivatives in the
dx dx2
given differential equation yields
( )
4e2x + 2e2x − 6 e2x = 0
dy d2 y
Similarly, y = e−3x −−−(ii) ⇒ = −3e2x and 2 = 9e2x . Substituting these derivatives
dx dx
in the given differential equation yields
( )
9e2x − 3e2x − 6 e−3x = 0
→ Note: if y1 , y2 , · · · , yn are each solution to a DE, then their linear combination is also a solution
to the differential equation. That is, y = a1 y1 + a2 y2 + · · · + an yn , where ai , i = 1, 2, 3, · · · , n are
arbitrary constants. For instance, y = a1 e2x + a2 e−3x is also a solution to the given differential
equation (∗).
2. Verify that the given function is a solution of the corresponding differential equation.
d2 y
(a) + y = 0; y = cos x
dx2
d2 y dy
(b) +4 + 13y = 0; y = e−2x (cos 3x + sin 3x)
dx2 dx
Lecture 2
Example(s):
Solve the following differential equations
(a) sin x cos ydx + cos x sin ydy = 0.
Solution
Dividing the equation through by cos x cos y and then integrating we get
sin x sin y
∫ ∫ ∫
dx + dy = 0 ⇒ − ln | cos x| − ln | cos y| = − ln |C| ⇒ cos x cos y = C
cos x cos y
Solution
x2 + 1 y
∫ ∫ ∫
Dividing through by (x + 1)(y 2 + 1) and integrating we get dx + 2
dy = 0.
x+1 y +1
By long division,
x−1
x2
)
x+1 +1
− x2 − x
−x+1
x+1
2
x2 + 1 2
So, = (x − 1) + . Thus, we have
x+1 x+1
2 y
∫ ∫ ∫ ∫
(x − 1)dx + dx + dy = 0
x+1 y2 + 1
x2 1
⇒ − x + 2 ln |x + 1| + ln |y 2 + 1| = C
2 2
Exercise:
y
(a) Solve xy ′ = y + y 2 . [ans: = C]
x(1 + y)
2
(b) Solve (2x2 y + y)dx + xdy = 0. [ans: x2 + ln(xy) = C or xy = a1 e−x ]
dy y2 − 1 y−1
(c) Solve = . [ans: = Cx2 ]
dx x y+1
dy
(d) Solve the initial value problem: (x2 + 9) + xy = 0; y(0) = 2. [ans: y 2 (x2 + 9) = 36]
dx
dy 2
(e) Solve (y + 1) + x(y 2 + 2y) = x. [ans: y 2 + 2y = 1 + Ce−x ]
dx
(f) Determine the family of curves such that at each point the slope is given by 2xy 2 . [ans:
1
x2 + = C]
y
(g) Show that the solution of the differential equation (1 + y 2 )dx + (1 + x2 )dy = 0; y(0) = −1 is
xy − x − y − 1 = 0.
Example(s):
Solve the following differential equations
Solution
1
Let u = x + 2y ⇒ du = dx + 2dy ⇒ dy = (du − dx). Substituting in the given
2
differential equation, we get
1 (3u + 5)
(u + 1)dx + (3u + 5)(du − dx) = 0 ⇒ dx − du = 0
2 u+3
3u + 5 3u + 5 4
∫ ∫ ∫
Integrating yields dx − du = 0. By long division, = 3− . So we have
u+3 u+3 u+3
4 4
∫ ∫ ( ) ∫ ∫ ∫ ∫
dx − 3− du = 0 ⇒ dx − 3du + du = C
u+3 u+3
⇒ x − 3u + 4 ln |u + 3| = C
⇒ x − 3(x + 2y) + 4 ln |x + 2y + 3| = C
⇒ x + 3y − 2 ln |x + 2y + 3| = a1
dy
(b) = (x + y)2 .
dx
Solution
dy
From = (x + y)2 ⇒ dy − (x + y)2 dx = 0. Let u = x + y ⇒ du = dx + dy ⇒ dy =
dx
du − dx. Substituting in the given DE yields (du − dx) − u2 dx = 0 ⇒ du − (1 + u2 )dx = 0.
Rearranging and integrating we get
du
∫ ∫
= dx − − − −(∗)
1 + u2
Let u = tan θ.
⇒ du = sec2 θdθ
Therefore, equation (∗) becomes
sec2 θdθ
∫ ∫ ∫ ∫
2 θ
= dx ⇒ dθ = dx ⇒ θ = x + C,
1+tan
where C is a constant of integration. Back substitution yields
tan−1 (u) = x + C ⇒ tan−1 (x + y) = x + C ⇒ x + y = tan (x + C)
dy
(c) = sin(x + y).
dx
Solution
dy
From = sin(x + y) ⇒ sin(x + y)dx − dy = 0. Let u = x + y ⇒ du = dx + dy ⇒
dx
dy = du − dx. Substituting in the given DE yields sin udx − (du − dx) = 0 ⇒ (1 + sin u)dx −
du = 0. Rearranging and integrating we get
du
∫ ∫ ∫
dx − = 0 − − − −(∗)
1 + sin u
Here, we use t substitution by letting t = tan( u2 ).
1 u 2dt 2dt 2dt
( )
⇒ dt = sec2 du ⇒ du = 2 u = 2
(u) =
2 2 sec ( 2 ) 1 + tan 2 1 + t2
Consider the following diagram
√
1 + t2
t
u
. 2
u u u u 2t
( ) ( ) ( )
1 sin u = sin + = 2 sin cos =
2 2 2 2 1 + t2
du 2
2dt/(1 + t ) 2dt 2dt
∴ = 2t = 2 =
1 + sin u 1 + 1+t2 t + 2t + 1 (t + 1)2
Exercise:
Solve the following differential equations
dy (
x+y
)
(a) = sin(x + y) + cos(x + y). [hint: put u = x + y, ans: 1 + tan 2 = Cex ]
dx
(b) (x + y)dx + (3x + 3y − 4)dy = 0. [hint: put u = x + y, ans: x + 3y + 2 ln(x + y − 2) = C]
dy x+y+1 2 1
(c) = . [hint: put u = x + y, ans: (x + y) + ln |3x + 3y + 4| = x + C]
dx 2y + 3 + 2x 3 9
Let f (x, y) = x3 + x2 y + 4y 2 x
⇒ f (λx, λy) = (λx)3 + (λx)2 (λy) + 4(λy)2 (λx)
= λ3 x3 + λ3 x2 y + 4λ3 y 2 x
= λ3 (x3 + x2 y + 4y 2 x)
= λ3 f (x, y)
Equation (7) is said to be homogeneous if and only if both M (x, y) and N (x, y) are homogeneous and
of the same degree. Note that if the sum of the powers of each term in equation (7) is the same, then
equation (7) is said to be homogeneous. If equation (7) is homogeneous, then the substitution
y = ux
Example(s):
Solve the following differential equations
10([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Solution
First, we need to test for homogeneity as follows: M (x, y) = x − 2y ⇒ M (λx, λy) =
λx − 2(λy) = λ(x − 2y) = λM (x, y), which is homogeneous of degree 1.
Similarly, N (x, y) = x ⇒ N (λx, λy) = (λx) = λ(x) = λN (x, y) which is homogeneous of degree
1.
Therefore, the given DE is homogeneous of degree 1. Next, let
y = ux ⇒ dy = udx + xdu
Solution
Clearly, the given equation is homogeneous of degree 1. Next, let
y = ux ⇒ dy = udx + xdu
dy
(c) xy = y 2 + 2x2 .
dx
Solution
The given DE can be written as (y 2 + 2x2 )dx − xydy = 0 − − − (∗). Clearly, equation (∗) is
homogeneous of degree 2. Next, let
y = ux ⇒ dy = udx + xdu
Exercise:
Solve the following equations
11([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
dy x+y−2
(a) = .
dx x−y+2
Solution
Put v = y − 2 ⇒ dv = dy. Substituting in the given DE yields
dv x+v
= ⇒ (x − v)dv − (x + v)dx = 0 − − − (∗)
dx x−v
Clearly, this equation is homogeneous of degree 1. Next, let
v = ux ⇒ dv = udx + xdu
dy y2 x
(b) x =y+ [ans: − = ln x + C]
dx x y
dy
(c) x = x cos(y/x) + y [ans: sec(y/x) + tan(y/x) = Cx]
dx
√
(d) xdy − ydx = x2 + y 2 dx [ans: sinh−1 (y/x) = ln x + C]
dy 1√ 2
= y 2 + x x2 + y 2
√
(e) xy [ans: x + y 2 = ln x + C]
dx x
12([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
∂2φ ∂2φ
respectively. From differential calculus, = . Therefore,
∂y∂x ∂x∂y
∂M . ∂N
= (8)
∂y ∂x
Equation (8) is the necessary condition for equation (7) to be exact. Now, from equation (i), we have
∂φ = M (x, y)∂x. Integrating yields
∫ ∫ ∫
∂φ = M (x, y)∂x ⇒ φ(x, y) = M (x, y)dx + g(y), − − −(∗∗)
where g is an arbitrary function. Equation (∗∗) is the solution of equation (7) so long as g(y) is
determined as follows: differentiating (∗∗) partially with respect to y, we get
∂φ ∂
∫
= M (x, y)dx + g ′ (y)
∂y ∂y
∂
∫
Comparing with equation (ii), we obtain M (x, y)dx + g ′ (y) = N (x, y). Therefore,
∂y
∂
∫ [ ∫ ]
g(y) = N (x, y) − M (x, y)dx dy + C,
∂y
where C is a constant of integration.
Example(s):
Solve the following differential equations
(a) (2xy + cos y)dx + (x2 − x sin y)dy = 0.
Solution
First, we need to test whether the given DE is exact. Here,
Thus,
φ(x, y) = x2 y + x cos y + g(y), − − −(∗)
where g is an arbitrary function of integration. Equation (∗) is the solution provided g(y) is
determined. Differentiating equation (∗) partially wrt y yields
∂φ
= x2 − x sin y + g ′ (y)
∂y
13([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
φ(x, y) = x2 y + x cos y + C
Solution
First, we need to test whether the given DE is exact. Here,
1
M = x3 + x tan y and N = y ln y + x2 sec2 y
2
∂M ∂N
⇒ = x sec2 y and = x sec2 y
∂y ∂x
∂M ∂N
Since = = x sec2 y, therefore, the given DE is exact. Now, let the solution to the given
∂y ∂x
DE be φ(x, y) (which we need to determine) such that dφ = M dx + N dy. That is,
∂φ ∂φ 1
dx + dy = (x3 + x tan y)dx + (y ln y + x2 sec2 y)dy
∂x ∂y 2
Comparing coefficients of the differentials, we have
∂φ
∫
= x3 + x tan y − − − (i) ⇒ φ(x, y) = (x3 + x tan y)dx + g(y) − − − (ii)
∂x
From (i), we have ∂φ = (2xy + cos y) ∂x. Integrating partially with respect to x, yields
∫ ∫
∂φ = (x3 + x tan y)∂x + g(y)
Thus,
x4 1 2
+ x tan y + g(y), − − −(∗)
φ(x, y) =
4 2
where g is an arbitrary function of integration. Equation (∗) is the solution provided g(y) is
determined. Differentiating equation (∗) partially wrt y yields
∂φ 1
= x2 sec2 y + g ′ (y)
∂y 2
Exercise:
14([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
3. Find the value of n such that when the differential equation (x+y 3 )dx+6xy 2 dy = 0 is multiplied
by xn makes it exact and hence solve it. [ans: n = − 21 , φ(x, y) = 2x1/2 y 3 + 32 x3/2 + C]
( )
3−y y 2 − 2x
( )
4. Show that the equation dx + dy = 0 is exact. Hence, find φ(x, y) given that
x2 xy 2
y−3 2
φ(−1, 2) = 0. [ans: φ(x, y) = + − 2]
x y
Lecture 3
µ = e . P (x)dx
∫
→ Note: in finding the integrating factor, we don’t write the constant of integration.
Example(s):
Solve the following differential equations
15([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Solution
The given DE can be rewritten as
dy
+ 2y = 1 · · · (∗) (linear ODE in dependent variable y)
dx
∫ ∫
Here, P (x) = 2 ⇒ P (x)dx = 2dx = 2x. Therefore, the integrating factor is
∫
P (x)dx
µ=e = e2x
dy d ( 2x )
e2x + 2e2x y = e2x ⇒ ye = e2x
dx dx
Integrating with respect to x yields
1 1
∫
2x
ye = e2x dx ⇒ ye2x = e2x + C ⇒ y= + Ce−2x
2 2
which is the solution.
Solution
The given DE can be rewritten as
dx 2
+ x = 4y · · · (∗) (linear ODE in dependent variable x)
dy y
2 2
∫ ∫
Here, P (y) = ⇒ P (y)dy = dy = 2 ln y = ln(y 2 ). Therefore, the integrating factor
y y
is ∫
= eln(y ) = y 2
P (y)dy 2
µ=e
Multiplying equation (∗) by y 2 yields
dx d ( 2)
y2 + 2yx = 4y 3 ⇒ xy = 4y 3
dy dy
Integrating with respect to y yields
∫
2
xy = 4y 3 dx ⇒ xy 2 = y 4 + C,
Solution
The given DE can be rewritten as
dy 1
− y = x2 · · · (∗) (linear ODE in dependent variable y)
dx x
1 1
∫ ∫
Here, P (x) = − ⇒ P (x)dx = − dx = − ln x = ln(1/x). Therefore, the integrating
x x
factor is ∫
P (x)dx 1
µ=e = eln(1/x) =
x
16([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
1
Multiplying equation (∗) by yields
x
1 dy 1 d y
( )
− 2y = x ⇒ =x
x dx x dx x
Integrating with respect to x yields
y y 1
∫
= xdx ⇒ = x2 + C,
x x 2
which is the solution.
Exercise:
1. Find the general solution of the following differential equation
dy 2
(a) + 2xy = 2x. [ans: y = 1 + Ce−x ]
dx
dy
(b) + y tan x = sin 2x. [ans: y = −2 cos2 x + C cos x]
dx
dy y
(c) x − 2y = x4 ex . [ans: = (x − 1)ex + C]
dx x2
df (y) dy
2. Show that the transformation u = f (y) reduces the equation · + P (x)f (y) = Q(x) to
dy dx
dy 2
a linear DE. Hence, solve (y + 1) + x(y 2 + 2y) = x. [ans: y 2 + 2y = 1 + Ce−x ]
dx
dy
3. Solve the differential equation defined by x − 2y = x6 sin x. [ans:
dx
y
= (6x − x3 ) cos x + (3x2 − 6) sin x + C]
x2
dC 2 12
4. Solve the initial value problem m2 + 2mC = 2; C(2) = 4. [ans: C = + 2]
dm m m
z = y. 1−n ,
Example(s):
Solve the following differential equations
17([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
dy
(a) + y = xy 4 .
dx
Solution
dy dy
+ y = xy 4 ⇒ + y −3 = x y −4
dx dx
dy 1 dz
Let z = y −3 ⇒ dz = −3y −4 dy ⇒ y −4 =− . So,
dx 3 dx
−1 dz dz
+z =x ⇒ − 3z = −3x − − − (∗) (linear ODE in dependent variable z)
3 dx dx
The integrating factor is ∫
−3dx
µ=e = e−3x
Multiplying equation (∗) through by e−3x yields
−3x dz d
∫
−3x −3x
e − 3e z = −3xe ⇒ (ze−3x ) = −3xe−3x ⇒ ze −3x
= −3 xe−3x dx + C
dx dx
Integrating by parts and rearranging we get [hint: put u = x, dv = e−3x dx]
3z = 3x + 1 + Ce3x ⇒ 3y −3 = 3x + 1 + Ce3x
dy
(b) + y = y 2 (sin x + cos x).
dx
Solution
dy dy
+ y = y 2 (sin x + cos x) y −2
+ y −1 = sin x + cos x
⇒
dx dx
dy dz
Let z = y −1 ⇒ dz = −y −2 dy ⇒ y −2 = − . So,
dx dx
dz
− z = −(sin x + cos x) − − − (∗) (linear in z)
dx
The integrating factor is ∫
(−1)dx
µ=e = e−x
Multiplying equation (∗) through by e−x , we get
dz d
e−x − e−x z = −e−x (sin x + cos x) ⇒ (ze−x ) = −e−x (sin x + cos x)
dx dx
∫ [∫ ∫ ]
−x −x −x −x
⇒ ze =− e (sin x + cos x)dx = − e sin xdx + e cos xdx
18([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
dy y x2
(a) Solve − = y3. [ans: 3 + 2x3 = C]
dx x y2
dy 1 1 3 x
( )
(b) Solve − 1+ y = y3. [ans: = Ce−x − 6]
dx 2 x x y2
y
(c) Solve x(6x2 − y − 1)dy + 2ydx = 0. [ans: = 6 + Ce−y ]
x2
dy
(d) Prove that the transformation z = y 1−n reduces the equation + P (x)y = Q(x)y n to a linear
dx
dy x
equation in z and x. Hence, solve the initial value problem + xy = 3 ; y(0) = 2. [ans:
dx y
2
y 4 = 1 + 15e−2x ]
Example(s):
(a) A curve is defined by the condition that at each point the gradient is equal to twice the sum of
the coordinates. Find the equation of the curve.
Solution
dy dy 1
= 2(x + y) ⇒ − 2y = 2x which is linear in y. Solving it yields y = −x − + Ce2x .
dx dx 2
M dy − N dx = 0, (∗)
→ Note 1: orthogonal trajectories has important applications in the field of physics and engineering.
For example, the equipotential lines and the streamlines in an irrotational two-dimensional flow are
orthogonal.
dy −1
→ Note 2: the differential equation for the other family is obtained by replacing by .
dx dy/dx
Example(s):
19([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
(a) x + y = c.
Solution
Here, F (x, y) ≡ x + y = c ⇒dF ≡ dx + dy = 0, which is the DE for the family F (x, y).
dy dx
The DE for the orthogonal trajectories is obtained by replacing by − . Hence, the
dx dy
DE for the orthogonal trajectories is dy − dx = 0. Integrating yields y − x = k, which is
the required orthogonal trajectories.
x
(b) y = .
c+x
Solution
x ydx − xdy
Here, F (x, y) ≡ − x = c ⇒ dF ≡ − dx = 0 ⇒ (y 2 − y)dx + xdy = 0,
y y2
which is the DE for the family F (x, y). The DE for the orthogonal trajectories is obtained by
dy dx
replacing by − . Hence, the DE for the orthogonal trajectories is (y 2 −y)dy −xdx = 0.
dx dy
Integrating yields 2y 3 − 3y 2 − 3x2 = k, which is the required orthogonal trajectories.
(c) x2 + y 2 = c. [ans: orthogonal trajectories are y = kx]
2. (a) Find the orthogonal trajectories of all parabolas having their vertices at the origin and foci
on the x-axis.
Solution
The equation of parabolas having their vertices at the origin and foci on the x-axis is given by
y2 2xydy − y 2 dy
y 2 = cx. Here, F (x, y) ≡ = c ⇒ dF ≡ = 0 ⇒ 2xdy − ydx = 0,
x x2
which is the DE for the family F (x, y). The DE for the orthogonal trajectories is obtained
dy dx
by replacing by − . Hence, the DE for the orthogonal trajectories is 2xdx + ydy = 0.
dx dy
Integrating yields 2x2 + y 2 = k, which is the required orthogonal trajectories.
(b) Find the orthogonal trajectories of family of straight lines through the origin. [hint: the
equation of the family of straight lines through the origin is y = mx, answer: orthogonal
trajectories are x2 + y 2 = k]
Example(s):
(a) A substance cools from 100o C to 60o C in 10 seconds. Find the temperature of the substance
after 40 seconds, assuming room temperature to be 20o C.
Solution
We apply Newton’s law of cooling which states that “the rate at which a substance cools is
directly proportional to the excess temperature above the room temperature.”
Let the temperature of the substance at time t be T . Then Newton’s law of cooling becomes:
dT dT
∝ (T − 20) ⇒ = k(T − 20),
dt dt
where k is a constant of proportionality. Separating the variables, we obtain
dT
= kdt.
T − 20
20([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
T − 20
⇒ = e40k = e40×0.1 ln(0.5) = e4 ln(0.5) ⇒ T = 80e4 ln(0.5) + 20 = 25
80
Therefore, T = 25o C, when t = 40 seconds.
(b) The population of Juja constituency in 1964 and 1970 was 12 thousand and 18 thousand
1
respectively. Find the year when the population was 5 thousand, given that the rate of
3
growth of the population is directly proportional to the population.
Solution
dP dP
Let P be the population at time t. Then we have = kP ⇒ = kdt. Integrating and
dt P
applying the given conditions, we get
∫18 1970
dP 1
∫
= kdt ⇒ k= ln(1.5)
P 6
12 1964
Also,
1
∫5 3 ∫t ]5 1
dP [
3
[ ]t 1 [ ]
= kdt ⇒ ln(P ) =k t ⇒ ln(16/3) − ln(12) = ln(1.5) t − 1964
P 12 1964 6
12 1964
⇒ t = 1952
Exercise:
(a) An electric circuit has a constant electromotive force E = 40v, a resistor of R = 10Ω and an
inductance L = 0.2 henry (H), with initial current I = 0 at t = 0 and basic differential equation
dI ( )
is: L + RI = E. Determine the current at any time t. [ans: I = 4 1 − e−50t ]
dt
(b) The JKUAT engineering students’ population N (t) at any time t is assumed to satisfy the logistic
dN 1 10000
growth law = N (10000 − N ). Prove that N (t) = , where C is an arbitrary
dt 500 1 + Ce−20t
constant.
(c) If a body in air at 25o C cools from 100o C to 75o C in one minute. Find its temperature at the
end of three minutes.
(d) A company is using Newspaper advertising to introduce a new product to a community of 50,000
people. It was assumed that the rate at which people learn about the new product is proportional
to the product of the number of people who have heard about it and the number of people who
have not heard about it. If 100 individuals were aware of the product initially and 500 people
dN
were aware about it after 10 days of the campaign [hint: ∝ N (50000 − N )]
dt
i) How many people will be aware of the product after 20 days? [6 mks]
ii) When will half of the community be aware of the product? [3 mks]
Lecture 4
21([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Similarly,
eαx Dy = (D − α)eαx y
That is, to shift eαx to the RHS of D, shift it but in place of D substitute (D − α).
22([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Case 1: When the roots of the auxiliary equation are real and distinct
Let the roots be α and β. Then the general solution is given by
y = Aeαx + Beβx ,
(D − α)(D − β)y = 0
y = Aeαx + Beβx
Example(s):
Solve the following differential equations
d2 y dy
(a) 2
−5 + 6y = 0.
dx dx
Solution
In terms of the D operator the given DE becomes (D2 − 5D + 6)y = 0. Thus, the auxiliary
equation is D2 − 5D + 6 = 0. Hence, the roots are α = 2 and β = 3. The general solution to the
given DE is y = Ae2x + Be3x .
d2 y dy
(b) 2 − − 10y = 0.
dx2 dx
Solution
In terms of the D operator the given DE becomes (2D2 − D − 10)y = 0. The auxiliary equation
is 2D2 − D − 10 = 0. Hence, the roots are α = −2 and β = 25 . The general solution is
5
y = Ae−2x + Be 2 x .
d2 y dy
(c) − = 0. [ans: y = Aex + B]
dx2 dx
Generalization:
Consider a homogeneous linear ODE of order n, with constant coefficients:
[ ]
an Dn + an−1 Dn−1 + an−2 Dn−2 + · · · + a2 D2 + a1 D + a0 y = 0, (16)
23([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Example(s):
Solve the following differential equation
d3 y d2 y dy
(a) 3
− 2 2
− + 2y = 0.
dx dx dx
Solution
In terms of the D operator the given DE becomes (D3 − 2D2 − D + 2)y = 0. The auxiliary
equation is D3 −2D2 −D+2 = 0 ⇒ (D−2)(D+1)(D−1) = 0. The roots are α1 = 2, α2 = −1
and α3 = 1. Thus, the general solution is y = A1 e2x + A2 e−x + A3 ex .
Case 2: When the roots of the auxiliary equation are real and equal
Let the roots be D1 = D2 = α. The general solution is given by
y = (Ax + B)eαx ,
(D − α)2 y = 0
Example(s):
Solve the following differential equations
d2 y dy
(a) 2
−4 + 4y = 0.
dx dx
Solution
In terms of the D operator the equation becomes (D2 − 4D + 4)y = 0. The auxiliary equation
is D2 − 4D + 4 = 0. Hence, the roots are α1 = α2 = 2. The general solution is y = (Ax + B)e2x .
d2 y dy
(b) 2
+ 10 + 25y = 0.
dx dx
Solution
In terms of the D operator the equation becomes (D2 + 10D + 25)y = 0. The auxiliary equation
is (D2 + 10D + 25) = 0. Hence, the roots are α1 = α2 = −5. The general solution is y =
(Ax + B)e−5x .
24([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
d2 y dy
(a) Find the general solution of −2 + y = 0. [ans: y = (Ax + B)ex ]
dx2 dx
d2 y dy
(b) Solve the initial value problem 2
+6 + 9y = 0; y(0) = −4 and y ′ (0) = 14. [ans:
dx dx
y = (2x − 4)e−3x ]
Generalization:
Consider equation (16). Let the roots of the auxiliary equation be α1 , α2 , · · · , αn , where α1 = α2 =
· · · = αn . The general solution is given by
. · · · + An−1 x + An )eαx
y = (A1 xn−1 + A2 xn−2 +
Example(s):
Solve the following differential equation
d3 y d2 y dy
(a) 3
− 3 2
+3 − y = 0.
dx dx dx
Solution
In terms of the D operator the given DE becomes (D3 − 3D2 + 3D − 1)y = 0. The auxiliary
equation is D3 − 3D2 + 3D − 1 = 0 ⇒ (D − 1)(D − 1)(D − 1) = 0. Hence the roots are
D1 = D2 = D3 = 1. The general solution is y = (A1 x2 + A2 x + A3 )ex .
Case 3: When the roots of the auxiliary equation are complex conjugate
Let the roots be D = (α ± iβ). The general solution is given by
Proof. Let the roots be D1 = (α + iβ) and D2 = (α − iβ). The general solution is given by
y = A1 e(α+iβ)x + B1 e(α−iβ)x
= eαx [A1 eiβx + B1 e−iβx ]
= eαx [A1 (cos βx + i sin βx) + B1 (cos βx − i sin βx)]
= eαx [(A1 + B1 ) cos βx + i(A1 − B1 ) sin βx]
= eαx [A cos βx + B sin βx],
Example(s):
Solve the following differential equations
d2 y dy
(a) +6 + 13y = 0.
dx2 dx
Solution
In terms of the D operator the given DE becomes (D2 + 6D + 13)y = 0. The auxiliary equation
is D2 + 6D + 13 = 0. Hence, the roots are D = −3 ± i2 (complex conjugate). From which we
obtain α = −3, β = 2. Thus, the general solution is y = e−3x (A cos 2x + B sin 2x).
25([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
(b) 2
−8 + 25y = 0.
dx dx
Solution
In terms of the D operator the given DE becomes (D2 − 8D + 25)y = 0. The auxiliary equation
is D2 − 8D + 25 = 0. Hence, the roots are D = 4 ± i3 (complex conjugate). From which we
obtain α = 4, β = 3. Thus, the general solution is y = e4x (A cos 3x + B sin 3x).
Exercise:
d2 y dy
(a) Find the general solution of 2
−2 + 5y = 0. [ans: y = ex (A cos 2x + B sin 2x)]
dx dx
d3 y d2 y dy
(b) Find the general solution of 3
− 3 2 + 16 − 48y = 0.[ans: y = A cos 4x + B sin 4x + Ce3x ]
dx dx dx
d2 y
(c) Solve the initial value problem + 9y = 0; y(π) = −2 and y ′ (π) = 3. [ans:
dx2
y = 2 cos 3x − sin 3x]
d2 y dy
(d) Solve the initial value problem 2
−6 + 25y = 0; y(0) = −3 and y ′ (0) = −1. [ans:
dx dx
y= e3x (2 sin 4x − 3 cos 4x)]
Lecture 5
which makes use of inverse differential operator. We will consider 9 cases of F̃ (x).
→ Note: In finding the particular integral, we don’t write constants of integration, since these can be
absorbed with the constants of the complementary solution.
D(eαx ) = αeαx
D2 (eαx ) = α2 eαx
.. ..
. .
Dn (eαx ) = αn eαx ⇒ D=α
Example(s):
26([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
(a) Find the particular integral of 2
−3 + 2y = e−3x .
dx dx
Solution
In terms of the D operator the given DE becomes
1
(D2 − 3D + 2)y = e−3x ⇒ yp (x) = e−3x
D2 − 3D + 2
Substituting D with −3 yields
1 1
yp (x) = e−3x = e−3x
(−3)2 − 3(−3) + 2 20
d3 y d2 y dy
(b) Find the complete solution of − 6 + 12 − 8y = ex + e3x .
dx3 dx2 dx
Solution
In terms of the D operator the given DE becomes (D3 − 6D2 + 12D − 8)y = ex + e3x .
i) The complementary solution
The auxiliary equation is D3 − 6D2 + 12D − 8 = 0. Hence, the roots are
D1 = D2 = D3 = 2. Thus, the complementary solution is yc (x) = (Ax2 + Bx + C)e2x
1
yp (x) = (ex + e3x )
D3
− 6D2
+ 12D − 8
1 1
= 3 2
ex + 3 2
e3x
D − 6D + 12D − 8 D − 6D + 12D − 8
1 1
= 3 2
ex + 3 2
e3x
(1) − 6(1) + 12(1) − 8 (3) − 6(3) + 12(3) − 8
= −ex + e3x
Exercise:
d2 y dy d3 y
(a) Find the complete solution of 5 2 + 2 + e2x = 3 + 24y. [ans:
dx dx dx
−2x 3x 4x 1 2x
y = Ae + Be + Ce + e ]
8
Example(s):
27([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y
(a) Find the particular integral of + 4y = cos 3x
dx2
Solution
In terms of the D operator the given DE becomes (D2 + 4)y = cos 3x. Thus, the particular
integral is given by
1
yp (x) = cos 3x. Substituting D2 with −(3)2 yields.
D2 + 4
1 1
= 2
cos 3x = − cos 3x
−(3) + 4 5
d2 y dy
(b) Find the complete solution of 2
+2 + y = sin 2x.
dx dx
Solution
In terms of the D operator the given DE becomes (D2 + 2D + 1)y = sin 2x.
1 1
yp (x) = sin 2x = sin 2x
D2 + 2D + 1 2
−(2) + 2D + 1
1
= sin 2x (Introduce a D2 in the denominator -multiply by conjugate)
2D − 3
2D + 3 2D + 3 2D + 3
= sin 2x = 2
sin 2x = sin 2x
(2D − 3)(2D + 3) 4D − 9 −4(2)2 − 9
2D + 3 1{ }
= − sin 2x = − 2D[sin 2x] + 3 sin 2x
25 25
1
= − (4 cos 2x + 3 sin 2x)
25
D2 x = 0
D3 x2 = 0
⇒ Dk xn = 0 if k > n
→ Note: the dropping of terms is valid only if there exists at least one term in the denominator
which doesn’t contain the operator D (i.e., if a0 ̸= 0). If, however, a0 = 0, we need to factor out D in
the denominator and operate with the integral operator, D−1 , first.
We then apply the Maclaurin’s series expansion of the resulting inverse differential operator. Recall
from Maclaurin’s series expansion that:
1 1
= 1 + x + x2 + x3 + · · · and = 1 − x + x2 − x3 + · · ·
1−x 1+x
28([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Hence,
1
= 1 + 2D + 4D2 + 8D3 + · · ·
1 − 2D
1 D D2 D3
} =1− + − + ···
D
{
2 4 8
1+
2
e.t.c.
Example(s):
Find the particular integral of the following ODEs
d2 y dy
(a) 2
+2 + y = x + 1.
dx dx
Solution
In terms of the D operator the given equation becomes (D2 + 2D + 1)y = x + 1. The particular
integral is given by
1
yp (x) = (x + 1). Here, D is not common in every term of (D2 + 2D + 1).
D2
+ 2D + 1
1
= (x + 1), (we drop D2 since (x + 1) is of degree 1 and 2 > 1).
2D
[
+ 1 ] [ ]
= 1 − 2D + 4D2 + · · · (x + 1) = (x + 1) − 2D(x + 1) + 4D2 (x + 1) + 0
= [(x + 1) − 2(1) + 4(0)] = [x + 1 − 2] = x − 1
d2 y dy
(b) 2
+2 = x − 2.
dx dx
Solution
In terms of the D operator the given equation becomes (D2 + 2D)y = x − 2. The particular
integral is given by
1
yp (x) = (x − 2). We first factor out D since it is common in every term of (D2 + 2D).
D2 + 2D ( ) ( )
1 D−1 1 x2 1 x2
= (x − 2) = (x − 2) = − 2x = { − 2x
D
}
D(D + 2) D+2 D+2 2 2
2 +1
2
( ) [ ]( )
1 1 x2 1 D D2 D3 x2
= − 2x = 1− + − + ··· − 2x
D
{ }
2 2 2 2 4 8 2
1+
2
[( ) ( ) ( ) ]
1 x 2 1 x2 1 2 x2
= − 2x − D − 2x + D − 2x + 0
2 2 2 2 4 2
[( ) ] [ ]
1 x2 1 1 1 x2 1 1 1( 2 )
= − 2x − (x − 2) + (1) = − 2x − x + 1 + = 2x − 10x + 5
2 2 2 4 2 2 2 4 8
Case 4: When F̃ (x) = eαx f (x) where f (x) = cos βx, f (x) = sin βx or f (x) is a polynomial
In this case, we use the shift operator.
Example(s):
d2 y dy
(a) Find the particular integral of the differential equation +2 + y = ex (x + 1).
dx2 dx
Solution
29([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
In terms of the D operator the given equation becomes (D2 + 2D + 1)y = ex (x + 1). The
particular integral is
1
yp (x) = ex (x + 1). Shifting ex to the left yields.
D2+ 2D + 1
1 1
= ex 2
(x + 1) = ex 2 (x + 1), (Drop D2 since 2 > 1).
(D + 1) + 2(D + 1) + 1 D + 4D + 4
1 1 1 1 [ ]
= ex (x + 1) = ex (x + 1) = ex 1 − D + D2 + · · · (x + 1)
4D + 4 4 D+1 4
1 x[ ] 1 1
= e (x + 1) − D(x + 1) + D2 (x + 1) + 0 = ex [x + 1 − 1 + 0] = xex
4 4 4
d2 y dy
(b) Find the general solution of the differential equation 2
−2 − 3y = e−2x cos 3x.
dx dx
Solution
In terms of the D operator the given equation becomes (D2 − 2D − 3)y = e−2x cos 3x.
1
yp (x) = e−2x cos 3x. Shifting e−2x to the left yields.
D2 − 2D − 3
1
= e−2x (x + 1)
(D − 2)2 − 2(D − 2) − 3
1
= e−2x 2 cos 3x (replace D2 with −(3)2 )
D − 6D + 5
1 1
= e−2x 2
cos 3x = e−2x cos 3x
−(3) − 6D + 5 −(6D + 4)
(6D − 4) (6D − 4)
= −e−2x cos 3x = −e−2x cos 3x (replace D2 with −(3)2 )
(6D + 4)(6D − 4) 36D2 − 16
(6D − 4) (6D − 4) 1 −2x
= −e−2x cos 3x = −e−2x cos 3x = e (6D − 4) cos 3x
36(−9) − 16 36(−9) − 16 340
1 −2x { } 1 −2x { }
= e 6D[cos 3x] − 4 cos 3x = e − 18 sin 3x − 4 cos 3x
340 340
1 −2x { }
= − e 9 sin 3x + 2 cos 3x
170
1 −2x { }
y = Ae3x + Be−x − e 9 sin 3x + 2 cos 3x
170
Exercise:
d2 y dy
(a) Find the particular integral of the differential equation 2
+3 + 2y = e−2x (x + 1). [ans:
dx dx
1 2
( )
yp (x) = −e−2x x + 2x + 2 ]
2
d2 y dy
(b) Find the complete solution of the differential equation 2
+3 − 4y = xe−4x . [ans:
dx dx
1
y = Ae−4x + Bex − xe−4x (5x + 2)]
50
30([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d3 y d2 y dy
(c) Find the complete (general) solution of the differential equation 3
− 3 2
+2 = 10 + 4xe2x .
dx dx dx
[ans: y = A + Bex + Ce2x + 5x + e2x (x2 − 3x)]
d3 y d2 y dy
(d) [Assignment 1 ] Show that the solution of the equation + 3α + 3α2 + α3 y = 0 is
dx3 dx2 dx
d3 y d2 y dy
y = (Ax2 +Bx+C)e−αx . Hence, find the complete solution of 3 −6 2 +12 −8y = e2x (x+1).
dx dx dx
1
[ans: y = (Ax2 + Bx + C)e−2x + e2x x4 + 4x3 ]
( )
24
Lecture 6
Example(s):
Find the complete solution of the following ODEs
d2 y dy
(a) 2
−2 + y = ex .
dx dx
Solution
In terms of the D operator the given equation becomes (D2 − 2D + 1)y = ex .
i) The complementary solution
The auxiliary equation is D2 − 2D + 1 = 0 and so the roots are D1 = D2 = 1. Hence, the
complementary solution is yc (x) = (Ax + B)ex .
ii) The particular integral
1
yp (x) = ex . Shifting ex to the left yields.
D2 − 2D + 1
1 1 1
= ex 2
= ex 2 (1) = ex D−2 1 = ex D−1 x = ex x2
(D + 1) − 2(D + 1) + 1 D 2
Therefore, the complete solution isy = yc (x) + yp (x). That is,
1
y = (Ax + B)ex + ex x2
2
d2 y dy
(b) +3 − 4y = e−4x .
dx2 dx
Solution
In terms of the D operator the equation becomes (D2 + 3D − 4)y = e−4x .
i) The complementary solution
The auxiliary equation is D2 + 3D − 4 = 0 ⇒ (D + 4)(D − 1) = 0. Hence, the roots
are D1 = 1, D2 = −4. Thus, the complementary solution is yc (x) = Aex + Be−4x .
ii) The particular integral
1
yp (x) = e−4x . Shifting e−4x to the left yields.
D2+ 3D − 41
1 1 1 1
= e−4x 2
= e−4x 2 (1) = e−4x D−1 (1) = e−4x x
(D − 4) + 3(D − 4) − 4 D − 5D D−5 D−5
1 1 1 −4x D 1
[ ]
= − e−4x { x = − e 1 + + · · · x = − e−4x (1 + 5x)
5 D }
5 5 25
1−
5
31([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
d2 y dy
(c) Find the complete solution of the differential equation 2
−6 + 9y = 6e3x + 7e−2x − log 2.
dx dx
7 1
[ans: y = (Ax + B)e3x + 3x2 e3x + e−2x − log 2]
25 9
Example(s):
Find the particular integral of the following ODEs
d2 y
(a) + 4y = sin 2x.
dx2
Solution
In terms of the D operator the equation becomes (D2 + 4)y = sin 2x. The particular integral is
given by
1 1
yp (x) = sin 2x = 2 ei2x . Shifting ei2x to the left yields.
D2 +4 D +4
1 1 1 D − i4 1
= ei2x 2
(1) = ei2x 2 (1) = ei2x x = ei2x 2 x = ei2x (1 − i4x)
(D + i2) + 4 D + i4D D + i4 D + 16 16
1
= (1 − i4x)(cos 2x + i sin 2x)
16
1
Extracting the imaginary part we get yp (x) = (sin 2x − 4x cos 2x).
16
d2 y 1
(b) + 9y = cos 3x. [ans: yp (x) = (6x sin 3x + cos 3x)]
dx2 36
Example(s):
Find the particular integral of the following equations.
32([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y
(a) + 4y = sin 2x cos 3x.
dx2
Solution
1 1
sin 2x cos 3x = (sin(2x + 3x) + sin(2x − 3x)) = (sin 5x − sin x). In terms of the D operator
2 2
2 1
the given equation becomes (D + 4)y = (sin 5x − sin x). The particular integral is given by
2
1 1 1 1 1
( )
yp (x) = 2
(sin 5x − sin x) = 2
sin 5x − 2 sin x
2D +4 2 D +4 D +4
1 1 1 1 1 1
( ) ( )
= sin 5x − sin x = − sin 5x + sin x
2 −(5)2 + 4 −(1)2 + 4 2 21 3
d2 y dy
(b) 2
+2 + y = cos2 x.
dx dx
Solution
1
cos2 x = (1 + cos 2x). In terms of the D operator the given equation becomes
2
1
(D2 + 2D + 1)y = (1 + cos 2x). The particular integral is given by
2
1 1 1 1 1
( )
yp (x) = 2
(1 + cos 2x) = 2
(1) + 2 cos 2x
2 D + 2D + 1 2 D + 2D + 1 D + 2D + 1
1 1 1 1
( ) ( )
= 1+ 2
cos 2x = 1+ cos 2x
2 −(2) + 2D + 1 2 2D − 3
1 2D + 3 1 2D + 3 1 1
( ) ( ) ( )
= 1+ cos 2x = 1 + cos 2x = 1 − (2D + 3) cos 2x
2 4D2 − 9 2 −4(2)2 − 9 2 25
1 4 3
( )
= 1+ sin 2x − cos 2x
2 25 25
Exercise:
d2 y dy
(a) Find the complete solution of 2
+2 + y = sin x cos 2x. [ans:
dx dx
1 1
y = (Ax + B)e−x − (6 cos 3x + 8 sin 3x) + cos x]
200 4
d2 y dy
(b) Solve the differential equation 2
−4 + 2y = ex sin2 ( x2 ). [ans: ]
dx dx
d2 y dy
(c) Solve the differential equation 2
−2 + 4y = ex sin2 ( x2 ). [ans:
dx dx
( √ √ ) 1
y = ex A cos 3x + B sin 3x + ex (2 − 3 cos x)]
12
SolutionIn terms of the D operator the given equation becomes (D2 + 1)y = (x + 1) sin x. The
33([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Lecture 7
We let yp (x) be the general form of the function, F̃ (x), on the RHS of the given differential equation.
The choice of yp (x) is given in the table below.
Rules:
1. If F̃ (x) is one of the function in the first column of the above table, choose corresponding function
in second column.
2. If yp (x) contains a term that is obtainable from yc (x), then refine yp (x) by multiplying the
affected term by x (or by x2 if this solution is a double root). For example, if yc (x) = a1 ex +a2 e2x
and F̃ (x) = e2x , then the appropriate choice for yp (x) will be yp (x) = Axe2x , where A is the
undetermined coefficient.
3. If F̃ (x) is sum of functions listed in several lines of the above table in the first column, then the
choice for yp (x) will be the sum of the function in the corresponding lines in the second column.
34([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
→ Note: once an appropriate choice for yp (x) is found, we then compute the respective derivatives of
yp (x). Substitute yp (x) and its derivatives in the given differential equation, and determine the
values of the constants by equating the coefficients and then solve the resulting system of algebraic
equations to obtain the values of the undetermined coefficients.
Example(s):
Use the method of undetermined coefficients to find the complete solutions of the following differential
equations.
d2 y dy
(a) 2
−2 + 2y = x sin x.
dx dx
Solution
In terms of the D operator the given DE becomes (D2 − 2D + 2)y = x sin x. We first need to
find the complementary solution.
i) The complementary solution
The auxiliary equation is D2 − 2D + 2 = 0. Hence, the roots are D = 1 ± i (complex
conjugate). The complementary solution is given by
yc (x) = ex (A1 cos x + B1 sin x) = A1 ex cos x + B1 ex sin x
Clearly, none of the terms in yp (x) is contained in yc (x) so we cannot refine the yp (x).
Equation (∗) is a solution to the given DE and so it must satisfy it. Computing the
respective derivatives of equation (∗), we obtain
yp′ (x) = Ax cos x − Bx sin x + (A − C) sin x + (B + D) cos x (∗∗)
yp′′ (x) = −Ax sin x − Bx cos x + (2A − C) cos x − (2B + D) sin x (∗ ∗ ∗)
Substituting equations (∗), (∗∗) and (∗ ∗ ∗) in the given DE yields
yp′′ (x) − 2yp′ (x) + 2yp (x) = x sin x
That is,
−Ax sin x − Bx cos x + (2A − C) cos x − (2B + D) sin x − 2Ax cos x + 2Bx sin x
−2(A − C) sin x − 2(B + D) cos x + 2Ax sin x + 2Bx cos x + 2C cos x + 2D sin x
= x sin x
35([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
(b) 2
−2 − 3y = xe−x .
dx dx
Solution
In terms of the D operator the given equation becomes (D2 − 2D − 3)y = xe−x . We first need
to find the complementary solution.
This is a solution to the given differential equation and so it must satisfy the given
differential equation. Computing the respective derivatives, we obtain
That is,
Ax2 e−x + (−4A + B)xe−x + (2A − 2B)e−x + 2Ax2 e−x + (−4A + 2B)xe−x
−2Be−x − 3Ax2 e−x − 3Bxe−x = xe−x
Exercise:
36([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
(a) 2
−3 + 2y = 2x2 + ex + 2xex + 4e3x .
dx dx
Solution
In terms of the D operator the given equation becomes (D2 − 3D + 2)y = 2x2 + ex + 2xex + 4e3x .
We first need to find the complementary solution.
This is a solution to the given differential equation and so it must satisfy the given
differential equation. Computing the respective derivatives, we obtain
That is,
⇒ (2A)x2 + (2B − 6A)x + (2A − 3B + 2C) + (2E − D)ex + (−2E)xex + (2F )e3x
= 2x2 + ex + 2xex + 4e3x
2A = 2, 2B − 6A = 0, 2A − 3B + 2C = 0, 2E − D = 1, −2E = 2, 2F = 4
Solving yields
7
A = 1, B = 3, C = , D = −3, E = −1, F = 2
2
Substituting the values of A, B, C, D, E and F in equation (∗) yields:
7
yp (x) = x2 + 3x + − 3xex − x2 ex + 2e3x
2
Therefore, the complete (general) solution is y = yc (x) + yp (x). That is,
7
y = A1 ex + A2 e2x + x2 + 3x + − 3xex − x2 ex + 2e3x
2
37([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
(b) 2
−3 − 4y = 2 sin x. [hint: let yp (x) = A cos x + B sin x, ans:
dx dx
1
y = A1 e−x + A2 e4x + (3 cos x − 5 sin x)]
17
d2 y dy
(c) −2 + y = 6xex . [hint: let yp (x) = Ax3 ex + Bx2 ex , ans: y = ex (A1 + A2 x + x3 )]
dx2 dx
d2 y dy 1
(d) 2
+3 + 2y = cos x. [ans: y = (3 sin x + cos x) + Ae−x + Be−2x ]
dx dx 10
d2 y dy
(e) +2 + y = x2 + 1. [ans: y = x2 − 4x + 7 + (Ax + B)e−x ]
dx2 dx
ex
(f) y ′′ − 3y ′ − 4y = −8ex cos 2x. [ans: y = Ae4x + Be−x + (10 cos 2x + 2 sin 2x)]
13
d3 y d2 y dy
(g) [Assignment] 3
− 3 2
+2 = 10 + 4xe2x . [hint: let yp (x) = Ax + Bx2 e2x + Cxe2x ,
dx dx dx
ans: y = A1 + A2 ex + A3 e2x + 5x + e2x (x2 − 3x)]
Example(s):
Use the method of variation of parameters to find the complete solution of the following differential
equations.
d2 y
(a) + y = sec x.
dx2
Solution
In terms of the D operator the given DE becomes (D2 + 1)y = sec x. We first need to find the
complementary solution.
Equation (∗) is a solution to the given differential equation and so in must satisfy it. Now,
yp′ (x) = −A(x) sin x + B(x) cos x + A′ (x) cos x + B ′ (x) sin x
To make calculations easier, we impose the condition that the sum containing the derivatives
of the arbitrary functions should be equal to zero. i.e.,
Hence,
yp′ (x) = −A(x) sin x + B(x) cos x
yp′′ (x) = −A(x) cos x − B(x) sin x − A′ (x) sin x + B ′ (x) cos x (∗∗)
38([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Substituting equations (∗) and (∗∗) in the given differential equation yields
yp′′ (x) + yp (x) = sec x i.e,
−A(x) cos x − B(x) sin x − A′ (x) sin x + B ′ (x) cos x + A(x) cos x + B(x) sin x = sec x
ø ø
ø cos x 0 øø
ø
ø− sin x sec xø
ø ø ∫
′
B (x) = ø
ø ø =1 ⇒ B(x) = 1dx = x
ø cos x sin x øø
ø− sin x cos xø
ø ø
d2 y dy 1
(b) 2
−2 + y = ex ln(x), x > 0. [ans: y = (Ax + B)ex + x2 ex (2 ln x − 3)]
dx dx 4
Solution
In terms of the D operator the given DE becomes [D2 − 2D + 1]y = ex ln(x). We first need to
find the complementary solution.
Equation (∗) is a solution to the given differential equation and so in must satisfy it. Now,
To make calculations easier, we impose the condition that the sum containing the derivatives
of the arbitrary functions should be equal to zero, i.e.,
39([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Hence,
yp′ (x) = ex [(x + 1)A(x) + B(x)] (∗∗)
x[
yp′′ (x) = e (x + 2)A(x) + B(x) + (x + 1)A′ (x) + B ′ (x)
]
(∗ ∗ ∗)
Substituting equations (∗), (∗∗) and (∗∗) in the given differential equation yields
yp′′ (x) − 2yp′ + yp (x) = ex ln(x) i.e,
ø ø
ø x 0 øø
ø
ø(x + 1) ln xø
ø ø
′ ø = −x ln x
B (x) = øø
ø x 1øø
ø(x + 1) 1ø
ø ø
1
Using integration by parts: put u = ln x, dv = dx ⇒ du = dx, v = x.
x
∫
⇒ A(x) = x ln x − dx = x[ln(x) − 1]
Similarly, ∫
B(x) = − x ln xdx
1 x2
Using integration by parts: put u = ln x, dv = xdx ⇒ du = dx, v = .
x 2
x2 x x2
∫
⇒ B(x) = − ln x + dx = [1 − 2 ln(x)]
2 2 4
Substituting A(x) and B(x) in equation (∗) yields
[ ]
2 x2 1
yp (x) = x (ln x − 1) + (1 − 2 ln x) ex = x2 ex (2 ln x − 3)
4 4
1
y = (Ax + B) ex + x2 ex (2 ln x − 3)
4
40([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
d2 y
(a) + 4y = tan 2x.
dx2
Solution
In terms of the D operator the given equation becomes (D2 + 4)y = tan 2x. We first need to
find the complementary solution.
Equation (∗) is a solution to the given differential equation and so it must satisfy it. Now,
yp′ (x) = −2A(x) sin 2x + 2B(x) cos 2x + A′ (x) cos 2x + B ′ (x) sin 2x
To make calculations easier, we impose the condition that the sum containing the derivatives
of the arbitrary functions should be equal to zero. i.e.,
Hence,
yp′ (x) = −2A(x) sin 2x + 2B(x) cos 2x (∗∗)
yp′′ (x) = −4A(x) cos 2x − 4B(x) sin 2x − 2A′ (x) sin 2x + 2B ′ (x) cos 2x (∗ ∗ ∗)
Substituting equations (∗) and (∗ ∗ ∗) in the given differential equation yields yp′′ (x) +
4yp (x) = tan 2x i.e,
−4A(x) cos 2x−4B(x) sin 2x−2A′ (x) sin 2x+2B ′ (x) cos 2x+4A(x) cos 2x+4B(x) sin 2x = tan 2x
sin 2x
⇒ −2A′ (x) sin 2x + 2B ′ (x) cos 2x = tan 2x = (ii)
cos 2x
In matrix form, equations (i) and (ii) yield
( )[ ] ( )
cos 2x sin 2x A′ (x) 0
=
−2 sin 2x 2 cos 2x B ′ (x) tan 2x
ø ø
ø cos 2x 0 øø
ø
ø−2 sin 2x tan 2xø
ø ø
′ cos 2x tan 2x 1
B (x) = øø ø = = sin 2x
ø cos 2x sin 2x øø 2 2
ø−2 sin 2x 2 cos 2xø
ø ø
41([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Using integration by parts: put u = tan 2x, dv = sin 2xdx ⇒ du = 2 sec2 2xdx, v =
1
− cos 2x.
2
1 1 1 1 dx
[ ∫ ] [ ∫ ]
2
⇒ A(x) = − − cos 2x tan 2x + cos 2x sec 2xdx = − − sin 2x +
2 2 2 2 cos 2x
By t substitution we have, let
dt
t = tan x ⇒ dt = sec2 xdx = (1 + tan2 x)dx = (1 + t2 )dx ⇒ dx =
1 + t2
1 t
⇒ cos x = √ , sin x = √
1+t 2 1 + t2
Hence,
1 − t2 dx dt 1 1 1
( )
2 2
cos 2x = cos x − sin x = ⇒ = = + dt
1 + t2 cos 2x 1−t 2 2 1+t 1−t
1 1 1 1 1 1 1
[ ∫ ( ) ]
⇒ A(x) = − − sin 2x + + dt = sin 2x + ln (1 − t)
2 2 2 1+t 1−t 4 2
1 1
= sin 2x − [ln(1 + t) − ln(1 − t)]
4( 4 ø
1 ø1 + tø
ø)
= sin 2x − ln ø
ø ø
4 1 − tø
By back substitution we have
1 ø 1 + tan x ø
ø = 1 (sin 2x − ln |sec 2x + tan 2x|)
( ø ø)
A(x) = sin 2x − ln øø
4 1 − tan x ø 4
Similarly,
1 1
∫
B(x) = sin 2xdx = − cos 2x
2 4
Substituting A(x) and B(x) in equation (∗) yields
1 1
yp (x) = (sin 2x − ln |sec 2x + tan 2x|) cos 2x − cos 2x sin 2x
4 4
1
= − cos 2x ln |sec 2x + tan 2x|
4
1
y = A cos 2x + B sin 2x − cos 2x ln |sec 2x + tan 2x|
4
d2 y dy 1
(b) 2
+3 + 2y = .
dx dx 1 + ex
Solution
1
In terms of the D operator the given equation becomes (D2 + 3D + 2)y = . We first need
1 + ex
to find the complementary solution.
42([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Equation (∗) is a solution to the given differential equation and so in must satisfy it. Now,
To make calculations easier, we impose the condition that the sum containing the derivatives
of the arbitrary functions should be equal to zero. i.e.,
Hence,
yp′ (x) = −A(x)e−x − 2B(x)e−2x (∗∗)
yp′′ (x) = A(x)e−x + 4B(x)e−2x − A′ (x)e−x − 2B ′ (x)e−2x (∗ ∗ ∗)
Substituting equations (∗) and (∗ ∗ ∗) in the given differential equation yields yp′′ (x) +
1
3yp′ (x) + 2yp (x) = i.e,
1 + ex
1
A(x)e−x +4B(x)e−2x −A′ (x)e−x −2B ′ (x)e−2x +−3A(x)e−x −6B(x)e−2x +2A(x)e−x +2B(x)e−2x =
1 + ex
1
⇒ −A′ (x)e−x − 2B ′ (x)e−2x = (ii)
1 + ex
In matrix form, equations (i) and (ii) yield
0
( )[ ]
e−x e−2x A′ (x)
= 1
−e−x −2e−2x ′
B (x)
1 + ex
Using Cramer’s rule, we obtain
ø ø
ø 0
ø e−2x øø
ø 1 ø
ø
x
−2e −2x ø
−e−2x 1 −ex
A′ (x) = øø1 + e
ø ø
ø = · =
ø e
−x e−2x øø 1 + ex e−3x 1 + ex
ø −x
ø−e −2e ø
−2x ø
ø ø
ø e−x 0 øø
ø
ø
ø−e−x 1 øø
ø
1 + ex øø = e
−x 1 e2x x ex
B ′ (x) = øø · = = e −
ø e
−x e−2x øø 1 + ex e−3x 1 + ex 1 + ex
ø −x
ø−e −2e ø
−2x ø
−ex
∫
A(x) = dx = − ln |1 + ex |
1 + ex
Similarly,
ex
∫ ( )
B(x) = ex − dx = ex − ln |1 + ex |
1 + ex
Substituting A(x) and B(x) in equation (∗) yields
43([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y
(c) + y = tan x. [ans: y = A cos x + B sin x − cos x ln |sec x + tan x|]
dx2
d2 y dy ex
(d) 2
−2 + y = 2. [ans: y = (Ax + B) ex − (1 + ln x) ex ]
dx dx x
d2 y
(e) i) + y = x − cot x. [ans: y =]
dx2
d2 y
ii) + y = x sin x. [ans: y =]
dx2
Lecture 8
dn y n−1 d
n−1 y
n−2 d
n−2 y 2
2d y dy
an xn + an−1 x + an−2 x + · · · + a2 x + a1 x + a0 y = F̃ (x), (17)
dxn dxn−1 dxn−2 dx2 dx
where a0 , a1 , · · · , an are constants. The transformation x = et reduces equation (17) to a linear
differential equation with constant coefficients.
dy dy dt 1 dy dt 1
= = , (since x = et ⇒ t = ln x ⇒ = )
dx dt dx x dt dx x
dy dy
∴ x =
dx dt
(ii) Differentiating the result in proof (i) above with respect to x yields
d dy d dy d dy dt
( ) ( ) ( )
x = = (by chain rule)
dx dx dx dt dt dt dx
d2 y dy 1 d2 y 2
2d y d2 y dy
⇒ x 2+ = 2
⇒ x 2
= 2
−x
dx dx x dt dx dt dx
d 2y d2 y dy
∴ x2 2 = −
dx dt2 dt
44([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
(iii) Differentiating the result in proof (ii) above with respect to x yields
( ) ( ) ( )
d d2 y d d2 y dy d d2 y dy dt
x2 2 = − = − (by chain rule)
dx dx dx dt2 dt dt dt2 dt dx
( )
3y d2 y d3 y d2 y d3 y d3 y d2 y 2
2d 1 2d y
⇒ x + 2x = − 2 ⇒ x3 = − − 2x
dx3 dx2 x dt3 dt dx3 dt3 dt2 dx2
( )
3y d3 y d2 y d2 y dy
3d
⇒ x = − − 2 −
dx3 dt3 dt2 dt2 dt
d3 y d3 y d2 y dy
∴ x3 = − 3 +2
dx3 dt 3 dt 2 dt
Example(s):
Solve the following differential equations
d2 y dy
(a) x2 2
− 5x + 8y = 2 ln x.
dx dx
Solution
dy dy d2 y d2 y dy
Let x = et . Then, x = and x2 2 = 2 − . Substituting in the given equation, we
dx dt dx dt dt
get
d2 y dy dy d2 y dy
− − 5 + 8y = 2t ⇒ − 6 + 8y = 2t (∗)
dt2 dt dt dt2 dt
d
Let D = . Then in terms of the D operator, equation (∗) becomes
dt
[D2 − 6D + 8]y = 2t
t 3
Therefore, the general solution is y = yc (x) + yp (x). That is, y = Ae4t + Be2t + + . Back
4 16
substitution yields
ln x 3
y = Ax4 + Bx2 + +
4 16
d2 y dy 2 B x ln x
(b) x 2
+2 − y = ln x. [ans: y = Ax + 2
+ [3 ln x − 2]]
dx dx x x 18
Solution
45([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
The equation can be written as x2 2
+ 2x − 2y = x ln x, which is of the Euler-Cauchy
dx dx
dy dy d2 y d2 y dy
equation. Let x = et . Then, x = and x2 2 = 2 − . Substituting in the given
dx dt dx dt dt
equation, we get
d2 y dy dy d2 y dy
− + 2 − 2y = et t ⇒ + − 2y = et t (∗)
dt2 dt dt dt2 dt
d
Let D = . Then in terms of the D operator, equation (∗) becomes
dt
[D2 + D − 2]y = et t
tet 1 tet
y = Aet + Be−2t + [3t − 2] + et = A1 et + Be−2t + [3t − 2]
18 27 18
Back substitution yields
B x ln x
y = A1 x + + [3 ln(x) − 2]
x2 18
Exercise:
d2 y dy ln x A ln x
(a) x2 2
−x − 3y = , x > 0. [ans: y = + Bx3 − (2 ln x + 1)]
dx dx x x 16x
d2 y dy 2y
= (ln x)2 . [ans: y = x A cos(ln x) + B sin(ln x) + (ln x)2 − 2 ]
{ }
(b) x 2
− +
dx dx x
Example(s):
(a) Solve the system defined by
dy
+ x = e3t
dt
dx
−y = 0
dt
46([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
1 1
subject to the initial conditions x(0) = and y(0) = .
2 5
Solution
d
Let D = . In terms of the D operator the system becomes
dt
x + Dy = e3t (i)
Dx − y = 0 (ii)
Operating with D on equation (ii) and adding the result to equation (i), we get (D2 + 1)x = e3t .
Solution
d
Let D = . In terms of the D operator the system becomes
dt
(2D − 1)y + (D + 1)x = 0
(3D − 1)y + (2D + 1)x = et
Adding yields:
(2D + 1)(2D − 1)y − (D + 1)(3D − 1)y = −(D + 1)et
( )
⇒ (4D2 − 2D + 2D − 1)y − (3D2 − D + 3D − 1)y = − et + et
47([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
(a) Solve the system of ODEs defined by. [ans: x = Aet + Be−t and y = −Aet + Be−t + cos t]
dx
+ y = cos t
dt
dy
+ x = − sin t
dt
(b) Solve the following system. [ans: x = 4e3t − 5e2t and y = 8e3t − 5e2t ]
dx
= x+y
dt
dy
= −2x + 4y
dt
subject to the initial conditions x(0) = −1 and y(0) = 3.
1 5
(c) Solve the following system of equations. [ans: y = Aet + Be−3t + t + and
8 12
2 1 11
x = −2Aet + Be−3t − t − ]
3 3 36
dx dy
2 − 2 − 3x = t
dt dt
dx dy
2 + 2 + 3x + 8y = 2
dt dt
(d) Solve the following system of equations. [ans: ]
dx dy
2 + − 2x − 2y = 5et
dt dt
dx dy
+ + 4x + 2y = 5e−t
dt dt
Lecture 9
48([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
5 Laplace transform
Suppose a function f (t) is defined for t ≥ 0. Also, let L be the Laplace transform operator, then the
Laplace transform, with respect to t, of f (t) is a function defined by
∫∞
L [f (t)] = e−st f (t)dt = F (s), Re(s) > 0, where s is a dummy variable.
0
Example(s):
Find the Laplace transform of the following functions:
(a) f (t) = 1
(c) f (t) = t2
(d) f (t) = cos bt, where b is a constant. [hint: put u = cos bt and dv = e−st dt]
Proof. From the definition of Laplace transform, with respect to t, of a function f (t) we have
∫∞
L [f (t)] = e−st f (t)dt
0
2
For example, we know that L[t2 ] = . Then from the first shifting property, we have
s3
2
L[e4t t2 ] =
(s − 4)3
Similarly,
s s−1
L[cos 2t] = ⇒ L[et cos 2t] =
s2 +4 (s − 1)2 + 4
Exercise:
49([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Solution
3
∫∞ ∫2 π ∫∞ ∫∞
3
( )
−st −st −st
L [f (t)] = e f (t)dt = e f (t)dt + e f (t)dt = 0 + e−st cos t − π dt
2
0 0 3
π 3
π
2 2
3 3
Put t − π = u ⇒ dt = du. Changing limits of integration: when t = π ⇒ u=0
2 2
and when t = ∞ ⇒ u = ∞. Therefore,
∫∞ ∫∞
−s(u+ 23 π) − 23 πs 3
L [f (t)] = e cos (u) du = e e−su cos (u) du = e− 2 πs L [cos (u)]
u=0 u=0
s
( )
− 23 πs
= e 2
s +1
{
(t + 1), if 0 ≤ t ≤ 2
(b) h(t) = .
3, if t > 2
Solution
∫∞ ∫2 ∫∞
−st −st
L [h(t)] = e h(t)dt = e (t + 1)dt + e−st 3dt
0 0 2
1
Put u = t + 1 and dv = e−st dt ⇒ du = dt, v = − e−st . Integration by parts yields
s
]2 ∫2 ( ∫∞
1 1
[ )
L [h(t)] = −(t + 1) e−st − − e−st dt + 3 e−st dt
s t=0 s
0 2
∫2 ∫∞
3 1 1
= − e−2s + + e−st dt + 3 e−st dt
s s s
0 2
2 ]∞
3 1 1 1 1
[ ] [
= − e−2s + + − e−st + 3 − e−st
s s s s t=0 s t=2
3 −2s 1 1 −2s 1 3 −2s
= − e + − 2e + 2+ e
s s s s s
1 1 ( −2s
)
= + 1−e
s s2
3. Find the Laplace transform of f (t) = e−3t (2 cos 5t − 3 sin 3t). [ans:
s+3 3
2 2
−3 ]
(s + 3) + 25 (s + 3)2 + 9
50([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Example(s):
Solution
Since the denominator consists of products of functions of s, we decompose the given function
5s + 3 A Bs + C
into its partial fractions. Let 2
= + 2 .
(s − 1)(s + 2s + 5) s − 1 s + 2s + 5
Put s = 1 ⇒ A(1 + 2 + 5) = 5 + 3 ⇒ A = 1
Put s = 0 ⇒ 5A − C = 3 ⇒ 5 − C = 3 ⇒ C = 2
Put s = −1 ⇒ A(1 − 2 + 5) − 2(C − B) = −5 + 3 ⇒ 4 − 2(2 − B) = −2 ⇒ B = −1.
Therefore,
5s + 3 1 −s + 2
= +
(s − 1)(s2 + 2s + 5) s − 1 s2 + 2s + 5
51([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Hence,
5s + 3 1 −s + 2
[ ] [ ]
−1 −1
∴L = L + 2
(s − 1)(s2 + 2s + 5) s − 1 s + 2s + 5
1 s−2
[ ] [ ]
= L−1 − L−1 2
s−1 s + 2s + 5
1 s−2
[ ] [ ]
= L−1 − L−1 , (completing the square)
s−1 (s + 1)2 + 22
1 s+1 3 2
[ ] [ ]
= L−1 − L−1 −
s−1 (s + 1)2 + 22 2 (s + 1)2 + 22
3
= et − e−t cos 2t + e−t sin 2t
2
Exercise:
s+2 5 3
(a) Find the inverse Laplace transform, with respect to t, of . [ans: f (t) = e3t − et ]
s2 − 4s + 3 2 2
..
. [ ]
L f (n) (t) = sn L[f (t)] − sn−1 f (0) − sn−2 f ′ (0) − sn−3 f ′′ (0) − · · · − f (n−1) (0)
Proof. From the definition of Laplace transform, we have
∫∞
L [f (t)] = e−st f (t)dt
0
It follows that
∫∞
′
e−st f ′ (t)dt
[ ]
L f (t) =
0
Using integration by parts, put u = e−st and dv = f ′ (t)dt ⇒ du = −se−st dt, v = f (t).
Integration by parts yields
[ ]∞ ∫∞
′ −st
f (t)(−se−st dt)
[ ]
L f (t) = e f (t) −
0
0
∫∞
= −f (0) + s e−st f (t)dt
0
= sL[f (t)] − f (0)
Similarly,
∫∞
′′
e−st f ′′ (t)dt
[ ]
L f (t) =
0
Using integration by parts, put u = e−st and dv = f ′′ (t)dt ⇒ du = −se−st dt, v = f ′ (t).
Integration by parts yields
[ ]∞ ∫∞
′′ −st ′
f ′ (t)(−se−st dt)
[ ]
L f (t) = e f (t) −
0
0
∫∞
= −f ′ (0) + s e−st f ′ (t)dt = sL[f ′ (t)] − f ′ (0) = s {sL[f (t)] − f (0)} − f ′ (0)
0
= s2 L[f (t)] − sf (0) − f ′ (0)
52([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
By induction, we have
[ ]
L f (n) (t) = sn L[f (t)] − sn−1 f (0) − sn−2 f ′ (0) − sn−3 f ′′ (0) − · · · − f (n−1) (0)
d2 y dy
a + b + cy = f (t) or ay ′′ + by ′ + cy = f (t) (18)
dt2 dt
where a, b, c are constants. Taking the Laplace transform on both sides of equation (18), we get
aL y ′′ + bL y ′ + cL [y] = L [f (t)]
[ ] [ ]
{ }
⇒ a s2 L [y] − sy(0) − y ′ (0) + b {sL [y] − y(0)} + cL [y] = L [f (t)] (19)
Given the initial conditions, equation (19) can be solved for Y (s). We then take the inverse Laplace
transform on both sides to get the solution, y(t).
Example(s):
Solve the following differential equations using the Laplace transform method
Solution
Taking the Laplace transform on both sides we have
[ ]
L y ′′ − 6L y ′ + 9L [y] = L e3t t2
[ ] [ ]
{ } 2
⇒ s2 L [y] − sy(0) − y ′ (0) − 6 {sL [y] − y(0)} + 9L [y] =
(s − 3)3
Solution
Taking the Laplace transform on both sides we have
53([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
Use Laplace transform method to solve the following initial value problems
d2 y 1 1 2
(a) + y = e−t ; y(0) = 0, y ′ (0) = 0. [ans: y(t) = e−2t − cos t + sin t]
dt2 5 5 5
(b) y ′′ + y = t subject to the initial conditions y(0) = 0, y ′ (0) = 2. [ans: y(t) = t + sin t]
dy 4 1
(c) + 2y = 4e3t subject to the initial condition y(0) = 1. [ans: y(t) = e3t + e−2t ]
dt 5 5
(d) y ′′ − 3y ′ + 2y = 2e3t ; y(0) = 5 and y ′ (0) = 7. [ans: y(t) = 4et + e3t ]
1
( )
(e) y ′′ + 2y ′ + y = 3te−t ; y(0) = 4 and y ′ (0) = 2. [ans: y(t) = e−t 4 + 6t + t3 ]
2
20 −0.5x 11 −2x 1 −2x
(f) 2y ′′ + 5y ′ + 2y = e−2x ; y(0) = 1 and y ′ (0) = 1. [ans: y(x) = e − e − xe ]
9 9 3
Lecture 10
Definition 6.1 (Analytic function). A function f (x) is said to be analytic (defined) at a point x = x0
if f (x) can be expanded in a power series about x0 which has a positive radius of convergence.
Here, an ’s are constants and (20) converges for |x − x0 | < r, where r > 0. The radius of convergence,
r, can be found from ratio test/root test. Hence, the function f (x) is single valued and possesses
derivatives of all orders in the interval |x − x0 | < r.
p(x)
→ Note: a rational function is analytic everywhere except at those values of x at which q(x) = 0.
q(x)
54([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
d2 y dy
a2 (x) + a1 (x) + a0 (x)y = 0 (21)
dx2 dx
We can write equation (21) into the equivalent normalized form as
d2 y dy
2
+ P1 (x) + P2 (x)y = 0, (22)
dx dx
a1 (x) a0 (x)
where P1 (x) = , P2 (x) = , a2 (x) ̸= 0.
a2 (x) a2 (x)
Definition 6.2 (Ordinary point). A point x = x0 is called an ordinary point of equation (22) if both
P1 (x) and P2 (x) are analytic at x = x0 .
Definition 6.3 (Singular point). If at least P1 (x) and P2 (x) in equation (22) is not analytic at the
point x = x0 , then we say that the point x0 is a singular point of the differential equation (21).
Definition 6.4 (Regular singular point). If x0 is a singular point of the differential equation (21) but
both the products, (x − x0 )P1 (x) and (x − x0 )2 P2 (x) in their simplest form, are analytic at the point
x = x0 , then the point x = x0 is called a regular singular point of the differential equation (21).
Definition 6.5 (Irregular singular point). If x0 is a singular point of the differential equation (21)
and at least (x − x0 )P1 (x) and (x − x0 )2 P2 (x), in their simplest form, is not analytic at x = x0 , then
the point x = x0 is said to be an irregular singular point of the differential equation (21).
Example(s):
d2 y dy 1
(a) Determine the singular point(s) of the equation (x − 1) 2
+x + y = 0.
dx dx x
Solution
d2 y x dy 1 x 1
2
+ + y = 0. Here, P1 (x) = , P2 (x) =
dx x − 1 dx x(x − 1) x−1 x(x − 1)
Solution
i) Normal form:
d2 y 1 dy x−5 1 x−5
2
− + y = 0. Here, P1 (x) = − , P2 (x) =
dx 2x dx 2x2 2x 2x2
ii) Singular points:
55([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Also,
ø (x − 5) øø 5
(x−x0 )2 P2 (x)ø = x2 · =− (finite ⇒ (x − x0 )2 P2 (x) is analytic at x = 0)
ø
2x2 2
ø
x=x0 x=0
Since (x − x0 )P1 (x) and (x − x0 )2 P2 (x) are both analytic at x = 0, therefore, the point
x = 0 is a regular singular point of the given DE.
(c) Find the singular points of the following differential equation and determine whether they are
regular or irregular points:
d2 y dy
x2 (1 − x) + (1 − x) +y =0
dx2 dx
Solution
i) Normal form:
d2 y 1 dy 1 1 1
+ + y = 0. Here, P1 (x) = , P2 (x) =
dx2 x2 dx x2 (1 − x) x2 x2 (1 − x)
Also,
ø 1 ø
(x−x0 )2 P2 (x)ø = (x−1)2 · øx=1 = 0 (finite ⇒ (x − x0 )P1 (x) is analytic at x = 1)
ø ø
x=x0 (x
−x2 −1)
Since (x − x0 )P1 (x) and (x − x0 )2 P2 (x) are both analytic at x = 1, therefore, the point
x = 1 is a regular singular point of the given DE.
56([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
(d) Identify all regular singular points of the following differential equation
d2 y dy
(x3 − 3x2 + 2x) + x(x − 2) + 4x2 y = 0
dx2 dx
d2 y dy
(e) Show that x = 0 is an ordinary point for the equation (x2 − 1) 2
+ 3x + xy = 0.
dx dx
Example(s):
Use the power series method to solve the following differential equations about the given ordinary
points
d2 y dy
(a) (1 − x2 ) 2
− 2x + 2y = 0 about the ordinary point x0 = 0.
dx dx
Solution
The solution of the given DE is given by
∞
an xn
∑
y=
n=0
Differentiating yields
∞ ∞
nan xn−1 , n(n − 1)an xn−2
∑ ∑
y′ = y ′′ =
n=1 n=2
∞ ∞ ∞ ∞
n(n − 1)an xn−2 − n(n − 1)an xn − 2nan xn + 2an xn = 0
∑ ∑ ∑ ∑
⇒
n=2 n=2 n=0 n=0
∞ ∞
n(n − 1)an xn−2 + [2 − n(n − 1) − 2n] an xn = 0
∑ ∑
⇒ (∗)
n=2 n=0
We can now change the indexing so that the series has the general term xn−2 . Plugging in
n = n − 2 in the second summation of equation (∗) yields
∞ ∞
n−2
[2 − (n − 2)(n − 3) − 2(n − 2)] an−2 xn−2 = 0
∑ ∑
n(n − 1)an x +
n=2 n=2
∞
[n(n − 1)an − ((n − 2)(n − 3) + 2n − 6)) an−2 ] xn−2 = 0
∑
⇒
n=2
∞
[n(n − 1)an − n(n − 3)an−2 ] xn−2 = 0
∑
⇒
n=2
Equating the coefficients yields
(n − 3) .
n(n − 1)an − n(n − 3)an−2 = 0 ⇒ an = an−2 , n≥2
(n − 1)
57([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
The above recurrence relation is used to calculate an for n ≥ 2 in terms of a0 and a1 , which
are left arbitrary. Thus, we have
Even subscripts Odd subscripts
−1
a2 = a0 a3 = 0
1
1 2
a4 = a2 a5 = a3
3 4
3 4
a6 = a4 a7 = a5
5 6
.. ..
. .
(2k − 3) (2k − 2)
a2k = a2k−2 a2k+1 = a2k−1 , k ≥ 1
(2k − 1) 2k
Multiplying the corresponding members of each column we get:
−1 1 3 −
(2k
3) −1
a a
2 · a
4 ·6 · · · a2k = a0 · a
2·
a · · ·
a2k−2 ⇒ a2k = a0
3 (2k − 1)
4
1 5 (2k − 1)
Similarly,
2 4 (2k − 2)
a a
3 · a
5 ·7 · · · a2k+1 = 0 · a
3· a
5···
a2k−1 ⇒ a2k+1 = 0
4 6 2k
Therefore, the solution becomes
∞ ∞ ∞ ∞
x2k
an xn a2k x2k + a2k+1 x2k+1 = −a0
∑ ∑ ∑ ∑
y= ⇒ y =
n=0 k=0 k=0 k=0
(2k − 1)
d2 y
(b) + 4y = 0 about the ordinary point x0 = 0.
dx2
Solution
Let the solution of the given DE be
∞
an xn
∑
y=
n=0
Differentiating yields
∞ ∞
nan xn−1 , n(n − 1)an xn−2
∑ ∑
y′ = y ′′ =
n=1 n=2
n=2 n=0
We can now change the indexing so that the series has the general term xn−2 . Putting n = n − 2
in the second summation of equation (∗) yields
∞ ∞ ∞
n−2 n−2
[n(n − 1)an + 4an−2 ] xn−2 = 0
∑ ∑ ∑
n(n − 1)an x +4 an−2 x =0 ⇒
n=2 n=2 n=2
−4 .
n(n − 1)an + 4an−2 = 0 ⇒ an = an−2 , n ≥ 2
n(n − 1)
The above recurrence relation is used to calculate an for n ≥ 2 in terms of a0 and a1 , which
are left arbitrary. Thus, we have
58([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
−4 −4 −4 (−4)k
a a
2 ·4 · · · a2k = a0 · a
2···
a2k−2 ⇒ a2k = a0
2(1) 4(3) 2k(2k − 1) (2k)!
Similarly,
−4 −4 −4 (−4)k
a a
3 ·5 · · · a2k+1 = a1 · a
3···
a2k−1 ⇒ a2k+1 = a1
3(2) 5(4) (2k + 1)(2k) (2k + 1)!
→ Note: if the initial conditions are known, we apply Taylor series expansion to obtain the
power series solution of the given IVP.
(c) Use Taylor series expansion to find the third degree power series solution of the initial value
problem (IVP) y ′′ − 2xy ′ + 3y = 0 − − − (∗); y(0) = 2, y ′ (0) = −4.
Solution
The Taylor series expansion of y(x) about the point x0 is given by
∞
y (n) (x0 )
(x − x0 )n
∑
y=
n=0
n!
Thus, the 3rd degree Taylor series solution of the given IVP is obtained by putting n = 3 and
x0 = 0. Thus, we have
y(0) = 2
y ′ (0) = −4
y ′′ = 2xy ′ − 3y ⇒ y ′′ (0) = 2(0)y ′ (0) − 3y(0) = −6
y ′′′ = 2xy ′′ + 2y ′ − 3y ′ = 2xy ′′ − y ′ ⇒ y ′′′ (0) = 2(0)y ′′ (0) − y ′ (0) = 4
59([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Exercise:
d2 y dy
(a) Use power series method to solve (1 − x2 ) − 6x − 4y = 0 about the ordinary point x0 = 0.
dx2 dx
Solution
Let the solution to the given DE be
∞ ∞
an (x − x0 )n = an xn
∑ ∑
y=
n=0 n=0
Differentiating yields
∞ ∞
nan xn−1 , n(n − 1)an xn−2
∑ ∑
y′ = y ′′ =
n=1 n=2
We can now change the indexing so that the series has the general term xn−2 . So we put n = n−2
in the second summation of equation (∗) and get
∞ ∞
n(n − 1)an xn−2 − (n − 1)(n + 2)an−2 xn−2 = 0
∑ ∑
n=2 n=2
∞
[n(n − 1)an − (n − 1)(n + 2)an−2 ] xn−2 = 0
∑
⇒
n=2
(n + 2).
n(n − 1)an − (n − 1)(n + 2)an−2 = 0 ⇒ an = an−2 , n ≥ 2
n
The above recurrence relation is used to calculate an for n ≥ 2 in terms of a0 and a1 , which
are left arbitrary. Thus, we have
Even subscripts Odd subscripts
4 5
a2 = a0 a3 = a1
2 3
6 7
a4 = a2 a5 = a3
4 5
8 9
a6 = a4 a7 = a5
6 7
.. ..
. .
(2k + 2) (2k + 3)
a2k = a2k−2 a2k+1 = a2k−1 , k ≥ 1
2k (2k + 1)
60([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
(b) Find power series solution of the following differential equations about the ordinary point x0 = 0.
dy ∞ 5k
xk ]
∑
(i) = 5y. [ans: y = a0
dx k=0 k!
∞ (2x)k
(ii) y ′ − 2y = 0. = a0 e2x ]
∑
[ans: y = a0
k=0 k!
d2 y dy ∞ 1
(iii) (1 + x2 ) − 2y = 0. (−1)k−1 x2k ]
∑
+ 2x [ans: y =
dx2 dx k=0 2k − 1
( ) ( )
1 2 1 4
(iv) y ′′ + xy ′ + y = 0. [ans: y = a0 1 − 2x + 8x + · · · + a1 x − 13 x3 + 1 5
15 x + ··· ]
(v) y ′′ + xy ′ + (x2 + 2)y = 0. [ans: y = a0 (1 − x2 + 41 x4 + · · · ) + a1 (x − 21 x3 + 3 5
40 x + · · · )]
(c) Use Taylor’s theorem to find the third degree series solution to the following IVPs.
d2 y dy
(1 − x2 ) − 2x + p(p + 1)y = 0 (23)
dx2 dx
where p is a positive integer is called Legendre’s differential equation. This equation arises in
many problems in physics, especially in boundary value problems in spheres.
d2 y 2x dy p(p + 1) 2x p(p + 1)
− + y=0 ⇒ P1 (x) = − , P2 (x) =
dx2 1 − x2 dx 1 − x2 1 − x2 1 − x2
61([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Therefore, the poinst x = −1 and x = 1 are the only singular points of equation (23). All other
points are ordinary. Thus, we study the general solution to equation (23) in the interval −1 < x < 1.
To solve equation (23) about the ordinary point x0 = 0, we assume that it has a power series solution
of the form
∞
an xn
∑
y=
n=0
Differentiating yields
∞ ∞
nan xn−1 , n(n − 1)an xn−2
∑ ∑
y′ = y ′′ =
n=1 n=2
We can now change the indexing so that the series has the general term xn−2 . So we put n = n − 2
in the second summation and get
∞ ∞
n−2
[(n − 2)(n − 1) − p(p + 1)]an−2 xn−2 = 0
∑ ∑
n(n − 1)an x −
n=2 n=2
∞
[n(n − 1)an − [(n − 2)(n − 1) − p(p + 1)]an−2 ] xn−2 = 0
∑
⇒
n=2
∞
[n(n − 1)an + (p − n + 2)(p + n − 1)an−2 ] xn−2 = 0
∑
⇒
n=2
−(p − n + 2)(p .+ n − 1)
n(n − 1)an + (p − n + 2)(p + n − 1)an−2 = 0 ⇒ an = an−2 , n ≥ 2
n(n − 1)
The above recurrence relation is used to calculate an for n ≥ 2 in terms of a0 and a1 , which are
left arbitrary. Thus, we have
Even subscripts Odd subscripts
−p(p + 1) −(p − 1)(p + 2)
a2 = a0 a3 = a1
2(1) 3(2)
−(p − 2)(p + 3) −(p − 3)(p + 4)
a4 = a2 a5 = a3
4(3) 5(4)
−(p − 4)(p + 5) −(p − 5)(p + 6)
a6 = a4 a7 = a5
6(5) 7(6)
.. ..
. .
−(p − 2k + 2)(p + 2k − 1) −(p − 2k + 1)(p + 2k)
a2k = a2k−2 a2k+1 = a2k−1 , k ≥ 1
2k(2k − 1) (2k + 1)(2k)
Multiplying the corresponding members of each column we get:
−p(p + 1) −(p − 2)(p + 3) −(p − 4)(p + 5) −(p − 2k + 2)(p + 2k − 1)
a
a
2 · a
4 ·6 · · · a2k = a0 · a
2· a
4 ···
a2k−2
2(1) 4(3) 6(5) 2k(2k − 1)
(−1)k p(p + 1)(p − 2)(p + 3)(p − 4)(p + 5) · · · (p − 2k + 2)(p + 2k − 1)
= a0
(2k)!
62([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
k
(−1)k (p − 2j +.2)(p + 2j − 1)
∏
⇒ j=1
a2k = a0 , k ≥ 1
(2k)!
Similarly,
−(p − 1)(p + 2) −(p − 3)(p + 4) −(p − 5)(p + 6) −(p − 2k + 1)(p + 2k)
a
a
3 · a
5 ·7 · · · a2k+1 = a1 · a
3 a
5 ···
a2k−1
3(2) 5(4) 7(6) (2k + 1)(2k)
(−1)k (p − 1)(p + 2)(p − 3)(p + 4)(p − 5)(p + 6) · · · (p − 2k + 1)(p + 2k)
= a1
(2k + 1)!
k
(−1)k (p − 2j. + 1)(p + 2j)
∏
⇒ j=1
a2k+1 = a1 , k ≥ 1
(2k + 1)!
Therefore, the solution becomes
∞ ∞ ∞
an xn = a2k x2k + a2k+1 x2k+1
∑ ∑ ∑
y =
n=0 k=0 k=0
k
(−1)k (p − 2j + 2)(p + 2j − 1)
∏
∞
j=1
x2k
∑
= a0
k=0
(2k)!
k
(−1)k (p − 2j + 1)(p + 2j)
∏
∞
j=1
x2k+1
∑
+a1
k=0
(2k + 1)!
[ ]
p(p + 1) 2 p(p + 1)(p − 2)(p + 3) 4
= a0 1 − x + x − ···
2! 4!
[ ]
(p − 1)(p + 2) 3 (p − 1)(p + 2)(p − 3)(p + 4) 5
+a1 x − x + x − ···
3! 5!
= a0 y0 (x) + a1 y1 (x)
which is the general solution of the Legendre’s equation. The functions y0 (x) and y1 (x) are called the
Legendre’s polynomials.
Example(s):
d2 y dy
(a) Determine the power series solution of x2 2
+ (x2 − 3x) + 3y = 0 about the point x0 = 0.
dx dx
Solution
Clearly, the point x = 0 is a regular singular point of the given differential equation. We assume
a power series solution of the form
∞
an (x − x0 )n+r , a0 ̸= 0
∑
y=
n=0
63([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Differentiating yields
∞ ∞
n+r−1
(n + r)(n + r − 1)an xn+r−2
∑ ∑
′ ′′
y = (n + r)an x , y =
n=0 n=0
n=1 n=1
∞
r
{[(n + r)(n + r − 4) + 3] an + (n + r − 1)an−1 } xn+r = 0
∑
⇒ [(r − 3)(r − 1)] a0 x +
n=1
The above recurrence relation is used to calculate an for n ≥ 1 in terms of a0 which is left
arbitrary. We consider two cases of r.
Case 1: when r = 3
−(n + 2) −1
The above recurrence relation becomes an = an−1 = an−1 , n ≥ 1. Thus,
(n + 3)(n − 1) + 3 n
we have.
1 1 1 1 −1
a1 = − a0 a2 = − a1 a3 = − a2 a4 = − a3 ··· ak = ak−1
1 2 3 4 k
Multiplying yields
1 1 1 1 1
a
a
1 · a
2 · a
3 ·4 · · · ak = − a0 · − a
1·− a
2·− a
3··· −
ak−1
1 2 3 4 k
Thus, we obtain
(−1)k
ak = a0
k!
64([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Case 2: when r = 1
−n −1
The above recurrence relation becomes an = an−1 = an−1 , n ≥ 1.
(n + 1)(n − 3) + 3 n−2
Thus, we have.
1 1
a1 = − a0 = a0 a2 = − a1 = −∞
1− 0
Exercise:
Determine the power series solution of the following differential equations about the regular singular
point x = 0.
d2 y dy
(a) 2x2 2
−x + (x − 5)y = 0.
dx dx
d2 y dy
(b) 2x2 + (x + 2) + y = 0.
dx2 dx
d2 y dy
(c) 2x2 2
+x + (x2 − 2)y = 0.
dx dx
d2 y dy
(d) 9x(1 − x) − 12 + 4y = 0.
dx2 dx
d2 y dy
x2 2
+x + (x2 − p2 )y = 0 (24)
dx dx
is called Bessel’s equation of order p. The solutions of equation (24) are known as Bessel functions.
The equivalent normalized form of equation (24) is
( )
d2 y 1 dy p2 1 n2
+ + 1 − y=0 ⇒ P1 (x) = , P2 (x) = 1 − 2
dx2 x dx x2 x x
where x0 is the regular singular point of equation (24) about which we are finding the solution,
a0 , a1 , · · · are constants
65([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
n=0 n=2
∞ ∞
⇒ a0 (r2 − p2 )xr + a1 [(r + 1)2 − p2 ]xr+1 + [(n + r)2 − p2 ]an xn+r + an−2 xn+r = 0
∑ ∑
n=2 n=2
[ ] −1 .
3. (n + r)2 − p2 an + an−2 = 0 ⇒ an = an−2 , n ≥ 2 (recurrence relation)
(n + r)2 − p2
The above recurrence relation is used to calculate an for n ≥ 2 in terms of a0 and a1 which are
left arbitrary. We consider two cases of r
Case 1: when r = p
−1
The above recurrence relation becomes an = an−2 , n ≥ 2. Thus, we have (note a1 = 0).
(p + n)2 − p2
Even subscripts Odd subscripts
−1 −1 −1
a2 = 2 2
a0 = a0 a3 = a1 = 0
(p + 2) − p 4(p + 1) (p + 3)2 − p2
−1 −1 −1
a4 = 2 2
a2 = a2 a5 = a3 = 0
(p + 4) − p 8(p + 2) (p + 5)2 − p2
−1 −1 −1
a6 = 2 2
a4 = a4 a7 = a5 = 0
(p + 6) − p 12(p + 3) (p + 7)2 − p2
.. ..
. .
−1 −1 −1
a2k = 2 2
a2k−2 = a2k−2 a2k+1 = a2k−1 = 0, k ≥ 1
(p + 2k) − p 4k(p + k) (p + 2k + 1)2 − p2
Multiplying the corresponding members of each column we get:
For the even subscripts,
−a0 −a2 −a2k−2
a2 · a4 · · · a2k = · ···
4(p + 1) 8(p + 2) 4k(p + k)
(−1) k
= a0 · a2 · · · a2k−2
22k k!(p + 1)(p + 2) · · · (p + k)
(−1)k 1
⇒ a2k = 2k
a0 . We choose a0 = p and get,
2 k!(p + 1)(p + 2) · · · (p + k) 2 p!
(−1)k 1 (−1)k (−1)k
a2k = = =
22k k!(p + 1)(p + 2) · · · (p + k) 2p p! 2p+2k k!(p + k)! 2p+2k k!Γ(p + k + 1)
66([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
a3 · a5 · · · a2k+1 = 0 ⇒ a2k+1 = 0
Therefore,
∞ ∞ ∞
an xn+r a2k xp+2k + a2k+1 xp+2k+1
∑ ∑ ∑
y= ⇒ y1 =
n=0 k=0 k=0
∑∞
· (−1)k xp+2k
= p+2k k!Γ(p + k + 1)
+0
k=0
2
= Jp (x) (26)
Equation (26) is called Bessel function and Jp (x) stands for the Bessel function of order p
Case 2: when r = −p
Similarly, the Bessel function for r = −p is [we replace p by −p in equation (26)]
∞
∑ (−1)n · x−p+2n
y2 = = J−p (x)
n=0
n!2−p+2n Γ(−p + n + 1)
Therefore, the general solution of equation (24) is y = AJp (x) + BJ−p (x).
Lecture 11
A = {a, b, c, d, e, f }
We can also specify a set by giving a description of its elements (without actually listing the elements).
For example, the set B = {2, 4, 6, 8, 10} can also be written
Symbol Meaning
∈ Belongs to (or is a member of). For example, x ∈ A means element x belongs to the set A.
∈
/ Is not a member of. For example, x ∈/ A means element x is not a member of A.
∀ For all
∃ There exists
| or : such that
67([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
7.4 Subsets
Let A and B be two sets. If every element of A is an element of B, we say that A is a subset of
B, and we write A ⊆ B. We also say that A is contained in B. For example, let A = {2, 5, 7} and
B = {1, 2, 3, 4, 5, 6, 7, 8}. Then, it is clear that A is contained in B, i.e., A ⊂ B.
7.6.2 Intersection
Let A and B be sets. The intersection of A and B, denoted by A ∩ B is
A ∩ B = {x : x ∈ A and x ∈ B}
Thus, the intersection of sets is the set of all objects which belong to all of them. For example, let
A = {1, 4, 9, 16} and B = {0, 1, 3, 4, 5, 6}. Then,
A ∩ B = {1, 4}
Definition 7.1 (Disjoint sets). Two sets A and B are said to be disjoint if they do not have a
member in common. That is, A ∩ B = ∅. If this is the case, we say that A and B do not intersect. If
A ∩ B ̸= ∅, we say that A and B intersect.
68([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
For example, if A = {2, 1, 3, 5} and B = {x, t, 7, 1}, then A ∪ B = {1, 2, 3, 5, x, t, 7} and A ∩ B = {1}.
Therefore,
A∆B = {2, 3, 5, x, t, 7}
(a) If one considers the set of men and women, then a universal set is probably the set of human
beings.
(b) If one considers sets such as pigs, cows, chickens, or horses, the universal set is probably the set
of animals.
Similarly, let the universal set be U = {0, 1, 2, 3, 5, 6} and D = {3, 5}. Clearly, Dc = {0, 1, 2, 6}.
→ Note: the complement is always with respect to a particular universal set. Thus, when discussing
complements, it is essential to define the universal set.
69([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
Example(s):
1. Safaricom (Kenya Ltd) surveyed 400 of its customers to determine the way they learned about
the new Kochokocho promotion. The survey shows that 180 learned about the promotion from
radio, 190 from television, 190 from newspapers, 80 from radio and television, 90 from radio and
newspapers, 50 from television and newspapers, and 30 from all three forms of media. Draw a
Venn diagram to represent this information. Hence, determine the number of customers who:
(a) learned of the promotion from at least two of the three media.
(b) learned of the promotion from exactly one of the three media.
(c) did not learn of the promotion from any of the three media.
Solution
Let the universal set be
70([email protected])
Downloaded by Francis Mbae
lOMoARcPSD|43072212
(a) At least two of the media means we add : 50,60, 20 and 30 to get 160. Thus exactly 160
customers learned of the promotion from at least two of the three media.
(b) Exactly one of the media means Radio only or Television only or Newspapers only. From
the Venn diagram we have: 40 + 90 + 80 = 210.
(c) |U | − |R ∪ T ∪ N | = 400 − (40 + 50 + 60 + 30 + 90 + 20 + 80) = 30.
2. Each of the 100 students in the first year of Open Universitys Computer Science Department
studies at least one of the subsidiary subjects: mathematics, electronics and accounting. Given
that 65 study mathematics, 45 study electronics, 42 study accounting, 20 study mathematics
and electronics, 25 study mathematics and accounting, and 15 study electronics and accounting,
find the number who study:
3. A group of 150 tourists planned to visit East Africa. Among them, 3 fall ill and did not come, of
the rest 6 visited all the three countries, 8 visited Uganda and Tanzania, 26 visited Kenya and
Tanzania, 17 visited Kenya and Uganda, 27 visited Kenya only, and 45 visited Uganda only.
71([email protected])
Downloaded by Francis Mbae