13
Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

  • View
    235

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Fast Fourier Transform (FFT) (Section 4.11)

CS474/674 – Prof. Bebis

Page 2: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

DFT – Time Complexity

• How much time does DFT take?

u=0,1,2,...,N-1

O(N2) time

Page 3: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Fast Fourier Transform (FFT)

• FFT takes O(NlogN) time (assumes N=2n)

Page 4: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Deriving FFT

• Assume that N=2n and let

• Since N=2n, there exist M such that N=2M

u=0,1,2,...,N-1

Page 5: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Deriving FFT (cont’d)

• Note that:

• Therefore:

or

Page 6: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Deriving FFT (cont’d)

• How can we compute F(u) for u=M,M+1,…,2M-1?

• Note that

x

Page 7: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Deriving FFT (cont’d)

• Thus:

Page 8: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Deriving FFT (cont’d)

• Therefore, an N-point transform can be computed using two N/2-point transforms!

• Similarly, each N/2-point transform can be computed

using two N/4-point transforms etc.

Page 9: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Example

Page 10: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Example (cont’d)

Page 11: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Implementation Details

• The input must be provided in the required order at each level

f(0) f(1) f(2) f(3) f(4) f(5) f(6) f(7)

required order

original order

Page 12: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Implementation Details (cont’d)

• Bit-wise reversal rule:

Page 13: Fast Fourier Transform (FFT) (Section 4.11) CS474/674 – Prof. Bebis

Inverse FFT

• The inverse FFT can be computed using the same implementation– Use a flag for the sign of the exponential

– Use F(u) instead of f(x)

– Multiply by N

Forward DFT Inverse DFT