You are on page 1of 3

# 300069 Digital Signal Processing / 300596 Advanced Signal Processing: Exercise 2

Exercise 2
Problem 3.8
Calculate the DFT of the data sequence {0, 1, 1, 0} and check the validity of your answer
by calculating its IDFT.
Solution
N −1

DFT: X (k ) = ∑ x(n) ⋅ e − j 2πnk / N , k = 0,1,2,...N − 1.
n =0

X (0) = 0 + 1 + 1 + 0 = 2.

X (1) = 0 + e − j 2π / 4 + e − j 4π / 4 + 0 = − j − 1.
X (2) = 0 + e − j 4π / 4 + e − j 8π / 4 + 0 = 0.
X (3) = 0 + e − j 6π / 4 + e − j12π / 4 + 0 = j − 1.
IDFT: x(n) =

1 N −1
∑ X (k ) ⋅ e j 2πnk / N , n = 0,1,2,...N − 1.
N k =0

x(0) = (2 − j − 1 + 0 + j − 1) / 4 = 0.
x(1) = (2 + (− j − 1)e j 2π / 4 + 0 + ( j − 1)e j 6π / 4 ) / 4 = 1.
x(2) = (2 + (− j − 1)e j 4π / 4 + 0 + ( j − 1)e j12π / 4 ) / 4 = 1.
x(3) = (2 + (− j − 1)e j 6π / 4 + 0 + ( j − 1)e j18π / 4 ) / 4 = 0.

Problem 3.15
Calculate the DFT of the date sequence {0, 1, 1, 0} using the decimation-in-time FFT
algorithm. Check the answer with that of Problem 3.8. Compare the numbers of complex
additions and multiplications in the two methods.
Solution
x0 = 0

X 21 (0)

X 11 (0)

X 21 (1)

X 11 (1)

W20
x2 = 1

W40
x1 = 1

X 22 (0)

W20
x3 = 0

JJ Zou, UWS School of Engineering

X 11 (2)

W41
X 22 (1)

X 11 (3)

1/3

X 22 (0) = x1 + W20 x3 = x1 + x3 = 1. X 11 (1) = X 21 (1) + W41 X 22 (1) = X 21 (1) − jX 22 (1) = −1 − j.17 Calculate the FFT of the data sequence {0. Solution x0 = 0 x4 = 1 0 2 0 2 0 2 W x3 = 1 x7 = 0 X 1 ( 0) X 21 (1) X 11 (1) X 1 (1) X 22 (0) W40 X 11 (2) X 1 ( 2) X 22 (1) W41 X 11 (3) X 1 (3) W x1 = 0 x5 = 1 X 11 (0) W x2 = 1 x6 = 0 X 21 (0) 0 2 W JJ Zou. Stage 2 (final result – the DFT of the input sequence) X 11 (0) = X 21 (0) + W40 X 22 (0) = X 21 (0) + X 22 (0) = 2. X 22 (1) = x1 − W20 x3 = x1 − x3 = 1. The above result is the same as that of Problem 3. 1. 0.300069 Digital Signal Processing / 300596 Advanced Signal Processing: Exercise 2 Stage 1 X 21 (0) = x0 + W20 x 2 = x0 + x2 = 1. X 21 (1) = x0 − W20 x2 = x0 − x2 = −1. X 11 (3) = X 21 (1) − W41 X 22 (1) = X 21 (1) + jX 22 (1) = −1 + j. 1. 0}.8) 12 16 Problem 3. X 11 (2) = X 21 (0) − W40 X 22 (0) = X 21 (0) − X 22 (0) = 0. 1. Complex additions Complex multiplications FFT (Problem 3. 0. 1.15) 8 4 DFT (Problem 3.8. The following table compares the numbers of additions and multiplications in the two methods. UWS School of Engineering X 23 (0) X 12 (0) W80 X 1 ( 4) X 23 (1) X 12 (1) W81 X 1 (5) X 24 (0) W40 X 12 (2) W82 X 1 ( 6) X 24 (1) W41 X 12 (3) W83 X 1 (7 ) 2/3 .

X 22 (0) = x 2 + W20 x6 = x 2 + x6 = 1. UWS School of Engineering 3/3 . Stage 3 (Final result – the FFT of the input sequence) X 1 (0) = X 11 (0) + W80 X 12 (0) = X 11 (0) + X 12 (0) = 4. X 22 (1) = x2 − W20 x6 = x2 − x6 = 1. X 1 (6) = X 11 ( 2) − W82 X 12 (2) = X 11 (2) + jX 12 (2) = 0. X 1 (3) = X 11 (3) + W83 X 12 (3) = X 11 (3) + (− 2 / 2 − j 2 / 2) X 12 (3) = −1 + 2 + j. X 11 (1) = X 21 (1) + W41 X 22 (1) = X 21 (1) − jX 22 (1) = −1 − j. X 1 (7) = X 11 (3) − W83 X 12 (3) = X 11 (3) − (− 2 / 2 − j 2 / 2) X 12 (3) = −1 − 2 + j. X 24 (1) = x3 − W20 x7 = x3 − x7 = 1. X 23 (1) = x1 − W20 x5 = x1 − x5 = −1. X 11 (2) = X 21 (0) − W40 X 22 (0) = X 21 (0) − X 22 (0) = 0.300069 Digital Signal Processing / 300596 Advanced Signal Processing: Exercise 2 Stage 1 X 21 (0) = x0 + W20 x 4 = x0 + x4 = 1. X 1 ( 4) = X 11 (0) − W80 X 12 (0) = X 11 (0) − X 12 (0) = 0. X 12 (1) = X 23 (1) + W41 X 24 (1) = X 23 (1) − jX 24 (1) = −1 − j. X 24 (0) = x3 + W20 x7 = x3 + x7 = 1. X 12 (3) = X 23 (1) − W41 X 24 (1) = X 23 (1) + jX 24 (1) = −1 + j. X 23 (0) = x1 + W20 x5 = x1 + x5 = 1. X 21 (1) = x0 − W20 x 4 = x0 − x4 = −1. X 1 (2) = X 11 (2) + W82 X 12 (2) = X 11 (2) − jX 12 (2) = 0. JJ Zou. Stage 2 X 11 (0) = X 21 (0) + W40 X 22 (0) = X 21 (0) + X 22 (0) = 2. X 12 (2) = X 23 (0) − W40 X 24 (0) = X 23 (0) − X 24 (0) = 0. X 1 (5) = X 11 (1) − W81 X 12 (1) = X 11 (1) − ( 2 / 2 − j 2 / 2) X 12 (1) = −1 + 2 − j. X 12 (0) = X 23 (0) + W40 X 24 (0) = X 23 (0) + X 24 (0) = 2. X 11 (3) = X 21 (1) − W41 X 22 (1) = X 21 (1) + jX 22 (1) = −1 + j. X 1 (1) = X 11 (1) + W81 X 12 (1) = X 11 (1) + ( 2 / 2 − j 2 / 2) X 12 (1) = −1 − 2 − j.