Chap4-fast Fourier Transform

  • Uploaded by: Gurumayum Tangkeshwari
  • 0
  • 0
  • January 2021
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Chap4-fast Fourier Transform as PDF for free.

More details

  • Words: 6,898
  • Pages: 80
Loading documents preview...
Chapter 4 Fast Fourier Transform Content

Introduction Radix-2 DIT- FFT Algorithm Radix-2 DIF- FFT Algorithm

The fast algorithm of IDFT Mixed Radix FFT Algorithm Chirp-z FFT Algorithm Applications of FFT Algorithms Copyright © 2005. Shi Ping CUC

Introduction  Problems N 1

1 nk X ( k )   x( n)W N RN ( k ), x( n)  N n0

N 1

 X (k )W n0

 nk N

RN ( n )



Although the DFT is a computable transform, the straightforward implementation is very inefficient, especially when the sequence length N is large.



Direct computation of the N-point DFT requires N2 complex multiplications and N2 – N complex additions; That means 4N2 real multiplications and 4N2 -2N real additions are required. Copyright © 2005. Shi Ping CUC

Introduction  How to reduce the computational complexity 

In 1965, Cooley and Tukey showed a procedure to substantially reduce the amount of computations involved in the DFT. This led to the explosion of applications of the DFT.



All these efficient algorithms are collectively known as Fast Fourier Transform (FFT) algorithms.



Most of the computations can be eliminated using the symmetry and periodicity properties of DFT.

Copyright © 2005. Shi Ping CUC

Introduction kn  N

(W )  W

Symmetry Periodicity

nk N

W W

W

 kn N

W

N/ 2 N

mnk mN

 1,

Combine

W

W

kn N

k (n N ) N

W nk N

, W

 kn N

k ( N n) N

W

n( N k ) N

W

( k  N/ 2 ) N

W

W

(k  N )n N

nk / m N /m

 W

k N

Decomposition Copyright © 2005. Shi Ping CUC

Introduction  FFT algorithm classification DIT - FFT: Decimation-in-time FFT algorithm

DIF - FFT: Decimation-in-frequency FFT algorithm

Copyright © 2005. Shi Ping CUC

return

Radix-2 DIT- FFT Algorithm Radix-2: the sequence length N satisfied: L is an integer

N 2

L

 How does DIT-FFT operate To decompose an N point time domain signal into N signals each containing a single point. Each decomposing stage uses an interlace decomposition, separating the even- and odd-indexed samples; 

To calculate the N frequency spectra corresponding to these N time domain signals; 

To synthesize the N spectra into a single frequency spectrum. 

Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm 1 signal of 16 points

0

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

2 signals of 8 points

0

2 4 6 8 10 12 14

1

3 5 7 9 11 13 15

4 signals of 4 points

0

4 8 12

2 6 10 14

1

5 9 13

8 signals of 2 points

0 8

4 12 2 10 6 14

1 9

16 signals of 1 point

0

4 12

1

8

2 10 6 14

3 7 11 15

5 13 3 11 7 15

9 5 13

3 11 7 15

Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm  Algorithm principle 

To divide N-point sequence x(n) into two N/2-point sequence x1(r) and x2(r)

N x1 ( r )  x( 2r ); x2 ( r )  x( 2r  1) , r  0,1,2,  1 2 

To compute the DFT of x1(r) and x2(r)

X 1 (k )  X 2 (k ) 

N 1 2

 x (r )W r 0

1

N 1 2

rk N 2

 x (r )W r 0

2

rk N 2



N 1 2

 x(2r )W r 0



N 1 2

 x(2r  1)W r 0

N (k  0 ~  1) 2

rk N 2

rk N 2

N (k  0 ~  1) 2

Copyright © 2005. Shi Ping CUC



To compute the DFT of N-point sequence x(n) N 1

X ( k )   x ( n)W n0

 

nk N

N 1



 x(n)W

n  0 ( even )

N 1 2

N 1 2

r 0

r 0

nk N



N 1

 x(n)W

n  0 ( odd )

nk N

2 rk ( 2 r 1 ) k x ( 2 r ) W  x ( 2 r  1 ) W   N N N 1 2

N 1 2

rk k rk x ( r ) W  W x ( r ) W  1 N N 2 N r 0

2

 X 1 ( k )  W Nk X 2 ( k )

r 0

2

( k  0,1,2,  N  1) Copyright © 2005. Shi Ping CUC

