unit - 3: fast-fourier-transform (fft) algorithms[ · fast fourier transform algorithms...

100
UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?] Dr. Manjunatha. P [email protected] Professor Dept. of ECE J.N.N. College of Engineering, Shimoga October 15, 2014

Upload: lytruc

Post on 19-May-2019

361 views

Category:

Documents


18 download

TRANSCRIPT

Page 1: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

UNIT - 3: Fast-Fourier-Transform (FFT)algorithms[?, ?, ?, ?]

Dr. Manjunatha. [email protected]

ProfessorDept. of ECE

J.N.N. College of Engineering, Shimoga

October 15, 2014

Page 2: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Unit 3 Syllabus Introduction

Digital Signal Processing: [?, ?, ?, ?]

Slides are prepared to use in class room purpose, may be used as areference material

All the slides are prepared based on the reference material

Most of the figures/content used in this material are redrawn, someof the figures/pictures are downloaded from the Internet.

This material is not for commercial purpose.

This material is prepared based on Digital Signal Processing forECE/TCE course as per Visvesvaraya Technological University (VTU)syllabus (Karnataka State, India).

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 2 / 100

Page 3: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Unit 3 Syllabus

Unit 3 Syllabus

PART - A

UNIT - 3: Fast-Fourier-Transform (FFT) algorithms

Fast-Fourier-Transform (FFT) algorithms.

Direct computation of DFT.

Need for efficient computation of the DFT (FFT algorithms)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 3 / 100

Page 4: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

Fast Fourier Transform Algorithms

This unit provides computationally efficient algorithms for evaluating the DFT.

Direct computation of DFT has large number addition and multiplication operations.

The DFT has the various applications such as linear filtering, correlation analysis, andspectrum analysis.

Hence an efficient computation of DFT is an important issue in DSP.

There are two different approaches in computing efficient DFT, those are:

1 Divide and Conquer approach2 DFT as Linear filtering.

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 4 / 100

Page 5: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

Computation ofDFT

DIT DFTAlgorithm

Radix-2FFT

Algorithm

DFT as LinearFiltering

Divide andConquerApproach

Radix-4FFT

Algorithm

Split-RadixFFT

Algorithm

Chirp-ZTransformAlgorithm

DIF DFTAlgorithm

GoertzelAlgorithm

Figure 1: FFT Algorithms

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 5 / 100

Page 6: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

Computational complexity of DFT

Direct Computation of DFT

DFT expression is

X (k) =

N−1∑n=0

x(n)W knN k = 0, 1, . . . ,N − 1

IDFT expression is

x(n) =1

N

N−1∑k=0

X (k)W −knN n = 0, 1, . . . ,N − 1

X (k) = x(0)W 0N + x(1)W k

N + x(2)W 2kN , . . . ,+x(N − 1)W

(N−1)kN

For each value of k there are N complex multiplications and N − 1 additions.

Number of complex multiplications required to calculate X (k) is N × N = N2.

Number of complex additions required to calculate X (k) is (N − 1)× N = N2 − N.

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 6 / 100

Page 7: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

Direct Computation of DFT for complex valued sequence x(n) (To determine number of realmultiplications, real additions and trigonometric functions)Let the sequence x(n) be of complex valued and is expressed as

x(n) = xR (n) + jxI (n)

Its DFT isX (k) = XR (k) + jXI (k)

X (k) =

N−1∑n=0

x(n)e−j 2πN

kn

=

N−1∑n=0

[xR (n) + jxI (n)]e−j 2πN

kn

=

N−1∑n=0

[xR (n) + jxI (n)]

[cos

(2π

Nkn

)− jsin

(2π

Nkn

)]

=

N−1∑n=0

[xR (n)cos

(2π

Nkn

)+ xI (n)sin

(2π

Nkn

)]

−j

N−1∑n=0

[xR (n)sin

(2π

Nkn

)− xI (n)cos

(2π

Nkn

)]

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 7 / 100

Page 8: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

X (k) =

N−1∑n=0

[xR (n)cos

(2π

Nkn

)+ xI (n)sin

(2π

Nkn

)]

−j

N−1∑n=0

[xR (n)sin

(2π

Nkn

)− xI (n)cos

(2π

Nkn

)]

There are 4 Real multiplications and 2 real additions.

For each value of k there are 4N real multiplications and 2(N-1) real additions.

For complete DFT evaluation there are 4N.N = 4N2 real multiplications

For complete DFT evaluation there are X (k) 2(N − 1)N = 2N(N − 1) real additions.

There are 2 trigonometric functions are there in the above equation.

For each value of k there are 2N trigonometric functions are executed.

For complete DFT evaluation there are 2N.N = 2N2 trigonometric functions are executed.

Consider a two complex numbers (a+jb) and (c+jd), ”+” symbol is used represent thecomplex number, and addition of these complex number is:

(a + c) + j(b + d)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 8 / 100

Page 9: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

Periodicity PropertyW k+N

N = W kN

Proof:

WN = e−j 2πN

W k+NN = e−j 2π

N(k+N)

W k+NN = e−j 2π

N(k+N)

= e−j 2πN

k .e−j2π

= e−j 2πN

k .1

Since e−j2π = cos2π − jsin2π = 1

W k+NN = e−j 2π

Nk

= [e−j 2πN ]k

= W kN

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 9 / 100

Page 10: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

Symmetry Property

Wk+N/2N = −W k

N

Proof:

WN = e−j 2πN

Wk+N/2N = e−j 2π

N(k+N/2)

= e−j 2πN

k .e−jπ

= e−j 2πN

k .1

Since e−jπ = cosπ − jsinπ = −1

Wk+N/2N = e−j 2π

Nk .(−1)

= [e−j 2πN ]k

= −W kN

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 10 / 100

Page 11: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

Fast Fourier Transform Algorithms Introduction

W 2N = WN/2

Proof:

WN = e−j 2πN

WN/2 = e−j 2π

N/2

= [e−j 2πN ]2

= W 2N

ThereforeW 2

N = WN/2

Direct computation of the DFT does not exploit these symmetry and periodicity property.

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 11 / 100

Page 12: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIT-FFT algorithm

FFT algorithms

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 12 / 100

Page 13: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIT-FFT algorithm

There are two methods in divide and conquer approach

1 Decimation in Time (DIT)-FFT algorithm and

2 Decimation in Frequency (DIF)-FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 13 / 100

Page 14: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIT-FFT algorithm

Decimation in Time (DIT)-FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 14 / 100

Page 15: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Radix-2 algorithm

The sequence x(n) of length N is factored in such a way that

N = r1r2r3 . . . rv

In this case r1 = r2 = r3 = . . . rv = r so that N = rv , where r is called the radix of theFFT algorithm.

r = 2 is called radix-2 algorithm, which is most widely used FFT algorithm.

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 15 / 100

Page 16: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The N point data sequence x(n) is splitted into two N/2 point data sequences f1(n), f2(n)These f1(n) and f2(n) data sequences contain even and odd numbered samples of x(n).

f1(n) = x(2n) n = 0, 1, . . . ,N/2− 1

f2(n) = x(2n + 1) n = 0, 1, . . . ,N/2− 1

The N point DFT is expressed as

X (k) =

N−1∑n=0

x(n)W knN k = 0, 1, . . . ,N − 1

The sequence x(n) is splitted as even and odd numbered samples and its DFT is:

X (k) =∑

n=even

x(n)W knN +

∑n=odd

x(n)W knN

=

N/2−1∑m=0

x(2m)W 2mkN +

N/2−1∑m=0

x(2m + 1)Wk(2m+1)N

In the above equation f1(m) = x(2m) and f2(m) = x(2m + 1), and its DFT is

X (k) =

N/2−1∑m=0

f1(m)(W 2N )mk +

N/2−1∑m=0

f2(m)(W 2N )mk W k

N

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 16 / 100

Page 17: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

X (k) =

N/2−1∑m=0

f1(m)(WN/2)mk + W kN

N/2−1∑m=0

f2(m)(WN/2)mk

Comparing the above equation with DFT equation and can be expressed as:

X (k) = F1(k) + W kN F2(k) k = 0, 1, . . . ,N − 1

where F1(k) and F2(k) are N/2 point DFT of f1(m) and f2(m) respectively

F1(k) and F2(k) are periodic with period N/2 hence F1(k + N/2) = F1(k) and

F2(k + N/2) = F2(k), and also W(k+N/2)N = −W k

N . Replace k by k+N/2

X (k + N/2) = F1(k + N/2) + W(k+N/2)N F2(k + N/2)

X (k + N/2) = F1(k)−W kN F2(k)

