2 Second order difference equations
You will learn in this section about solving second order linear constant coefficient difference equations. In this case two initial conditions are required, typically either and or and . In the first case we use the left shift property of the z-transform, in the second case we use the right shift property. The same three basic steps are involved as in the first order case.
Task!
By solving
(12)
obtain the general term of the Fibonacci sequence.
Begin by taking the z-transform of (12), using the left shift property. Then insert the initial conditions and solve the resulting algebraic equation for , the z-transform of :
(taking z-transforms )
(inserting initial conditions)
so
(solving for ). Now solve the quadratic equation and hence factorize the denominator of :
so if
This form for often arises in solving second order difference equations. Write it in partial fractions and find , leaving and as general at this stage:
where
Hence, taking inverse z-transforms
(13) Now complete the Fibonacci problem:
With so
we obtain, using (13)
for the term of the Fibonacci sequence. With an appropriate computational aid you could (i) check that this formula does indeed give the familiar sequence
and (ii) obtain, for example, and .
Task!
Use the right shift property of z-transforms to solve the second order difference equation
with and .
[Hint: the steps involved are the same as in the previous Task]
We now give an Example where a quadratic equation with repeated solutions arises.
Example 1
- Obtain the z-transform of .
-
Solve
[Hint: use the result from (1) at the inversion stage.]
Solution
- where we have used the property
-
Taking the z-transform of the difference equation and inserting the initial conditions:
from which, using the result (1) on the second term,
We shall re-do this inversion by an alternative method shortly.
Task!
Solve the difference equation
with arbitrary. (14)
Start by obtaining using the left shift theorem:
To find the inverse z-transforms recall the results for and from Key Point 6 (page 21) and some of the particular cases discussed in Section 21.2. Hence find here:
Taking and with
Hence (15) Those of you who are familiar with differential equations may know that
(16)
has solutions and and a general solution
(17)
where and .
This differential equation is a model for simple harmonic oscillations. The difference equation (14) and its solution (15) are the discrete counterparts of (16) and (17).