0% found this document useful (0 votes)
100 views25 pages

Fast Fourier Transform (FFT)

The document discusses the Fast Fourier Transform (FFT) algorithm. It explains that FFT exploits computational savings over the direct evaluation of the Discrete Fourier Transform (DFT) by reducing the time complexity from O(N^2) to O(NlogN). The FFT algorithm divides the DFT computation into multiple stages of smaller DFTs, combining the outputs in an efficient manner using symmetry properties. The main FFT algorithms are decimation-in-time and decimation-in-frequency, with decimation-in-time explained through an 8-point DFT example.

Uploaded by

vinayak masta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
100 views25 pages

Fast Fourier Transform (FFT)

The document discusses the Fast Fourier Transform (FFT) algorithm. It explains that FFT exploits computational savings over the direct evaluation of the Discrete Fourier Transform (DFT) by reducing the time complexity from O(N^2) to O(NlogN). The FFT algorithm divides the DFT computation into multiple stages of smaller DFTs, combining the outputs in an efficient manner using symmetry properties. The main FFT algorithms are decimation-in-time and decimation-in-frequency, with decimation-in-time explained through an 8-point DFT example.

Uploaded by

vinayak masta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 25

Fast Fourier Transform

(FFT)

Dr. Ajay Singh Raghuvanshi


Electronics & Telecommunication
Engineering, NIT, Raipur
FFT (Fast Fourier Transform)
 Algorithms that exploit computational savings are
collectively called Fast Fourier Transforms or FFT
 Fast Fourier transform proposed by Cooley and Tukey in
1965.
 The fast Fourier transform is a highly efficient procedure
for computing the DFT of a finite series and requires less
number of computations than that of direct evaluation of
DFT
 In 1969, the 2048 point analysis of a seismic trace took
13 ½ hours. Using the FFT, the same task on the same
machine took 2.4 seconds!

02/10/2023 Dr Ajay Singh Raghuvanshi 2


Recall Discrete Fourier Transform: DFT
IDFT DFT
1 N 1 N 1
x[n]   Xk e j2  / Nkn Xk    x[n]e  j2  / N kn

N k 0 n0

Computational complexity of DFT:


Each DFT coefficient requires
N complex multiplications
N-1 complex additions
All N DFT coefficients require
N2 complex multiplications
N(N-1) complex additions
 Complexity in terms of real operations
4N2 real multiplications
2N(N-1) real additions

02/10/2023 Dr Ajay Singh Raghuvanshi 3


N 1
X k   x[n]e  j 2kn / N , k  0, 1, ..., N  1
n 0

1 N 1
x[n] 
N
 k
X
k 0
e j 2kn / N
, n  0, 1, ..., N  1
 j 2 / N
To simplify notations, lets define twiddle factor W N  e
N 1
X k   x[n]W Nkn , k  0, 1, ..., N  1
n 0

1 N 1
x[n] 
N
 k N , n  0, 1, ..., N  1
X W
k 0
 kn

Nth root of unity


 j 2 / N  j 2 /( N / 2 )  j 4 / N 2
WN  e W( N / 2)  e e W N

(WN )  W N
N
N
 e 
 j 2 / N N
 e  j 2  1
02/10/2023 Dr Ajay Singh Raghuvanshi 4
Most fast methods are based on symmetry properties
Conjugate symmetry
 j2  / N k N  n   j2  / N kN
e e e  j2  / Nk n  e j2  / Nkn
W   e
kn *
N
 j 2kn / N *
 e j 2kn / N
 W  kn
N

Periodicity in n
 j2  / N kn  j2  / N k n  N  j2  / N k  N n
e e e
kn k ( n N ) kn N
W N  WN  WN .WN As
(WN )  WN
N
N
 e   j 2 / N N
 e  j 2
1
kn k ( n N ) n(k  N )
W N W N W N
02/10/2023 Dr Ajay Singh Raghuvanshi 5
FFT Algorithms
 Note that two length N/2 DFTs take less
computation than one length N DFT:
2(N/2)2<N2
 There are basically two types of FFT
Algorithms and one hardware implementation
Decimation in Time
Decimation in frequency
The Goertzel Algorithm

02/10/2023 Dr Ajay Singh Raghuvanshi 6


Decimation-In-Time FFT Algorithms
 Makes use of both symmetry and periodicity
 Consider special case of N an integer power of 2
 Separate x[n] into two sequence of length N/2
N 1 N 1 N 1
Xk    x[n]e  j2  / N kn
  x[n]e  j2  / N kn
  x[n]e  j2  / N kn

n0 n even n odd

 Even indexed samples in the first sequence


 Odd indexed samples in the other sequence
N / 2 1 N / 2 1
X k    x[2r ]W 2 rk
N   x[2r  1]W  N
2 r 1k

r 0 r 0
N / 2 1 N / 2 1
G[k] and H[k] are
the N/2-point DFT’s
  x[2r ]W
r 0
rk
N /2  WNk  x[2r  1]W
r 0
rk
N /2
of each
 Gk  WNk H k  subsequence
02/10/2023 Dr Ajay Singh Raghuvanshi 7
N
X k   Gk  WNk H k  and usi ngsymtry
2
 N N
X k    Gk  WNk H k  for k  0,1,...  1
 2 2

02/10/2023 Dr Ajay Singh Raghuvanshi 8


8-point DFT example using
decimation-in-time
Two N/2-point DFTs
2(N/2)2 complex
multiplications
2(N/2)2 complex additions
Combining the DFT outputs
N complex multiplications
N complex additions
Total complexity
N2/2+N complex
multiplications
N2/2+N complex additions
More efficient than direct DFT
Repeat same process
Divide N/2-point DFTs into
Two N/4-point DFTs
Combine outputs