X (k) = F1(k) + W kN F2(k) k = 0, 1, . . . ,N/2− 1

X (k + N/2) = F1(k)−W kN F2(k) k = 0, 1, . . . ,N/2− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 17 / 100

Page 18: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

8 point DFT

To Demonstrate the FFT algorithm 8 point DFT is considered as an example.

The block diagram of an 8 point DFT is as shown in Figure.

8-point DFT

(0)x (0)X

(2)X(1)X

(7)X(7)x

(2)x(1)x

DiscreteTime Signal( )x n is

DFT of( )X k

( )x n

Figure 2: Block diagram of 8 point DFT

For this Figure X (k) can be obtained from F1(k) and F2(k).

where F1(k) and F2(k) are two 4-point DFTs

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 18 / 100

Page 19: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The 8 point DFT can be found by combining two 4 point DFT F1(k) and F2(k).The sequences f1(m) and f2(m) are

f1(m) = x(2n) = [x(0), x(2), x(4), x(6)]

f2(m) = x(2n + 1) = [x(1), x(3), x(5), x(7)]

X (k) = F1(k) + W kN F2(k) k = 0, 1, . . . ,N/2− 1

X (k + N/2) = F1(k)−W kN F2(k) k = 0, 1, . . . ,N/2− 1

(0)X

-1-1

1(2 ) ( )x n f m=

1(0) (0)x f=

1(2) (1)x f=

1(6) (3)x f=

1(4) (2)x f=

1(0)F

1(3)F

1(2)F

1(1)F

2(2 1) ( )x n f m+ =

2(1) (0)x f=

2(2) (1)x f=

2(7) (3)x f=

2(5) (2)x f=

2 (0)F

2 (3)F

2 (2)F

2 (1)F

08W

38W

28W

18W -1

-1

(3)X

(2)X

(1)X

(0 4) (4)X X+ =

(3 4) (7)X X+ =

(2 4) (6)X X+ =

(1 4) (5)X X+ =N/2-point DFTi.e.4-point DFT

N/2-point DFTi.e.4-point DFT

Figure 3: 8 point DFT using two 4-point DFTDr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 19 / 100

Page 20: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The process of decimation in time is repeated for the sequences f1(n) and f2(n).

f1(n) and f2(n) are two N/2 point sequences.

This is done by splitting the sequences into odd and even numbered sequences for f1(n) as

v11(n) = f1(2n) n = 0, 1, . . . ,N

4− 1

v12(n) = f1(2n + 1) n = 0, 1, . . . ,N

4− 1

Similarly splitting is done into odd and even numbered sequences for f2(n) as

v21(n) = f2(2n) n = 0, 1, . . . ,N

4− 1

v22(n) = f2(2n + 1) n = 0, 1, . . . ,N

4− 1

v11(n), v12(n), v21(n) and v22(n) are four N/4 point samples.

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 20 / 100

Page 21: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Apply the N/4 point DFT to obtain F1(k), based on the N/2 point DFT.

F1(k) = V11(k) + W kN/2V12(k) k = 0, 1, . . . ,

N

4− 1

F1(k + N/4) = V11(k)−W kN/2V12(k) k = 0, 1, . . . ,

N

4− 1

Similarly apply the N/4 point DFT to obtain F2(k).

F2(k) = V21(k) + W kN/2V22(k) k = 0, 1, . . . ,

N

4− 1

F2(k + N/4) = V21(k)−W kN/2V22(k) k = 0, 1, . . . ,

N

4− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 21 / 100

Page 22: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The symbolic representation of F1(k) and F2(k) are as shown in Figure.

N/2-pointDFT i.e.4-point DFT

1(0)f1(0)F

1(2)F

1(1)F

1(3)F1(3)f

1(2)f

1(1)f

Figure 4: Symbolic representation of F1(k)

N/2-pointDFT i.e.4-point DFT

2 (0)f2 (0)F

2 (2)F

2 (1)F

2 (3)F2 (3)f

2 (2)f

2 (1)f

Figure 5: Symbolic representation of F2(k)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 22 / 100

Page 23: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The 4-point sequences v11(n) and v12(n) are:

v11(n) = f1(2n) = x(4n) = [x(0), x(4)] n = 0, 1

v12(n) = f1(2n + 1) = x(4n + 2) = [x(2), x(6)] n = 0, 1

F1(k) = V11(k) + W kN/2V12(k) k = 0, 1, . . . ,

N

4− 1

F1(k + N/4) = V11(k)−W kN/2V12(k) k = 0, 1, . . . ,

N

4− 1

The detailed two N/4 point DFT for F1(k) are shown in Figure.

N/4-pointDFT i.e.2-point DFT

11 1(0) (0) (0)v f x= =

11 1(1) (2) (4)v f x= =

11(0)V

11(1)V

12 1(0) (1) (2)v f x= =

12 1(1) (3) (6)v f x= =

12 (0)V

12 (1)V

12 1( ) (2 1) (4 2)V n f n x n= + = +

N/4-pointDFT i.e.2-point DFT

11 1( ) (2 ) (4 )V n f n x n= =1(0)F

1(2)F

1(1)F

1(3)F14W

04W

-1

-1

Figure 6: 4-point DFT F1(k)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 23 / 100

Page 24: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The 4-point sequences v21(n) and v22(n) are:

v21(n) = f2(2n) = x(4n) = [x(1), x(5)] n = 0, 1

v22(n) = f2(2n + 1) = x(4n + 2) = [x(3), x(7)] n = 0, 1

F2(k) = V21(k) + W kN/2V22(k) k = 0, 1, . . . ,

N

4− 1

F2(k + N/4) = V21(k)−W kN/2V22(k) k = 0, 1, . . . ,

N

4− 1

The detailed two N/4 point DFT for F2(k) are shown in Figure.

N/4-pointDFT i.e.2-point DFT

21 2(0) (0) (1)v f x= =

21 2(1) (2) (5)v f x= =

21(0)V

21(1)V

22 2(0) (1) (3)v f x= =

22 2(1) (3) (7)v f x= =

22 (0)V

22 (1)V

22 2( ) (2 1) (4 3)V n f n x n= + = +

N/4-pointDFT i.e.2-point DFT

21 2( ) (2 ) (4 1)V n f n x n= = +2 (0)F

2 (2)F

2(1)F

2 (3)F14W

04W

-1

-1

Figure 7: Symbolic representation of F2(k)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 24 / 100

Page 25: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The decimation of the data sequence repeated again and again until the sequences reduceto the one point sequence.

For N = 2v , the decimation can be performed till v = log2N.

For N=8 v = log28 = 3.

The N/4 sequences are further splitted as odd and even sequences.

This will result in sequence of length N/8. The 2-point DFTs are expressed as

2-point DFT11 1(0) (0) (0)v f x= =

11 1(1) (2) (4)v f x= =

11(0)V

11(1)V

11( ), 0,1V k where k =11( ), 0,1V n where n =

Figure 8: 2-point DFT V11(k)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 25 / 100

Page 26: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The n DFT is expressed as

X (k) =

N−1∑n=0

x(n)W knN k = 0, 1, . . . ,N/2− 1

The two point DFT for V11(k) is expressed as

V11(k) =

N−1∑n=0

v11(n)W kn2 k = 0, 1

For k=0

V11(0) =1∑

n=0

v11(n)W 02

=1∑

n=0

v11(n)

= v11(0) + v11(1)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 26 / 100

Page 27: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

For k=1

V11(1) =1∑

n=0

v11(n)W n2

= v11(0)W 02 + v11(1)W 1

2

W 02 = 1 and W 1

2 = e−j 2π2 ⇒ W 1

2 = e−jπ = cosπ − jsinπ = −1

V11(1) = v11(0)− v11(1)

V11(0) = v11(0) + W 02 v11(1)

V11(1) = v11(0)−W 02 v11(1)

2-point DFT

11(0)V

11(1)V02W

-1

11(0)v

11(1)v

Figure 9: 2-point DFT V11(k)

Similarly V12(k),V21(k), and V22(k) are estimated, and these details are as shown inFigure 11

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 27 / 100

Page 28: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

The detailed two N/4 point DFT for F2(k) are shown in Figure.

The block diagram 8 point DFT computation is as shown in Figure

(7)X

(1)X

(2)X

(3)X

(4)X

(0)X

(6)X

(5)X

Third Stage Decimation

First Stage Decimation

Second Stage Decimation

Shuffled array inbit reversal order

Natural order ofDFT Sequence

2-point DFT(0)x

(4)x

2-point DFT(2)x

(6)x

Combine2-point DFTs

2-point DFT(1)x

(5)x

2-point DFT(3)x

(7)x

Combine2-point DFTs

