Lecture 6: Discrete Fourier Transform

Similar documents
(i) Represent continuous-time periodic signals using Fourier series

18.085: Summer 2016 Due: 3 August 2016 (in class) Problem Set 8

w n = c k v n k (1.226) w n = c k v n k + d k w n k (1.227) Clearly non-recursive filters are a special case of recursive filters where M=0.

Review of Concepts from Fourier & Filtering Theory. Fourier theory for finite sequences. convolution/filtering of infinite sequences filter cascades

Definition. A signal is a sequence of numbers. sequence is also referred to as being in l 1 (Z), or just in l 1. A sequence {x(n)} satisfying

Summary of lecture 1. E x = E x =T. X T (e i!t ) which motivates us to define the energy spectrum Φ xx (!) = jx (i!)j 2 Z 1 Z =T. 2 d!

The Discrete Fourier Transform

Algorithms of Scientific Computing

Scientific Computing: An Introductory Survey

FFT Octave Codes (1B) Young Won Lim 7/6/17

LAB # 5 HANDOUT. »»» The N-point DFT is converted into two DFTs each of N/2 points. N = -W N Then, the following formulas must be used. = k=0,...

Problem Set 8 - Solution

EE482: Digital Signal Processing Applications

MATLAB Laboratory 10/14/10 Lecture. Taylor Polynomials

Quantitative Understanding in Biology Fourier Analysis and Signal Processing

Nov EXAM INFO DB Victor Phillip Dahdaleh Building (DB) - TEL building

Correlation, discrete Fourier transforms and the power spectral density

INFE 5201 SIGNALS AND SYSTEMS

Discrete Fourier Transform

Engineering Geodesy I. Exercise 3: Monitoring of a Bridge Determination of the Eigenfrequencies

4.1. If the input of the system consists of the superposition of M functions, M

Nonhomogeneous Linear Differential Equations with Constant Coefficients - (3.4) Method of Undetermined Coefficients

EE482: Digital Signal Processing Applications

Math 56 Homework 5 Michael Downs

(i) Understanding the characteristics and properties of DTFT

Quantitative Understanding in Biology Module IV: ODEs Lecture III: Fourier Analysis

DFT Octave Codes (0B) Young Won Lim 4/15/17

!Sketch f(t) over one period. Show that the Fourier Series for f(t) is as given below. What is θ 1?

Computational Data Analysis!

Lecture 4 Filtering in the Frequency Domain. Lin ZHANG, PhD School of Software Engineering Tongji University Spring 2016

CS 179: GPU Programming. Lecture 9 / Homework 3

The Discrete Fourier Transform

Fourier Transform in Image Processing. CS/BIOEN 6640 U of Utah Guido Gerig (slides modified from Marcel Prastawa 2012)

MARN 5898 Fourier Analysis.

FILTERING IN THE FREQUENCY DOMAIN

EP375 Computational Physics

CS 179: GPU Programming. Lecture 9 / Homework 3

Review of Linear Systems Theory

Mathematical methods and its applications Dr. S. K. Gupta Department of Mathematics Indian Institute of Technology, Roorkee

8/19/16. Fourier Analysis. Fourier analysis: the dial tone phone. Fourier analysis: the dial tone phone

Analysis of Impulse Response for a linear system

CS711008Z Algorithm Design and Analysis

ECG782: Multidimensional Digital Signal Processing

Information and Communications Security: Encryption and Information Hiding

FOURIER TRANSFORM METHODS David Sandwell, January, 2013

Topic 7. Convolution, Filters, Correlation, Representation. Bryan Pardo, 2008, Northwestern University EECS 352: Machine Perception of Music and Audio

There and back again A short trip to Fourier Space. Janet Vonck 23 April 2014

LABORATORY 1 DISCRETE-TIME SIGNALS

3. Lecture. Fourier Transformation Sampling

SEISMIC WAVE PROPAGATION. Lecture 2: Fourier Analysis

EE 313 Linear Systems and Signals The University of Texas at Austin. Solution Set for Homework #1 on Sinusoidal Signals

Data Processing and Analysis

1D Wave PDE. Introduction to Partial Differential Equations part of EM, Scalar and Vector Fields module (PHY2064) Richard Sear.

Image Analysis. 3. Fourier Transform

Lecture 5. Complex Numbers and Euler s Formula

Trig Identities. or (x + y)2 = x2 + 2xy + y 2. Dr. Ken W. Smith Other examples of identities are: (x + 3)2 = x2 + 6x + 9 and

Fundamentals of the DFT (fft) Algorithms

Fourier Analysis and Power Spectral Density

Computer Vision. Filtering in the Frequency Domain