N X ( k )  X 1 ( k )  W X 2 ( k ) ( k  0,1,   1) 2 N ( k  ) N N N 2 X (k  )  X 1 (k  )  W N X 2 (k  ) 2 2 2 N k  X 1 (k )  W N X 2 (k ) ( k  0,1,  1) 2 k N

x1 ( r )

X 1 (k )

x(n)

X (k ) x2 (r )

X 2 (k ) Copyright © 2005. Shi Ping CUC



Butterfly computation flow graph

X (k )  X 1 (k )  W X 2 (k ) k N

N X ( k  )  X 1 ( k )  W Nk X 2 ( k ) 2

X 1 (k )  WNk X 2 (k )

X 1 (k )

X 2 (k )

N ( k  0,1,   1) 2 N ( k  0,1,  1) 2

W Nk 1

X 1 (k )  WNk X 2 (k )

There are 1 complex multiplication and 2 complex additions Copyright © 2005. Shi Ping CUC

X 1 ( 0)

x1 (0)  x(0) x1 ( r )

x2 ( r )

x1 (1)  x(2) x1 (2)  x(4)

N/2point

X ( 0)

X 1 (1)

X (1)

X 1 (2)

X ( 2)

DFT

x1 (3)  x(6)

X 1 (3)

x2 (0)  x(1)

X 2 (0)

W N0

x2 (1)  x(3)

X 2 (1)

W N1

X 2 (2)

W N2

X 2 (3)

W N3

x2 (2)  x(5) x2 (3)  x(7)

N/2point DFT

X ( 3) 1

X ( 4)

1

X ( 5)

1

X ( 6)

1

X (7)

N-point DFT Copyright © 2005. Shi Ping CUC

x ( 0) x ( 4)

X ( 0)

W N0

1

x ( 2) x ( 6)

W N0

X (1)

W N0 W N2

1

1

x(1) x ( 5)

W

0 N

1

x ( 3) x(7)

W

0 N

W N0 W N2

1

X ( 2)

1

1 1

W

0 N

W

1 N

W

2 N

W

3 N

X ( 3) 1

X ( 4)

1

X ( 5)

1

X ( 6)

1

X (7)

Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm  The computation complexity

for N  23

X (k )

x (n) 2-point DFT 2-point DFT 2-point DFT 2-point DFT

Synthesize the 2-point DFTs into a 4-point DFT Synthesize the 2-point DFTs into a 4-point DFT

Synthesize the 4-point DFTs into a 8-point DFT

3-stage synthesize, each has N/2 butterfly computation Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm for

N  2L



There are L-stage synthesization, each has N/2 butterfly computations. Each butterfly computation has 1 complex multiplication and 2 complex additions.



The total number of complex multiplications is:

N N m F  L  log 2 N 2 2 

The total number of complex additions is:

aF  NL  N log 2 N Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm  The characteristics of DIT-FFT algorithm 

In-place computation

X m ( k )  X m 1 ( k )  W Nr X m 1 ( j )

X m1 (k )

X m1 ( j )

WNr 1

X m ( j )  X m 1 ( k )  W Nr X m 1 ( j )

Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm

At the end of computation flow graph at any stage, output variables can be stored in the same registers previously occupied by the corresponding input variables. This type of memory location sharing is called in-place computation which results in significant saving in overall memory requirements.

Copyright © 2005. Shi Ping CUC

Radix-2 DIT- FFT Algorithm 

Bit-reversed order

In the DFT computation scheme, the DFT samples X(k) appear at the output in a sequential order while the input samples x(n) appear in a different order: a bit-reversed order. Thus, a sequentially ordered input x(n) must be reordered appropriately before the fast algorithm can be implemented. Let m, n represent the sequential and bit-reversed order in binary forms respectively, then: m: 000

001

010

011

100

101

110

111

n:

100

010

110

001

101

011

111

000

Copyright © 2005. Shi Ping CUC



Why is the input bit-reversed order

n0

n1 0

0 1

x( n2 n1n0 ) 0

1

n2 0

x(000)

x(0)

1

x(100)

x (4)

x(010)

x (2)

1

x(110)

x(6)

0

x(001)

x (1)

1

x(101)

x(5)

x(011)

x(3)

x(111)

x (7 )

0

0

1

1

Copyright © 2005. Shi Ping CUC



How to get the bit-reversed order

Let n represent the natural order, the bit-reversed order, then:

nˆ represent the

if nˆ  n , x(n)  x(nˆ ) A(0) A(1) A( 2) A( 3)

A(4) A(5) A(6) A(7)

n

x(0) x(1) x ( 2) x ( 3)

x ( 4) x ( 5) x ( 6)



x ( 0) x ( 4) x ( 2 ) x ( 6)

x(1)

x(7)

x ( 5) x ( 3 ) x ( 7 )

Copyright © 2005. Shi Ping CUC



The distance between two nodes in a butterfly For

N 2

L

there are L stages

Stage

Distance

stage 1

1

stage 2

2

stage 3

4

 stage L

2

L 1

Copyright © 2005. Shi Ping CUC

return

Radix-2 DIF- FFT Algorithm  How does DIF-FFT operate

Copyright © 2005. Shi Ping CUC

x (n)

0

1

2

3

4

5

6

7

0

1

2

3

4

5

6

7

butterfly computation 0

1

0

1

2

2

3

0

1

2

3

3

0

1

2

3

butterfly computation

X (k )

butterfly computation

0

1

0

1

0

0

1

0

1

0

1 1

0

1

0

1

butterfly

butterfly

butterfly

butterfly

0

2

1

3

4

6

5

7

Copyright © 2005. Shi Ping CUC

Radix-2 DIF- FFT Algorithm  Algorithm principle 

To divide N-point sequence x(n) into two N/2-point sequence

The former N/2-point The latter N/2-point

N x( n), 0  n  1 2 N N x( n  ), 0  n   1 2 2

Copyright © 2005. Shi Ping CUC



To compute the DFT of N-point sequence x(n) N 1

X ( k )   x( n)W n0



N 1 2

 x(n)W n0 N 1 2

nk N

nk N

N 1 2



N 1 2

 x(n)W n0

nk N

N 1

 x(n)W



n ( n

N   x( n  )W N 2 n0

nk N

N 2

N )k 2

N k  N  nk 2    x( n)  W N x ( n  )W N 2  n0  N 1 2

N  nk  k    x( n)  ( 1) x( n  )W N 2  n0 

( k  0,1, N  1) Copyright © 2005. Shi Ping CUC

Radix-2 DIF- FFT Algorithm 

To separate the even and odd numbered samples of X(k)

N let k  2r , k  2r  1, ( r  0,1,,  1) 2 N 1 2

N  nr N  X ( 2r )    x( n)  x( n  )W N ( r  0,1,  1) 2  2 2 n0  N 1 2

N  n nr N  X ( 2r  1)    x( n)  x( n  )W N W N ( r  0,1,  1) 2  2 n0  2 Copyright © 2005. Shi Ping CUC

Radix-2 DIF- FFT Algorithm N   x1 ( n)  x( n)  x( n  2 ) let  N  n   x2 ( n)   x( n)  x( n  )W N  2   N 1 2

X ( 2r )   x1 ( n)W n0

N 1 2 n0

N ( r  0,1,  1) 2

nr N 2

X ( 2r  1)   x2 ( n)W

N n  0,1,  1 2

nr N 2

N ( r  0,1,  1) 2 Copyright © 2005. Shi Ping CUC

Radix-2 DIF- FFT Algorithm 

Butterfly computation flow graph

N x1 (n)  x(n)  x(n  ) 2

x(n)

N x( n  ) 2

W Nn 1

N  n  x 2 ( n )   x ( n )  x ( n  ) W N 2  

There are 1 complex multiplication and 2 complex additions

Copyright © 2005. Shi Ping CUC

for N  23 x1 (0)

x ( 0)

x1 (1)

x(1)

x1 (2)

x ( 2)

x ( 5) x ( 6) x(7)

N/2point

X ( 2)

DFT

X ( 4)

x1 (3)

x ( 3) x ( 4)

X ( 0)

1 1 1 1

W N0

x2 (0)

W N1

x2 (1)

W N2

x2 (2)

W N3

x2 (3)

X ( 6) X (1) N/2point

X ( 3)

DFT

X ( 5) X (7)

Copyright © 2005. Shi Ping CUC

for N  23 x ( 0)

X ( 0)

x(1) x ( 2)

1

x ( 3) x ( 4) x ( 5) x ( 6) x(7)

W 1 1 1 1

0 N

1

W N0

1

W N3

X ( 4) X ( 2)

W N0

W N2 1

X ( 6) X (1)