Combine4 pointDFTs

Figure 10: Three stages in computation of an N=8 point DFT

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 28 / 100

Page 29: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

11(0)V

0 02 8W W=

2-point DFT

(0)x

(4)x

-10 0

4 8W W=

Combine 2-point DFTs

1 24 8W W=0 0

2 8W W=

(2)x

(6)x

-1 -1

-1

12 (1)V

12 (0)V

11(1)V

21(0)V

0 02 8W W=

2-point DFT

(1)x

(5)x

-10 0

4 8W W=

Combine 2-point DFTs

1 24 8W W=0 0

2 8W W=

(3)x

(7)x

-1 -1

-1

22 (1)V

22 (0)V

21(1)V

-1

-1

-1

-1

28W

18W

08W

38W

1(0)F

1(2)F

1(3)F

1(1)F

2 (0)F

2 (2)F

2 (3)F

2 (1)F

(7)X

(1)X

(2)X

(3)X

(4)X

(0)X

(6)X

(5)X

Combine Two-4 point DFTs

Third Stage Decimation First Stage DecimationSecond Stage Decimation

Shuffled array inbit reversal order

Natural order ofDFT Sequence

Figure 11: Signal flow graph depicting Radix-2 DIT-FFT algorithm for N=8

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 29 / 100

Page 30: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Computational complexity in FFT algorithm

The basic computation of every stage of signal flow graph is represented by generalstructure is known as butterfly computation.

In this computation two complex numbers say (a,b), multiply b by W rN , and then add and

subtract the product from a to form new complex numbers (A,B).

This basic computation is as shown in Figure and is called as butterfly because the flowgraph resembles a butterfly

rNA a W b= +

rNW

-1

a

br

NB a W b= −

Figure 12: Butterfly computation in DIT-FFT algorithm

Butterfly operation requires two complex additions and one complex multiplication.

In complete signal flow graph Figure 11. there are N/2=4 butterflies in every stage ofdecimation and there are log2N = 3 = v stages of decimation (for N=8).

Total number of butterfly operations =N/2log2N = 4× 3 = 12

Total number of complex additions =2× N/2× log2N = N × log2N

Total number of complex multiplications =1× N/2× log2N = N/2× log2N

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 30 / 100

Page 31: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Table 1: Comparison of computational complexity for the direct computation of DFT versusthe FFT algorithm

No of Direct Computation DIT-FFT algorithm SpeedPoints Complex Complex Complex Complex improvement

multiplications additions multiplications additions for multiplications

N2 N2 − N N/2log2N Nlog2N N2

N/2log2N

4 16 12 4 8 4 times8 64 56 12 24 5.3 times

16 256 240 32 64 8 times32 1024 992 80 160 12.8 times64 4096 4032 192 384 21.3 times

256 65536 65280 1024 2048 64.0 times1024 1048576 1047552 5120 10240 204.8 times

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 31 / 100

Page 32: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Memory requirement in FFT algorithm

In butterfly computation, two complex numbers say (a,b), are input and (A,B) form newcomplex numbers.

Once ’A’ and ’B’ are estimated there is no need to store the old values a and b, hencesame memory locations can be used for ’A ’and ’B’.

’A’ is stored in location ’a’ and ’B ’is stored in location in ’b’, this is called in placecomputation.

For one butterfly computation four memory locations are required, two for ’a’ or ’A’ andtwo for ’b’ or ’B’ (’a’ or ’b’are two complex numbers ). Memory locations for onebutterfly = 2× 2 = 4

rNA a W b= +

rNW

-1

a

br

NB a W b= −

Figure 13: Butterfly computation in DIT-FFT algorithm

Computations are usually performed in stage wise. In every stage there are N/2 butterflies.Memory locations for one stage = 4× N/2 = 2N

2N locations are required for each stage. Usually stage by stage calculations areperformed, and the same locations are shared for next stage.

In every stage N/2 twiddle factors are required. Hence a maximum of (2N + N/2)memory locations are required.

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 32 / 100

Page 33: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Table 2: Shuffling of the data and bit reversal

Sl. Memory address Memory addressNo in bit reversed

Decimal Binary Binary Decimal1 0 000 000 02 1 001 100 43 2 010 010 24 3 011 110 65 4 100 001 16 5 101 101 57 6 110 011 38 7 111 111 7

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 33 / 100

Page 34: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Radix-2 DIT-FFT algorithm

Computation of twiddle factor

WN = e−j 2πN

W8 = e−j 2π8 = e−j π

4

W 08 = e0 = 1

W 18 = e−j π

41 = e−jπ/4 = cos(π/4)− jsin(π/4) = 0.7071− j0.7071

W 28 = e−j π

42 = e−jπ/2 = cos(π/2)− jsin(π/2) = −j

W 38 = e−j π

43 = e−j 3π

4 = cos

(3π

4

)− jsin

(3π

4

)= −0.7071− j0.7071

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 34 / 100

Page 35: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

Use the 8 point redix-2 DIT-FFT algorithm to find the DFT of the sequence x(n)={0.707,1,0.707,0,-0.707, -1,-0.707,0}

Solution:Based on the signal flow graph it is first we have to determine the two point DFT

V11(0) = x(0) + W 08 x4

= 0.707 + 1(−0.707) = 0

V11(1) = x(0)−W 08 x4

= 0.707− 1(−0.707) = 1.414

V11(1) = x(0)−W 08 + x4

= 0.707− 1(−0.707) = 1.414

V12(0) = x(2) + W 08 x6

= 0.707 + 1(−0.707) = 0

V12(1) = x(2)−W 08 x6

= 0.707− 1(−0.707) = 1.414

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 35 / 100

Page 36: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

V21(0) = x(1) + W 08 x5

= 1 + 1(−1) = 0

V21(1) = x(1)−W 08 x5

= 1− 1(−1) = 2

V22(0) = x(3) + W 08 x7

= 0 + 1(0) = 0

V22(1) = x(1)−W 08 x5

= 1− 1(0) = 0

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 36 / 100

Page 37: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

F1(0) = V11(0) + W 08 V12(0)

= 0 + 1(0) = 0

F1(1) = V11(1) + W 08 V12(1)

= 1.414 + (−j)1.414 = 1.414− j1.414

F1(2) = V11(0)−W 08 V12(0)

= 0− 1(0) = 0

F1(3) = V11(1)−W 08 V12(1)

= 1.414− (−j)1.414 = 1.414 + j1.414

F2(0) = V21(0) + W 08 V22(0)

= 0 + 1(0) = 0

F2(1) = V21(1) + W 08 V22(1)

= 2 + (−j)0 = 2

F2(2) = V21(0)−W 08 V22(0)

= 0− 1(0) = 0

F2(3) = V21(1)−W 08 V22(1)

= 2− (−j)0 = 2Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 37 / 100

Page 38: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

X (0) = F1(0) + W 08 F2(0)

= 0 + 1(0) = 0

X (1) = F1(1) + W 18 F2(1)

= (1.414− j1.414) + (0.7071− j0.7071)2

= 2.8284− j2.8284

X (2) = F1(2) + W 28 F2(2)

= 0 + (−j)(0) = 0

X (3) = F1(3) + W 38 F2(3)

= (1.414 + j1.414) + (−0.7071− j0.7071)2 = 0

X (4) = F1(0)−W 08 F2(0)

= 0 + 1(0) = 0

X (5) = F1(1)−W 18 F2(1)

= (1.414− j1.414)− (0.7071− j0.7071)2 = 0

X (6) = F1(2)−W 28 F2(2)

= 0− (−j)(0) = 0

X (7) = F1(3)−W 38 F2(3)

= (1.414 + j1.414)− (−0.7071− j0.7071)2

= 2.8284 + j2.8284

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 38 / 100

Page 39: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

11(0) 0V =

0 02 8W W=

2-point DFT

(0) 0.707x =

(4) 0.707x = −

-10 0

4 8W W=

Combine 2-point DFTs

1 24 8W W=0 0

2 8W W=

(2) 0.707x =

(6) 0.707x = −

-1 -1

-1

12 (1) 2V =

12 (0) 0V =

11(1) 1.414V =

21(0)0V

0 02 8W W=

2-point DFT

(1) 1x =

(5) 1x = −

-10 0

4 8W W=

Combine 2-point DFTs

1 24 8W W=0 0

2 8W W=

(3) 0x =

(7) 0x =

-1 -1

-1

22 (1) 0V =

22 (0) 0V =

21(1) 2V =

-1

-1

-1

-1

28W

18W

08W

38W

1(0) 0F =

1(2) 0F =

1(3) 1.414 1.414F j= +

1(1) 1.414 1.414F j= −

