Sie sind auf Seite 1von 23

Fourier Transforms

Some Properties of DFT


CS370 Lecture 20 Feb 17, 2017

1
Midterm details, etc.
Materials allowed: Official course notes, handwritten notes, assignments,
non-programmable calculators.
Data/Time: Tues, Feb 28, 7-9pm.
Location: To be announced. (Youll be divided among 3 rooms.)
Covers: Floating point, interpolation and splines, ordinary differential
equations. (No Fourier transforms.)

Q/A Session: Sunday, Feb 26. Time/Location: TBA (on Piazza).


Lecture on Mon, Feb 27: Assignment return, and questions
Lecture on Wed, March 1: Canceled.
Lecture on Fri, March 3: (Probably) discussion of midterm.

2
Recall: Discrete Fourier Transform
Last time, we developed the Discrete Fourier Transform pair:
1 1
= 1
=0 and = =0

2
where = , recalling Eulers formula = cos + sin.

This allows a perfect transformation between N time-domain data


points and N frequency-domain Fourier coefficients .

Emphasizes the frequencies present in the data.


3
Note: A Lack of Standardization
There is no single accepted standard definition of the DFT/IDFT pair.

We use the following, with 0-based indexing:


1 1
= 1
=0 and = =0 .

Matlab uses this instead, with 1-based indexing:


1
= =1 (1)(1) and =
=1 (1)(1) .

1
Note the different placement of the scaling by .

So be careful (a) when coding in Matlab, and (b) reading other sources!
4
2
Example 5.1: fn = cos

2
Consider a set of N data points such that fn = cos .

1
Show that 1 = 1 = , and for all other coefficients, = 0.
2

5
2
Example 5.1: DFT of N=12 points for cos

Original Data Resulting Fourier


coefficients
6
2
Example 5.1: fn = cos

2
Consider a set of N data points such that fn = cos .

1
Show that 1 = 1 = ; for all other coefficients, = 0.
2

Therefore we can express in our Fourier representation as


1
2
1 (1) 1 (1)
= cos = = + .
2 2
=0

7
Two Properties of the DFT
As consequences of the properties of Nth roots of unity

1. The sequence { } is doubly infinite and periodic.


i.e., If we allow < 0 or > 1, the coefficients
repeat.

2. Conjugate symmetry: If data is real, = .



Hence the | | are symmetric about = , as we saw in 2
2 plot for cos exhibits
the cos examples power spectra.
conjugate symmetry.

8
Yet to come in Fourier Transforms
Well try to develop more intuition for what the DFT means.
Well look at how to do the DFT quickly (Fast Fourier Transform, FFT).
Well discuss some applications.

9
10
Discrete Fourier Transform
Typically, we want to learn/achieve something by processing the data.
(Image data, audio samples, prices, intensities, etc.)

In theory, the time-domain data tells us everything!

In practice, Fourier coefficients provide easier access to useful


insights/information for certain problems.

11
Power/Fourier Spectrum
The power spectrum visualizes the Fourier coefficients by plotting their
moduli/magnitudes | |, e.g., using Matlab.

stem(abs(F)) bar(abs(F))
This expresses the magnitude of the frequencies, but ignores phase.
2
(Note: other sources use as power spectrum.)

12
Example Cosine (Notes, Example 5.1)
2
Last time, we saw a (rather artificial) example, cos .

13
Discrete Data Examples
What if our data is less artificial and more irregular? (N=9 here.)

or

A smooth hump - data. A rough hump - data.


14
Discrete Data A Smooth Hump

Data Fourier coefficients.

15
Discrete Data A Rough Hump

Data Fourier coefficients.

16
Discrete Data - Observations
1
Coefficient 0 is always the average of data values, 0 = 1
=0 .

(Sometimes called the direct current or DC.)

The smooth hump had one dominant frequency/wave; therefore one


coefficient pair, 1 and 8 , had large magnitude.

The rough hump had more irregularity, so more active (higher) frequencies.
Main hump still dominates, so low freqs 1 and 8 remain largest.

The power spectra ( plots) are symmetric, since the data was real.

17
A Matrix View of DFT
1 1
Our usual DFT is = =0 .

Letting and be vectors of Fourier coefficients and data, respectively,


we can write DFT as a matrix transformation, = , where is a
1

1
matrix where whose column is: 2 .


(1)
18
A Matrix View of DFT
1 41
e.g., For = 4, we have = =0 which in matrix form is
4

1 1 1 1 0 0
1 0 1 2 3 1 1
=
4 0 2 4 6 2 2
0 3 6 9 3 3

=
19
A Matrix View of IDFT
1
Our orthogonality identity leads to
= where is the identity
,

matrix. For = 4:
1 0 0 0 1 1 1 1 1 0 0 0
1 1 1 2 3 1 0 1 2 3 1 0 1 0 0
2 4 6 0 2 4 6 =
4 1 4 4 0 0 1 0
1 3 6 9 0 3 6 9 0 0 0 1

1
Therefore 1 = .
The IDFT becomes = 1 = .

20
A Matrix View of IDFT
e.g., For = 4, we have IDFT = 3=0 in matrix form:

1 0 0 0 0 0
1 1 2 3 1 1
=
1 2 4 6 2 2
1 3 6 9 3 3

=
21
Summary: Matrix Form of DFT pair
DFT: =

1
Inverse DFT: = =

22
DFT So Far
We derived the Discrete Fourier Transform (DFT) and its inverse, IDFT.

We examined the DFT for a few data sets, to gain intuition.

We identified some key properties of the DFT, and saw a matrix


formulation of it.

Well next look at DFTs computational cost, and how to accelerate it!

23

Das könnte Ihnen auch gefallen