W N1 W N2

W N0

W N0 1 1

W N0

1

X ( 5) X ( 3)

W N0

W N2 1

X (7)

Copyright © 2005. Shi Ping CUC

Radix-2 DIF- FFT Algorithm  The comparison of DIT and DIF The order of samples DIT-FFT: the input is bit- reversed order and the output is natural order DIF-FFT: the input is natural order and the output is bitreversed order 

The butterfly computation DIT-FFT: multiplication is done before additions DIF-FFT: multiplication is done after additions 

Copyright © 2005. Shi Ping CUC

Radix-2 DIF- FFT Algorithm 

Both DIT-FFT and DIF-FFT have the identical computation complexity. i.e. for N  2 L , there are total L stages and each has N/2 butterfly computation. Each butterfly computation has 1 multiplication and 2 additions.



Both DIT-FFT and DIF-FFT have the characteristic of in-place computation.



A DIT-FFT flow graph can be transposed to a DIFFFT flow graph and vice versa.

Copyright © 2005. Shi Ping CUC

return

The fast algorithm of IDFT  Algorithm 1 X (k ) 

N 1

nk x ( n ) W  N RN ( k ) n 0

1 x ( n)  N

N 1

 nk X ( k ) W RN ( n )  N

N 2

L

k 0

In an FFT flow graph of DFT:

x( n)  X ( k ); X ( k )  x( n) W N1  W N1 ; each stage is multiplied by 1/2 Copyright © 2005. Shi Ping CUC

The fast algorithm of IDFT  Algorithm 2

1 x ( n)  N

N 1

 X (k )W k 0

 nk N 

1   nk     X ( k )W N  N  k 0  1    DFT[ X ( k )] N N 1





(k  0 ,1 , N-1 )

Copyright © 2005. Shi Ping CUC

return

Mixed Radix FFT Algorithm Mixed radix: the sequence length N satisfied: M and L are integers.

N  ML

 Algorithm principle The input and output can be represented as 2-D arrays

row index  n1  0,1, L  1 n  Mn1  n0 ,  n0  0,1, M  1 column index k1  0,1, M  1 column index k  Lk1  k0 ,  row index k0  0,1, L  1 Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm N  4  3  12 ( M  4 ,L  3) n  4n1  n0  {n0 , 4  n0 , 8  n0 }  {0,1,2,11} For example:

 n1  0,1,2  n0  0,1,2,3

n0

0

1

2

3

0

x(0)

x(1)

x(2)

x(3)

1

x(4)

x(5)

x(6)

x(7)

2

x(8)

x(9)

x(10)

x(11)

n1

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm X ( k )  X ( Lk1  k 0 )  X ( k1 , k 0 )  

M 1 L 1

  x( Mn

n0  0 n1  0



1

 n0 )W

N 1

nk x ( n ) W  N n0

( Mn1  n0 )( Lk 1  k 0 ) N

M 1 L 1

Mn1 k 0 n0 k 0 Ln 0 k1 MLn 1 k1 x ( n , n ) W W W W  1 0 N N N N

n0  0 n1  0



M 1 L 1

Mn1 k 0 n0 k 0 Ln 0 k1 x ( n , n ) W W W  1 0 N N N

n0  0 n1  0

  L 1  n0 k1 n1 k 0  n0 k 0      x ( n1 , n0 )W L W N W M n0  0   n1  0   M 1

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm X ( k )  X ( Lk1  k 0 )  X ( k1 , k 0 ) L 1    n0 k0    n0 k1 n1 k 0      x ( n1 , n0 )W L W N W M  n0  0     n1  0  M 1



 X

M 1 n0  0



1

( k 0 , n0 )W

n0 k 0 N

M 1

 X  (k

n0  0

1

0

, n0 )W

n0 k1 M

W

n0 k1 M

 X 2 ( k 0 , k1 )

( k 0  0,1,  , L  1; k1  0,1,  , M  1) Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm  Computation procedures 

Store the input signal row-wise

suppose N  4  3, ( M  4 ,L  3)

n  4n1  n0 (n1  0,1,2; n0  0,1,2,3) n0 0 n1

1

2

3

0

x(0)

x(1)

x(2)

x(3)

1

x(4)

x(5)

x(6)

x(7)

2

x(8)

x(9) x(10) x(11) Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm 

Compute the L-point DFT at each column

X 1 ( k0 , n0 ) 