2 (0) 0F =

2 (2) 0F =

2 (3) 2F =

2 (1) 2F =

(7) 2.8284 2.8284X j= +

Combine Two-4 point DFTs

(1) 2.8284 2.8284X j= −

(2) 0X =

(3) 0X =

(4) 0X =

(0) 0X =

(6) 0X =

(5) 0X =

Figure 14: Symbolic representation of F1(k)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 39 / 100

Page 40: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

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

=

1 1 1 1 1 1 1 1

1 1√2− j 1√

2−j − 1√

2− j 1√

2−1 − 1√

2+ j 1√

2j 1√

2+ j 1√

21 −j −1 j 1 −j −1 j

1 − 1√2− j 1√

2j 1√

2− j 1√

21 1√

2+ j 1√

2−j − 1√

2+ j 1√

21 −1 1 −1 1 −1 1 −1

1 − 1√2

+ j 1√2

−j 1√2

+ j 1√2

−1 1√2− j 1√

2j − 1√

2− j 1√

21 j −1 −j 1 j −1 −j

1 1√2

+ j 1√2

j − 1√2

+ j 1√2

−1 − 1√2− j 1√

2−j 1√

2− j 1√

2

=

.7071.7070−.707−1−.7070

02.8284 − j2.8284000002.8284 + j2.8284

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 40 / 100

Page 41: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

Use the 8 point redix-2 DIT-FFT algorithm to find the DFT of the sequencex(n)={1,1,1,1,0,0,0,0}Solution: Based on the signal flow graph it is first we have to determine the two point DFT

V11(0) = x(0) + W 08 x4

= 1 + 1(0) = 1

V11(1) = x(0)−W 08 x4

= 1− 1(0) = 1

V12(0) = x(2) + W 08 x6

= 1 + 1(0) = 1

V12(1) = x(2)−W 08 x6

= 0.707− 1(0) = 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 41 / 100

Page 42: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

V21(0) = x(1) + W 08 x5

= 1 + 1(0) = 1

V21(1) = x(1)−W 08 x5

= 1− 1(0) = 1

V22(0) = x(3) + W 08 x7

= 1 + 1(0) = 1

V22(1) = x(1)−W 08 x5

= 1− 1(0) = 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 42 / 100

Page 43: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

F1(0) = V11(0) + W 08 V12(0)

= 1 + 1(1) = 2

F1(1) = V11(1) + W 08 V12(1)

= 1 + (−j)1 = 1− j

F1(2) = V11(0)−W 08 V12(0)

= 1− (−j)(1) = 1− j

F1(3) = V11(1)−W 08 V12(1)

= 1− (−j)1.414 = 1 + j

F2(0) = V21(0) + W 08 V22(0)

= 1 + 1(1) = 2

F2(1) = V21(1) + W 08 V22(1)

= 1 + (−j)1 = 1− j

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 43 / 100

Page 44: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

F2(2) = V21(0)−W 08 V22(0)

= 1− 1(1) = 0

F2(3) = V21(1)−W 08 V22(1)

= 1− (−j)1 = 1 + j

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 44 / 100

Page 45: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIT-FFT algorithm Problems on DIT-FFT algorithm

X (0) = F1(0) + W 08 F2(0)

= 2 + 1(2) = 4

X (1) = F1(1) + W 18 F2(1)

= (1− j1) + (0.707− j0.7071)(1− j)

= 1− j2.414

X (2) = F1(2) + W 28 F2(2)

= 0 + (−j)(0) = 0

X (3) = F1(3) + W 38 F2(3)

= (1 + j) + (−0.7071− j0.7071)(1 + j)

= 1− j0.414

X (4) = F1(0)−W 08 F2(0)

= 2− 1(2) = 0

X (5) = F1(1)−W 18 F2(1)

= (1− j1)− (0.707− j0.7071)(1− j)

= 1− j0.414

X (6) = F1(2)−W 28 F2(2)

= 0− (−j)(0) = 0

X (7) = F1(3)−W 38 F2(3)

= (1 + j)− (−0.7071− j0.7071)(1 + j)

= 1 + j2.414Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 45 / 100

Page 46: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

Decimation in Frequency (DIF)-FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 46 / 100

Page 47: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

N point DFT is expressed as:

X (k) =

N−1∑n=0

x(n)W knN k = 0, 1, . . . ,N − 1

Split this summations into two summations with N/2 data points for each summation.

X (k) =

N/2−1∑n=0

x(n)W knN +

N−1∑n=N/2

x(n)W knN

=

N/2−1∑n=0

x(n)W knN +

N/2−1∑n=0

x(n + N/2)Wk(n+N/2)N

=

N/2−1∑n=0

x(n)W knN + W

kN/2N

N/2−1∑n=0

x(n + N/2)W knN

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 47 / 100

Page 48: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

WkN/2N can be expressed as

WkN/2N = e−j 2π

NkN2 = e−jπk = e−jπ = (−1)k

X (k) =

N/2−1∑n=0

x(n)W knN + (−1)k

N/2−1∑n=0

x(n + N/2)W knN

=

N/2−1∑n=0

[x(n) + (−1)k x(n + N/2)

]W kn

N

Split the X (k) into even and odd numbered samples. This splitting in frequency is knownas decimation in frequency (DIF).

X (2k) =

N/2−1∑n=0

[x(n) + (−1)2k x(n + N/2)

]W 2kn

N k = 0, 1, . . .N/2− 1

X (2k + 1) =

N/2−1∑n=0

[x(n) + (−1)2k+1x(n + N/2)

]W

(2k+1)nN k = 0, 1, . . .N/2− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 48 / 100

Page 49: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

(−1)2k = 1 and W 2knN = (W 2

N )kn = W knN/2

Since W 2N = WN/2

Similarly (−1)2k+1 = −1 and W(2k+1)nN = W 2kn+n

N = W 2knN .W n

N Since W 2N = WN/2

Substituting these values in the previous equations:

X (2k) =

N/2−1∑n=0

[x(n) + x(n + N/2)] W knN/2 k = 0, 1, . . .N/2− 1

X (2k + 1) =

N/2−1∑n=0

[x(n)− x(n + N/2)] W 2knN .W n

N

=

N/2−1∑n=0

{[x(n)− x(n + N/2)] W nN}W

knN/2

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 49 / 100

Page 50: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

Let us define N/2 point sequences g1(n) and g2(n) as

g1(n) = [x(n) + x(n + N/2)] n = 0, 1, . . .N/2− 1

g2(n) = [x(n)− x(n + N/2)] W nN n = 0, 1, . . .N/2− 1

X (2k) =

N/2−1∑n=0

g1(n)W knN/2 k = 0, 1, . . .N/2− 1

X (2k + 1) =

N/2−1∑n=0

g2(n)W knN/2 k = 0, 1, . . .N/2− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 50 / 100

Page 51: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

To Demonstrate the DIF-FFT algorithm 8 point DFT is considered as an example. Thevalues of g1(n) and g2(n) is defined as

g1(n) = x(n) + x(n + N/2) n = 0, 1, . . .N/2− 1

g1(0) = x(0) + x(4)

g1(1) = x(1) + x(5)

g1(2) = x(2) + x(6)

g1(3) = x(3) + x(7)

g2(n) = [x(n)− x(n + 4)] W n8 n = 0, 1, . . .N/2− 1

g2(0) = [x(0)− x(4)]W 08

g2(1) = [x(1)− x(5)]W 18

g2(2) = [x(2)− x(6)]W 28

g2(3) = [x(3)− x(7)]W 38

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 51 / 100

Page 52: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

38W (7)X

(0)x

(3)x

(2)x

(1)x

1(0)g

1(1)g

1(3)g

1(2)g

(4)x

(7)x

(6)x

(5)x

2 (0)g

2 (1)g

2 (3)g

2 (2)g

4 point DFTs

4 point DFTs (5)X

(4)X

(3)X

(2)X

(1)X

(0)X

(6)X

28W

18W

08W

-1

-1

-1

-1

(2 )X K

(2 1)X K +

Figure 15: Decimation of DFT-FFT algorithm for N=8

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 52 / 100

Page 53: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

Let us define N/4 point sequences p11(n) and p12(n) as

p11(n) = [g1(n) + g1(n + N/4)] n = 0, 1, . . .N/4− 1

p12(n) = [g1(n)− g1(n + N/4)] W nN/2 n = 0, 1, . . .N/4− 1

p21(n) = [g2(n) + g2(n + N/4)] n = 0, 1, . . .N/4− 1

p22(n) = [g2(n)− g2(n + N/4)] W nN/2 n = 0, 1, . . .N/4− 1

X (4k) =

