6.003: signal processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: signal processing...

30
6.003: Signal Processing Discrete-Time Fourier Transform Definition Examples Properties Relations between Fourier series and transforms (DT and CT) Announcements: No PSet 4 – practice quiz questions have been posted instead. Office Hours today (7-9pm) and Sunday (4-6pm) - practice quiz problems and general questions Solutions to practice quiz questions will be posted Sunday at 6pm Quiz 1: Tuesday, March 3, 2-4pm in 32-141. - Coverage up to and including all of week 4. - Closed book except for one page of notes (8.5”x11” both sides). - No electronic devices. (No headphones, cellphones, calculators, ...) February 27, 2020

Upload: others

Post on 04-Aug-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

6.003: Signal Processing

Discrete-Time Fourier Transform

• Definition

• Examples

• Properties

• Relations between Fourier series and transforms (DT and CT)

Announcements:

• No PSet 4 – practice quiz questions have been posted instead.

• Office Hours today (7-9pm) and Sunday (4-6pm)

− practice quiz problems and general questions

• Solutions to practice quiz questions will be posted Sunday at 6pm

• Quiz 1: Tuesday, March 3, 2-4pm in 32-141.

− Coverage up to and including all of week 4.

− Closed book except for one page of notes (8.5”x11” both sides).

− No electronic devices. (No headphones, cellphones, calculators, ...)

February 27, 2020

Page 2: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

From Periodic to Aperiodic

Last time: representing arbitrary (aperiodic) CT signals as sums of sinu-

soidal components using the continuous-time Fourier transform.

Today: generalize the Fourier Transform idea to discrete-time signals.

Page 3: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Representions of Aperiodic Signals

How can we represent an aperiodic signal as a sum of sinusoids?

n

x[n]

−2 0 2Strategy: make a periodic version of x[n] by summing shifted copies:

xp[n] =∞∑

m=−∞x[n−mN ]

n

xp[n]

−2 0 2−N N

Since xp[n] is periodic, it has a Fourier series (which depends on N).

Find Fourier series coefficients Xp[k] and take the limit of Xp[k] as N →∞.

As N →∞, xp[n]→ x[n], and Fourier series will approach Fourier transform.

Page 4: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Representions of Aperiodic Signals

Example.

n

x[n]

−2 0 2Strategy: make a periodic version of x[n] by summing shifted copies:

xp[n] =∞∑

m=−∞x[n−mN ]

n

xp[n]

−2 0 2−N N

Calculate the Fourier series coefficients Xp[k]:

Xp[k] = 1N

∑n=〈N〉

xp[n]e−j2πNkn = 1

N+ 2N

cos 2πkN

+ 2N

cos 4πkN

Page 5: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Representions of Aperiodic Signals

Calculate the Fourier series coefficients Xp[k]:

Xp[k] = 1N

∑n=〈N〉

xp[n]e−j2πNkn = 1

N+ 2N

cos 2πkN

+ 2N

cos 4πkN

Plot the resulting Fourier coefficients for N=8.

k

Xp[k]

What happens if you double the period N?

Page 6: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Representions of Aperiodic Signals

Calculate the Fourier series coefficients Xp[k]:

Xp[k] = 1N

∑n=〈N〉

xp[n]e−j2πNkn = 1

N+ 2N

cos 2πkN

+ 2N

cos 4πkN

Plot the resulting Fourier coefficients for N=8.

k

Xp[k]

What happens if you double the period N?

• The amplitude will shrink by a factor of 2.

• There will be twice as many samples per period of the cosine functions.

k

Xp[k]

k

Xp[k]

The red samples are at new intermediate frequencies.

Page 7: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Representions of Aperiodic Signals

Define a new function X(Ω) = NXp[k] where Ω = 2πk/N .

NXp[k] = 1+2 cos 2πkN

+2 cos 4πkN

= 1+2 cos(Ω)+2 cos(2Ω) = X(Ω)

N=8:

Ω = 2πkN

NXp[k] = X(Ω)

N=16:

Ω = 2πkN

N=32:

Ω = 2πkN

The discrete function NXp[k] is a sampled version of the function X(Ω).

Page 8: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Representions of Aperiodic Signals

We can reconstruct x[n] from X(Ω) using Riemann sums.

xp[n] =∑k=〈N〉

Xp[k]e j2πNkn= 1

2π∑k=〈N〉

NXp[k]ej2πNkn(2πN

)x[n] = lim

N→∞xp[n] = lim

N→∞

