Tut 6 Sol
Tut 6 Sol
Nasser, 2022/2023
1. A stable system has input x[n] and output y[n] related by:
𝑦[𝑛] + 2𝑦[𝑛 − 1] + 3/4 𝑦[𝑛 − 2] = 𝑥[𝑛] − 2𝑥[𝑛 − 1]
a) Find the transfer function H(z)
b) Give a pole-zero plot for H(z) and specify the ROC
Solution:
a) Taking z-transform for both sides:
3
Ζ {𝑦[𝑛] + 2𝑦[𝑛 − 1] + 𝑦[𝑛 − 2]} = Ζ{𝑥[𝑛] − 2𝑥[𝑛 − 1]}
4
3
𝑌(𝑧) + 2𝑧 −1 𝑌(𝑧) + 𝑧 −2 𝑌(𝑧) = 𝑋(𝑧) − 2𝑧 −1 𝑋(𝑧)
4
𝑌(𝑧) 1 − 2𝑧 −1
𝐻(𝑧) = =
𝑋(𝑧) 1 + 2𝑧 −1 + 3 𝑧 −2
4
b)
1 − 2𝑧 −1 𝑧2 𝑧 2 − 2𝑧
𝐻(𝑧) = ( 2) =
3 3
1 + 2𝑧 −1 + 𝑧 −2 𝑧 𝑧 2 + 2𝑧 +
4 4
Zeros: 𝑧(𝑧 − 2) = 0 → 𝑧𝑒𝑟𝑜𝑠 𝑎𝑡 𝑧 = 0 & 𝑧 = 2
3 3 1
Poles: 𝑧 2 + 2𝑧 + 4 = 0 → (𝑧 + 2) (𝑧 + 2) = 0
3 1
∴ 2 𝑝𝑜𝑙𝑒𝑠 𝑎𝑡 𝑧 = − &𝑧 =−
2 2
Sketched as:
Page 1 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
Because the system is stable, the ROC must include the unit circle.
1 3
∴ 𝑅𝑂𝐶: < |𝑧| <
2 2
Page 2 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
c) The region of convergence of a causal LTI system extends outward from the largest
magnitude pole. The ROC of the system described by H(z) is shown in the figure below. The
region is |𝑧| > 0.75
Page 3 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
b) It’s a causal system where all the poles are within the unit circle (i.e., the ROC includes the
unit circle), thus, it is BIBO stable.
Solution:
a) Taking the z-transform for both sides:
1 3 1
Ζ {𝑦[𝑛] + 𝑦[𝑛 − 1] − 𝑦[𝑛 − 2]} = Ζ {𝑥[𝑛 − 1] − 𝑥[𝑛 − 2]}
2 16 2
1 −1 3 −2 1
𝑌(𝑧) + 𝑧 𝑌(𝑧) − 𝑧 𝑌(𝑧) = 𝑧 −1 𝑋(𝑧) − 𝑧 −2 𝑋(𝑧)
2 16 2
1 −1 3 −2 1
(1 + 𝑧 − 𝑧 ) 𝑌(𝑧) = (𝑧 −1 − 𝑧 −2 ) 𝑋(𝑧)
2 16 2
1
𝑌(𝑧) 𝑧 −1 − 2 𝑧 −2
𝐻(𝑧) = =
𝑋(𝑧) 1 + 1 𝑧 −1 − 3 𝑧 −2
2 16
b)
Page 4 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
1 1
𝑧 −1 − 2 𝑧 −2 𝑧−2
𝐻(𝑧) = =
1 3 1 3
1 + 2 𝑧 −1 − 16 𝑧 −2 𝑧 2 + 2 𝑧 − 16
1 1
Zeros: 𝑧 − 2 = 0 → 𝑧 = 2
1 3 3 1 3 1
Poles: 𝑧 2 + 2 𝑧 − 16 = 0 → (𝑧 + 4) (𝑧 − 4) = 0 → 𝑧1 = − 4 𝑎𝑛𝑑 𝑧2 = 4
c) It is BIBO stable because all the poles are inside the unit circle.
5. Suppose that Omar uses his cellular phone to call up Ali for a job interview. The call gets
digitized, and Omar’s voice ends up as a discrete-time signal x[n]. Because of interference being
put out by Omar’s microwave and electric kettle, his voice is distorted during transmission so
that the signal 𝑟[𝑛] received by Ali’s phone is not exactly equal to x[n]. In fact, the received
signal is given by:
Since this phone call, you have been hired to design an LTI channel equalizer that will “undo”
the distortion. The equalizer is required to be both causal and stable.
Let 𝐺(𝑧) be the transfer function of the distortion and 𝐻(𝑧) be the transfer function of the
equalizer. The equalizer will be placed in Omar’s phone so that it is in series with the distortion:
a) Find the transfer function of the distortion.
Solution:
Page 5 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
3 3 1
2𝑅(𝑧) = 𝑧 −1 𝑅(𝑧) + 𝑋(𝑧) − 𝑧 −1 𝑋(𝑧) + 𝑧 −2 𝑋(𝑧)
4 4 8
3 −1 3 −1 1 −2
(2 − 𝑧 ) 𝑅(𝑧) = (1 − 𝑧 + 𝑧 ) 𝑋(𝑧)
4 4 8
3 −1 1 −2
𝑅(𝑧) 1 − 4 𝑧 + 8 𝑧
𝐺(𝑧) = =
𝑋(𝑧) 3
2 − 4 𝑧 −1
b) Find the transfer function of the equalizer 𝐻(𝑧) = 1/𝐺(𝑧) so that the signal received by Ali’s
phone will equal 𝑥[𝑛]. Be sure to specify the region of convergence so that the equalizer will
be causal and stable.
Solution:
3 3
1 2 − 4 𝑧 −1 2𝑧 2 − 4
𝐻(𝑧) = = =
𝐺(𝑧) 1 − 3 𝑧 −1 + 1 𝑧 −2 𝑧 2 − 3 𝑧 + 1
4 8 4 8
1 1 1 1
Poles: (𝑧 − 2) (𝑧 − 4) = 0 → 𝑧1 = 2 𝑎𝑛𝑑 𝑧2 = 4
For the system to be causal and stable, the ROC must extend outwards of the maximum pole
and the poles must be inside the unit circle.
1
ROC: |𝑧| > 2
6. A digital filter is described by the difference equation:
𝑦[𝑛] = 0.99𝑦[𝑛 − 1] + 𝑥[𝑛]
a) Find the transfer function
b) Give a pole-zero plot for H(z)
c) Is the filter stable?
Solution:
a) 𝑌(𝑧) = 0.99𝑧 −1 𝑌(𝑧) + 𝑋(𝑧)
(1 − 0.99𝑧 −1 )𝑌(𝑧) = 𝑋(𝑧)
𝑌(𝑧) 1
𝐻(𝑧) = =
𝑋(𝑧) 1 − 0.99𝑧 −1
b)
1 𝑧
𝐻(𝑧) = =
1 − 0.99𝑧 −1 𝑧 − 0.99
Zeros: 𝑧 = 0
Poles: 𝑧 − 0.99 = 0 → 𝑧 = 0.99
c) Yes, poles are inside the unit circle.
7. Using a rectangular window, design an FIR low pass filter using the frequency sampling method
for the following specifications:
• Cutoff frequency = 1500 Hz
• Sampling frequency = 15000 Hz
• Order = 10
Page 6 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
Solution:
𝑓𝐶 1500 1
f𝐶𝑁 = = =
𝑓𝑠 15000 10
𝜋
𝜔𝑐 =
5
ℎ[𝑛] = ℎ𝑑 [𝑛]𝑤[𝑛]
1 𝜋 −𝑗𝜔𝜏 𝑗𝜔𝑛
ℎ𝑑 [𝑛] = ∫ 𝑒 𝑒 𝑑𝜔
2𝜋 −𝜋
1 𝜔𝑐 𝑗𝜔(𝑛−𝜏)
= ∫ 𝑒 𝑑𝜔
2𝜋 −𝜔𝑐
1 𝑒 𝑗𝜔𝑐 (𝑛−𝜏) − 𝑒 −𝑗𝜔𝑐(𝑛−𝜏)
= ( )
2𝜋 𝑗(𝑛 − 𝜏)
sin(𝜔𝑐 (𝑛 − 𝜏))
= , 𝑛≠𝜏
𝜋(𝑛 − 𝜏)
For 𝑛 = 𝜏
sin(𝜔𝑐 (𝑛 − 𝜏)) 𝜔𝑐
lim =
𝑛→𝜏 𝜋(𝑛 − 𝜏) 𝜋
sin(𝜔𝑐 (𝑛 − 𝜏))
𝑛≠𝜏
∴ ℎ𝑑 [𝑛] = 𝜋(𝑛 − 𝜏)
𝜔𝑐
{ 𝑛 = 𝜏}
𝜋
𝑁 10
Where 𝜏 = = =5
2 2
𝜋
sin ( (𝑛 − 5))
5
𝑛≠5
𝜋(𝑛 − 5) 1 0 ≤ 𝑛 ≤ 10
ℎ𝑑 [𝑛] = & 𝑤[𝑛] = { }
𝜋 0 𝑒𝑙𝑠𝑒
( )
5 𝑛 = 5}
{ 𝜋
n h[n] n h[n]
0 0.0 6 0.18709
1 0.0467 7 0.15136
2 0.1009 8 0.1009
3 0.15136 9 0.0467
4 0.18709 10 0.0
5 0.2
8. Using a rectangular window, design an FIR high pass filter using the frequency sampling method
for the following specifications:
• Cutoff frequency = 1000 Hz
• Sampling frequency = 4000 Hz
• Order = 6
Page 7 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
Solution:
𝑓𝐶 1000 1
f𝐶𝑁 = = =
𝑓𝑠 4000 4
𝜋
𝜔𝑐 =
2
ℎ[𝑛] = ℎ𝑑 [𝑛]𝑤[𝑛]
1 𝜋 −𝑗𝜔𝜏 𝑗𝜔𝑛
ℎ𝑑 [𝑛] = ∫ 𝑒 𝑒 𝑑𝜔
2𝜋 −𝜋
−𝜔𝑐 𝜋
1 𝑗𝜔(𝑛−𝜏)
ℎ𝑑 [𝑛] = (∫ 𝑒 𝑑𝜔 + ∫ 𝑒 𝑗𝜔(𝑛−𝜏) 𝑑𝜔)
2𝜋 −𝜋 𝜔𝑐
1 𝑒 −𝑗𝜔𝑐 (𝑛−𝜏) − 𝑒 −𝑗𝜋(𝑛−𝜏) 𝑒 𝑗𝜋(𝑛−𝜏) − 𝑒 𝑗𝜔𝑐(𝑛−𝜏)
= ( + )
2𝜋 𝑗(𝑛 − 𝜏) 𝑗(𝑛 − 𝜏)
1 𝑒 −𝑗𝜔𝑐 (𝑛−𝜏) − 𝑒 𝑗𝜔𝑐(𝑛−𝜏) 𝑒 𝑗𝜋(𝑛−𝜏) − 𝑒 −𝑗𝜋(𝑛−𝜏)
= ( + )
2𝜋 𝑗(𝑛 − 𝜏) 𝑗(𝑛 − 𝜏)
− sin(𝜔𝑐 (𝑛 − 𝜏)) sin(𝜋(𝑛 − 𝜏))
= +
𝜋(𝑛 − 𝜏) 𝜋(𝑛 − 𝜏)
− sin(𝜔𝑐 (𝑛 − 𝜏))
= (𝑏𝑒𝑐𝑎𝑢𝑠𝑒 sin(𝜋(𝑛 − 𝜏)) = 0 𝑓𝑜𝑟 (𝑛 − 𝜏) = 0,1,2, … )
𝜋(𝑛 − 𝜏)
−sin(𝜔𝑐 (𝑛 − 𝜏))
= , 𝑛≠𝜏
𝜋(𝑛 − 𝜏)
For 𝑛 = 𝜏
− sin(𝜔𝑐 (𝑛 − 𝜏)) −𝜔𝑐
lim =
𝑛→𝜏 𝜋(𝑛 − 𝜏) 𝜋
− sin(𝜔𝑐 (𝑛 − 𝜏))
𝑛≠𝜏
∴ ℎ𝑑 [𝑛] = 𝜋(𝑛 − 𝜏)
𝜔𝑐
{ 𝑛 = 𝜏}
𝜋
𝑁 6
Where 𝜏 = =2=3
2
𝜋
−sin (2 (𝑛 − 3))
𝑛≠3
𝜋(𝑛 − 3) 1 0≤𝑛≤6
ℎ𝑑 [𝑛] = & 𝑤[𝑛] = { }
𝜋 0 𝑒𝑙𝑠𝑒
(2)
{ 𝑛 = 3}
𝜋
n h[n] n h[n]
0 0.1061 4 -0.31830
Page 8 of 9
Advanced Digital Systems Tutorial Sheet 6 Solutions S. Nasser, 2022/2023
1 0.0 5 0.0
2 -0.31830 6 0.1061
3 0.5
Page 9 of 9