MAT 241-Variation of Parameters, Operator and Difference Equations
MAT 241-Variation of Parameters, Operator and Difference Equations
MAT 241-Variation of Parameters, Operator and Difference Equations
Difference Equation
Lawal G.S
University of Ibadan
gslawal@hotmail.com
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 1 / 54
Overview
1 Variation of Parameters
2 Operator Techniques
3 Difference Equation
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 2 / 54
Variation of Parameters
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 3 / 54
Variation of Parameters
K10 y1n−1 + K20 y2n−1 + K30 y3n−1 + ... + Kn0 ynn−1 = R(x)
where the last equation represents the condition that the given differential
equation be satisfied. From these equations, K10 , K20 , K30 , ..., Kn0 .
K1 , K2 , K3 , ..., Kn can then be found by integration leading to the required
equation. This method is applicable whenever the complementary solution
can be found including cases where a0 , a1 , a2 , ..., an are not constants.
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 4 / 54
Variation of Parameters
Example I:
Solve the differential equation using method of variation of parameters
(D 2 − 3D + 2)y = e 5x
Solution:
The differential equation can also be written as
y 00 − 3y 0 + 2y = e 5x
yc = c1 e x + c2 e 2x
y = K1 e x + K2 e 2x (i)
Continuation...
Differentiating (i) yields
Since there are two functions, we must arrive at two conditions for
determining them. One of these conditions is that
y 0 = K1 e x + 2K2 e 2x (iv )
substituting (i), (iv) and (v) into the given differential equation, we
obtain Thus,
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 6 / 54
Variation of Parameters
Continuation...
Continuation...
−K20 e 2 x + 2K20 e 2x = e 5x
K20 e 2x = e 5x
1
K20 = e 3x =⇒ K2 = e 3x + c2
3
Continuation...
hence
1 1
y = (− e 4x + c1 )e x + ( e 3x + c2 )e 2x
4 3
rearranging, we have
1 5x
y = c1 e x + c2 e 2x + e
12
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 9 / 54
Variation of Parameters
Example II:
Solve the differential equation
(D 2 + 4)y = 8 sin 2x
Solution:
The differential equation can also be written as
y 00 + 4y = 8 sin 2x
yc = c1 cos 2x + c2 sin 2x
Continuation...
Differentiating (*) yields
y 0 = −2K1 sin 2x + K10 cos 2x + 2K2 cos 2x + K20 sin 2x (∗∗)
Since there are two functions, we must arrive at two conditions for
determining them. One of these conditions is that
K10 cos 2x + K20 sin 2x = 0
such that (**) becomes
y 0 = −2K1 sin 2x + 2K2 cos 2x
Differentiating again
y 00 = −4K1 cos 2x − 2K10 sin 2x − 4K2 sin 2x + 2K20 cos 2x
Thus,
y 00 + 4y = −2K10 sin 2x + 2K20 cos 2x = 8 sin 2x (∗ ∗ ∗)
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 11 / 54
Variation of Parameters
Continuation...
From the two equations,
K10 cos 2x + K20 sin 2x = 0
0
−2K1 sin 2x + 2K20 cos 2x = 8 sin 2x
From here,
−K20 sin 2x
K10 =
cos 2x
substituting into the second equation, we obtain
−K20 sin 2x
−2 sin 2x + 2K20 cos 2x = 8 sin 2x
cos 2x
Multiply all by cos 2x, then
2K20 sin2 2x + 2K20 cos2 2x = 8 sin 2x cos 2x
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 12 / 54
Variation of Parameters
Continuation...
Continuation...
Hence
1
y = c1 cos 2x + c2 sin 2x − 2x cos 2x + sin 4x cos 2x + sin3 2x
2
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 14 / 54
Variation of Parameters
Tutorial Questions:
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 15 / 54
Operator Techniques
Operator Techniques
φ(D)y = R(x)
where m1 , m2 , ..., mn are constants and where the other of the factors
(D − m1 )(D − m2 ), ..., (D − mn ) is immaterial. This is not true if
a0 , a1 , ..., an are not constants.The constants, m1 , m2 , ..., mn are the root
of the auxiliary equation and the complementary solution is
y = c1 e m1 x + c2 e m2 x + ... + cn e mn x
a0 (D − m3 )(D − m4 )...(D − mn )y = Y2
so that
(D − m2 )Y2 = Y1
which can be solved for Y2 .By continuing in this manner, y can be
obtained. This method yields the general solution if all arbitrary constants
are kept, while it yields a particular solution if the constants are omitted.
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 17 / 54
Operator Techniques
φ(D)yp = R(x)
1
We call φ(D) an inverse operator.By reference to the entries in the
following table, the labour in finding particular solution of φ(D)y = R(x)
is often reduced.
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 18 / 54
Operator Techniques
1
e mx e −mx R(x)dx
R
(D−m) R(x)
1
e m1 x e −m1 x e m2 x ... e −mn−1 x e m
R R R
(D−m1 )(D−m2 )...(D−mn ) R(x)
1 px e px
φ(D) e φ(p) if φ(p) 6= 0
1 cos(px+q)
φ(D 2 )
cos(px + q) φ(−p 2 )
if φ(−p 2 ) 6= 0
1 sin(px+q)
φ(D 2 )
sin(px + q) if φ(−p 2 ) 6= 0
φ(−p 2 )
1 p k p
φ(D) x = (c0 + c1 D + ... + ck D +)x (c0 + c1 D + ... + cp D p )x p
1 px 1
φ(D) e F (x) e px φ(D+p) F (x)
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 19 / 54
Operator Techniques
Examples I:
1 4x
Evaluate D−2 (e )
Using the formula
1
(e 4x )
D −2
Z
= e 2x e −2x e 4x dx
1
= e 4x
2
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 20 / 54
Operator Techniques
Example II:
1
Evaluate (3e −2x )
(D + 1)(D − 2)
Using the formula;
1
(3e −2x )
(D + 1)(D − 2)
1 1
= (3e −2x )
D +1 D −2
Z
1 2x −2x −2x
= e e (3e )dx
D +1
1 3 −2x
= − e
D +1 4
Z
3 3
= e −x e x (− e −2x )dx = e −2x
4 4
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 21 / 54
Operator Techniques
Alternatively:
Using Partial fraction
1
(3e −2x )
(D + 1)(D − 2)
" #
−1 1
= 3
+ 3
(3e −2x )
D +1 D −2
1 1
=− (e −2x ) + (e −2x )
D +1 D −2
Z Z
−x x −2x
= −e e (e )dx + e 2x
e −2x (e −2x )dx
3
= e −2x
4
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 22 / 54
Operator Techniques
Example III:
1 px e px
Prove that e = if φ(p) 6= 0.
φ(D) φ(p)
By definition;
φ(D) = a0 (x)D n + a1 (x)D n−1 + a2 (x)D n−2 + ... + an−1 (x)D + an (x)
= φ(p)e px
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 23 / 54
Operator Techniques
Example IV:
Find the general solution of (D 2 − 3D + 2)y = e 5x using the result in
(Example III):
The complementary solution is;
yc = c1 e x + c2 e 2x
1 5x 1 5x e 5x
yp = e = e =
D 2 − 3D + 2 (52 ) − 3(5) + 2 12
e 5x
y = c1 e x + c2 e 2x +
12
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 24 / 54
Operator Techniques
Example V:
yc = c1 cos x + c2 sin x
1 cos(px + q)
2
cos(px + q) = if φ(−p 2 ) 6= 0
φ(D ) φ(−p 2 )
then we have
1 1 1
yp = cos 2x = cos 2x = − cos 2x
D2 +1 (−4 + 1) 3
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 25 / 54
Operator Techniques
Example VI:
1
Evaluate D 3 +D 2 +2D−1
cos 2x
Using the result in example IV,
1 cos(px + q)
cos(px + q) = if φ(−p 2 ) 6= 0
φ(D 2 ) φ(−p 2 )
then we have
1 1
cos 2x = cos 2x
D3 + D2 + 2D − 1 D(−4) − 4 + 2D − 1
1 (2D − 5) (2D − 5)
− cos 2x = − 2 cos 2x = − cos 2x
2D + 5 4D − 25 4(−4) − 25
1 1
= (2D − 5) cos 2x = (−4 sin 2x − 5 cos 2x)
41 41
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 26 / 54
Operator Techniques
Example VII:
Evaluate (D 3 + D)y = e −2x cos 2x
Using the formula in the table;
1 px 1
e F (x) = e px F (x)
φ(D) φ(D + p)
1 1
yp = e −2x cos 2x = e −2x cos 2x
D3 +D 3
(D − 2) + D − 2
1 1
= e −2x cos 2x = e −2x cos 2x
D 3 − 6D 2 + 13D − 10 −4D + 24 + 13D − 10
1 9D − 14
= e −2x cos 2x = e −2x cos 2x
9D + 14 81D 2 − 196
e −2x e −2x
= (9D − 14) cos 2x = (9 sin 2x + 7 cos 2x)
81(−4) − 196 260 th
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27 April, 2017 27 / 54
Operator Techniques
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 28 / 54
Difference Equation
Difference Equation
Definition 3.1.1
An equation which contains independent variable, dependent variable and
successive differences of the dependent variable is called the difference
equation.
Examples 3.1.2
1 yn+2 − 6yn+1 + 9yn = 0
2 (E 2 + 6E + 9)yn = 2n i.e yn+2 + 6yn+1 + 9yn = 2n
3 (∆2 + 3∆ + 2)yn = 1 or ∆2 yn + 3∆yn + 2yn = 1
or (yn+2 − 2yn+1 + yn ) + 3(yn+1 − yn ) + 2yn = 1
or yn+2 + yn+1 = 1
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 29 / 54
Difference Equation
Example 3.1.4
The order of the difference equation yn+2 − 7yn = 5 is
(n + 2) − n
=2
1
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 30 / 54
Difference Equation
Definition 3.1.5
Example i:
n+2−n
The order and degree of yn+2 + 4yn+1 + 4yn = 2n are = 2 and 1
1
respectively.
Example ii:
2 n+3−n
The order and degree of yn+3 + 3yn+2 + 3yn+1 + yn = 0 are =3
1
and 2 respectively.
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 31 / 54
Difference Equation
Definition 3.1.6
Particular solution
A solution which can be obtained from the general solution by assigning
particular values is called particular solution.
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 32 / 54
Difference Equation
∆2 yn = yn+2 − 2yn+1 + yn
Solution:
yn = A2n + B(−2)n =⇒ yn − A2n − B(−2)n = 0
yn+2 − 4yn = 0
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 34 / 54
Difference Equation
Definitions :
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 35 / 54
Difference Equation
Continuation...
Equation 3.1.8 is known as the auxiliary equation. This equation has
k-roots m1 , m2 , m3 , ..., mk .Some cases may arise;
Case I: When the roots are real and distinct
If m1 , m2 , m3 , ..., mk are real and distinct roots of auxiliary equation
(3.1.8), then the solution is
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 37 / 54
Difference Equation
Continuation...
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 38 / 54
Difference Equation
Continuation...
yn = c1 (α + iβ)n + c2 (α − iβ)n
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 39 / 54
Difference Equation
Example I:
Solve the difference equation yn+2 − 2yn+1 − 8yn = 0
Solution:
This equation can also be written as
(E 2 − 2E − 8)yn = 0
Let yn = mn , then
m2 − 2m − 8 = 0 =⇒ (m − 4)(m + 2) = 0
m = 4 and m = 2. Hence
yn = c1 (4)n + c2 (−2)n
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 40 / 54
Difference Equation
Example II:
(E 3 + E 2 − 8E − 12)yn = 0
m3 + m2 − 8m − 12 = 0
yn = (c1 + c2 n)(−2)n + c3 3n
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 41 / 54
Difference Equation
Example III:
Solve the difference equation yn+2 + 16yn = 0
Solution:
The given difference equation can be written as
(E 2 + 16)yn = 0
m2 + 16 = 0
Continuation...
π n π n
n π π
= 4 c1 cos + i sin + c2 cos − i sin
2 2 2 2
nπ nπ nπ nπ
= 4n c1 cos + i sin + c2 cos − i sin
2 2 2 2
n nπ nπ
= 4 (c1 + c2 ) cos + i(c1 − c2 ) sin
2 2
n nπ nπ
= 4 A cos + B sin
2 2
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 43 / 54
Difference Equation
or
φ(E )yn = R(n)
where a0 , a1 , ..., an are all constants is known as non-homogeneous linear
difference equation with constant coefficient.
The general solution of (3.1.9) consist of two parts, the complementary
function and the particular integral.
The complementary function is the general solution of the homogeneous
1
equation of (3.1.9) and the Particular Integral = R(n)
φ(E )
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 44 / 54
Difference Equation
Case I:R(n) = an
1 n 1 n
P.I = a = a
φ(E ) φ(a)
provided φ(a) 6= 0
If φ(a) = 0, then for the equation
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 45 / 54
Difference Equation
Continuation...
When k = 2,
1 n n(n − 1)an−2
P.I = a =
(E − a)2 2!
1 1 1
= e ian − e −ian
2i ia
φ(e ) φ(e −ia )
provided φ(e ia ) 6= 0 and φ(e −ia ) 6= 0
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 46 / 54
Difference Equation
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 47 / 54
Difference Equation
Example I:
Solve the difference equation yn+2 − 4yn+1 + 3yn = 5.4n
This equation can also be written as
(E 2 − 4E + 3)yn = 5.4n
Example II:
(E 2 − 3E + 2)yn = 6.2n
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 49 / 54
Difference Equation
Continuation...
1 1 1
= 6. .2n = 6. .2n = 6. .2n
(E − 1)(E − 2) (2 − 1)(E − 2) (E − 2)
= 6.n2n−1 = 3n2n
Hence the general solution is
yn = c1 + c2 (2)n + 3n2n
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 50 / 54
Difference Equation
Example III:
Solve the difference equation yn+2 − 6yn+1 + 8yn = 3n2 + 2
The given difference equation can be written as
(E 2 − 6E + 8)yn = 3n2 + 2
yn = c1 2n + c2 4n
1
= (3n2 + 2)
1 + 2∆ + ∆2 − 6 − 6∆ + 8
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 51 / 54
Difference Equation
Continuation...
1 1 1
= (3n2 + 2) = 2
2 (3n + 2)
∆2 − 4∆ + 3 3 (1 − 4∆−∆
)
3
−1
4∆ − ∆2
1
= 1− (3n2 + 2)
3 3
4∆ − ∆2 (4∆ − ∆2 )2
1
= 1+ + + ... (3n2 + 2)
3 3 9
8 44
= n2 + n +
3 9
Hence the general solution is
8 44
y n = c 1 2n + c 2 4n + n 2 + n +
3 9
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 52 / 54
Difference Equation
Tutorial Questions
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 53 / 54
Difference Equation
Lawal G.S (Department of Mathematics) MAT 241 Thursday 27th April, 2017 54 / 54