Digital Signal Processing Reference
In-Depth Information
2.5
2
1.5
1
0.5
0
−6
−4
−2
0
2
4
6
8
10
n
Figure 3.3:
A partial reconstruction (using Eq. (3.4)) of the infinite-extent periodic sequence
x
[
n
]
that
results from reconstruction of
x
[
n
]
from samples of the
z
-transform
X(z)
, where
x
[
n
]
= [1,1,1,1].
in the ROC, then
X
, which consists of
N
samples of
X(z)
along the unit circle, located at frequencies
specified as 2
πk/N
,where
k
= 0:1:
N
-1, can determine
X(z)
for all
z
according to the following equation:
[
k
]
N
−
1
X
z
−
N
N
1
−
[
k
]
X(z)
=
(3.5)
e
j
2
πk/N
z
−
1
1
−
k
=
0
Example 3.4.
, compute and display 1000 samples of the magnitude of the
z-transform directly, then compute and display 1000 samples of the magnitude of the z-transform using
Eq. (3.5).
For the sequence
[
1
,
1
,
1
,
1
]
In the m-code below, we first compute 1000 points of the
z
-transform by writing the
z
-transform
of the sequence and evaluating; we then extract four properly located samples from the 1000 samples and
use Eq. (3.5) to reconstruct the entire 1000 samples of the
z
-transform. The results are shown in Fig. 3.4.
inc = 1/999; xvec = inc/2:inc:1; zp = 2*pi*xvec;z=exp(j*zp);
ZX1=1+z.ˆ(-1) + z.ˆ(-2) + z.ˆ(-3);
figure(33); subplot(211);
plot(xvec,abs(ZX1)); axis([0,1,0,5])
k = 0:1:3; Fndx = fix((k/4)*1000) + 1;
Xtil = ZX1(Fndx);S=0;
for k = 0:1:3
S=S+Xtil(k+1)./(1-(exp(j*2*pi*k/4))*(z.ˆ(-1)));
end