L 1

 x( n , n 1

n1  0

0

x(n1 , n0 ) n0

X 1 ( k0 , n0 )

0

1

2

3

0

x(0)

x(1)

x(2)

x(3)

1

x(4)

x(5)

x(6)

2

x(8)

x(9)

n1

)W

n1 k 0 L

n0

0

1

2

3

0

X1

X1

X1

X1

x(7)

1

X1

X1

X1

X1

x(10) x(11)

2

X1

X1

X1

X1

k0

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm 

Multiply the resulting array by twiddle factor

X 1 (k0 , n0 )  X 1 (k0 , n0 )  W

n0

n0 k0 N

X 1 ( k0 , n0 )

X 1 ( k0 , n0 ) 0

1

2

3

0

X1

X1

X1

X1

1

X1

X1

X1

2

X1

X1

X1

k0

W Nn0 k0

n0

0

1

2

3

0

X1’

X1’

X1’

X1’

X1

1

X1’

X1’

X1’

X1’

X1

2

X1’

X1’

X1’

X1’

k0

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm 

Compute the M-point DFT of each row

X 2 ( k0 , k1 ) 

M 1

 X  (k

n0  0

1

X 1 ( k0 , n0 ) n0

0

, n0 )W

n0 k1 M

X 2 ( k0 , k1 )

0

1

2

3

k 0 k1

0

1

2

3

0

X1’

X1’

X1’

X1’

0

X2

X2

X2

X2

1

X1’

X1’

X1’

X1’

1

X2

X2

X2

X2

2

X1’

X1’

X1’

X1’

2

X2

X2

X2

X2

k0

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm 

Read the resulting array column-wise

M  4 ,L  3

X 2 ( k0 , k1 ) k 0 k1

0

0

XX(20)

XX(23) XX(26)

1

XX(21)

XX(24) XX(27) XX(10 2 )

2

XX(22) XX(25) XX(28) XX(11 2 )

1

2

3

XX(29)

X ( k )  X ( k1 , k0 )  X ( Lk1  k0 )

k  Lk1  k0  k1  0,1,2,3  k0  0,1,2 Copyright © 2005. Shi Ping CUC

x ( n) x( n1 , n0 )

X 1 (k0 , n0 )  W

4

10 9

8

11

3-point DFT

5

6

3-point DFT

0

7

3-point DFT

1

2

3-point DFT

3

n0 k0 N

X (k ) X 2 ( k0 , k1 ) 9 6 3 0

4

10 7 11 8

1 5 2

Copyright © 2005. Shi Ping CUC

X 1 (n0 , k0 )  WNn0k0

x (n) n n1 0

0

4

1

8

2

1

0

5

1

9

2

2

0

6

1

10

2

3

0

7

1

11

2

k0 3-point DFT n0=0 3-point DFT n0=1 3-point DFT n0=2 3-point DFT n0=3

0 1 2 0 1 2 0 1 2 0 1 2

0 12 0 12 0 12

W W W

W120 W121 W122 0 12 2 12 4 12

W W W

0 12 3 12 6 12

W W W

4-point DFT k0=0

4-point DFT k0=1

4-point DFT k0=2

X (k ) k

k1

k

0

0

0

1

3

1

2

6

2

3

9

3

0

1

4

1

4

5

2

7

6

3

10

7

0

2

8

1

5

9

2

8

10

3

11

11

Copyright © 2005. Shi Ping CUC

2

3-point DFT

X ( k )   x ( n)W3nk n0 2

X ( 0)   x ( n)  x (0)  x (1)  x ( 2) n0 2

X (1)   x ( n)W3n  x (0)  x (1)W31  x ( 2)W32 n0 2

X ( 2)   x ( n)W32 n  x (0)  x (1)W32  x ( 2)W34 n0

x ( 0)

X ( 0)

W30 W30 W30

x(1)

X (1)

W30 W31 W32

x ( 2)

X ( 2)

W30 W32 W34 Copyright © 2005. Shi Ping CUC

3

4-point DFT

X (0)   x( n)  x(0)  x(1)  x( 2)  x( 3) n0 3

X (1)   x( n)W4n  x(0)  x(1)W41  x( 2)W42  x( 3)W43 n0 3

X ( 2)   x( n)W42 n  x(0)  x(1)W42  x( 2)W44  x( 3)W46 n0 3

X ( 3)   x( n)W43 n  x(0)  x(1)W43  x( 2)W46  x( 3)W49 n0