N/4−1∑n=0

p11(n)W knN/4 k = 0, 1, . . .N/4− 1

X (4k + 2) =

N/4−1∑n=0

p12(n)W knN/4 k = 0, 1, . . .N/4− 1

X (4k + 1) =

N/4−1∑n=0

p21(n)W knN/4 k = 0, 1, . . .N/4− 1

X (4k + 3) =

N/4−1∑n=0

p22(n)W knN/4 k = 0, 1, . . .N/4− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 53 / 100

Page 54: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

The 4-point sequence g1(n) is splitted into two 2-point sequences p11(n) and p12(n) andrepresented as

p11(0) = g1(0) + g1(2)

p11(1) = g1(1) + g1(3)

p12(0) = [g1(0)− g1(2)]W 08 ∵ (W 0

4 = W 08 )

p12(1) = [g1(1)− g1(3)]W 28 ∵ (W 1

4 = W 28 )

Similarly the 4-point sequence g2(n) is splitted into two 2-point sequences p21(n) andp22(n) and represented as

p21(0) = g2(0) + g2(2)

p21(1) = g2(1) + g2(3)

p22(0) = [g2(0)− g2(2)]W 08

p22(1) = [g2(1)− g2(3)]W 28

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 54 / 100

Page 55: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

1(0)g

1(1)g

1(3)g

1(2)g

2 (0)g

2 (1)g

2 (3)g

2 (2)g

-1

-1

28W

08W

11(0)p

12 (1)p

12 (0)p

11(1)p

-1

-1

28W

08W

21(0)p

22(1)p

22 (0)p

21(1)p

Figure 16: N=8 point decimation in frequency FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 55 / 100

Page 56: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

The 2-point DFTs are computed directly and represented as

X (4k) =

N/4−1∑n=0

p11(n)W knN/4 k = 0, 1, . . .N/4− 1

X (4k + 2) =

N/4−1∑n=0

p12(n)W knN/4 k = 0, 1, . . .N/4− 1

X (4k + 1) =

N/4−1∑n=0

p21(n)W knN/4 k = 0, 1, . . .N/4− 1

X (4k + 3) =

N/4−1∑n=0

p22(n)W knN/4 k = 0, 1, . . .N/4− 1

X (0) = P11(0) + P11(1)

X (4) = [P11(0)− P11(1)]W 08

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

X (6) = [P12(0)− P12(1)]W 08

X (1) = P21(0) + P21(1)

X (5) = [P21(0)− P21(1)]W 08

X (3) = P22(0) + P22(1)

X (7) = [P22(0)− P22(1)]W 08Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 56 / 100

Page 57: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

(4)X

(2)X

(0)X

(6)X

-1

-1 08W

08W

11(0)p

12 (1)p

12 (0)p

11(1)p

(5)X

(3)X

(1)X

(7)X

-1

-1 08W

08W

21(0)p

22(1)p

22 (0)p

21(1)p

2 point DFT

Figure 17: N=8 point decimation in frequency FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 57 / 100

Page 58: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

38W

(0)x

(3)x

(2)x

(1)x

1(0)g

1(1)g

1(3)g

1(2)g

(4)x

(7)x

(6)x

(5)x

2 (0)g

2 (1)g

2 (3)g

2 (2)g28W

18W

08W

-1

-1

-1

-1

(4)X

(2)X

(0)X

(6)X

-1

-1

-1

28W

08W

-1 08W

08W

11(0)p

12 (1)p

12 (0)p

11(1)p

(5)X

(3)X

(1)X

(7)X

-1

-1

-1

28W

08W

-1 08W

08W

21(0)p

22(1)p

22 (0)p

21(1)p

DFT sequenceshuffled in bitreversal order

Input Sequence

2 point DFT

Figure 18: N=8 point decimation in frequency FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 58 / 100

Page 59: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms DIF-FFT algorithm

Computational Complexity Decimation in Frequency (DIF)-FFTalgorithm

A a b= +

rNW

-1

a

b ( ) rNB a b W= −

Figure 19: Butterfly structure decimation in frequency FFT algorithm

Butterfly operation requires two complex additions and one complex multiplication.

In complete signal flow graph Figure 30. there are N/2=4 butterflies in every stage ofdecimation and there are log2N = 3 = v stages of decimation (for N=8).

Total number of butterfly operations =N/2log2N = 4× 3 = 12

Total number of complex additions =2× N/2× log2N = N × log2N

Total number of complex multiplications =1× N/2× log2N = N/2× log2N

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 59 / 100

Page 60: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

Obtain the 8 point DFT of the following sequence using redix-2 DIF-FFT algorithm. Show allthe results along signal flow graph x(n)={2,1,2,1}

Solution:

W 08 = 1

W 18 = 0.707− j0.707

W 28 = −j

W 38 = −0.707− j0.707

g1(0) = x(0) + x(4)

= 2 + 0 = 2

g1(1) = x(1) + x(5)

= 1 + 0 = 1

g1(2) = x(2) + x(6)

= 2 + 0 = 2

g1(3) = x(3) + x(7)

= 1 + 0 = 1

g2(0) = [x(0)− x(4)]W 08

= [2− 0]× 1 = 2

g2(1) = [x(1)− x(5)]W 18

= [1− 0]× [0.707− j0.707]

= 0.707− j0.707

g2(2) = [x(2)− x(6)]W 28

= [2− 0]× [−j] = −j2

g2(3) = [x(3)− x(7)]W 38

= [1− 0]× [−0.707− j0.707]

= −0.707− j0.707

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 60 / 100

Page 61: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

38W

(0)x

(3)x

(2)x

(1)x

(4)x

(7)x

(6)x

(5)x

28W

18W

08W

-1

-1

-1

-1

1(0) (0) (4) =2+0=2g x x= +

1(1) (1) (5) =1+0=1g x x= +

1(3) (3) (7) =1+0=1g x x= +

1(2) (2) (6) =2+0=2g x x= +

02 8(0) [ (0) (4)]

=[2-0] 1=2g x x W= −

×1

2 8(1) [ (1) (5)] =[1-0] (.707 .707)g x x W

j= −

× −2

2 8(2) [ (2) (6)] =[2-0] ( ) 2g x x W

j j= −

× − = −3

2 8(3) [ (3) (7)] =[1-0] ( .707 .707)g x x W

j= −

× − −

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 61 / 100

Page 62: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

p11(0) = g1(0) + g1(2)

= 2 + 2 = 4

p11(1) = g1(1) + g1(3)

= 1 + 1 = 2

p12(0) = [g1(0)− g1(2)]W 08

= (2− 2)× 1 = 0

p12(1) = [g1(1)− g1(3)]W 08

= (1− 1)× (−j) = 0

p21(0) = g2(0) + g2(2)

= 2− j2

p21(1) = g2(1) + g2(3)

= 0.707− j0.707− 0.707− j0.707

= −j1.414

p22(0) = [g2(0)− g2(2)]W 08

= [2− (−j2)]× 1

= 2 + j2

p22(1) = [g2(1)− g2(3)]W 08

= [0.707− j0.707 + 0.707 + j0.707]× (−j)

= −j1.414

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 62 / 100

Page 63: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

-1

-1

28W

08W

-1

-1

28W

08W

1(0) 2g =

1(1) 1g =

1(3) 1g =

1(2) 2g =

2 (0) 2g =

2 (1) (.707 .707)g j= −

2 (2) 2g j= −

2 (3) ( .707 .707)g j= − −

11 1 1(0) (0) (2) 2 2 4p g g= +

= + =

012 1 1 8(1) [ (1) (3)]

(1 1) ( ) 0p g g W

j= −

= − × − =

012 1 1 8(0) [ (0) (2)]

(2 2) 1 0p g g W= −

= − × =

11 1 1(1) (1) (3) 1 1 2p g g= +

= + =

21 2 2(0) (0) (2) 2 2p g g

j= +

= −

122 2 2 8(1) [ (1) (3)]

(.707 .707 .707 .707) 1.414

p g g Wj j j

j

= −

= − + + ×−= −

022 2 2 8(0) [ (0) (2)]

[2 ( 2)] 2 2p g g W

j j j= −

= − − ×− = +

21 2 2(1) [ (1) (3)] (.707 .707 .707 .707)

1.414

p g gj j

j

= += − − −= −

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 63 / 100

Page 64: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

X (0) = P11(0) + P11(1)

= 4 + 2 = 6

X (4) = [P11(0)− P11(1)]W 08

= (4− 2)× 1 = 2

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

= 0 + 0 = 0

X (6) = [P12(0)− P12(1)]W 08

= (0− 0)× 1 = 0