02/10/2023 Dr Ajay Singh Raghuvanshi 9


 After two steps of decimation in time

 Repeat until we’re left with two-point DFT’s

02/10/2023 Dr Ajay Singh Raghuvanshi 10


02/10/2023 Dr Ajay Singh Raghuvanshi 11
• If N is a power of 2 (e.g., N = 2q), we can repeat this process to further reduce
the computations. The overall complexity reduces from N2 to (Nlog2N)/2.

02/10/2023 Dr Ajay Singh Raghuvanshi 12


Bit Reversing
• Note that the inputs have been shuffled so
that the outputs are produced in the
correct order.
• This can be represented as a bit-reversing
process:

Time Point Binary Reversed- Order


Word Bit Word
(n)
0 000 000 x[0]

1 001 100 x[4]

2 010 010 x[2]

3 011 110 x[6]

4 100 001 x[1]

5 101 101 x[5]

6 110 011 x[3]

7 111 111 x[7]


02/10/2023 Dr Ajay Singh Raghuvanshi 13
02/10/2023 Dr Ajay Singh Raghuvanshi 14
8-point DFT example using decimation-in-time
Two N/2-point DFTs
 2(N/2)2 complex multiplications
 2(N/2)2 complex additions
Combining the DFT outputs
 N complex multiplications
 N complex additions
Total complexity
 N2/2+N complex multiplications and N2/2+N complex
additions in first step
Repeat same process
 Divide N/2-point DFTs into Two N/4-point DFTs
 Combine outputs
 Hence computation results in N log2N complex
multiplications and additions
02/10/2023 Dr Ajay Singh Raghuvanshi 15
Decimation-in-frequency FFT algorithm
The decimation-in-time FFT algorithms are all based on
structuring the DFT computation by forming smaller and smaller
subsequences of the input sequence x[n]. Alternatively, we can
consider dividing the output sequence X[k] into smaller and
smaller subsequences in the same manner.
N 1
X [k ]   x[n]WNnk k  0,1,..., N  1
n 0

The even-numbered frequency samples are

N 1 ( N / 2 ) 1 N 1
X [2r ]   x[n]W n(2r )
N   x[n]W n(2r )
N   x[ n ]W n(2r )
N
n 0 n 0 n ( N / 2)

( N / 2 ) 1 ( N / 2 ) 1
X [ 2r ]   x[
n 0
n ]W 2 nr
N   x[
n 0
n  ( N / 2)]W 2 r ( n  ( N / 2 ))
N
Since
WN2 r [ n  ( N / 2)]  WN2 rnWNrN  WN2 rn
2
and WN  WN / 2
( N / 2 ) 1
X [ 2r ]   ( x
n 0
[ n ]  x[ n  ( N / 2 )])W rn
N /2 r  0,1,..., ( N / 2)  1

The above equation is the (N/2)-point DFT of the (N/2)-point


sequence obtained by adding the first and the last half of the
input sequence.
Adding the two halves of the input sequence represents time
aliasing, consistent with the fact that in computing only the even-
number frequency samples, we are sub-sampling the Fourier
transform of x[n].
We now consider obtaining the odd-numbered frequency points:
N 1 ( N / 2 ) 1 N 1
X [2r  1]   x[n]WNn ( 2 r 1)   x[ n ]W n ( 2 r 1)
N   x[ n ]W n ( 2 r 1)
N
n0 n 0 n ( N / 2 )

Since

N 1 ( N / 2 ) 1

 x[ n
n N / 2
]W n ( 2 r 1)
N   x[
n 0
n  ( N / 2 )]W ( n  N / 2 )( 2 r 1)
N

( N / 2 ) 1
 WN( N / 2 )( 2 r 1)  x[
n 0
n  ( N / 2)]
W n ( 2 r 1)
N

( N / 2 ) 1
  x[
n 0
n  ( N / 2)]
W n ( 2 r 1)
N
We obtain
( N / 2 ) 1
X [2r  1]   ( x
n 0
[ n ]  x[ n  N / 2])W n ( 2 r 1)
N

( N / 2 ) 1
  ( x
n 0
[ n ]  x[ n  N / 2])W n
N W nr
N /2 r  0,1,..., ( N / 2)  1

The above equation is the (N/2)-point DFT of the sequence


obtained by subtracting the second half of the input sequence
from the first half and multiplying the resulting sequence by
WNn.

Let g[n] = x[n]+x[n+N/2] and h[n] = x[n]x[x+N/2], the DFT can


be computed by forming the sequences g[n] and h[n], then
computing h[n] WNn, and finally computing the (N/2)-point DFTs
of these two sequences.
Flow graph of decimation-in-frequency decomposition of an N-
point DFT (N=8).
Recursively, we can further decompose the (N/2)-point DFT
into smaller substructures:
Butterfly structure for decimation-in-frequency FFT algorithm:

The decimation-in-frequency FFT algorithm also has the


computation complexity of O(N log2N)
Finally, we have
Decimation-In-Frequency FFT Algorithm
 Final flow graph for 8-point decimation in frequency

02/10/2023 Dr Ajay Singh Raghuvanshi 24


The comparison of DIT and DIF

 The order of samples


 DIT-FFT: the input is bit- shuffled order and
the output is natural order
 DIF-FFT: the input is natural order and the
output is bit shuffled order
 The butterfly computation
 DIT-FFT: multiplication is done before
additions
 DIF-FFT: multiplication is done after additions

02/10/2023 Dr Ajay Singh Raghuvanshi 25

You might also like