ee 4780 l.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
EE 4780 PowerPoint Presentation
Download Presentation
EE 4780

Loading in 2 Seconds...

play fullscreen
1 / 42

EE 4780 - PowerPoint PPT Presentation


  • 198 Views
  • Uploaded on

EE 4780. 2D Discrete Fourier Transform (DFT). 2D Discrete Fourier Transform. 2D Fourier Transform. 2D Discrete Fourier Transform (DFT). 2D DFT is a sampled version of 2D FT. 2D Discrete Fourier Transform. Inverse DFT. 2D Discrete Fourier Transform (DFT). where and .

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'EE 4780' - adamdaniel


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
ee 4780

EE 4780

2D Discrete Fourier Transform (DFT)

2d discrete fourier transform
2D Discrete Fourier Transform
  • 2D Fourier Transform
  • 2D Discrete Fourier Transform (DFT)

2D DFT is a sampled version of 2D FT.

2d discrete fourier transform3
2D Discrete Fourier Transform
  • Inverse DFT
  • 2D Discrete Fourier Transform (DFT)

where and

2d discrete fourier transform4
2D Discrete Fourier Transform
  • Inverse DFT
  • It is also possible to define DFT as follows

where and

2d discrete fourier transform5
2D Discrete Fourier Transform
  • Inverse DFT
  • Or, as follows

where and

periodicity
Periodicity
  • [M,N] point DFT is periodic with period [M,N]

1

periodicity11
Periodicity
  • [M,N] point DFT is periodic with period [M,N]

1

convolution
Convolution
  • Be careful about the convolution property!

Length=P+Q-1

Length=Q

Length=P

For the convolution property to hold, M must be greater than or equal to P+Q-1.

convolution13
Convolution
  • Zero padding

4-point DFT

(M=4)

dft in matlab
DFT in MATLAB
  • Let f be a 2D image with dimension [M,N], then its 2D DFT can be computed as follows:

Df = fft2(f,M,N);

  • fft2 puts the zero-frequency component at the top-left corner.
  • fftshift shifts the zero-frequency component to the center. (Useful for visualization.)
  • Example:

f = imread(‘saturn.tif’); f = double(f);

Df = fft2(f,size(f,1), size(f,2));

figure; imshow(log(abs(Df)),[ ]);

Df2 = fftshift(Df);

figure; imshow(log(abs(Df2)),[ ]);

dft in matlab15
DFT in MATLAB

f

Df = fft2(f)

After fftshift

dft in matlab16
DFT in MATLAB
  • Let’s test convolution property

f = [1 1];

g = [2 2 2];

Conv_f_g = conv2(f,g); figure; plot(Conv_f_g);

Dfg = fft (Conv_f_g,4); figure; plot(abs(Dfg));

Df1 = fft (f,3);

Dg1 = fft (g,3);

Dfg1 = Df1.*Dg1; figure; plot(abs(Dfg1));

Df2 = fft (f,4);

Dg2 = fft (g,4);

Dfg2 = Df2.*Dg2; figure; plot(abs(Dfg2));

Inv_Dfg2 = ifft(Dfg2,4);

figure; plot(Inv_Dfg2);

dft in matlab17
DFT in MATLAB
  • Increasing the DFT size

f = [1 1];

g = [2 2 2];

Df1 = fft (f,4);

Dg1 = fft (g,4);

Dfg1 = Df1.*Dg1; figure; plot(abs(Dfg1));

Df2 = fft (f,20);

Dg2 = fft (g,20);

Dfg2 = Df2.*Dg2; figure; plot(abs(Dfg2));

Df3 = fft (f,100);

Dg3 = fft (g,100);

Dfg3 = Df3.*Dg3; figure; plot(abs(Dfg3));

dft in matlab18
DFT in MATLAB
  • Scale axis and use fftshift

f = [1 1];

g = [2 2 2];

Df1 = fft (f,100);

Dg1 = fft (g,100);

Dfg1 = Df1.*Dg1;

t = linspace(0,1,length(Dfg1));

figure; plot(t, abs(Dfg1));

Dfg1_shifted = fftshift(Dfg1);

t2 = linspace(-0.5, 0.5, length(Dfg1_shifted));

figure; plot(t, abs(Dfg1_shifted));

dft domain filtering
DFT-Domain Filtering

a = imread(‘cameraman.tif');

Da = fft2(a);

Da = fftshift(Da);

figure; imshow(log(abs(Da)),[]);

H = zeros(256,256);

H(128-20:128+20,128-20:128+20) = 1;

figure; imshow(H,[]);

Db = Da.*H;

Db = fftshift(Db);

b = real(ifft2(Db));

figure; imshow(b,[]);

H

Frequency domain

Spatial domain

low pass filtering
Low-Pass Filtering

61x61

81x81

121x121

high pass filtering25
High-Pass Filtering

High-pass filter

anti aliasing
Anti-Aliasing

a=imread(‘barbara.tif’);

anti aliasing27
Anti-Aliasing

a=imread(‘barbara.tif’);

b=imresize(a,0.25);

c=imresize(b,4);

anti aliasing28
Anti-Aliasing

a=imread(‘barbara.tif’);

b=imresize(a,0.25);

c=imresize(b,4);

H=zeros(512,512);

H(256-64:256+64, 256-64:256+64)=1;

Da=fft2(a);

Da=fftshift(Da);

Dd=Da.*H;

Dd=fftshift(Dd);

d=real(ifft2(Dd));

noise removal
Noise Removal
  • For natural images, the energy is concentrated mostly in the low-frequency components.

“Einstein”

DFT of “Einstein”

Profile along the red line

Signal vs Noise

Noise=40*rand(256,256);

noise removal30
Noise Removal
  • At high-frequencies, noise power is comparable to the signal power.

Signal vs Noise

  • Low-pass filtering increases signal to noise ratio.
appendix impulse train
Appendix: Impulse Train
  • The Fourier Transform of a comb function is
impulse train cont d
Impulse Train (cont’d)
  • The Fourier Transform of a comb function is

(Fourier Trans. of 1)

?

appendix downsampling
Appendix: Downsampling
  • Question: What is the Fourier Transform of ?
downsampling
Downsampling
  • Let

Using the multiplication property:

example42
Example

No aliasing if