Digital Signal Processing Reference
In-Depth Information
Figure 2.6:
A VI allowing the user to drag a pole or pair of complex conjugate poles in the
z
-plane and
observe the impulse response of an IIR constructed from the pole or poles. The first 75 samples of the
impulse response are computed and displayed.
2.4.1 DIFFERENCE EQUATION
A simple, direct method is to write the difference equation of the system by inspection from the
z
-
transform, and then process a unit impulse.
Example 2.24.
Compute the impulse response that corresponds to a causal LTI system that has the
z
-transform
z
−
1
+
1
=
X(z)
0
.
9
z
−
1
1
−
The difference equation is
y
[
n
]=
x
[
n
]+
x
[
n
−
1
]+
0
.
9
y
[
n
−
1
]
with
y
= 0 for
n<
0. We can compute an arbitrary number of samples
N
of the impulse response
using the function
filter
with
b
= [1,1],
a
= [1, -0.9], and
x
= [1, zeros(1,N)]. Thus, we make the call
[
n
]
=
x
[
n
]
N=50; ImpResp = filter([1,1],[1,-0.9],[1,zeros(1,50)])