0% found this document useful (0 votes)
60 views

Lab.8. DFT and FFT Transforms

The document summarizes the Discrete Fourier Transform (DFT) and how it can be converted to the Fast Fourier Transform (FFT) to reduce the number of computations. The DFT of a discrete signal x(nT) transforms it from the time domain to the frequency domain. It requires N2 complex multiplications and (N-1)N complex additions, making it inefficient for large N. The FFT divides the DFT into two DFTs of size N/2 by separating x(n) into even and odd samples, recursively applying this process to obtain a significant reduction in computations compared to the direct DFT.

Uploaded by

Tsega Teklewold
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
60 views

Lab.8. DFT and FFT Transforms

The document summarizes the Discrete Fourier Transform (DFT) and how it can be converted to the Fast Fourier Transform (FFT) to reduce the number of computations. The DFT of a discrete signal x(nT) transforms it from the time domain to the frequency domain. It requires N2 complex multiplications and (N-1)N complex additions, making it inefficient for large N. The FFT divides the DFT into two DFTs of size N/2 by separating x(n) into even and odd samples, recursively applying this process to obtain a significant reduction in computations compared to the direct DFT.

Uploaded by

Tsega Teklewold
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

Lab.8.

Discrete Fourier Transform (DFT)


and Fast Fourier Transform (FFT)
(Theory and Implementation)
Learning Objectives
 DFT algorithm.
 Conversion of DFT to FFT algorithm.
 Implementation of the FFT algorithm.
DFT Algorithm
 The Fourier transform of an analogue signal
x(t) is given by:

X     x t e  jt
dt


 The Discrete Fourier Transform (DFT) of


a discrete-time signal x(nT) is given by:
N 1 2
j nk
X k    xn e N

n0

 Where: k  0,1, N  1
xnT   xn
DFT Algorithm
j
2 N 1
 If we let: e N
 WN then: X k    xn WNnk
n 0

Sampled signal
2

1
Amplitude

-1

-2
0 20 40 60 80 100 120
Sample
Frequency Domain
1

0.8
Magnitude

0.6

0.4

0.2

0
0 0.1 0.2 0.3 0.4 0.5
Normalised Frequency
DFT Algorithm
N 1
x[n] = input
X k    xn WNnk X[k] = frequency bins
n 0 W = twiddle factors

X(0) = x[0]WN0 + x[1]WN0*1 +…+ x[N-1]WN0*(N-1)


X(1) = x[0]WN0 + x[1]WN1*1 +…+ x[N-1]WN1*(N-1)
:
X(k) = x[0]WN0 + x[1]WNk*1 +…+ x[N-1]WNk*(N-1)
:
X(N-1) = x[0]WN0 + x[1]WN (N-1)*1 +…+ x[N-1]WN (N-1)(N-1)

Note: For N samples of x we have N frequencies


representing the signal.
Performance of the DFT Algorithm
 The DFT requires N2 (NxN) complex
multiplications:
 Each X(k) requires N complex multiplications.
 Therefore to evaluate all the values of the DFT
( X(0) to X(N-1) ) N2 multiplications are
required.
 The DFT also requires (N-1)*N complex
additions:
 Each X(k) requires N-1 additions.
 Therefore to evaluate all the values of the DFT
(N-1)*N additions are required.
Performance of the DFT Algorithm

120 120
Number of Multiplications

Number of Additions
100 100

80 80

60 60
40 40
20 20
0 0
0 1 2 3 4 5 6 7 8 9 10 0 1 2 3 4 5 6 7 8 9 10
Number of Samples Number of Samples

 Can the number of computations required


be reduced?
DFT  FFT
 A large amount of work has been devoted
to reducing the computation time of a DFT.
 This has led to efficient algorithms which
are known as the Fast Fourier Transform
(FFT) algorithms.
DFT  FFT
N 1
X k    xn WNnk ; 0  k  N  1 [1]
n 0

x[n] = x[0], x[1], …, x[N-1]

 Lets divide the sequence x[n] into even


and odd sequences:
 x[2n] = x[0], x[2], …, x[N-2]
 x[2n+1] = x[1], x[3], …, x[N-1]
DFT  FFT
2
 Equation 1 can be rewritten as: e
j
N
 WN
N N
1 1
2 2
X k    x2n  WN2 nk   x2n  1 WN2 n 1k [2]
n0 n0

 Since:
2 2
j 2 nk j nk
WN2 nk  e N
e N 2
WN2 n 1k  W Nk  W Nnk
 W Nnk 2
2

 Then: N
2
1
N
2
1

X k    x2n W Nnk  WNk  x2n  1 W Nnk


n0 2 n 0 2

 Y k   WNk Z k 
DFT  FFT
 The result is that an N-point DFT can be
divided into two N/2 point DFT’s:
N 1
X k    xn WNnk ; 0  k  N  1 N-point DFT
n0

 Where Y(k) and Z(k) are the two N/2


point DFTs operating on even and odd
samples respectively:
N N
1 1
2 2
X k    x1 n W Nnk  WNk 
 2 N
x n W nk
Two N/2-
n0 2 n 0 2 point DFTs
 Y k   WNk Z k 
DFT  FFT
 Periodicity and symmetry of W can be
exploited to simplify the DFT further:
N N
1 1
2 2
X k    x1 n W Nnk  WNk  x2 n W Nnk [3]
n 0 2 n 0 2


N N
1  N 1  N
2 N 2
 N n k   n k  
X  k     x1 n W  x n W
 2 k  2
N  WN 2
2 N
 2  n 0 2 n 0 2
N 2 2 N 2 2
Or: WN
k
2
e
j
N
k
e
j
N 2
e
j
N
k
e  j
 e
j
N
k
 W Nk : Symmetry

N 2 2 N 2
k j k j j k
And: WN 2
e N 2
e N 2 2
e N 2
 W Nk : Periodicity
2 2
DFT  FFT
 Symmetry and periodicity:

W86
W85 W87
WNk+N/2 = -WNk
WN/2k+N/2 = WN/2k
W84 W80 = W88
W8k+4 = -W8k
W8k+8 = W8k
W83 W81 = W89
W82
DFT  FFT
 Finally by exploiting the symmetry and
periodicity, Equation 3 can be written as:
N N
1 1
2 2
 N
X k     x1 nW Nnk  WNk  x2 nW Nnk
 2 n 0 2 n0 2
[4]
 Y k   W Nk Z k 
DFT  FFT
N 
X k   Y k   WNk Z k ;
k  0,    1
2 
 N N 
X  k    Y k   W N Z k ; k  0,   1
k

 2 2 

 Y(k) and WNk Z(k) only need to be


calculated once and used for both
equations.
 Note: the calculation is reduced from 0 to
N-1 to 0 to (N/2 - 1).
DFT  FFT
N 
X k   Y k   WNk Z k ;
k  0,    1
2 
 N N 
X  k    Y k   W N Z k ; k  0,   1
k

 2 2 

 Y(k) and Z(k) can also be divided into N/4


point DFTs using the same process shown
above:
Y k   U k   W Nk V k  Z k   Pk   W Nk Qk 
2 2

 N  N
Y  k    U k   W Nk V k  Z  k    Pk   W Nk Q k 
 4 2  4 2

 The process continues until we reach 2


point DFTs.

You might also like