12π

∑k=〈N〉

NXp[k]ej2πNkn(2πN

)= 1

∫2πX(Ω)ejΩndΩ

N=8:

Ω = 2πkN

NXp[k] = X(Ω)

−π π−2π 2π

2πN

N=16:

Ω = 2πkN

−π π−2π 2π

2πN

N=32:

Ω = 2πkN

−π π−2π 2π

2πN

Fourier Transform relation: x[n] ft⇐⇒ X(Ω)

Page 9: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Series and Fourier Transform

Fourier series and transforms are similar:

both represent signals by their frequency content.

Discrete-Time Fourier Series

X[k] = X[k+N ] = 1N

∑n=〈N〉

x[n]e−jkΩon analysis equation

x[n] = x[n+N ] =∑k=〈N〉

X[k]e jkΩon synthesis equation

where Ωo = 2πN

Discrete-Time Fourier Transform

X(Ω)= X(Ω+2π) =∞∑

n=−∞x[n]e−jΩn analysis equation

x[n] = 12π

∫2πX(Ω)ejΩn dΩ synthesis equation

Page 10: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Series and Fourier Transform

All of the information in a periodic signal is contained in one period.

The information in an aperiodic signal is spread across time.

Discrete-Time Fourier Series

X[k] = X[k+N ] = 1N

∑n=〈N〉

x[n]e−jkΩon analysis equation

x[n] = x[n+N ] =∑k=〈N〉

X[k]e jkΩon synthesis equation

where Ωo = 2πN

Discrete-Time Fourier Transform

X(Ω)= X(Ω+2π) =∞∑

n=−∞x[n]e−jΩn analysis equation

x[n] = 12π

∫2πX(Ω)ejΩn dΩ synthesis equation

Page 11: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Series and Fourier Transform

Periodic signals can be synthesized from a discrete set of k harmonics.

Aperiodic signals generally require a continuous set of frequencies Ω.

Discrete-Time Fourier Series

X[k] = X[k+N ] = 1N

∑n=〈N〉

x[n]e−jkΩon analysis equation

x[n] = x[n+N ] =∑k=〈N〉

X[k]e jkΩon synthesis equation

where Ωo = 2πN

Discrete-Time Fourier Transform

X(Ω)= X(Ω+2π) =∞∑

n=−∞x[n]e−jΩn analysis equation

x[n] = 12π

∫2πX(Ω)ejΩn dΩ synthesis equation

Page 12: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Fourier Series and Fourier Transform

Harmonic frequencies kΩo are samples of continuous frequency Ω.

Discrete-Time Fourier Series

X[k] = X[k+N ] = 1N

∑n=〈N〉

x[n]e−jkΩon analysis equation

x[n] = x[n+N ] =∑k=〈N〉

X[k]e jkΩon synthesis equation

where Ωo = 2πN

Discrete-Time Fourier Transform

X(Ω)= X(Ω+2π) =∞∑

n=−∞x[n]e−jΩn analysis equation

x[n] = 12π

∫2πX(Ω)ejΩn dΩ synthesis equation

Page 13: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

CT and DT Fourier Transforms

DT frequencies alias because adding 2π to Ω does not change e−jΩn.

Continuous-Time Fourier Transform

X(ω)=∫ ∞−∞

x(t)e−jωtdt analysis equation

x(t) = 12π

∫ ∞−∞

X(ω)ejωtdω synthesis equation

where Ωo = 2πN

Discrete-Time Fourier Transform

X(Ω)= X(Ω+2π) =∞∑

n=−∞x[n]e−jΩn analysis equation

x[n] = 12π

∫2πX(Ω)ejΩn dΩ synthesis equation

Page 14: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

CT and DT Fourier Transforms

DT frequencies alias because adding 2π to Ω does not change e−jΩn.

Because of aliasing, we need only integrate dΩ over a 2π interval.

Continuous-Time Fourier Transform

X(ω)=∫ ∞−∞

x(t)e−jωtdt analysis equation

x(t) = 12π

∫ ∞−∞

X(ω)ejωtdω synthesis equation

where Ωo = 2πN

Discrete-Time Fourier Transform

X(Ω)= X(Ω+2π) =∞∑

n=−∞x[n]e−jΩn analysis equation

x[n] = 12π

∫2πX(Ω)ejΩn dΩ synthesis equation

Page 15: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Examples of Fourier Transforms

Find the Fourier Transform (FT) of a rectangular pulse of width 2S+1:

pS [n] =