Introduction to Fourier Analysis Part 2. CS 510 Lecture #7 January 31, 2018

SOLUTIONS to ECE 2026 Summer 2018 Problem Set #3

Outline. Introduction

E2.5 Signals & Linear Systems. Tutorial Sheet 1 Introduction to Signals & Systems (Lectures 1 & 2)

Slow mo guys Saccades.

DOING PHYSICS WITH MATLAB FOURIER ANALYSIS FOURIER TRANSFORMS

Chapter 1 Divide and Conquer Polynomial Multiplication Algorithm Theory WS 2015/16 Fabian Kuhn

Digital Image Processing. Filtering in the Frequency Domain

Fourier Syntheses, Analyses, and Transforms

Technische Universität Kaiserslautern WS 2016/17 Fachbereich Mathematik Prof. Dr. J. Franke 19. January 2017

Discrete-Time Fourier Transform

3 rd class Mech. Eng. Dept. hamdiahmed.weebly.com Fourier Series

Response to Periodic and Non-periodic Loadings. Giacomo Boffi. March 25, 2014

Introduction to Signal Analysis Parts I and II

SE 461 Computer Vision. Nazar Khan PUCIT Lectures 5, 6 and 7

Fourier Transform and Frequency Domain

Fig. 1: Fourier series Examples

MA3232 Summary 5. d y1 dy1. MATLAB has a number of built-in functions for solving stiff systems of ODEs. There are ode15s, ode23s, ode23t, ode23tb.

Digital Signal Processing: Signal Transforms

Discrete-time signals and systems

Ch. 7.3, 7.4: Vectors and Complex Numbers

Signals and Systems Laboratory with MATLAB

E : Lecture 1 Introduction

Introduction to the Fourier transform. Computer Vision & Digital Image Processing. The Fourier transform (continued) The Fourier transform (continued)

In this Lecture. Frequency domain analysis

Intelligent Visual Prosthesis

Digital Signal Processing Lab 3: Discrete Fourier Transform

Recap of Monday. Linear filtering. Be aware of details for filter size, extrapolation, cropping

Section 6: Summary Section 7

CE 513: STATISTICAL METHODS

LAB 2: DTFT, DFT, and DFT Spectral Analysis Summer 2011

Homework Set 4 - SOLUTIONS

Today s lecture. Local neighbourhood processing. The convolution. Removing uncorrelated noise from an image The Fourier transform

Image Filtering, Edges and Image Representation

ANALOG AND DIGITAL SIGNAL PROCESSING ADSP - Chapter 8

Centre for Mathematical Sciences HT 2017 Mathematical Statistics

Computer Exercise 0 Simulation of ARMA-processes

Fourier Series and Fourier Transforms

Introduction to Decision Sciences Lecture 6

Jim Lambers ENERGY 281 Spring Quarter Lecture 5 Notes

Original application to speech was for data compression. Factor of about 10 But data compression is of less interest for speech these days

Transcription:

Lecture 6: Discrete Fourier Transform In the previous lecture we introduced the discrete Fourier transform as given either by summations or as a matrix vector product The discrete Fourier transform of f [f f f n- ] is another vector whose k th component is n n i( πk) j/ n i( π / n) kj j j j n kj f j j e f e f j Or, in terms of a matrix product it is kj Ff where F has kj component Three very important properties include trig functions, inverse discrete Fourier transforms and the convolution identity These will allow us to formulate a filter to purge images of unwanted periodic noise, see the Matlab code fftsinem The Matlab code ffttrigm computed the discrete Fourier transform for the sine and cosine functions with different frequencies f and f 4 Note the spikes occur at frequencies f and n-f The amplitudes are proportional the ±n/, will be positive real for the cosine function and opposite sign and imaginary for the sine function 4 3 real(fft(8*cos(*pi**t))) - 4 6 8 frequency imag(fft(4*(sin(*pi*4*t))) - - 4 6 8 frequency

Discrete Fourier Transform of Trig Functions Let t : /(n-): The discrete Fourier transform of e iπf t is for k f and n for k f The discrete Fourier transform of e -iπf t is for k n-f and n for k n-f The discrete Fourier transform of cos(πf t) is for k f or n-f, n/ for k f and n-f The discrete Fourier transform of sin(πf t) is for k f or n-f, (-n/)i for k f and (n/) i for k n-f The proofs of the Fourier transforms for the sine and cosine vectors follow from the Fourier transforms of the exponential functions and Euler s formula The above example also illustrates these properties In order to understand the first formula, consider the special case n 3 and use the matrix representation for the discrete Fourier transform iπ f e iπ f t iπ f/3 f Fe e iπ f /3 f e If f, + + 3 iπ f t Fe + + + + If f, + + iπ f t Fe 3 + + + + If f, F + + + + + + 3 iπ f t e The reader should verify the remaining Fourier transforms

The Inverse Discrete Fourier Transform The inverse discrete Fourier transform of g [g g g n- ] is another vector whose k th component is n n i( πk) j/ n i( π / n) kj e g j e g n n j j n n j Or, in terms of a matrix product it is kj F g where F has kj component n kj In order to confirm this, again consider the special case n 3 g j j FF 3 + + + + + + 3 + + + + + + + + + + + + 3 3 I 3 3 The inverse Fourier transform can be efficiently computed by using the same technique as in the fast Fourier transform The following illustrates the Matlab command ifft() for computing the inverse Fourier transform: >> f [ 7 ] >> g fft(f) g -35-433i -35 + 433i >> ifft(g) ans 7

The Discrete Convolution and Fourier Transform The discrete convolution of two vectors of length n is vector of length n- The components correspond to the n- degree polynomial that is a product of the two n- degree polynomials with coefficients from the two vectors of length n For example, for n 3 and the two vectors a [a a a ] and b [b b b ]: p ( x) p ( x) ( a + a x + a x )( b + b x + b x ) a b conv( a, b) a b ( ) ( ) 3 4 ( ) ( ab) + ab + ba x + ab + ab + ab x + ( ab + ab) x + ab x The convolution of a and b conv( a, b) Then [ ab ab+ ba ab + ab+ ab ab + ab ab] p p ( x) p ( x) The analogue of the convolution property for the discrete Fourier transforms requires the use of padded discrete Fourier transforms This is a technical difficulty caused be the fact that the dimension of vectors increase during the convolution of two vectors Let a be a n vector A padded a vector, is a n- vector with a in the first n components and eros in the last n- components For example, let n 3 and a [a a a ] A a a Its Fourier transform is a a 3 4 a 4 3 4 FA a a + a+ 3 4 3 a 4 3 4 3 The component wise product with a Fourier transform of a padded vectors of a and b is

4 4 FA* F B ( a + a + a)*( b + b + b) 3 3 4 3 4 3 4 ab + ( ab + ab ) + ( ab + ab + ab ) 3 4 3 3 4 3 + ( ab + ab ) + ab 4 Fconv( a, b) Convolution Property Let A and B be the padded vectors of two n vectors a and b The n- dimensional Fourier transform of the convolution of a and b is the point wise or array product of the Fourier transforms of A and B: Fconv( a, b) FA * F B Example Let n 3 and a [ 3 6] and b [8 6 3] >> a [ 3 6] >> b [8 6 3] >> conv(a,b) ans 6 36 7 45 8 >> A [a ] >> B [b ]

>> ffta fft(a) ffta -97-63799i 47 + 3943i 47-3943i -97 + 63799i >> fftb fft(b) fftb 7 747-74697i 479-6735i 479 + 6735i 747 + 74697i >> lhs fft(conv(a,b)) lhs e+ * 87-697 - 399i 847 + 5i 847-5i -697 + 399i >> rhs ffta*fftb rhs e+ * 87-697 - 399i 847 + 5i 847-5i -697 + 399i The convolution property can be restated as conv a b A B (, ) F ( F * F )

If B is an image, then its Fourier transform will reflect the frequencies of the periodic parts of the image By masking or filtering out the unwanted frequencies one can obtained a new image by applying the inverse Fourier transformation A filter is a matrix with the same dimension as the Fourier transform of the padded image whose components vary from to If the component is, then the frequency is allowed to pass; if the component is, then the frequency is tossed out Let Filter represent such a matrix Then the filtered image is NewB F ( Filter * F B) Application to Low Pass Filter Periodic Noise on Sine Curve - - 3 4 5 6 7 8 9 6 4 Shifted Fourier Transform 5 5 5

Matlab Code fftsinem to Filter High Frequencies clear; t ::; % Define sin( pi t) with high frequency variations x *sin(*pi*t) + *sin(*pi**t) + *cos(*pi**t); fftx fft(x,); fftx fftshift(fftx); % Padded fft figure() subplot(,,); plot(t,x); subplot(,,); plot(abs(fftx)); freqfilter eros(,); freqfilter(,7:3) ; newfftx freqfilter*fftx; % Low pass filter newx ifftshift(newfftx); newx ifft(newx,); % Padded inverse fft figure() subplot(,,); plot(abs(newfftx)); subplot(,,); plot(t,real(newx(,:))); 6 4 Filtered Frequency Domain 5 5 5 5 Filtered Time Domain -5-3 4 5 6 7 8 9