12
Discrete Fourier Transform in 2D – Chapter 14

Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Embed Size (px)

Citation preview

Page 1: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Discrete Fourier Transform in 2D – Chapter 14

Page 2: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Discrete Fourier Transform – 1D• Forward

• Inverse

MmugM

mG

M

mui

M

muug

MmG

M

uM

mui

M

u

e

0)(1

)(

2sin2cos)(1

)(

1

0

2

1

0

MumGM

ug

M

mui

M

mumG

Mug

M

mM

mui

M

m

e

0)(1

)(

2sin2cos)(1

)(

1

0

2

1

0

M is the length (number of discrete samples)

Page 3: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Discrete Fourier Transform – 2D• After a bit of algebraic manipulation we find that the 2D

Fourier Transform is nothing more than two 1D transforms

• Do a 1D DFT over the rows of the image• Then do a 1D DFT over the columns of the row-wise

DFT• This is for an MxN (columns by rows)

1

0

21

0

2),(

11),(

N

vN

nviM

uM

mui

eevugMN

nmG

1D DFT over row g(*,v)

Page 4: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

What’s it all mean?

• Whereas for the 1D DFT we were adding together 1D sinusoidal waves…– For the 2D DFT we are adding together 2D

sinusoidal surfaces

• Whereas for the 1D DFT we considered parameters of amplitude, frequency, and phase– For the 2D DFT we consider parameters of

amplitude, frequency, phase, and orientation (angle)

Page 5: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Visualization

• A pixel in DFT space represents an orientation and frequency of the sinusoidal surface

• The corners each represent low frequency components which is inconvenient

Page 6: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Quadrant swapping

• Quadrant swapping brings all low frequency data to the center

A D

B C

C B

D A

Page 7: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

• A pixel in DFT space represents an orientation and frequency of the sinusoidal surface

Visualization

Page 8: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Visualization

• The image is really a depiction of the frequency power spectrum and as such should be thought of as a surface

• Low frequencies are at the center, high frequencies are at the boundaries

Page 9: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Visualization

• Image coordinates represent the effective frequency…

• …and the orientation

Nn

Mm

nmf

22

1),(

is the sampling interval

nMmNnm ,),( tan1

Page 10: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Something interesting

• If the DFT space is square then rotation in the spatial domain is rotation in the frequency domain

Page 11: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

Artifacts

• Since spatial signal is assumed to be periodic, drastic differences (large gradients) at the opposing edges cause a strong vertical line in the DFT

Page 12: Discrete Fourier Transform in 2D – Chapter 14. Discrete Fourier Transform – 1D Forward Inverse M is the length (number of discrete samples)

No border differences