103
o Introduction o DTFS & Properties o FT of periodic signals o DFT & Properties: Sampling of the DTFT o DTFT, DTFS, DFT, DFS, FFT, ZT: numerical o Summary ELEC442: DSP DTFS, DTFT, DFS, DFT, FFT M.A. Amer Concordia University Electrical and Computer Engineering Figures and examples in these course slides are taken from the following sources: A. Oppenheim, A.S. Willsky and S.H. Nawab, Signals and Systems, 2nd Edition, Prentice-Hall, 1997 A.V. Oppenheim, R.W. Schafer and J.R. Buck, Discrete-Time Signal Processing M.J. Roberts, Signals and Systems, McGraw Hill, 2004 J. McClellan, R. Schafer, M. Yoder, Signal Processing First, Prentice Hall, 2003 Slides 2-22 are from http://metalab.uniten.edu.my/~zainul/images/Signals&Systems

DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

  • Upload
    buinhu

  • View
    568

  • Download
    42

Embed Size (px)

Citation preview

Page 1: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

o Introduction o DTFS & Properties o FT of periodic signalso DFT & Properties: Sampling of the DTFTo DTFT, DTFS, DFT, DFS, FFT, ZT: numericalo Summary

ELEC442: DSP

DTFS, DTFT, DFS, DFT, FFT

M.A. AmerConcordia UniversityElectrical and Computer Engineering

Figures and examples in these course slides are taken from the following sources:

•A. Oppenheim, A.S. Willsky and S.H. Nawab, Signals and Systems, 2nd Edition, Prentice-Hall, 1997

•A.V. Oppenheim, R.W. Schafer and J.R. Buck, Discrete-Time Signal Processing

•M.J. Roberts, Signals and Systems, McGraw Hill, 2004

•J. McClellan, R. Schafer, M. Yoder, Signal Processing First, Prentice Hall, 2003

•Slides 2-22 are from http://metalab.uniten.edu.my/~zainul/images/Signals&Systems

Page 2: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

2

Periodic DT Signals

A DT signal is periodic with period where is a positive integer if

The fundamental period of is the smallest positive value of for which the equation holds

Example:

is periodic with fundamental period

Page 3: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

3

Fourier representation of signals

The study of signals and systems using sinusoidal representations is termed Fourier analysis, after Joseph Fourier (1768-1830)

The development of Fourier analysis has a long history involving a great many individuals and the investigation of many different physical phenomena, such as the motion of a vibrating string, the phenomenon of heat propagation and diffusion

Fourier methods have widespread application beyond signals and systems, being used in every branch of engineering and science

The theory of integration, point-set topology, and eigenfunction expansions are just a few examples of topics in mathematics that have their roots in the analysis of Fourier series and integrals

Page 4: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

4

Approximation of Signals by Sinusoids

A signal can be approximated by a sum of many sinusoids at harmonic frequencies of the signal f0with appropriate amplitude and phase

The more harmonic components are added, the more accurate the approximation becomes

Instead of using sinusoidal signals, mathematically, we can use the complex exponential functions with both positive and negative harmonic frequencies

A Fourier representation is unique, i.e., no two same signals in time domain give the same function in frequency domain

Page 5: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

5

Overview of Fourier Analysis MethodsPeriodic in TimeDiscrete in Frequency

Aperiodic in TimeContinuous in Frequency

Continuous in Time

Aperiodic in Frequency

Discrete in Time

Periodic in Frequency

−∞=

=

⇒⊗

=

⇒⊗

k

tjkk

Ttjk

k

eatx

dtetxT

a

0

