B. Frequency Domain Representation of Lti Systems: Objective
B. Frequency Domain Representation of Lti Systems: Objective
B. Frequency Domain Representation of Lti Systems: Objective
% Z – domain
% H(z) = (1-5z^(-1)+6z^(-2))/(1+1.25z^(-1)+0.375z^(-2))
b2 = [1 –5 6]; a2 = [1 1.25 0.375];
printsys(b2,a2,’z’);
3. For the LTI systems described by the following difference equations, generate its
frequency response. Comment on the type of response.
y[n]-0.3695y[n-1]+0.1958y[n-2]=0.2066x[n]+0.4131x[n-1] +0.2066x[n-2]
Sample Solution Frequency response
0
Magnitude Response (dB)
-20
% ex2_3.m
% Frequency domain response of -40
% y[n]–0.3695y[n-1]+0.1958y[n-2] = -80
freqz(b1,a1,64); -100
-200
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
Normalized frequency (Nyquist == 1)
5. Compute and plot the DTFT of the following sequence and observe the properties
s[n]= A cos(2πf0n + φ) Try for fo=100Hz, φ=π/6 and different lengths of sequence.
cd d:\dsp_lab\demo\pez_31
pez
Observe the relation between location of poles and zeroes in z plane, impulse response
and frequency response for the following systems
i y(n) = 0.77y(n-1)+x(n)+x(n-1)
ii y(n) = 0.77y(n-1)+0.77x(n)-x(n-1)
iii H(z) = 1-z-1/1+0.77z-1
iv H(z) = 1-z-1+z-2-z-3+z-4-z-5
v y(n) = x(n)+x(n-1)+x(n-2)+x(n-3)+x(n-4)+x(n-5)
vi H(z)=3-3z-1
7. Compute and plot the magnitude, phase and group delay for the following DTFT and
observe the properties
8. Consider an IIR filter described by y(n)-0.8y(n-1)=x(n). Find the impulse response h(n).
(i) Truncate h(n) to three terms and obtain h3(n). Plot the DTFT of h(n) and h3(n). (ii)
Truncate h(n) to ten terms and obtain h10(n). Plot the DTFT of h(n) and h10(n). (iii). If
the same input is applied to both the original filter and the truncated filter, will the
greatest mismatch in the response y(n) of the two filters occur at earlier or later time
instants n?
N −1
iii. y (n) − α y (n − 1) = (1 − α ) x(n), α = first order exponential average
N +1
(a) Sketch the frequency response of each filter with N=4 and N=9. How will the
choice of N affect the averaging?
(b) Generate the signal x(n)=1 – 0.6n; 0≤n≤299, add some noise and apply the noisy
signal to each averager and compare the results.
10. Digital filters are used to compensate for the sinc distortion of a ZOH DAC by
providing 1/sinc(ω) boost. Two such filters are (i) y(n)=[x(n)-18x(n-1)+x(n-2)]/16 and
(ii) y(n)+0.125 y(n-1)=1.125 x(n). For each filter state whether it is FIR (and if so
linear phase) or IIR. Plot the frequency response of each filter and compare with
|1/sinc(ω)| function. Over what digital frequency range does each filter provide the
required sinc boost?
12. The impulse response of filters for step interpolation, linear interpolation and ideal
(sinc) interpolation by N are given by
hS(n) = u(n)-u(n-(N-1))
⎧ |n|
⎛ n ⎞ ⎪1 − | n |≤ N
hL(n) = tri(n/N) where tri ⎜ ⎟ = ⎨ N
⎝ N ⎠ ⎪0
⎩ elsewhere
sin(nπ / N )
hI(n)=sinc(n/N) where sinc(n/N)= , sinc(0)=1
(nπ / N )
Plot the frequency response of each interpolating function for N=4 and N=8. How
does the response of step interpolation and linear interpolation schemes compare with
ideal interpolation.
13. To interpolate a signal x(n) by N, we use an upsampler (that places N-1 zeros after
each sample) followed by a filter that performs the appropriate interpolation. Generate
a test signal x(n)=cos(0.5πn) 0≤ n ≤ 3. Upsample this by N=8 to obtain xU(n).
(i) Use the step interpolation filter hS(n) to obtain xS(n). Plot xU(n) and xS(n) on the same
plot. Does it look like a sine wave
(ii) Use the step interpolation filter hS(n) followed by a compensating filter y(n)=[x(n)-
18x(n-1)+x(n-2)]/16 to obtain xC(n). Plot xU(n) and xC(n) on the same plot. Does it
look like a sine wave. Is there any improvement?
(iii) Use the linear interpolation filter hL(n) to obtain xL(n). Plot xU(n) and a delayed (by
8) version of xL(n) on the same plot. Does it look like a sine wave.
(iv) Use the ideal interpolation filter hI(n)= sinc(n/N) |n| ≤ M to obtain xI(n) (with
M=4,8,16). Plot xU(n) and a delayed (by M) version of xI(n) on the same plot. Does it
look like a sine wave. What is effect of increasing M?