1 −S ≤ N ≤ S0 otherwise

n

p2[n]

−2 0 2

n

p5[n]

−5 0 5

PS(Ω) =∞∑

n=−∞pS [n]e−jΩn =

S∑n=−S

e−jΩn

= ejΩS + ejΩ(S−1) + · · ·+ 1 + · · ·+ e−jΩ(S−1) + e−jΩS

= 1 + 2 cos(Ω) + 2 cos(2Ω) + · · ·+ 2 cos(SΩ)

We would like to reduce this expression to a closed form to better identify

trends across S.

Page 16: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Working with Sums

Closed form sums of exponential sequences.

A =N−1∑n=0

αn

If the series has finite length (here N terms), it will converge for finite α.

A = 1 + α + α2 + · · · + αN−1

αA = α + α2 + · · · + αN−1 + αN

A− αA = 1 − αN

A =

1− αN

1− α if α 6= 1

N if α = 1

If the series has infinite length, it will converge if |α| < 1.

∞∑n=0

αn = limN→∞

N−1∑n=0

αn = limN→∞

1− αN

1− α = 11− α if |α| < 1

Page 17: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Examples of Fourier Transforms

Find the Fourier Transform (FT) of a rectangular pulse of width 2S+1:

pS [n] =

1 −S ≤ N ≤ S0 otherwise

n

p2[n]

−2 0 2

PS(Ω) =S∑

n=−Se−jΩn =

(ejΩS

) 2S∑n=0

e−jΩn =(ejΩ(S+ 1

2 )

ejΩ/2

)1− e−jΩ(2S+1)

1− e−jΩ

=(ejΩ(S+ 1

2 ) − e−jΩ(S+ 12 )

ejΩ/2 − e−jΩ/2

)=

sin(Ω(S+1

2))

sin (Ω/2)

Ω

P2(Ω)

0 2π−2π

5

Page 18: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Examples of Fourier Transforms

Compare Fourier transforms of pulses with different widths.

n

p2[n]

−2 2

1

Ω

P2(Ω)

2π−2π 2π5

5

n

p4[n]

−4 4

1

Ω

P4(Ω)

2π−2π 2π9

9

n

p6[n]

−6 6

1

Ω

P6(Ω)

2π−2π 2π13

13

As the function widens in n the Fourier transform narrows in Ω.

Page 19: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Moments

Similar to CT, the value of X(Ω) at Ω = 0 is the sum of x[n] over time t.

X(0) =∞∑

n=−∞x[n]e−jΩn =

∞∑n=−∞

x[n]

n

p2[n]

−2 2

1

Ω

P2(Ω)

2π−2π 2π5

5”area” = 5

Page 20: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Moments

The value of x[0] is 12π times the integral of X(Ω) over Ω = [−π, π].

x[0] = 12π

∫2πX(Ω) e jΩndΩ = 1

∫2πX(Ω) dΩ

n

p2[n]

−2 2

1

Ω

P2(Ω)

2ππ-π−2π 2π5

5

Ω

P2(Ω)

2ππ-π−2π 2π5

5equal areas

area

2π = 1++

−−

Notice that the form of this relation is similar to the one for CT at the end

of last lecture (and repeated in the next slide).

Page 21: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Moments

The value of x(0) is the integral of X(ω) divided by 2π.

x(0) = 12π

∫ ∞−∞

X(ω) e jωtdω = 12π

∫ ∞−∞

X(ω) dω

−1 1

x1(t)

1

t++

−− ++ −−

2

π

X1(ω) = 2 sinωω

ω

area

2π = 1

2

πω

equal areas !

Page 22: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Stretching Time

Stretching time compresses frequency and increases amplitude

(preserving area).

−1 1

x1(t)

1

t

2

π

X1(ω) = 2 sinωω

ω

−2 2

1

t

4

πω

Very similar in CT and DT.

Page 23: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Compressing Time to the Limit

Alternatively, we could compress time while keeping area = 1.

−12

12

x(t)

1

t

1

2πω

X(ω) = sinω/2ω/2

ω

−14

14

2

t

1

2πω

In the limit, the pulse has zero width but area 1!

We represent this limit with the delta function: δ(t).

1

t

1

ω

Page 24: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Math With Impulses

Although physically unrealizeable, the impulse (a.k.a. Dirac delta) function

is useful as a mathematically tractable approximation to a very brief signal.

Example 1: Find the Fourier transform of a unit impulse function.

X(ω) =∫ ∞−∞

