EAU_Math2051_Part_I
EAU_Math2051_Part_I
October 8, 2024
dy d 2y dy
4x +y =x and 2
+4 − 6y = e x
dx dx dx
are first and second-order ordinary differential equations respectively.
The general nth −order ordinary differential equation in one dependent
variable is given by the general form general form
F (x, y , y 0 ) = 0 or y 0 = f (x, y ).
Example
1. x 00 (t) + 2x(t) + sin(t) = 0 is a linear ODE,
2. x 0 + x 2 = 1 is a nonlinear ODE.
Definition
Let h(x) be a real valued function defined on an interval [a, b] and having
nth order derivative for all x ∈ (a, b). If h(x) satisfies the nth order ODE
(3) on (a, b), that is,
1. F (x, h(x), h0 (x), h00 (x), . . . , h(n) (x)) is defined for all x ∈ (a, b) and
2. F (x, h(x), h0 (x), h00 (x), . . . , h(n) (x)) = 0, for all x ∈ (a, b),
then y = h(x) is called a (an Explicit) solution of the ODE on [a, b].
Example
The function h(x) = sin x + cos x is an explicit solution for the DE y 00 + y = 0,
where as the function h(x, y ) = x 2 + y 2 − 4 = 0 is an implicit solution of the DE
yy 0 = −x on (−2, 2), since y > 0.
Theorem
1. (Existence) Let F (t, x) be a continuous function, then the initial value
problem
dx
= F (t, x), x(to ) = xo
dt
has a solution x = f (t) defined in some neighbourhood of to .
2. (Uniqueness) If F (t, x) is a once continuously differentiable function, then
there exists a unique solution to the initial value problem,
dx
= F (t, x), x(to ) = xo
dt
(EAU) Math 2051 (Part I) October 8, 2024 10 / 63
First Order ODEs Separation of Variables
A First Order ODE is generally of the form
g (y )dy = f (x)dx
y 0 = g (ax + by + c).
x 2 y 0 = x 2 + xy + y 2 .
(EAU) Math 2051 (Part I) October 8, 2024 14 / 63
Exact Differential Equations
Definition
An ODE of the form M(x, y )dx + N(x, y )dy = 0 is said to be an exact DE
is some domain D, if there exists a function F (x, y ) such that
∂F ∂F
∂x = M(x, y ) and ∂y = N(x, y ) for all (x, y ) ∈ D.
∂F ∂F
= M(x, y ) and = N(x, y ),
∂x ∂y
Example
Solve each of the following DEs.
1 (x 2 − 3x 2 y )dx − (x 3 +
√
y )dy = 0.
x−y +4
2 y0 = x+y .
∂ ∂
(µN) = (µN) (by exactness of the given DE) (4)
∂y ∂x
and this is equivalent to the equation
µy M + µMy = µx N + µNx ,
dµ
µMy = N + µNx
dx
dµ My −Nx
which is equivalent to dx = µ( N ) and this is a separable differential
equation.
M y − Nx
This idea works correctly if the ratio is a function of x only; that
N
My −Nx
is, if p(x) = N is a function of x only. In this case
dµ My − Nx
= dx,
µ N
which implies R
p(x)dx
µ(x) = e .
dµ M y − Nx
= −µ , which is a separable differential equation.
dy M
My −Nx
Hence, if instead, the fraction q(y ) = M is a function of y alone, then
R
− q(y )dy
µ(y ) = e .
M y − Nx 0−3 −3e 2y
= =
N 3x − e −2y 3xe 2y − 1
which is not a function of x alone. Hence obtaining µ(x) is not possible.
M −N
However, yM x = 0−3 1 = −3( constant function)
can be considered
R as a function of y alone . Therefore,
µ(y ) = e − (−3)dy = e 3y .
Example
Now to solve the problem in (5), multiplying the given equation by
µ(y ) = e 3y we have an exact DE
e 3y dx + (3x − e −2y )e 3y dy = 0.
∂F ∂F
= e 3y and = (3x − e −2y )e 3y .
∂x ∂y
a0 (x) f (x)
p(x) = and q(x) = .
a1 (x) a1 (x)
Write the left side of the resulting equation as the derivative of the
product of y and the integrating factor. The integrating factor is
designed to make this possible. The right side is a function of just x.
That is R
de p(x)dx y R
= e p(x)dx q(x)
dx
Integrate both sides of this equation with respect to x and solve the
resulting equation for y gives the general solution.
R Z R
p(x)dx
e y = e p(x)dx q(x)dx.
d(ye 3x )
= 6e 3x .
dx
4 We integrate
d(ye 3x )
Z Z
dx = 6e 3x
dx
and get y (x)e 3x = 2e 3x + C . Then solve for y (x) to get the general
solution y (x) = Ce −3x + 2 for an arbitrary constant C .
(EAU) Math 2051 (Part I) October 8, 2024 25 / 63
Reading Assignment .
Definition
A linear ordinary differential equation of order n in the dependent variable
y and independent variable x is an equation which can be expressed in the
form:
Example
y1 = cos x and y2 = sin x are two solutions of the homogenous DE
y 00 + y = 0. Then for any arbitrary constants c1 and c2 ,
y (x) = c1 cos x + c2 sin x is also a solution to the given DE.
Example
1 The functions f1 (x) = e x and f2 (x) = 4e x are Linearly Dependent on
R since −4f1 (x) + f2 (x) = −4e x + 4e x = 0, for all x ∈ R.
2 The functions f1 (x) = x and f2 (x) = x 3 are LI on R, since for
c1 , c2 ∈ R, c1 f1 (x) + c2 f2 (x) = c1 x + c2 x 3 = 0, ∀x ∈ R\{0} implies
c1 = 0 and c2 = 0.
(EAU) Math 2051 (Part I) October 8, 2024 30 / 63
Existence of Linearly Independent Solutions for a LHODE
Theorem
The Linear Homogenous Differential Equation (LHODE) (8) always has n
Linearly Independent (LI) solutions. Furthermore, if f1 (x), f2 (x), . . . , fn (x)
are n LI solutions of (8), then every solution of (8) can be expressed as a
linear combination of these solution functions. i.e. If y is a solution for
(8), then
Xn
y (x) = ci fi (x)
i=1
Example
Consider the second order linear homogenous DE y 00 + y = 0. Then
f1 (x) = sin x, f2 (x) = cos x are LI solutions of the given equation and the
general solution of the DE is given by y (x) = c1 sin x + c2 cos x, for
constants c1 , c2 ∈ R.
(EAU) Math 2051 (Part I) October 8, 2024 31 / 63
Fundamental Set of Solutions
Definition
If f1 (x), f2 (x), . . . , fn (x) are n linearly independent solutions of (8) on
[a, b], then the set {f1 (x), f2 (x), . . . fn (x)} is called the Fundamental Set
of Solutions of (8) and the function
Example
Consider the third order linear homogenous DE y 000 − 2y 00 − y 0 + 2y = 0.
Then the functions e x , e −x , e 2x are LI (particular) solutions and hence the
general solution of the given equation is given by:
y (x) = c1 e x + c2 e −x + c3 e 2x , where c1 , c2 , c3 ∈ R.
(EAU) Math 2051 (Part I) October 8, 2024 32 / 63
The Wronskian of Functions
Definition
Let f1 (x), f2 (x), . . . , fn (x) be n real valued functions each of which has an
(n − 1)th derivative on the interval [a, b]. The determinant:
Example
The Wronskian, W(x) of y1 (x) = e 2x and y2 (x) = xe 4x is
e 2x xe 4x
W(x) = = e 4x + 2xe 4x − 2xe 4x = e 4x
2e 2x e 4x + 4xe 4x
(EAU) Math 2051 (Part I) October 8, 2024 33 / 63
Wronskian Test for Linearly Independence
Theorem
The n functions f1 , f2 , . . . , fn are Linearly Independent on an interval [a, b]
if and only if the Wronskian of f1 , f2 , . . . , fn is different from zero for
some x ∈ [a, b]. That is, f1 , f2 , . . . , fn are LI if and only if there exists
x ∈ [a, b] such that W(x) 6= 0.
Example
1 Show that x and x 2 are Linearly Independent.
Solution:
Consider the Wronskian of x and x 2 ,
x x2
W(x, x2 ) = = 2x 2 − x 2 = x 2
1 2x
Definition
A Differential Equation
bn f (n) (x) + bn−1 f (n−1) (x) + · · · + b1 f 0 (x) + b0 f (x) = 0 for all x ∈ [a, b].
Hence the derivatives of f are linearly dependent since at least one of the
coefficients b0 , b1 , . . . , bn is different from zero.
The simplest case with this property is a function f such that
f (k) (x) = cf (x), ∀x ∈ [a, b] for some constant c.
which implies
00 0
u y1 + u 0 (2y1 + p(x)y1 ) = 0.
00
This is a second order DE in u. Let u 0 = z. Then u = z 0 . Using
separation of variables we get
0 0
z −2y1
= −p
z y1
which is a first order DE and hence the name reduction of order andR
integrating and taking the constant zero gives us ln z = −2 ln y1 − pdx.
This implies
1 R
z = 2 e − pdx .
y1
(EAU) Math 2051 (Part I) October 8, 2024 40 / 63
Reduction of Order...
But z = u 0 . Then
1 − R pdx
u0 = e
y12
and then Z
y2 1 − R pdx
=u= e dx.
y1 y12
Therefore, the second solution for the given equation is
Z
1 − R pdx
y2 = y1 e dx.
y12
Example
The function y1 (x) = x is a solution of the homogenous DE
00
(x 2 − 1)y − 2xy 0 + 2y = 0.
00
Solution The given equation is equivalent to y + p(x)y 0 + q(x)y = 0,
where
−2x 2
p(x) = 2 and q(x) = 2 .
x −1 x −1
If y2 is a second solution of the given equation then y2 (x) = u(x)y1 (x),
where
Z Z Z
1 − R x−2x
2 −1 dx
1 ln |x 2 −1| 1
u(x) = 2
e dx = 2
e dx = (1− 2 )dx = x+
x x x
y (x) = c1 e λx + c2 xe λx
Example
(1) Consider the Differential Equation y 00 − 4y 0 + 4y = 0. The corresponding
characteristic equation is λ2 − 4λ + 4 = 0 and the roots are λ1 = λ2 = 2.
Therefore, the general solution of the given DE is given by
y (x) = c1 e −2x + c2 xe −2x , where c1 and c2 are arbitrary constants.
(2) Consider the Differential Equation 3y 00 + 12y 0 + 4y = 0. Then, the characteristic
equation is 3λ2 + 12λ + 4 = 0 and the roots of the characteristic equation are,
λ1 = λ2 = − 32 and hence the general solution of the equation is:
2 2
y (x) = c1 e − 3 x + c2 xe − 3 x ,
Example
Solve y 00 − 2y 0 + 10y = 0.
Solution
The characteristic equation of the given equation is λ2 − 2λ + 10 = 0 with
roots λ1 = 1 + 3i and λ2 = 1 − 3i. Then y1 = e x cos 3x and y2 = e x sin 3x
are two independent solutions of the given equation. Therefore,
y = c1 y1 + c2 y2 , where c1 and c2 are arbitrary constants, is a general
solution of the given equation. That means
b2 y 00 + b1 y 0 + b0 y = f (x), (14)
where b2 , b1 , b0 are constants is called a nonhomogeneous differential
equation with constant coefficients.
Theorem
Consider the nonhomogeneous differential equation
From the theorem we can see that, if yh (x) denote the general solution of the
homogeneous part of (14) and yp (x) denote a particular solution of the DE (14), then
the general solution of (14) is given by
Definition
1. A function is called an undetermined coefficient function (UC
function) if it is either:
a) a function defined by (a linear combination) of the following
i) x n , n = 0, 1, 2, . . . ,
ii) e ax , where a is any non-zero constant
iii) sin(bx + c), where b, c are constants, such that b 6= 0.
iv) cos(bx + c), where b, c are constants, such that b 6= 0.
or
b) a function which is defined as a finite product of two or more functions
of the above 4 types.
2. Let f be an UC function. A set S of functions consisting of f and all
the derivatives of f which are mutually LI UC functions is said to be
the UC set of function f.
Example
(−D sin x − E cos x) − 2(D cos x − E sin x) − 3(D sin x + E cos x) = −10 sin x.
Simplifying this gives us, (2E − 4D) sin x + (−2D − 4E ) cos x = −10 sin x.
Therefore,
2E − 4D = −10
−2D − 4E = 0
which implies D = 2 and E = −1. Then, yp1 (x) = 2 sin x − cos x.
Therefore, the general solution is
1 −x
y (x) = C1 e 3x + C2 e −x − xe + 2 sin x − cos x.
2
Now we want to get a particular solution corresponding to f (x) and this can be done by
varying the constants, c1 and c2 with respect to x. If yp is a particular solution
corresponding to f (x), then
0 y2
f y20 W1 (x)
c01 (x) = =
W (x) W (x)
and
y1 0
y0 f W2 (x)
c02 (x) = 1 =
W (x) W (x)
By integrating both sides we will get:
Z Z
W1 (x) W2 (x)
yp (x) = dx y1 (x) + dx y2 (x).
W(x) W(x)
(EAU) Math 2051 (Part I) October 8, 2024 54 / 63
Example
Solve the differential equation y 00 − 4y = 8x.
Solution: First solve the homogeneous equation y 00 − 4y = 0.
Then the characteristic equation is λ2 − 4 = 0, which implies λ = ±2. If y1 and y2 are
two linearly independent solutions of the equation y 00 − 4y = 0, then
y1 = e 2x , y2 = e −2x . Therefore, the general solution of the homogeneous equation is
yh (x) = c1 e 2x + c2 e −2x and
y1 y2 e 2x e −2x
W(x) = = = −2 − 2 = −4,
‘y10 y20 2e 2x −2e −2x
0 y2 e 2x
0
W1 (x) = = = −8xe −2x
8x y20 −2e −2x
8x
−2x
Therefore, c1 (x) = W
R 1 (x)
dx = −8xe dx = 2 xe −2x dx = −xe −2x − 21 e −2x and
R R
W (x) −4
R W2 (x) R 8xe 2x
dx = −2 xe dx = −xe 2x + 21 e 2x . Therefore,
R 2x
similarly c2 (x) = W (x) dx = −4
yp (x) = c1 (x)e 2x + c2 (x)e −2x a particular solution and the general solution for the
problem is y (x) = yh (x) + yp (x).
Remark: This method looks easier when the integrads (or the quotients of the
Wronskian) are simple. However, it could be very difficult to get the particular solution
when the integrand is complicated.
(EAU) Math 2051 (Part I) October 8, 2024 55 / 63
The Cauchy-Euler Equations
Let us consider linear differential equations with variable coefficients with
some special forms.
Definition
The linear differential equation with variable coefficient of the form:
Example
The linear differential equation 3x 2 y 00 − 11xy 0 + 2y = sin x is a Cauchy-Euler
equation.
dy dy dt 1 dy
= . =
dx dt dx x dt
and
d 2y
1 d dy dy
= + .
dx 2 x dx dt dt
1 d 2y
d 1
= .
dx x x dt 2
2
dt 1 dy 1 d y dy
− 2 = − .
dx x dt x 2 dt 2 dt
(EAU) Math 2051 (Part I) October 8, 2024 57 / 63
Substituting into (18) we get:
2
2 1 d y dy 1 dy
a2 x 2 2
− + a1 x. + a0 y = F (e t ).
x dt dt x dt
This implies,
d 2y dy
a2 2
+ (a1 − a2 ) + a0 y = F (e t ).
dt dt
Then
d 2y dy
A2 2
+ A1 + A0 y = G (t), (19)
dt dt
where A2 = a2 , A1 = a1 − a2 , A0 = a0 and F (e t ) = G (t), which is a
second order linear differential equation with constant coefficients.
Example
Solve each of the following DEs.
1. x 2 y 00 − 2xy 0 + 2y = 0.
2. x 2 y 00 − 2xy 0 + 2y = x 3 .
(EAU) Math 2051 (Part I) October 8, 2024 58 / 63
Systems of ODE of the First Order
which is called the normal form. In vector form this system becomes:
X0 = AX + F(t),
where
Definition
A solution vector of the system of differential equation in (20) over some
interval I is a a vector (x1 (t), x2 (t), . . . , xn (t))T whose entries are
differentiable functions that satisfies the system in (20) on the interval I .
This implies,
Ax = λx,
which is an eigenvalue problem.
(EAU) Math 2051 (Part I) October 8, 2024 61 / 63
Eigenvalue Method for Homogeneous Systems with
Constant Coefficients
Once we find the eigenvalues λi and a corresponding eigenvector xi , the
general solution will be
y(t) = c1 x1 e λ1 t + · · · + cn xn e λn t ,
where c1 , ..., cn are constants.
Example
Solve the following systems of linear differential equations.
0
y1 = −3y1 + y2
y20 = y1 − 3y2