W40 W40 W40W40

x ( 0)

X ( 0)

x(1)

X (1)

x ( 2)

X ( 2)

W W W W

x ( 3)

X ( 3)

W40 W43 W46W49

0 4

1 4

2 4

3 4

0 4

2 4

4 4

6 4

W W W W

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm Another alternative computation procedures: 

Store the input signal column-wise



Compute the M-point DFT at each row



Multiply the resulting array by the twiddle factor



Compute the L-point DFT of each column



Read the resulting array row-wise

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm

N  ML

 Computation complexity

M L-point DFT The number of complex multiplications is ML2 The number of complex additions is ML ( L  1) 



Multiplication by twiddle factor

N

L M-point DFT The number of complex multiplications is LM 2 The number of complex additions is LM ( M  1) 

Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm 

Mixed Radix FFT

ML  N  LM  N ( M  L  1) Complex additions ML ( L  1)  ML ( M  1)  N ( M  L  2) Complex multiplications



2

2

Direct computation of the DFT

N2 Complex additions N ( N  1) Complex multiplications

N2 N R   N ( M  L  1) M  L  1

N ( N  1) N 1 R   N ( M  L  2) M  L  2 Copyright © 2005. Shi Ping CUC

Mixed Radix FFT Algorithm For 

N  N1 N 2  N L

Mixed Radix FFT

Complex multiplications

 L   N   N i   L  1  i 1  

 L   Complex additions N   N i   L  i 1   N i is a prime number, but N i  2 Copyright © 2005. Shi Ping CUC

return

Chirp-z Transform Algorithm  Algorithm principle 

Suppose that we wish to compute the value of the ztransform of x(n) at a set of points {zk, k=0,1,…,M-1} and these points {zk} fall on an arc, then: N 1

X ( zk )   x( n)z k n (0  k  M  1) n0

k

zk  AW , A  A0e

j 0

, W  W0e

 j0

zk  ( A0e j0 )(W0 k )e jk0  A0W0 k e j (0  k0 ) Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm

z0  A0e

j 0

Unit circle

Im( z )

z1  A0W01e j ( 0 0 ) 2 0

z2  A0W e

j ( 0  20 )

  k j ( 0  k0 ) zk  A0W0 e 

Re(z )

z M 1  A0W0( M 1)e j[ 0 ( M 1)0 ] Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm k 0

zk  A0W e 



j ( 0  k0 )

If W0 >1, the points fall on a contour that spirals toward the origin; If W0<1, the points fall on a contour

that spirals away from the origin; 

A0

z0

0

Re(z )

A0 , 0 will determined the position of



0

Im( z )

z0

 0 is the frequency increment in radians between two neighboring samples Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm k 0

zk  A0W e if

j ( 0  k0 ) Im( z )

MN

A  A0 e j 0  1 ( A0  1, 0  0) W  W0 e

 j 0

e

j

2 N

Re(z )

2 (W0  1,  0  ) N Chirp-z transform

DFT Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm 1 2 2 2 let nk  [n  k  ( k  n) ] 2 N 1

N 1

n0

n0

X ( z k )   x ( n) z k n   x( n) A nW nk N 1

n2 2

  x( n) A nW W

( k  n )2  2

W

k2 2

n0

W

 n  x ( n) A W  n0 

k 2 N 1 2

g (n)

n2 2

 W 

( k  n )2  2

(0  k  M  1)

h( k  n) Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm n

let g( n)  x( n) A W h( n)  W

X ( zk )  W k2 2

n2 2

(0  n  N  1)

n2  2

k 2 N 1 2

 g(n)h(k  n) n0

 W [ g( n)  h( n)]

(0  k  M  1) Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm Flow graph

g (n)

x (n)

h(n)

(0  n  N  1)

A nW

n2 2

X ( zk )

f (k )

(0  k  M  1)

W

k2 2

Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm if W0  1, h( n)  W

n2  2

e

j

0 2 n 2

h(n) is a complex exponential sequence n 20 The phase 2

The frequency in radians n 0 The frequency of h(n) increases linearly with time. Such signals are used in radar systems and are called chirp-z signals.

Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm  Implementation procedures

x( n) : N (0 ~ N  1) n2 2

g( n)  x ( n) A nW : N (0 ~ N  1) h( n) : M  N - 1 {-(N - 1) ~ ( M  1)} f ( k )  g ( n)  h( n) : 2 N  M  2 {( N  1) ~ ( M  N  2)} If we want to compute this linear convolution with circular convolution, the period L should be satisfied