X (1) = P21(0) + P21(1)

= (2− j2− j1.414)

= 2− j3.414

X (5) = [P21(0)− P21(1)]W 08

= [2− j2− (−j1.414)]× 1

= 2− j0.586

X (3) = P22(0) + P22(1) = (2 + j2− j1.414)

= 2 + j0.586

X (7) = [P22(0)− P22(1)]W 08

= [2 + j2− (−j1.414)]× 1 = 2 + j3.414

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 64 / 100

Page 65: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

011 11 8(4) [ (0) (1)]

(4-2)1=2X p p W= −

12 12(2) (0) (1) 0+0=0X p p= −

11 11(0) (0) (1) 4+2=6X p p= +

011 11 8(6) [ (0) (1)]

(0-0)1=0X p p W= +

-1

-1 08W

08W

021 21 8(5) [ (0) (1)]

[2-j2-(-j1.414)]1=2-j0.566X p p W= +

22 22(3) (0) (1) 2+j2-j1.414=2+j0.586X p p= +

21 21(1) (0) (1) 2-j2-j1.414=2-j3.414X p p= +

022 22 8(7) [ (0) (1)]

[2+j2-(-j1.414)]1=2+j3.414X p p W= −

-1

-1 08W

08W

2 point DFT

11(0) 4p =

12 (1) 0p =

12 (0) 0p =

11(1) 2p =

21(0) 2 2p j= −

22 (1) 1.414p j= −

22 (0) 2 2p j= +

21(1) 1.414p j= −

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 65 / 100

Page 66: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

DIF-FFT algorithm Problems on DIF-FFT algorithm

38W

(0) 2x =

(3) 1x =

(2) 2x =

(1) 1x =

1(0)=2g

1(1)=1g

1(3)=1g

1(2)=2g

(4) 0x =

(7) 0x =

(6) 0x =

(5) 0x =

2 (0)=2g

2 (1) (.707 .707)g j= −

2 (2) 2g j= −2

8W

18W

08W

-1

-1

-1

-1

(4) 2X =

(2) 0X =

(0) 6X =

(6) 0X =

-1

-1

-1

28W

08W

-1 08W

08W

11(0) 4p =

12 (1) 0p =

12 (0) 0p =

11(1) 2p =

(5) 2 0.586X j= −

(3) 2 0.586X j= +

(1) 2 3.414X j= −

(7) 2 3.414X j= +

-1

-1

-1

28W

08W

-1 08W

08W

21(0) 2 2p j= −

22 (1) 1.414p j= −

2 point DFT

2 (3) ( .707 .707)g j= − −

22 (0) 2 2p j= +

21(1) 1.414p j= −

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 66 / 100

Page 67: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

Inverse Radix-2-FFT algorithms

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 67 / 100

Page 68: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

Inverse Radix-2-Decimation in frequency (DIF)

FFT algorithms

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 68 / 100

Page 69: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

N point IDFT is defined as

x(n) =1

N

N−1∑k=0

X (k)W −knN n = 0, 1, . . . ,N − 1

WN = e−j2π/N and W −knN = e−j2πkn/N =

DFT X (k) is splitted into even and odd numbered values

F1(k) = X (2k) k = 0, 1, . . . ,N/2− 1

F2(k) = X (2k + 1) k = 0, 1, . . . ,N/2− 1

x(n) =1

N

[ ∑k=even

X (k)W −knN +

∑k=odd

X (k)W −knN

]

=1

N

N/2−1∑m=0

X (2m)W −2mnN +

N/2−1∑m=0

X (2m + 1)W−2(2m+1)N

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 69 / 100

Page 70: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

F1(m) = X (2m) and F2(m) = X (2m + 1)

x(n) =1

N

N/2−1∑m=0

F1(m)(W 2N )−mn +

N/2−1∑m=0

F2(m)(W 2N )−mn(W −n

N )

W 2N = WN/2

x(n) =1

N

N/2−1∑m=0

F1(m)(WN/2)−mn + W −nN

N/2−1∑m=0

F2(m)(WN/2)−mn

x(n) =1

2

1

N/2

N/2−1∑m=0

F1(m)(WN/2)−mn + W −nN

1

N/2

N/2−1∑m=0

F2(m)(WN/2)−mn

Summations represents the N/2 IDFT of f1(n) and f2(n) for F1(m) and F2(m)respectively

x(n) =1

2

[f1(n) + W −n

N f2(n)]

n = 0, 1, . . . ,N − 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 70 / 100

Page 71: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

f1(n) and f2(n) are periodic

f1

(n +

N

2

)= f1(n)

f2

(n +

N

2

)= f2(n)

Replace n by n+N/2 forx(n)

x

(n +

N

2

)=

1

2

[f1

(n +

N

2

)+ W

−(n+ N2 )

N f2

(n +

N

2

)]

W−(n+ N

2 )N = W −n

N W−N/2N

= W −nN e−j 2π

NN2

= W −nN e jπ

= = −W −nN

Hence x(

n + N2

)can be written as

x

(n +

N

2

)=

1

2

[f1(n)−W −n

N f2(n)]

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 71 / 100

Page 72: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

x(n) =1

2

[f1(n) + W −n

N f2(n)]

n = 0, 1, . . .N

2− 1

x

(n +

N

2

)=

1

2

[f1(n)−W −n

N f2(n)]

n = 0, 1, . . .N

2− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 72 / 100

Page 73: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

Consider an 8 point Inverse DIF FFT. The sequence x(n) can be obtained from f1(n) andf1(n), where f1(n) and f2(n) are 4 point sequences.

38W −

28W −

18W −

08W −

-1

-1

-1

-1

N/2-point IDFT4-point IDFT

(0)x

(3)x

(2)x

(1)x

(4)x

(7)x

(6)x

(5)x

1(0)f

1(1)f

1(3)f

1(2)f

2 (0)f

2 (1)f

2 (3)f

2 (2)fN/2-point IDFT4-point IDFT

1(0) (0)F X=

1(3) (6)F X=

1(2) (4)F X=

1(1) (2)F X=

2 (0) (1)F X=

2 (3) (7)F X=

2 (2) (5)F X=

2 (1) (3)F X=

1( ) (2 )F k X k=

1( ) (2 )F k X k=

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

Figure 20: 8-point IDFT by combining 4-point IDFT of f1(n) and f2(n)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 73 / 100

Page 74: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

The decimation of X (k) is splitted into F1(k) and F2(k) are

F1(k) = X (2k) = [X (0),X (2),X (4),X (6)]

F2(k) = X (2k + 1) = [X (1),X (3),X (5),X (7)]

Next F1(k) and F2(k) are splitted into even and odd numbered samples

V11(k) = F1(2k) k = 0, 1, . . .N

4− 1

V12(k) = F1(2k + 1) k = 0, 1, . . .N

4− 1

V21(k) = F2(2k) k = 0, 1, . . .N

4− 1

V22(k) = F2(2k + 1) k = 0, 1, . . .N

4− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 74 / 100

Page 75: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

The sequences f1(n) and f1(n + N/4) are obtained from v11(n) and v12(n), where v11(n)and v12(n) are N/4 point IDFT of V11(k) and V12(k) respectively

f1(n) =1

2

[v11(n) + W −n

N/2v12(n)

]k = 0, 1, . . .

N

4− 1

f1

(n +

N

4

)=

1

2

[v11(n)−W −n

N/2v12(n)

]k = 0, 1, . . .

N

4− 1

Similarly f2(n) can be written as

f2(n) =1

2

[v21(n) + W −n

N/2v22(n)

]k = 0, 1, . . .

N

4− 1

f2

(n +

N

4

)=

1

2

[v21(n)−W −n

N/2v22(n)

]k = 0, 1, . . .

N

4− 1

V11(k) = F1(2k) = X (4k) = [X (0),X (4)] k = 0, 1

V12(k) = F1(2k + 1) = X (4k + 2) = [X (2),X (6)] k = 0, 1

V21(k) = F2(2k) = X (4k + 1) = [X (1),X (5)] k = 0, 1

V22(k) = F2(2k + 1) = X (4k + 3) = [X (3),X (7)] k = 0, 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 75 / 100

Page 76: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

N/2-pointIDFT i.e.4-pointIDFT

1(0)F

1(2)F

1(1)F

1(3)F

1(0)f

1(3)f

1(2)f

1(1)f

Figure 21: 4-point IDFT

N/2-pointIDFT i.e.4-pointIDFT

2 (0)F

2 (2)F

2 (1)F

2 (3)F

2 (0)f

2 (3)f

2 (2)f

2 (1)f

Figure 22: 4-point IDFT

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 76 / 100

Page 77: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