δ(t)e−jωtdt

Since δ(t) is zero except near t=0, only values of e−jωt near t=0 are impor-

tant. Because e−jωt is a smooth function of t, e−jωt can be replaced by

e−jω0:

X(ω) =∫ ∞−∞

δ(t)e−jω0dt = 1

This matches our previous result which was based explicitly on a limit.

Here the limit is implicit.

Page 25: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Math With Impulses

Although physically unrealizeable, the impulse function is extremely useful

as a mathematically tractable approximation to a very brief signal.

Example 2: Find the function whose Fourier transform is a unit impulse.

x(t) = 12π

∫ ∞−∞

δ(ω)ejωtdω = 12π

∫ ∞−∞

δ(ω)ej0tdω = 12π

1 ctft⇐⇒ 2πδ(ω)

Notice the similarity to the previous result:

δ(t) ctft⇐⇒ 1

These relations are duals of each other.

• A constant in time consists of a single frequency at ω = 0.

• An impulse in time contains components at all frequencies.

Page 26: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Math With Impulses

Delta functions are similarly useful in discrete-time transforms.

Let

X(Ω) =∞∑

m=−∞δ(Ω− 2πm)

where the sum results because DT Fourier Transforms are periodic in 2π.

Then

x[n] = 12π

∫2πX(Ω)ejΩndΩ = 1

∫2πδ(Ω)ejΩndΩ = 1

∫2πδ(Ω) dΩ = 1

Thus if x[n] = 1 for all n, the transform is a delta function in frequency.

1 dtft⇐⇒

∞∑m=−∞

2πδ(Ω− 2πm)

We previously showed a similar result for CT:

1 ctft⇐⇒ 2πδ(ω)

Page 27: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Math With Impulses

Using delta functions to calculate the transforms of complex exponentials.

Let

X(ω) = δ(ω−ωo)then

x(t) = 12π

∫ ∞−∞

X(ω)ejωtdω = 12π

∫ ∞−∞

δ(ω−ωo)ejωtdω

The delta function is zero except when ω = ωo. Therefore we can substitute

ejωot for ejωt without changing the result of the integration.

x(t) = 12π

∫ ∞−∞

δ(ω−ωo)ejωotdω = 12πe

jωot

∫ ∞−∞

δ(ω−ωo)dω = 12πe

jωot

Thus the transform of a complex exponential is a delta at that frequency.

ejωot ctft⇐⇒ 2πδ(ω−ωo)

The analgous expresion for DT holds using analogous reasoning.

ejΩon dtft⇐⇒

∞∑m=−∞

2πδ(Ω−Ωo−2πm)

Page 28: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Relations Between Fourier Series and Fourier Transforms

Continuous Time:

ej2πkT

t ctft⇐⇒ 2πδ(ω−2πk

T

)x(t) = x(t+T ) ctfs⇐⇒ X[k]

x(t) = x(t+T ) =∞∑

k=−∞X[k]ej

2πTkt ctft⇐⇒

∞∑k=−∞

2πX[k]δ(ω−2π

Tk)

Discrete Time:

ej2πkN

n dtft⇐⇒

∞∑m=−∞

2πδ(

Ω−2πkN−2πm

)x[n] = x[n+N ] dtfs⇐⇒ X[k]

x[n] = x[n+N ] =∑k=〈N〉

X[k]ej2πNkn dtft⇐⇒

∑k=〈N〉

∞∑m=−∞

2πX[k]δ(

Ω−2πNk−2πm

)

Page 29: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Relation between Fourier Transform and Fourier Series

Each term in the Fourier series is replaced by an impulse in ω.

· · ·· · ·

x(t) =∞∑

k=−∞xp(t− kT )

t0 T

· · ·· · ·

X[k]

k

· · ·· · ·

X(ω) =∞∑

k=−∞2πX[k] δ(ω − k2π

T)

ω0 2π

T

Page 30: 6.003: Signal Processingsigproc.mit.edu/_static/spring20/lectures/lec04b.pdf6.003: Signal Processing Discrete-Time Fourier Transform • De nition • Examples • Properties • Relations

Summary

Discrete-Time Fourier Transform

• Definition

• Examples

• Properties

• Relations between Fourier series and Fourier transforms (DT and CT)

Quiz 1: Tuesday, March 3, 2-4pm in 32-141.

• Coverage up to and including all of week 4.

• Closed book except for one page of notes (8.5”x11” both sides).

• No electronic devices. (No headphones, cellphones, calculators, ...)