Professional Documents
Culture Documents
This Is A CLOSED BOOK Examination: Department of Electrical and Computer Engineering Examination
This Is A CLOSED BOOK Examination: Department of Electrical and Computer Engineering Examination
Venue ____________________
ETEN3000 Digital Signal Processing
Student Number |__|__|__|__|__|__|__|__|
EXAMINATION
End of Semester 1, 2017
2
Total Marks 100
3
Supplied by the University
4
1 x 16 page answer book
5
Formula sheet (separate to exam paper)
6
Materials 9
10
None
11
Calculator
12
A non-programmable calculator is permitted in this exam
13
Instructions to Students
14
17
18
Total ________
End of Semester 1, 2017
ETEN3000 Digital Signal Processing
X c ( jw )
1
-wo 0 wo w
Suppose xc (t ) is sampled at ws < 2wo such that the spectrum of the sampled signal
contains aliased components. These aliased components can be removed in discrete-
time by the ideal low pass filter
ïì1, q < qc
H (e jq ) = ïí
ïïî0, otherwise
If ws = 60p and wo = 40p , determine the maximum value of qc such that as much
as possible of the un-aliased signal components are retained. (8 Marks)
(b) A causal LTI system with input x[n] and output y[n] is described by the following
LCCDE
y[n] = 3
2
y[n -1] + y[n - 2] + x[n -1]
Page 1 of 5
End of Semester 1, 2017
ETEN3000 Digital Signal Processing
(a) A Type I linear phase highpass FIR filter with 7 taps is to be designed using the
window method.
Suppose the cutoff frequency of the ideal highpass filter is qc = 0.4p , design the filter
using the Bartlett window and list the 7 filter coefficients. (9 Marks)
(b) A digital bandstop filter with the following design specification is to be realised as a
linear phase FIR filter. Suppose the frequency response of the filter is to have the form
H ( e jq ) = A(q ) e- j M q 2
H ( e jq )
1 + d1 1 + d3
1
1 - d1 1 - d3
d2
p q
0 q1 q2 q3 q4
d1 = d2 = 0.1, d3 = 0.14
(ii) Comment on the likelihood that your window will lead to a design that meets the
design specification. (2 Marks)
Page 2 of 5
End of Semester 1, 2017
ETEN3000 Digital Signal Processing
A digital lowpass filter with the following design specification is to be realised as an IIR
filter.
Stop-band attenuation: ³ 20 dB
Pass-band deviation: £ 1.5 dB
Pass-band edge: 0.3p
Stop-band edge: 0.75p
(b) Determine the transfer function H(z) of the corresponding digital IIR filter. Present
your answer in the form
b0 + b1z-1 + + bM z-M
H ( z) =
1 + a1z-1 + + aN z-N
where M and N are some positive integers and a1, , aN , b0 , , bM are real
constants. (4 Marks)
(c) Draw the Direct Form I block diagram of the IIR filter. (3 Marks)
Page 3 of 5
End of Semester 1, 2017
ETEN3000 Digital Signal Processing
4 x [n] = {7, 3, 0, 4}
3
y[n] = x1[n] 2 n=0
}n=0 .
7
x[n ] = {1, -1, 1 , 1, 0, -1, 0, 2
2
Page 4 of 5
End of Semester 1, 2017
ETEN3000 Digital Signal Processing
(a) Use the 4-point DFT/FFT and 4-point IDFT/IFFT, and the overlap-add method to find
the linear convolution w[n] = x[n] * y[n] where (17 Marks)
(b) The power spectrum of a discrete-time signal is to be estimated using the Welch
method with Hamming window and 50% overlap. Suppose the periodograms of the
Welch method are to be computed with the radix-2 Cooley-Tukey FFT algorithm.
(ii) Suppose the number of samples N acquired is large. Explain why it is not
advantageous to increase L beyond the value obtained in Part (b)(i). (6 Marks)
Page 5 of 5
SOLUTIONS
Question 1
2p
Now qc = wc ⋅ T = wc ⋅
ws
Therefore, we require
2p 2p
qc < 20p ⋅ =
60p 3
X s ( jw )
H ( jw )
w
0 wc 40p 60p
wo w s
w1 = w s - wo
qc < q1
where q1 = qs - qo = 2p - woT
2p 2p 4
Now woT = wo ⋅ = 40p ⋅ = p
ws 60p 3
Therefore, we require
4 2
qc < 2p - p = p
3 3
q
-2p 0 qc qo 2p 4p
qs
q1 = qs - qo
z-1 z2 z
H ( z) = ⋅ =
(1 - 2 z-1 )(1 + 1 z -1 )
2
z2 ( z - 2)( z + 12 )
2 2
H ( z) = 5
- 5
1 - 2 z -1 1 + 12 z-1
n
\ h[n] = ( 52 ) 2n u[n] - ( 52 )(- 12 ) u[ n]
ì 2n ,
ï 0 £ n £ M2 ïì n, 0£n£3
ï
ï M ï
ï 3
ï ï
and w[n] = í2 - 2Mn , M2 £ n £ M = í2 - n3 , 3 £ n £ 6
ï
ï ï
ï
ï
ï0, otherwise ï
ï
ï
î î0,
ï otherwise
n 0 1 2 3 4 5 6
hd [ n] 0.0624 -0.0935 -0.3027 0.6 -0.3027 -0.0935 0.0624
w[ n] 0.0 0.3333 0.6667 1.0 0.6667 0.3333 0.0
h[n] = hd [n] w[n] 0.0 -0.0312 -0.2018 0.6 -0.2018 -0.0312 0.0
(bi) The filter is required to be Type I or Type II. The tightest transition width is given by
Now, since
width of lower passband = 2´q1 = 0.4p > Dq
width of stopband = q3 - q2 = 0.7p - 0.4p = 0.3p > Dq
width of upper passband = 2´(p - q4 ) = 2´(p - 0.9p ) = 0.2p = Dq
\ d = min {d1, d2 ; d2 , 1d
2 3 } = min {0.1, 0.1; 0.1, } = 0.07
0.14 ,
2
é A-8 ù é 23.0980 - 8 ù
and M = ê ú = ê ú = êé10.5161úù = 11
êê 2.285 Dq úú ê 2.285 ⋅ 0.2p ú
This results in a Type II filter which, according to the design matrix in pp. 14 of the
Attachment, is not suitable for a bandstop filter. We thus increase M to 12 to obtain
a Type I filter which is now suitable.
(bii) Kaiser claims the design will yield an M that is within 2 of the required value.
Question 3
Stop-band attenuation: ³ 20 dB
Pass-band deviation: £ 1.5 dB
Pass-band edge: w1 = 2 tan ( 0.32 p ) = 1.01905
Stop-band edge: w2 = 2 tan ( 0.75
2 )
p = 4.82843
20log10 a2 = - 20 a2 = 0.1 = g 2
é
ê 1 log
ê
N = ê
1- g12 g22
⋅
1- g22 g12( )ùúú = é1.7615ù = 2
ú ê ú
êê 2 log w12
w
( ) úú
and the N = 2 stable and causal poles of H c ( s) are located at
whereupon H c ( s) is given by
1 1 s0 s1 s0 s1
H c ( s) = s
⋅ s
= = 2
1- s0
1- s1
( s - s0 )( s - s1 ) s - ( s0 + s1 ) s + s0 2
wc2
=
s2 + 2wc s + wc2
Sem 1 Exam, 2017 – Solutions 4
We now determine the cut-off frequency wc . We require, at w = w1
1
4
³ g12
1 + (w1 wc )
Likewise, at w = w2 we require
1
4
£ g 22
1 + (w2 wc )
w2
i.e. wc £ 1
= 1.53072
ëê( 2 )
é 1 g 2 - 1ù 4
ûú
Finally, suppose
1.27154 + 1.53072
wc = = 1.40113
2
1.96317
Then H c (s) = 2
s + 1.9815s + 1.96317
H ( z ) = H c (s) 1 - z-1
s= 2
1 + z-1
wc2
=
( ) ( )+w
2
- z -1 - z -1
21 -1 + 2 wc 2 1 2
c
1+ z 1 + z-1
wc2 (1 + z-1 ) 2
=
(4 + 2 2wc + wc2 ) + (-8 + 2wc2 ) z-1 + (4 - 2 2wc + wc2 ) z-2
ì
ï 0.2(1 + 2 z-1 + z-2 )
ï
ï , wc = 2
ï
ï 1 - 0.4 z-1 + 0.2 z-2
ï
ï
ï
ï 0.2143(1 + 2 z-1 + z-2 )
=ï
í , wc = 1.5
ï
ï1 - 0.3336 z -1
+ 0.1913 z -2
ï
ï
ï
ï
ï 0.197777(1 + 2 z-1 + z-2 )
ï , wc = 1.40113
ï
ï - z -1
+ z -2
î1 0.410396 0.201505
(c) The Direct I form block diagram of H ( z ) , for wc = 2 , is shown below. The block
diagram for wc = 1.5 and wc = 1.40113 can be drawn similarly.
0.2
x[n] y[n]
z -1 z -1
0.4 0.4
z -1 z -1
0.2 -0.2
(a) It can be shown, using for example the table method with the periodic extension of one
of the sequences, that
{ }n=0
2 2 2 3
4 x [ n ] = 1 + a + 2 a , -1 + a , - 2 a - a , 2 - a
x1[ n] 2
Therefore, we require
1 + a + 2a 2 = 7
-1 + a 2 = 3
-2a - a 2 = 0
and 2-a = 4
The last equation indicates that, if it exists, a can only equal -2. We next substitute
a = -2 into the first 3 equations and find they all hold. Accordingly, one can conclude
there exists a solution, that solution is unique, and is given by a = -2.
⋅ wH [ n ] = {0, 2, 2, 0}
3
w[ n ] = 4
0 2
+( 34 ) 2 +( 34 ) 2 +0 2 n= 0
Following the steps outlined in the Attachment, we begin with the following table.
n 0 1 2 3 4 5 6 7
1
x[n] 1 -1 2
1 0 -1 0 2
1
x(1) [n] 1 -1 2
1
1
x (2) [ n] 2
1 0 -1
x (3) [n] 0 -1 0 2
We next window the sub-sequences x(1) [n] , x (2) [ n] and x (3) [n] , and compute their
modified periodograms. However, since we want a frequency resolution of 2p 8 , we
must first zero-pad the windowed sub-sequences to 8 points. Thus
x(1) [n]w[n] 0 - 2 1 0 0 0 0 0
X (1) [i ]
1- 2 -1 -1 + j 2 1+ j2 1+ 2 1- j2 -1- j 2 -1
= DFT { x (1) [n ]w[n ]}
j 28p i 2 3- 1 1 3 5 3 + 1 5 3 1
PW(1) (e ) = 14 X (1) [i ] 4 2 4 4 4 4 2 4 4 4
x (2) [n]w[n] 0 2 0 0 0 0 0 0
X (2) [i ]
2 1- j -j 2 -1 - j - 2 -1 + j j 2 1+ j
= DFT { x (2) [n ]w[n ]}
j 28p i 2 1 1 1 1 1 1 1 1
PW(2) (e ) = 14 X (2) [i ] 2 2 2 2 2 2 2 2
k =3 x (3) [n] 0 -1 0 2
x(3) [n]w[n] 0 - 2 0 0 0 0 0 0
X (3) [i ]
- 2 -1 + j j 2 1+ j 2 1- j -j 2 -1 - j
= DFT { x (3) [n ]w[n ]}
j 28p i 2 1 1 1 1 1 1 1 1
PW(3) (e ) = 14 X (2) [i ] 2 2 2 2 2 2 2 2
j 28p i
PW(1) ( e ) 3- 1
4
1
4
3
4
5
4
3+ 1
4
5
4
3
4
1
4
2 2
j 28p i
PW(2) ( e ) 1
2
1
2
1
2
1
2
1
2
1
2
1
2
1
2
j 28p i
PW(3) ( e ) 1
2
1
2
1
2
1
2
1
2
1
2
1
2
1
2
j 2p i
SˆW (e 8 ) = 7 - 1
12 3 2
5
12
7
12
9
12
7 + 1
12 3 2
9
12
7
12
5
12
1
3 {PW(1) + PW(2) + PW(3) } 0.3476 0.4167 0.5833 0.7500 0.8190 0.7500 0.5833 0.4167
Examiner’s Note: Students are expected to show side calculations in the script, an
example of which is as follows where a = (1- j ) 2 .
é X (1) [0]ù é .1 1 1 ùú é - 2 +1 ù
ê ú ê 1 1 1 1 1
é 0 ù ê ú é 1- 2 ù
ê (1) ú ê ú
* ê ú ê ú ê ú
ê X [1] ú ê .1 a - j -a* -1 -a j a úê ú ê -a 2 - j ú ê -1 ú
ê ú ê ú ê- 2 ú ê ú ê ú
ê X (1) [2]ú ê. j úú ê 1 ú ê j 2 -1 ú ê ú
ê ú ê 1 -j -1 j 1 -j -1
ê ú ê ú ê-1 + j 2 ú
ê (1) ú ê. úê ú ê * ú ê ú
ê X [3]ú ê 1 -a* j a -1 a* -j -a ú ê 0 ú ê a 2+ j ú ê 1+ j2 ú
ê ú = ê úê ú = ê ê
ú = ê ú
ê X (1) [4]ú ê. -1 úú ê 0 ú ê + ú + ú
ê ú ê 1 -1 1 -1 1 -1 1
ê ú ê 2 1 ú ê 1 2 ú
ê (1) ú ê. *ú ê 0 ú ê ú ê ú
ê X [5]ú ê 1 -a -j a *
-1 a j -a ê ú ú ê a 2 - j ú ê 1 - j 2 ú
ê ú ê úê 0 ú ê ú ê ú
ê X (1) [6]ú ê .1 ê-1- j 2 ú
ê ú ê j -1 -j 1 j -1 - j úú ê ú ê - j 2 -1 ú
ê ú ê ú
ê (1) ú ê. * * ú êë 0 úû ê * ú ê -1 ú
ë û
êë X [7]úû ëê 1 a j -a -1 -a -j a ûú ëê-a 2 + j ûú
(i) Clearly, x[n] is shorter than y[n]. Therefore, P = 2 and Q = 6. Also, for 4-point
DFT/IDFTs, N = 4.
(iii) To compute the “full” N-point linear convolutions of x[n] with segments of y[n],
we require the segments of y[n] to have length L = N – P + 1 = 4 – 2 + 1 = 3.
(iv) y[n] has length Q = 6. Therefore, there are R = êéQ Lúù = êé6 3ùú = 2 segments.
(v) We zero pad y[n] to RL = 2 ´ 3 = 6 points. But y[n] already has 6 point. Therefore,
zero-padding is not required, and its two 3-point segments are given by
y0[n] = {1, 0, - 2}
(vi) The remaining steps are summarised by the following table, where Yrzp [k ] =
DFT { yrzp [n ]} , and wr [n] = IDFT { X zp [k ]Yrzp [k ]} .
n 0 1 2 3 4 5 6
y0zp [n] 1 0 -2 0
Y0zp [k ] -1 3 -1 3
X zp [k ] ⋅ Y0zp [k ] 0 3+j3 -2 3-j3
w0 [ n ] 1 -1 -2 2
y1zp [ n - L ] 0 1 -1 0
Y1zp [k ] 0 1-j -2 1+j
X zp [k ] ⋅ Y1zp [k ] 0 2 -4 2
w1[n - L] 0 1 -2 1
w[ n] 1 -1 -2 2 1 -2 1
(bi) The Welch method uses a length L Hamming window. Since we require the main-
lobe width of this window to be less than 0.01 cycles/sample, i.e.,
8p
Dml = £ 2p ´ 0.01 rad/sample
L -1
we get
8p
L³ + 1 = 401
2p ´ 0.01
But L must be an integer power of 2. Thus, L = 512 .
(bii) Increasing L will increase spectral resolution but we already have enough resolution.
Indeed, increasing L will reduce the number of segments K which in turn will
increase the variance of the estimate.