L  N  M 1

L2

m Copyright © 2005. Shi Ping CUC

g (n) N

0

N-1

n

h(n) N+M-1 -(N-1)

M-1

0

n

f (k ) N-1 -(N-1)

2N+M-2 M 0

M-1

N-1 N+M-2

k

Copyright © 2005. Shi Ping CUC

Implementation scheme

x (n)

g (n) L-point DFT

0  n  N 1

G (r )

F (r )

f (k )

X ( zk )

L-point IDFT

0  k  M 1

H (r ) n

A W

L-point DFT

n2 2

h(n)

W

k2 2

hL (n)

hL (n)  h(( n)) L  RL (n) Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm  Computation complexity The number of complex multiplications

g( n)  x( n) A nW

n2 2

(0  n  N  1) : N L G( r )  DFT[ g( n)] : log 2 L 2 L H ( r )  DFT[hL ( n)] : log 2 L 2 F ( r )  G( r )  H ( r ) : L L f ( k )  IDFT[ F ( r )] : log 2 L 2 k2 X ( zk )  f ( k )  W 2 (0  k  M  1) : M Copyright © 2005. Shi Ping CUC

Chirp-z Transform Algorithm A nW

n2 2

h( n)  W

: n2  2

2N :

2N

The total number of complex multiplications

3 L log 2 L  5 N  L  M 2 Copyright © 2005. Shi Ping CUC

return

Applications of FFT Algorithms  Efficient computation of the DFT of two N-point real sequence Suppose that x1 ( n) and x2 ( n) are two real-valued sequences of length N, and let x (n) be a complex-valued sequence defined as x(n)  x1 (n)  jx 2 (n) (0  n  N  1)

X (k )  DFT[ x(n)]  X1 (k )  jX 2 (k )

(0  k  N  1)

1 X 1 ( k )  DFT[ x1 ( n)]  X ep ( k )  [ X ( k )  X * (( N  k )) N RN ( k )] 2 1 1 X 2 ( k )  DFT[ x2 ( n)]  X op ( k )  [ X ( k )  X * (( N  k )) N RN ( k )] j 2j Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms  Efficient computation of the DFT of a 2N-point real sequence

g (n) is a real-valued sequences of length 2N Subdivide g (n) into two N-point real-valued sequences x1 (n)  g(2n) x2 (n)  g(2n  1) (0  n  N  1) Let x (n) be the N-point complex-valued sequence x(n)  x1 (n)  jx 2 (n)

(0  n  N  1)

1 X 1 ( k )  DFT[ x1 ( n)]  [ X ( k )  X  (( N  k )) N RN ( k )] 2 1 X 2 ( k )  DFT[ x2 ( n)]  [ X ( k )  X  (( N  k )) N RN ( k )] 2j Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms G(k ) 

2 N 1

N 1

n0 N 1

n0

nk 2 nk ( 2 n 1 ) k g ( n ) W  g ( 2 n ) W  g ( 2 n  1 ) W    2N 2N 2N n0

N 1

  g( 2n)W n0 N 1

N 1

2 nk 2N

W

k 2N

 g(2n  1)W

n0 N 1

2 nk 2N

  x1 ( n)W Nnk  W2kN  x 2 ( n)W Nnk n0

n0

 X 1 ( k )  W2kN X 2 ( k )

(0  k  N  1)

G( k  N )  X 1 ( k )  W X 2 ( k ) k 2N

(0  k  N  1) Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms Computation complexity An N-point DFT and 2-stage butterfly computations

N complex multiplications log 2 N  2 N 2 complex additions N log 2 N  4 N if computing the 2N-point real sequences directly

complex multiplications N log 2 2 N complex additions 2 N log 2 2 N Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms  FFT algorithms for linear convolution 

Linear convolution is a key operation in many signal processing applications



Since a DFT can be efficiently implemented using FFT algorithms, it is of interest to develop methods for the implementation of linear convolution using the DFT Let x(n) and h(n) be two sequences of length L and M, respectively. Denote N = L+M-1



 x( n), 0  n  L  1 x( n)   L  n  N 1  0,

 h( n), 0  n  M  1 h( n)   M  n  N 1  0, Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms

y( n)  x( n)  h( n)  x( n) N h(n) Implementation scheme