N/4-pointDFT i.e.2-point DFT

11(0)v

11(1)v

12 (0)v

12 (1)v

N/4-pointDFT i.e.2-point DFT 1

4W −

04W −

-1

-1

11 1(0) (0) (0)V F X= =11 1( ) (2 ) (4 )V k F k X k= =

11 1(1) (2) (4)V F X= =

12 1(0) (1) (2)V F X= =12 1( ) (2 2) (4 2)V k F k X k= + = +

12 1(1) (3) (6)V F X= =

1(1)f

1(0)f

1(2)f

1(3)f

1/ 2

1/ 2

1/ 2

1/ 2

Figure 23: 4-point sequence by combining two 2-point sequences v11(n) and v12(n)

N/4-pointDFT i.e.2-point DFT

21(0)v

21(1)v

22(0)v

22 (1)v

N/4-pointDFT i.e.2-point DFT 1

4W −

04W −

-1

-1

21 2(0) (0) (1)V F X= =21 2( ) (2 ) (4 1)V k F k X k= = +

21 2(1) (2) (5)V F X= =

22 2(0) (1) (3)V F X= =22 2( ) (2 1) (4 3)V k F k X k= + = +

22 2(1) (3) (7)V F X= =

2 (1)f

2 (0)f

2 (2)f

2 (3)f

1/ 2

1/ 2

1/ 2

1/ 2

Figure 24: 4-point sequence by combining two 2-point sequences v21(n) and v22(n)

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 77 / 100

Page 78: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

Computation of 2-point IDFT

By definition N point IDFT is

x(n) =1

N

N−1∑k=0

X (k)W −knN n = 0, 1, . . . ,N − 1

2-point v11(n) is defined as

v11(n) =1

2

1∑k=0

V11(k)W −kn2 n = 0, 1

For n=0

v11(0) =1

2

1∑k=0

V11(k)W −02

=1

2

1∑k=0

[V11(0)W −0

2 + V11(1)W −02

]

=1

2

1∑k=0

[V11(0) + V11(1)]

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 78 / 100

Page 79: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

For n=1

v11(1) =1

2

1∑k=0

V11(k)W −k2

=1

2

1∑k=0

[V11(0)W −0

2 + V11(1)W −12

]

=1

2

1∑k=0

[V11(0)− V11(1)]

v11(1) =1

2

1∑k=0

[V11(0)− V11(1)W −0

2

]The 2-point IDFTs are

v11(0) =1

2

1∑k=0

[V11(0) + V11(1)W −0

2

]

v11(1) =1

2

1∑k=0

[V11(0)− V11(1)W −0

2

]

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 79 / 100

Page 80: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

02W −

11(0) (0)V X=

11(1) (4)V X=

11(0)v

11(1)v

1/ 2

1/ 2

1−Figure 25: Butterfly structure IDFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 80 / 100

Page 81: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

11(0)v

0 02 8W W− −=

2-point IDFT

-10 0

4 8W W− −=

Combine 2-point IDFTs

1 24 8W W− −=

0 02 8W W− −=

-1 -1

-1

12 (1)v

12 (0)v

11(1)v

21(0)v

0 02 8W W− −=

-10 0

4 8W W− −=

Combine 2-point DFTs

1 24 8W W− −=

0 02 8W W− −=

-1 -1

-1

22 (1)v

22 (0)v

21(1)v

-1

-1

-1

-1

28W −

18W −

08W −

38W −

Combine Two-4 point IDFTs

Third Stage Decimation First Stage DecimationSecond Stage Decimation

DFT in bit reversalorder

x(n) Naturalorder order

(0)x

(1)x

(2)x

(3)x

(4)x

(5)x

(6)x

(7)x

1(0)f

1(2)f

1(3)f

1(1)f

2 (0)f

2 (2)f

2 (3)f

2 (1)f

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2

1/ 2(7)X

(4)X

(2)X

(6)X

(1)X

(0)X

(3)X

(5)X

Figure 26: Signal flow graph of 8-point Inverse Radix-2DIF-FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 81 / 100

Page 82: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

Inverse Decimation in Frequency (IDFT)-FFT

algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 82 / 100

Page 83: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

First five points of the eight point DFT of a real valued sequence is given by X(0)=[0,2+j2,-j4,2-j2,0]. Determine the remaining points. Hence find the original sequence x(n) usingDecimation in frequency FFT algorithmSolution:X (0) = 0, X (1) = 2 + j2, X (2) = −j4, X (3) = 2− j2, X (4) = 0The remaining values will be determine using symmetry propertyX (N − k) = X∗(k)X (k) = X∗(N − k)X (5) = X∗(8− 5) = X∗(3) = 2 + j2X (6) = X∗(8− 2) = X∗(2) = −j4X (7) = X∗(8− 7) = X∗(1) = 2− j2

W −08

W −18 = 0.707 + j0.707

W −28 = j

W −38 = −0.707 + j0.707

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 83 / 100

Page 84: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

v11(0) = X (0) + W −08 X (4)

= 0 + 1× 0 = 0

v11(1) = X (0) + W −08 X (4)

= 0− 1× 0 = 0

v12(0) = X (2) + W −08 X (6)

= −j4 + 1× (j4) = 0

v12(1) = X (2) + W −08 X (6)

= −j4− 1× (j4) = −j8

v21(0) = X (1) + W −08 X (5)

= 2 + j2 + 1× (2 + j2) = 4 + j4

v21(1) = X (1)−W −08 X (5)

= 2 + j2− 1× (2 + j2) = 0

v22(0) = X (3) + W −08 X (7)

= 2− j2 + 1× (2− j2) = 4− j4

v22(1) = X (3)−W −08 X (7)

= 2− j2− 1× (2− j2) = 0

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 84 / 100

Page 85: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

f1(0) = v11(0) + W −08 v12(0)

= 0 + 1× 0 = 0

f1(1) = v11(1) + W −28 v12(1)

= 0 + j × (−j8) = 8

f1(2) = v11(0)−W −28 v12(0)

= 0− 1× (0) = 0

f1(3) = v11(1)−W −28 v12(1)

= 0− j × (−j8) = −8

f2(0) = v21(0) + W −08 v22(0)

= 4 + j4 + 1× (4− j4) = 8

f2(1) = v21(1) + W −28 v22(1)

= 0 + j × (0) = 0

f2(2) = v21(0)−W −028 v22(0)

= 4 + j4− 1× (4− j4) = j8

f2(3) = v21(1)−W −28 v22(1)

= 0− j × (0) = 0

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 85 / 100

Page 86: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIF-FFT algorithm

x(0) = 1/8[f1(0) + W −08 f2(0)]

= 1/8[0 + 1× 8] = 1

x(1) = 1/8[f1(1) + W −18 f2(1)]