0

)(

P-CTDT :SeriesFourier Inverse CT

)(1

DTP-CT :SeriesFourier CT

T

0

T

ω

ω

=

⇒+⊗

=

+⇒⊗∞

−∞=

π

ωω

π

ωω

π

ωπ 2

2

2

)(21][

DT PCT :TransformFourier DT Inverse

][)(

PCTDT :TransformFourier DT

deeXnx

enxeX

njj

n

njj

=

=

=

⇒⊗

=

⇒⊗

1

0

NN

1

0

NN

0

0

][1][

P-DTP-DT SeriesFourier DT Inverse

][][

P-DTP-DT SeriesFourier DT

N

k

knj

N

n

knj

ekXN

nx

enxkX

ω

ω

∞−

∞−

=

⇒⊗

=

⇒⊗

ωωπ

ω

ω

ω

dejXtx

dtetxjX

tj

tj

)(21)(

CTCT :TransformFourier CT Inverse

)()(

CTCT :TransformFourier CT

Page 6: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

6

Overview of Fourier Analysis Methods

Variable Period Continuous Frequency

Discrete Frequency

DT x[n] n N k

CT x(t) t T k

Nkk /2πω =

Tkk /2πω =

ω

Ω

• DT-FS: Discrete in time; Periodic in time; Discrete in Frequency; Periodic in Frequency• DT-FT: Discrete in time; Aperiodic in time; Continous in Frequency; Periodic in Frequency• CT-FS: Continuous in time; Periodic in time; Discrete in Frequency; Aperiodic in Frequency• CT-FT: Continuous in time; Aperiodic in time; Continous in Frequency; Aperiodic in Frequency

Page 7: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

7

Negative frequency?

Page 8: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

8

Negative Frequency?

Page 9: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

9

Negative Frequency?

Page 10: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

10

Outline

o Introduction o DTFS & properties o DTFT of periodic signalso DFT: Sampling of the DTFTo DTFT, DTFS, DFT, DFS, FFT, ZT: numerical (Matlab)o Summary

Page 11: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

11

Discrete-Time Fourier Series (DTFS)

Given a periodic sequence with period N so that

The FS can be written as

(Recall: the FS of continuous-time periodic signals require infinite many complex exponentials)

Not that for DT periodic signals we have

Due to the periodicity of the complex exponential we only need N exponentials for DT FS

The FS coefficients can be obtained via

]n[x~ ]rNn[x~]n[x~ +=

[ ] ( )∑ π=k

knN/2jekX~N1]n[x~

( )( ) ( ) ( ) ( )knN/2jmn2jknN/2jnmNkN/2j eeee πππ+π ==

[ ] ( )∑−

=

π=1N

0k

knN/2jekX~N1]n[x~

[ ] ( )∑−

=

π−=1N

0n

knN/2je]n[x~kX~

Page 12: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

12

DTFS Pair

For convenience we sometimes use Analysis equation

Synthesis equation

( )N/2jN eW π−=

[ ]∑−

=

−=1N

0k

knNWkX~

N1]n[x~

[ ] ∑−

=

=1N

0n

knNW]n[x~kX~

Page 13: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

13

Concept of DTFS

Page 14: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

14

The DTFS

Note: we could divide x[n] or X[k] by N

Page 15: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

15

The DTFS

Page 16: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

16

The DTFS

Page 17: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

17

The DTFS

Page 18: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

18

The DTFS

Page 19: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

19

The DTFS

Page 20: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

20

Example: periodic square

Page 21: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

21

Example: periodic square

- We know that

Page 22: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

22

Example: periodic square

Page 23: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

23

Example: periodic square

Page 24: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

24

Example: periodic square

DTFS of an periodic rectangular pulse train The DTFS coefficients

[ ] ( )( )

( )( ) ( )

( )10/ksin2/ksine

e1e1ekX~ 10/k4j

k10/2j

5k10/2j4

0n

kn10/2j

ππ

=−−

== π−π−

π−

=

π−∑

Page 25: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

25

Example: periodic impulse train

DFS of a periodic impulse train

Since the period of the signal is N

We can represent the signal with the DTFS coefficients as

[ ] =

=−δ= ∑∞

−∞= else0rNn1

rNn]n[x~r

[ ] ( ) ( ) ( ) 1ee]n[e]n[x~kX~ 0kN/2j1N

0n

knN/2j1N

0n

knN/2j ==δ== π−−

=

π−−

=

π− ∑∑

[ ] ( )∑∑−

=

π∞

−∞=

=−δ=1N

0k

knN/2j

re

N1rNn]n[x~

Page 26: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

26

Properties of DTFS

Linearity

Shifting

Duality

[ ] [ ][ ] [ ]

[ ] [ ] [ ] [ ]kX~bkX~anx~bnx~akX~nx~kX~nx~

21DFS

21

2DFS

2

1DFS

1

+ →←+ →← →←

[ ] [ ][ ] [ ]

[ ] [ ]mkX~nx~ekX~emnx~

kX~nx~

DFSN/nm2j

N/km2jDFS

DFS

− →← →←− →←

π

π−

[ ] [ ][ ] [ ]kx~NnX~

kX~nx~DFS

DFS

− →← →←

Page 27: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

27

Properties of DTFS

Page 28: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

28

Summary of Properties

Page 29: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

29

Symmetry Properties

Page 30: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

30

Periodic Convolution Take two periodic sequences

Form the product

The periodic sequence with given DTFS can be written as

Periodic convolution is commutative

[ ] [ ][ ] [ ]kXnx

kXnxDFS

DFS

22

11 ~~

~~

→← →←

[ ] [ ] [ ]kXkXkX 213~~~ =

[ ] [ ] [ ]∑−

=

−=1

0213

~~~ N

mmnxmxnx

[ ] [ ] [ ]∑−

=

−=1

0123

~~~ N

mmnxmxnx

Page 31: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

31

Periodic Convolution

Page 32: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

32

Outline

o Introduction o DTFS & properties o DTFT of periodic signalso DFT: Sampling of the DTFTo DTFT, DTFS, DFT, DFS, FFT, ZT: numerical (Matlab)o Summary

Page 33: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

33

The DTFT

=

⇒+⊗

=

+⇒⊗

−∞=

π

ωω

π

ωω

π

ωπ 2

2

2

)(21][

DT PCT :TransformFourier DT Inverse

][)(

PCTDT :TransformFourier DT

deeXnx

enxeX

njj

n

njj

• DTFT represents a DT aperiodic signal as a sum of infinitely many complex exponentials, with the frequency varying continuously in (-π, π)• DTFT is periodic

only need to determine it for

DTFT is continuous in frequency

Page 34: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

34

The DTFT

From the numerical computation viewpoint, the computation of DTFT by computer has several problems: The summation over n is infinite The independent variable is continuous

DTFT and z-transform are not numerically computable transforms

nj

n

j enxeX ωω −∞

−∞=∑= ][)(

ω

Page 35: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

35

FS versus FT

Aperiodic signals can be viewed as a periodic signal with an infinite period

FS: a representation of periodic signals as a linear combination of complex exponentials The FS cannot represent an aperiodic signal for all times

FT: apply to signals that are not periodic The FT can represent an aperiodic signal for all time

NN

1

0

NN

1

0

P-DTP-DF ][1][

P-DFP-DT ][][

:DTFS

0

0

⇒=

⇒=

∑−

=

=

N

k

knj

N

n

knj

ekXN

nx

enxkX

ω

ω

DT PCT )(21][

PCTDT ][)(

:DTFT

22

2

⇒+=

+⇒=

∑∞

−∞=

ππ

ωω

πωω

ωπ

deeXnx

enxeX

njj

n

njj

Page 36: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

36

The FT of Periodic Signals

Periodic sequences are not absolute or square summable: no DTFT exist We can represent them as sums of complex exponentials: DTFS

We can combine DTFS and DTFT Periodic impulse train with values proportional to DTFS coefficients

This is periodic with 2π since DTFS is periodic

( ) [ ]∑∞

−∞=

−=

k

j

NkkX

NeX πωδπω 2~2~

Page 37: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

37

The FT of Periodic Signals The inverse transform can be written as

FT Pair:

Example:

( ) [ ]∑∞

−∞=

−=

k

j

NkkX

NeX πωδπω 2~2~

( ) [ ]

[ ] [ ]∑∫∑

∫ ∑∫−

=

−∞=

−∞=

=

−=

1

0

22

0

2

0

2

0

~12~1

2~221~

21

N

k

nN

kjnj

k

nj

k

njj

ekXN

deN

kkXN

deN

kkXN

deeX

πωεπ

ε

ωεπ

ε

ωεπ

ε

ω

ωπωδ

ωπωδππ

ωπ

[ ]∑−

=

=1

0

2~ ~1][

N

k

nN

kjX ekX

Nn

π

Page 38: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

38

Example Consider the periodic impulse train

The DTFS was calculated previously to be

Therefore the FT is

[ ]∑∞

−∞=

−δ=r

rNn]n[p~

[ ] k allfor 1kP~ =

( ) ∑∞

−∞=

ω

π

−ωδπ

=k

j

Nk2

N2eP~

Page 39: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

39

Finite-length x[n] & Periodic Signals

Convolve with periodic impulse train

The FT of the periodic sequence is

This implies that

DFS coefficients of a periodic signal = equally spaced samples of the FT of one period

[ ] [ ]∑∑∞

−∞=

−∞=

−=−δ∗=∗=rr

rNnxrNn]n[x]n[p~]n[x]n[x~

( ) ( ) ( ) ( )

( )

π

−ωδ

π=

π

−ωδπ

==

∑∞

−∞=

πω

−∞=

ωωωω

Nk2eX

N2eX~

Nk2

N2eXeP~eXeX~

k

Nk2jj

k

jjjj

[ ] ( )Nk2

jNk2j

eXeXkX~ π=ω

ωπ

=

=

Page 40: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

40

Finite-length x[n] & Periodic Signals

Page 41: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

41

Example

Consider

The FT is

The DFS coefficients

≤≤

=else0

4n01]n[x

( ) ( )( )2/sin

2/5sineeX 2jj

ωω

= ω−ω

[ ] ( ) ( )( )10/ksin

2/ksinekX~ 10/k4j

ππ

= π−

Page 42: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

42

Outline

o Introduction to frequency analysiso DTFS & properties o DTFT of periodic signalso DFT: Sampling of the DTFT o DTFT, DTFS, DFT, DFS, FFT, ZT: numerical (matlab)o Summary

Page 43: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

43

Sampling the DTFT:Sampling in frequency domain

In the DTFT

The summation over n is infinite The independent variable is continuous

DTFT is not numerically computable transform

To numerically represent the continuous frequency DTFT, we must take samples of it DFT

nj

n

j enxeX ωω −∞

−∞=∑= ][)(

ω

Page 44: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

44

Sampling the DTFT:Review to sampling

Sampling is converting x(t) to x[n] T : sampling period in second; fs = 1/T : sampling frequency in Hz Ωs=2πfs : Sampling frequency in radian-per-second

In frequency domain: convolution of X(jw) with an impulse train

Creates replica of the FT of x(t); Replica are periodic with Ωs

If Ωs< ΩN sampling maybe irreversible due to aliasing of images

[ ] ( ) ∞<<∞−= nnTxnx c

( ) ( )( )∑∞

−∞=

Ω−Ω=Ωk

scs kjXT

jX 1

( )ΩjXc

( )ΩjXs

( )ΩjXs

ΩN-ΩN

ΩN-ΩN Ωs 2Ωs 3Ωs

-2Ωs Ωs3Ωs

ΩN-ΩN Ωs 2Ωs 3Ωs

-2Ωs

Ωs

3Ωs

Ωs<2ΩN

Ωs>2ΩN

Page 45: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

45

Sampling the DTFT:Sampling in frequency domain

Consider an aperiodic x[n] with a DTFT Assume a sequence is obtained by sampling the DTFT

Since the DTFT is periodic, the resulting sequence is also periodic

could be the DFS of a sequence The corresponding sequence is

[ ] ( )( )

( )( ) 10 ;~ /2

/2−≤≤==

=LkeXeXkX kNj

kN

j π

πω

ω

( )ωjDTFT eXnx →←][

[ ]kX~

[ ] ( ) 10 and 10 ;~1][~ 1

0

/2 −≤≤−≤≤= ∑−

=

LkNnekXN

nxN

k

knNj π

Page 46: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

46

Sampling the DTFT

We can also write it in terms of the z-transform

The sampling points are shown in figure

[ ] ( )( )

( )( )kNj

kN

j eXeXkX /2

/2

~ π

πω

ω ===

[ ] ( ) ( )( )( )kNj

ezeXzXkX kN

/2/2

~ ππ ==

=

Page 47: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

47

Sampling the DTFT

The only assumption made on x[n]: its DTFT exist

Combine the equations gives

Term in the parenthesis [] is

( ) [ ]∑∞

−∞=

−=m

mjj emxeX ωω [ ] ( )∑−

=

=1

0

/2~1][~ N

k

knNjekXN

nx π[ ] ( )( )kNjeXkX /2~ π=

[ ] ( ) ( )

[ ] ( ) ( ) [ ] [ ]∑∑ ∑

∑ ∑∞

−∞=

−∞=

=

=

−∞=

−=

=

=

mm

N

k

mnkNj

N

k

knNj

m

kmNj

mnpmxeN

mx

eemxN

nx

~1

1][~

1

0

/2

1

0

/2/2

π

ππ

[ ] ( ) ( ) [ ]∑∑∞

−∞=

=

− −−==−r

N

k

mnkNj rNmneN

mnp δπ1

0

/21~

[ ] [ ] [ ]∑∑∞

−∞=

−∞=

−=−∗=rr

rNnxrNnnxnx δ][~

Page 48: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

48

Sampling the DTFT

FS are samples of the FT of one period

FS are still samples of the FT; But, one period is no longer identical to x[n]

Page 49: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

49

Sampling the DTFT

DFS coefficients of a periodic sequence obtained through summing periodic replicas of aperiodic original sequence x[n]

If x[n] is of finite length & we take sufficient number of samples of its DTFT, x[n] can be recovered by

No need to know the DTFT at all frequencies, to recover x[n]

DFT: Representing a finite length sequence by samples of DTFT

[ ] [ ] −≤≤

=else

Nnnxnx

010~

Page 50: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

50

Sampling in the frequency domain

The relationship between and one period of in the under-sampled case is considered a form of time domain aliasing

Time domain aliasing can be avoided only if has finite length just as frequency domain aliasing can be avoided only for

signals being band-limited If has finite length N and we take a sufficient number L

of equally spaced samples of its FT, then the FT is recoverable from these samples equivalently is recoverable from

Sufficient number L means: L>=NWe must have at least as many frequency samples as the

signal’s length

][nx ][~ nx

][nx

][nx

][nx ][~ nx

Page 51: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

51

The DFT

Consider a finite length sequence x[n] of length N

For x[n] associate a periodic sequence The DFS coefficients of the periodic sequence are samples of the

DTFT of x[n]

Since x[n] is of length N there is no overlap between terms of x[n-rN] and we can write the periodic sequence as

To maintain duality between time and frequency We choose one period of as the DFT of x[n]

[ ] 10 of outside 0 −≤≤= Nnnx

[ ] [ ]∑∞

−∞=

−=r

rNnxnx~

[ ] ( )[ ] ( )( )[ ]NkXkXkX == N mod ~

[ ]kX~

[ ] [ ] −≤≤

=else

NkkXkX0

10~

[ ] ( )[ ] ( )( )[ ]Nnxnxnx == N mod ~

Page 52: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

52

The DFT

Consider the DFS pair

The equations involve only one period so we can write

The DFT pair

[ ] ( )∑−

=

=1

0

/2~1][~ N

k

knNjekXN

nx π

[ ] ( )∑−

=

−=1

0

/2][~~ N

n

knNjenxkX π

[ ]( )

−≤≤= ∑−

=

else

NkenxkXN

n

knNj

0

10][~1

0

/2π [ ] ( )

−≤≤= ∑−

=

else

NkekXNnx

N

k

knNj

0

10~1][

1

0

/2π

[ ] ( )

N, LLk

enxkXN

n

knNj

>=−≤≤

= ∑−

=

10

][1

0

/2π [ ] ( )

NLwhereLk

ekXN

nxN

k

knNj

>=−≤≤

= ∑−

=

,10

1][1

0

/2π

[ ] ][nxkX DFT →←

Page 53: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

53

DFT: x[n] finite duration

Page 54: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

54

DFT: Example 1

DFT of a rect. pulse x[n], N=5 Consider x[n] of any length L>5 Let L=N=5 Calculate the DFS of the

periodic form of x[n]

[ ] ( )

( )

±±=

=

−−

=

=

π−

π−

=

π−∑

else0,...10,5,0k5

e1e1

ekX~

5/k2j

k2j

4

0n

n5/k2j

Page 55: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

55

DFT: Example 1

Let L=2N=10 We get a different set

of DFT coefficients Still samples of the

DTFT but in different places

x[n] = Inverse X[k] depends on relation L & N

Page 56: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

56

DFT: Example 1summary

The larger the DFT size K, the more details of the INVERSE DFT, i.e., x[n ] can be seen

Page 57: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

57

DFT: example 2

NLwhereLk >=−≤≤ ,10

Page 58: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

58

DFT: example 3

NLwhereLk >=−≤≤ ,10

Page 59: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

59

DFT: example 3

Page 60: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

60

Properties of DFT (very similar to that of DTFS)

Linearity

Duality

[ ] [ ][ ] [ ]

[ ] [ ] [ ] [ ]kbXkaXnbxnaxkXnxkXnx

DFT

DFT

DFT

2121

22

11

+ →←+ →← →←

[ ] [ ][ ] ( )( )[ ]N

DFT

DFT

kNxnXkXnx

− →← →←

Page 61: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

61

Example: Duality

Page 62: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

62

Circular Shift property

( )( )[ ] ( )

( )N

NN

mN

Nnnmnxny

by shift circular toequivalent is mshift circular A -m)-(Nby shift circular left a toequivalent is mby shift Circular -

modulo where, ][ 1-Nn0 range in the be always bemust y[n] :shift"Circular "

m]-n[ :shiftlinear apply cannot We1-Nn0 range over the defined belonger nomay

m],-x[ny[n] shifted them,arbitrary an For -Nn and 0nfor 0x[n]-

1-Nn0for defined ]length x[n-NConsider -

>

=−=≤≤−

∞≤≤∞−==>≤≤

=>=<=

≤≤

Page 63: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

63

Circular Shift property[ ] [ ]

( )( )[ ] [ ] ( )mNkjDFTN

DFT

ekXmnxkXnx

/21-Nn0 π− →←≤≤− →←

Page 64: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

64

Page 65: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

65

Circular Shift property

Page 66: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

66

Circular Convolution Property

10 −≤≤ Nn

][~ nx

• Linear convolution: one sequence is multiplied by a time–reversed and linearly-shifted version of the other

•Circular convolution: the second sequence is circularly time-reversed and circularly-shifted it is called an N-point circular convolution

][ N ][][ 213 nxnxnx =

Page 67: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

67

Circular Convolution Property

( ) ( ) ( )

( ) ( )( )

aliasing en with timConvolutioLinear n ConvolutioCircular

0

10][][

thenN, period of sequence periodic a ][~y form :y[n] of DFTget To)12 oflength max. has BUT length of