x (n)

h(n)

Zero-padding (N-L)

Zero-padding (N-M)

x(n) h(n)

N-point DFT

y(n) N-point IDFT

N-point DFT

Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms If x(n) is an infinite length sequence (or a finite length sequence of length much greater than M ), then

We can first segment x(n) into a set of contiguous finite-length subsequences xi(n) of length L each:

 x( n), iL  n  ( i  1) L  1 x i ( n)   otherwise  0,

i  0,1,

Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms 

x ( n)   x i ( n) i 0



y( n)  x( n)  h( n)   xi ( n)  h( n) i 0

 x0 ( n)  h( n)  x1 ( n)  h( n)  x2 ( n)  h( n)   There are two methods for computing these short convolutions using DFT and fitting the outputs together

 Overlap-add method  Overlap-save method Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms Overlap-add method Each of these short convolutions can be implemented using the DFT-based method discussed earlier, where now the DFTs (and the IDFT) are computed on the basis of N points. 

N  2  L  M 1 m

yi (n)  xi (n) N h(n) i  0,1, The results of the short linear convolutions overlap and the overlapped portions are added to get the correct final result. 

y( n)   yi ( n)  y0 ( n)  y1 ( n)   i 0

Copyright © 2005. Shi Ping CUC

x (n)

L

L

L

M-1

x 0 ( n)

0

L

L

N

x1 (n)

0

x2 (n)

0

y0 ( n )

y1 (n)

y(n)

y2 (n)

Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms 

Overlap-save method

N  L  M  1, ( N  2 ) m

Each data block xi (n) consists of the last M-1 data points of the previous data block xi 1 ( n) followed by L new data points to form a data sequence of length N. The first data block x0 ( n) consists of M-1 zeros followed by L data points. An N-point DFT is computed for each data block.

Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms yi (n)  xi (n) N h(n) The first M-1 points of yi (n) are corrupted by aliasing and must be discarded. To avoid loss of data due to aliasing, the last M-1 points of each data block are saved and these points become the first M-1 data points of the subsequent data block.

 yi ( n), M  1  n  N  1 y i ( n)   otherwise  0, 

y( n)   yi [n  i ( N  M  1)] i 0

Copyright © 2005. Shi Ping CUC

yi (n)  xi (n)  h(n)

N  M 1

yi (n)  xi (n) N h(n)  yi (( n)) N RN (n) yi (n) N+M-1

yi (n) M-1

N

L N+M-1

M-1

N

N+M-1

N+M-1

yi (n)

L Copyright © 2005. Shi Ping CUC

x (n)

L

L

L

L

x 0 ( n)

x1 (n)

x2 (n)

x 3 ( n)

N

0

x0 ( n)

M-1

x1 (n) M-1

x2 (n)

N

M-1

y0 (yn0)( n) M-1

y(n)

y1 (yn1 ()n) y2y(n 2 ()n) Copyright © 2005. Shi Ping CUC

Applications of FFT Algorithms  FFT algorithms for linear correlation

x (n) L-point sequence Linear correlation

N  L  M  1, ( N  2 ) m

y(n) M-point sequence

rxy ( n) 

M 1

 x ( n  m ) y (m ) 

m 0

N-point FFT

X ( k )  DFT[ x( n)]

N-point FFT

Y ( k )  DFT[ y( n)]

N multiplication

Rxy (k )  X (k )Y  (k )

N-point IFFT

rxy ( n)  IDFT[ Rxy ( k )] Copyright © 2005. Shi Ping CUC

return

g (n) 8-point real-valued sequence (2N=8) x (n) 4-point complex-valued sequence (N=4) x (n)

X 1 (k )

X (k ) 4point

1/ 2

G ( 0)

1/ 2

G (1)

1/ 2

G ( 2)

1/ 2

G ( 3)

DFT



X (( N  k )) N RN ( k )

1

0 1 / 2 j W8

1 1

1/ 2 j W

1 8

2 W 1/ 2 j 8

1/ 2 j W

1

3 8

G ( 4) 1 1 1

G ( 5) G ( 6) G (7)

1

X 2 (k )

return

Copyright © 2005. Shi Ping CUC

Related Documents

Series Fourier
January 2021 0
Analisis De Fourier Hsu.pdf
February 2021 0
Series De Fourier
January 2021 0
Discrete Cosine Transform
February 2021 1

More Documents from "Rahul Kumar"