= 1/8[8 + (.707 + j .707)(0) = 1

x(2) = 1/8[f2(0) + W −28 f2(2)]

= 1/8[0 + j(j8)] = −1

x(3) = 1/8[f1(3) + W −38 f2(3)]

= 1/8[−8 + (−0.707 + j .707)(0) = −1

x(4) = 1/8[f1(0)−W −08 f2(0)]

= 1/8[0− 1× 8] = −1

x(5) = 1/8[f1(1)−W −18 f2(1)]

= 1/8[8− (.707 + j .707)(0) = 1

x(6) = 1/8[f1(2)−W −28 f2(2)]

= 1/8[0− j(j8)] = 1

x(7) = 1/8[f1(3)−W −38 f2(3)]

= 1/8[−8 + (−0.707 + j .707)(0) = −1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 86 / 100

Page 87: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

Inverse Radix-2 Decimation in Time (DIT)-FFT

algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 87 / 100

Page 88: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

N point IDFT is expressed as:

x(n) =1

N

N−1∑k=0

X (k)W −knN n = 0, 1, . . . ,N − 1

Split this summations into two summations with N/2 data points for each summation.

x(n) =1

N

N/2−1∑k=0

X (k)W −knN +

N−1∑k=N/2

X (k)W −knN

=

1

N

N/2−1∑k=0

X (k)W −knN +

N/2−1∑k=0

X (k + N/2)W−n(k+N/2)N

=

1

N

N/2−1∑k=0

X (k)W −knN + W

−nN/2N

N/2−1∑k=0

X (k + N/2)W −knN

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 88 / 100

Page 89: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

W−nN/2N can be expressed as

W−nN/2N = e−j 2π

NnN2 = e jπn = [e jπ]n = (−1)n

x(n) =1

N

N/2−1∑n=0

X (k)W −knN + (−1)n

N/2−1∑k=0

X (k + N/2)W −knN

=1

N

N/2−1∑n=0

[X (k) + (−1)k X (k + N/2)

]W −kn

N

Split the x(n) into even and odd numbered samples.

x(2n) =1

N

N/2−1∑k=0

[X (k) + (−1)2nX (k + N/2)

]W −2kn

N n = 0, 1, . . .N/2− 1

x(2n + 1) =1

N

N/2−1∑k=0

[X (k) + (−1)2n+1X (k + N/2)

]W

−(2n+1)kN n = 0, 1, . . .N/2− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 89 / 100

Page 90: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

(−1)2n = 1 and W −2knN = (W 2

N )−kn = W −knN/2

Since W 2N = WN/2

Similarly (−1)2n+1 = −1 and W−k(2n+1)N = W −2kn−k

N = W −2knN/2

.W −kN Since W 2

N = WN/2

Substituting these values in the previous equations:

X (2n) =1

N

N/2−1∑k=0

[X (k) + X (k + N/2)] W −knN/2

n = 0, 1, . . .N/2− 1

X (2n + 1) =

N/2−1∑n=0

[X (k)− X (k + N/2)] W −2knN .W −k

N

=1

N

N/2−1∑n=0

{[X (k)− X (k + N/2)] W −kN }W −kn

N/2

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 90 / 100

Page 91: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

Let us define N/2 point DFTs G1(k) and G2(k) as

G1(k) = [X (k) + X (k + N/2)] k = 0, 1, . . .N/2− 1

G2(k) = [X (k)− X (k + N/2)] W −kN k = 0, 1, . . .N/2− 1

x(2n) =1

N

N/2−1∑n=0

G1(k)W −knN/2

k = 0, 1, . . .N/2− 1

x(2n + 1) =1

N

N/2−1∑n=0

G2(k)W −knN/2

k = 0, 1, . . .N/2− 1

x(2n) =1

2

1

N/2

N/2−1∑n=0

G1(k)W −knN/2

k = 0, 1, . . .N/2− 1

x(2n + 1) =1

2

1

N/2

N/2−1∑n=0

G2(k)W −knN/2

k = 0, 1, . . .N/2− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 91 / 100

Page 92: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

To Demonstrate the DIF-FFT algorithm 8 point DFT is considered as an example. Thevalues of G1(k) and G2(k) is defined as

G1(k) = X (n) + X (k + N/2) k = 0, 1, . . .N/2− 1

G1(0) = X (0) + X (4)

G1(1) = X (1) + X (5)

G1(2) = X (2) + X (6)

G1(3) = X (3) + X (7)

G2(k) = [x(k)− X (k + 4)] W −k8 k = 0, 1, . . .N/2− 1

G2(0) = [X (0)− X (4)]W −08

G2(1) = [X (1)− X (5)]W −18

G2(2) = [X (2)− X (6)]W −28

G2(3) = [X (3)− X (7)]W −38

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 92 / 100

Page 93: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

38W

4 point IDFTs

4 point IDFTs28W

18W

08W

-1

-1

-1

-1

(2 )x n

(2 1)x n+

(1)X

(2)X

(0)X

(3)X

(5)X

(6)X

(4)X

(7)X

1(0)G

1(1)G

1(3)G

1(2)G

2 (0)G

2 (1)G

2 (3)G

2 (2)G

(0)x

(6)x

(2)x

(4)x

(1)x

(7)x

(3)x

(5)x

Figure 27: Decimation of DFT-FFT algorithm for N=8

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 93 / 100

Page 94: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

Let us define N/4 point sequences P11(k), P12(k) , P21(k),and P22(k) as

P11(k) = [G1(k) + G1(k + N/4)] k = 0, 1, . . .N/4− 1

P12(k) = [G1(k)− G1(k + N/4)] W −kN/2

k = 0, 1, . . .N/4− 1

P21(k) = [G2(k) + G2(k + N/4)] k = 0, 1, . . .N/4− 1

P22(k) = [G1(k)− G2(k + N/4)] W −kN/2

k = 0, 1, . . .N/4− 1

x(4n) =1

2

1

N/4

N/4−1∑n=0

P11(k)W −knN/4

n = 0, 1, . . .N/4− 1

x(4n + 2) =1

2

1

N/4

N/4−1∑n=0

P12(k)W −knN/4

n = 0, 1, . . .N/4− 1

x(4n + 1) =1

2

1

N/4

N/4−1∑n=0

P21(k)W −knN/4

n = 0, 1, . . .N/4− 1

x(4n + 3) =1

2

1

N/4

N/4−1∑n=0

P22(k)W −knN/4

n = 0, 1, . . .N/4− 1

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 94 / 100

Page 95: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

Two 2-point sequences P11(k) and P12(k) are obtained from 4-point sequence G1(k).

P11(0) = G1(0) + G1(2)

P11(1) = G1(1) + G1(3)

P12(0) = [G1(0) + G1(2)]W −08 ∵ (W −0

4 = W −08 )

P12(1) = [G1(1)− G1(3)]W −28 ∵ (W −1

4 = W −28 )

Similarly Two 2-point sequences P21(k) and P22(k) are obtained from 4-point sequenceG2(k).

P21(0) = G2(0) + G2(2)

P21(1) = G2(1) + G2(3)

P22(0) = [G2(0)− G2(2)]W −08

P22(1) = [G2(1)− G2(3)]W −28

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 95 / 100

Page 96: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

-1

-1

28W −

08W −

-1

-1

28W −

08W −

1(0)G

1(1)G

1(3)G

1(2)G

2 (0)G

2 (1)G

2 (3)G

2 (2)G

11(0)P

12 (1)P

12 (0)P

11(1)P

21(0)P

22 (1)P

22 (0)P

21(1)P

Figure 28: N=8 point decimation in frequency FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 96 / 100

Page 97: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

The 2-point IDFTs are computed directly and represented as

x(0) =1

8[P11(0) + P11(1)]

x(4) =1

8[[P11(0)− P11(1)]W −0

8

x(2) =1

8[P12(0) + P12(1)]

x(6) =1

8[P12(0)− P12(1)]W −0

8

x(1) =1

8[P21(0) + P21(1)]

x(5) =1

8[P21(0)− P21(1)]W −0

8

x(3) =1

8[P22(0) + P22(1)]

x(7) =1

8[P22(0)− P22(1)]W −0

8

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 97 / 100

Page 98: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

(4)X

(2)X

(0)X

(6)X

-1

-1 08W

08W

11(0)p

12 (1)p

12 (0)p

11(1)p

(5)X

(3)X

(1)X

(7)X

-1

-1 08W

08W

21(0)p

22(1)p

22 (0)p

21(1)p

2 point DFT

Figure 29: N=8 point decimation in frequency FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 98 / 100

Page 99: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

38W −

28W −

18W −

08W −

-1

-1

-1

-1

-1

-1

-1

28W −

08W −

-1 08W −

08W −

-1

-1

-1

28W −

08W −

-1 08W −

08W −

sequence x(n) inbit reversal order

Input DFT

2 point IDFT

(1)X

(2)X

(0)X

(3)X

(5)X

(6)X

(4)X

(7)X

(0)x

(6)x

(2)x

(4)x

(1)x

(7)x

(3)x

(5)x

11(0)P

12 (1)P

12 (0)P

11(1)P

21(0)P

22 (1)P

22 (0)P

21(1)P

1(0)G

1(1)G

1(3)G

1(2)G

2 (0)G

2 (1)G

2 (3)G

2 (2)G

1/8

1/8

1/8

1/8

1/8

1/8

1/8

Figure 30: N=8 point decimation in frequency FFT algorithm

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 99 / 100

Page 100: UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[ · Fast Fourier Transform Algorithms Introduction Computation of DFT DIT DFT Algorithm Radix-2 FFT Algorithm DFT as Linear Filtering

FFT algorithms Inverse Radix-2 DIT-FFT algorithm

Computational Complexity Decimation in Frequency (DIF)-FFTalgorithm

A a b= +

rNW

-1

a

b ( ) rNB a b W= −

Figure 31: Butterfly structure decimation in frequency FFT algorithm

Butterfly operation requires two complex additions and one complex multiplication.

In complete signal flow graph Figure 30. there are N/2=4 butterflies in every stage ofdecimation and there are log2N = 3 = v stages of decimation (for N=8).

Total number of butterfly operations =N/2log2N = 4× 3 = 12

Total number of complex additions =2× N/2× log2N = N × log2N

Total number of complex multiplications =1× N/2× log2N = N/2× log2N

Dr. Manjunatha. P (JNNCE) UNIT - 3: Fast-Fourier-Transform (FFT) algorithms[?, ?, ?, ?]October 15, 2014 100 / 100