then,length of and If

)()()( so, is from DFT -

so, :nconvolutioCircular - so h[n],* x[n] y[n] :nconvolutioLinear

/2

===>

−≤≤−=

==

====−

∑∞

−∞=

else

NnrNnynw

nxN-(y[n]Nw[n]

Nh[n]x[n]

kHkXkYeYY(k) eY

X(k)H(k)W(k) n] x[n] N h[w[n] eHeXeY

r

kNjj

jjj

πω

ωωω

Page 68: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

68

Circular Convolution: example 1

Circular convolution of two finite length sequences

][][ 01 nnnx −= δ

[ ] [ ] ( )( )[ ]∑−

=

−=1

0213

N

mNmnxmxnx

[ ] [ ] ( )( )[ ]∑−

=

−=1

0123

N

mNmnxmxnx

][][

][

23

1

0

0

kXWkX

WkXkn

N

knN

=

=

][][ 01 nnnx −= δ

Page 69: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

69

Example 2: L=N

Two rect. X[n]: L=N=6

DFT of each sequence

Multiplication of DFTs

Inverse DFT

[ ] [ ] −≤≤

==else

Knnxnx

0101

21

[ ] [ ] =

=== ∑−

=

elsekN

ekXkXN

n

knN

j

001

0

2

21

π

[ ] [ ] [ ] =

==elsekN

kXkXkX0

02

213

[ ] −≤≤

=else

NnNnx

010

3

Page 70: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

70

Example 2: L=2N

Augment zeros to each sequence L=2N=12

The DFT of each sequence

Multiplication of DFTs

[ ] [ ]Nk2j

NLk2j

21

e1

e1kXkX π−

π−

−==

[ ]2

Nk2j

NLk2j

3

e1

e1kX

−= π

π−

x[n] = Inverse DFT X[k] is not unique; depends on L and N

Page 71: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

71

Circular convolution example

Page 72: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

72

Page 73: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

73

Symmetry Property

Page 74: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

74

Symmetry Properties

Page 75: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

75

Outline

o Introduction to frequency analysiso DTFS & properties o DTFT of periodic signalso DFT: sampling of the DTFTo DTFT, DTFS, DFT, DFS, FFT, ZT: numerical (matlab)o Summary

Page 76: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

76

Discrete-time signal transforms

76

Page 77: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

77

Numerical Calculation of FT

1. The original signal is digitized2. A Fast Fourier Transform (FFT) algorithm

is applied, which yields samples of the FT at equally spaced intervals

For a signal that is very long, e.g., a speech signal or a music piece, spectrogram is used FT over successive overlapping short

intervals

Page 78: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

78

Matlab examples: DTFT

Suppose that:

Analytically, the DTFT is X(ejω): continuous function of ω X(ejω): periodic with period 2π

Plot it using

78

Page 79: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

79

Matlab examples: DTFT

Signal x[n] DTFT

79

Page 80: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

80

Matlab examples: DFT

Close form X(ejω) not always easy To plot |X(ejω)|, we sampled from 0 to 2π

In code: w and X are vectors Small step size 0.001 to simulate continuous frequency

Workaround: DFT Uniform L-samples from DTFT from 0 to 2π Takes discrete values and returns discrete values No need to find |X(ejω)| analytically Fast implementation using the fast Fourier transform (FFT) Matlab: fft(x,L)

• L: number of samples to take• More L more resolution • Default L is N=length(x)

80

Page 81: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

81

Matlab examples: DFT

Calculating the DFT

Plotting the DFT against k

81

Page 82: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

82

Matlab examples: DFT

Notes: Default L=32 gives bad

resolution information lost x-axis not usefulCannot find fundamental

frequency 3π/8

82

Page 83: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

83

Matlab examples: DFT

Effect of increasing L (better resolution)

• L=64

• L-128

83

Page 84: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

84

Matlab examples: DFT Obtaining the frequency (x-axis)

Spike at 3π/8=1.17 Spike at 2π-3π/8 = 5.11 FFT calculates from 0 to 2π More familiar to shift using

fftshift

84

Page 85: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

85

Matlab examples: DFT

Spikes at 3π/8 and -3π/8

85

Page 86: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

86

Matlab examples: DFT

Sometimes we want frequency in Hz

86

Page 87: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

87

Matlab examples: DFT

|X[k]| vs. ωk

Discrete DFT

87

|X(ejω)| vs. ω Continuous By interpolating DFT

|X(f)| vs. f Continuous f = (ω/ 2π) fs fs : sampling frequency fft values divided by N Peak at 0.5 (half our

amplitude of 1)

Page 88: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

88

Matlab examples: DFS No special function Same as DFT Provided signal corresponds to 1 period

88

Page 89: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

89

Matlab examples: z-Transform

Suppose that:

89

Page 90: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

90

Matlab examples: z-Transform

90

Page 91: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

91

Matlab examples: z-Transform

91

Page 92: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

92

Matlab examples: z-Transform

92

Evaluate H2(ejω) directly from z-Transform

Page 93: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

93

Matlab examples: z-Transform

93

Finding z-Transform analytically

Page 94: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

94

Outline

o Introduction to frequency analysiso DTFS & properties o DTFT & properties o FT of periodic signals o DTFT, DTFS, DFT, DFS, FFT, ZT: numerical (matlab)o FTTo Summary

Page 95: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

95

FFT: Fast Fourier transform

FFT is a direct computation of the DFT FFT is a set of algorithms for the efficient

and digital computation of the N-point DFT, rather than a new transform

Use the number of arithmetic multiplications and additions as a measure of computational complexity

Page 96: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

96

FFT

The DFT pair was given as Baseline for computational complexity:

Each DFT coefficient requires• N complex multiplications• N-1 complex additions

All N DFT coefficients require• N2 complex multiplications• N(N-1) complex additions

Complexity in terms of real operations• 4N2 real multiplications• 2N(N-1) real additions

[ ] ( )∑−

=

π=1N

0k

knN/2jekXN1]n[x

[ ] ( )∑−

=

π−=1N

0n

knN/2je]n[xkX

Page 97: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

97

FFT

Most fast methods are based on symmetry properties Conjugate symmetry

Periodicity in n and k

The Second Order Goertzel Filter• Approximately N2 real multiplications and 2N2 real additions• Do not need to evaluate all N DFT coefficients

Decimation-In-Time FFT Algorithms (N/2)log2N complex multiplications and additions

( ) ( ) ( ) ( ) ( ) ( )knN/2jnkN/2jkNN/2jnNkN/2j eeee π−π−π−−π− ==

( ) ( ) ( ) ( )( )nNkN/2jNnkN/2jknN/2j eee +π+π−π− ==

Page 98: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

98

Symmetry and periodicity of complex exponential

Complex conjugate symmetry

Periodicity in n and k

For example

The number of multiplications is reduced by a factor of 2

ImRe)( *][ knN

knN

knN

knN

nNkN WjWWWW −=== −−

nNkN

NnkN

knN WWW )()( ++ ==

Re])[Re][(Re

Re][ReRe][Re ][

knN

nNkN

knN

WnNxnxWnNxWnx

−+=

−+ −

Page 99: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

99

Outline

o Introduction to frequency analysiso DTFS & properties o DTFT & properties o FT of periodic signals o DTFT, DTFS, DFT, DFS, FFT, ZT: numerical (matlab)o FTTo Summary

Page 100: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

100

Overview of signal transformsVariable Period Continuous

FrequencyDiscrete Frequency

DT x[n] n N k

CT x(t) t T k

Nkk /2πω =

Tkk /2πω =

ω

Ω• DT-FS: Discrete in time; Periodic in time; Discrete in Frequency; Periodic in Frequency• DT-FT: Discrete in time; Aperiodic in time; Continous in Frequency; Periodic in Frequency• CT-FS: Continuous in time; Periodic in time; Discrete in Frequency; Aperiodic in Frequency• CT-FT: Continuous in time; Aperiodic in time; Continous in Frequency; Aperiodic in Frequency• DFT: Discrete in time; Aperiodic in time; Discrete in Frequency; Periodic in Frequency;

finite-duration x[n]• DFS: Discrete in time; Periodic in time (make finite-duration x[n] periodic);

Discrete in Frequency; Periodic in Frequency;

Page 101: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

101

Relationships between signal transforms

Ω= j ez

Continuous-time analog signal

x(t)

Discrete-time analog sequence

x [n]

Sample in timeSampling period = Ts

ω=2πfΩ = ω Ts,scale amplitude by 1/Ts

Sample in frequency,Ω = 2πn/N,N = Length

of sequence

ContinuousFourier Transform

X(f)

∞≤≤∞

∫∞

∞−

f-

dt e x(t) ft2 j- π

Discrete Fourier Transform

X(k)

10

e [n]x 1

0 =n

Nnk2j-

−≤≤

∑−

Nk

N π

Discrete-Time Fourier Transform

X(Ω)

π20

e [n]x - =n

j-

≤Ω≤

∑∞

Ωn

LaplaceTransform

X(s)s = σ+jω

∞≤≤∞

∫∞

∞−

s-

dt e x(t) st

z-TransformX(z)

∞≤≤∞−

∑∞

∞−

z =n

n- z [n]x

s = jωω=2πf

C CC

C

C D

D

DC Continuous-variable Discrete-variable

Ω= j ez r

Page 102: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

102

Fourier versus Cosine Transform

Recall: the cosine wave starts out 1/4th later in its period

It has an offset Common to measure this offset in degree or radians One complete period equals 360° or 2π radian

The cosine wave thus has an offset of 90° or π/2 This offset is called the phase of a sinusoid We cannot restrict a signal x(t) to start out at zero

phase or 90° phase all the time Must determine its frequency, amplitude, and phase to

uniquely describe it at any one time instant With the sine or cosine transform, we are restricted to

zero phase or 90° phase

Page 103: DTFS, DTFT, DFS, DFT, FFT - users.encs.concordia.causers.encs.concordia.ca/.../teach/elec442/notes/Ch8_DTFT_DFT_FS.pdf · o Introduction o DTFS & Properties o FT of periodic signals

103

DCT: One Dimensional

+=

=

1

0 2)12(cos

21 n

t nftxCX tffπ

>

==

0,1

0,2

1

f

fCf

where

n = size

x = signal

X = transform coefficients