ece 468 digital signal processing - engineering | siuchen/ece468/guide.pdf · ece 468 digital...

36
ECE 468 Digital Signal Processing 1. History: Digital signal processing has its roots in 17th and 18th century mathematics. The techniques and applications of this field are as old as Newton and Gauss and as new as digital computers and integrated circuits 2. Definition: Digital signal processing (DSP) is concerned with the representation of the signals by a sequence of numbers or symbols and the processing of these signals. Digital signal processing and analog signal processing are subfields of signal processing. 3. Applications: DSP includes subfields like: Audio and speech signal processing, sonar and radar signal processing, sensor array processing, spectral estimation, statistical signal processing, digital image processing, signal processing for communications, biomedical signal processing, seismic data processing, etc. DSP is not confined to 1D signals. Sometimes 2D, 3D or 4D signals. Until recently, signal processing has typically been carried out using analog equipment. With the development of computers, more and more DSP applications. It was often useful to simulate a signal processing system on a computer before implementing it in analog hardware. 1

Upload: duongtuong

Post on 20-Mar-2018

227 views

Category:

Documents


6 download

TRANSCRIPT

Page 1: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

ECE 468 Digital Signal Processing

1. History:• Digital signal processing has its roots in 17th and 18th

century mathematics.

• The techniques and applications of this field are as old as Newton and Gauss and as new as digital computers and integrated circuits

2. Definition:• Digital signal processing (DSP) is concerned with the

representation of the signals by a sequence of numbers or symbols and the processing of these signals.

• Digital signal processing and analog signal processing are subfields of signal processing.

3. Applications:• DSP includes subfields like:

Audio and speech signal processing, sonar and radar signal processing, sensor array processing, spectral estimation, statistical signal processing, digital image processing, signal processing for communications, biomedical signal processing, seismic data processing, etc.

• DSP is not confined to 1D signals. Sometimes 2D, 3D or 4D signals.

• Until recently, signal processing has typically been carried out using analog equipment. With the development of computers, more and more DSP applications. It was often useful to simulate a signal processing system on a computer before implementing it in analog hardware.

1

Page 2: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Broadcasting: television and radio programs.

Sound waves digital signals broadcasted/receivedanalogous format and filtered

Telecommunications: transfer signals, etc. If satellites are usedAudio waves electromagnetic waves wireless mediumAudio waves light waves transfer by optical fibres …

Navigation: Devices or systems such as SONAR or Radar work primarily on the basis of DSP. For example, SONAR makes use of sound waves (signals) in order to calculate the depth. On the other hand, radars make use of radio waves in order to communicate thelocations of various objects in a particular radius.

2

Page 3: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Radar remote sensingTo investigate the Earth and solar system using radar remote sensing techniques. DSP for geoscience applications.

www.stanford.edu/group/radar/

Biomedical Applications: DSP is used extensively in the field of biomedicine. In it, the various signals that are generated by the different organs in the human body are measured in order to findinformation regarding the health of the same. For example, in case of electrocardiograms (ECG), the electric signals generated by the heart are measured.

3

Page 4: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Digital imaging:

sp.cs.tut.fi/

Apart from those mentioned above, digital signal processing has various other applications. For example, it is used in cars,remote controls, seismic analysis etc. Thus, DSP proves to be one of the most useful techniques developed in the modern times.

4

Page 5: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Chapter 1: Discrete-Time Signals and Systems

Signal and System:• A signal can be defined as a function that conveys

information, generally about the state or behavior of a physical system.

• In the fields of communications, signal processing, and in electrical engineering, a signal is any time-varying or spatial-varying quantity.

• In DSP, engineers usually study digital signals in one of the following domains: time domain, spatial domain, frequency domain, etc.

What is time domain and spatial domain?

For example: Speech signal in a time domain; picture in a spatial domain

Time (seconds)

magnitude

1D

Pixel locations (mm)

Pixel loc

2D

• Signals are represented mathematically as functions of one or more independent variables.

• The independent variable of the mathematical representation of a signal may be either continuous or discrete.

• Continuous-time signals: signals that are defined at a continuum of times and thus are represented by continuous variable functions.

• Discrete-time signals: defined at discrete times and thus the independent variable take on only discrete values; i.e., discrete-signals are represented as sequences of number.

• Our example: Speech signals and pictures may have either a continuous or a discrete variable representation, and if certainconditions hold, these representation are entirely equivalent.

•Digital signals are those for which both time and amplitude are discrete.

•Continuous-time, continuous-amplitude signals are sometimes called analog signals.

• Signal processing:

transformoriginal signal --> another signal(Voice to light, light to light, sound to electrical signals, etc…Or separate 2 signals, enhance some components of signals, etc…

• Continuous-time system: both input and output are continuous-time signals;

• Discrete-time system: both input and output are discrete-time signals.

•Digital systems Input and output are digital signals;

• DSP deal with transformation of signals that are discrete in both amplitude and time.

5

Page 6: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

• Continuous-time system: both input and output are continuous-time signals;

• Discrete-time system: both input and output are discrete-time signals.

•Digital systems Input and output are digital signals;

• DSP deal with transformation of signals that are discrete in both amplitude and time.

•Advantages of DSP: flexibility using computers or with digital hardware; to simulate analog systems or to realize signal transformations impossible to realize with analog hardware.

1.1 Discrete-Time Signals –Sequences • Focus on signals represented by sequences.

• x(n): sequence of number x, the nth number in the sequence is denoted x(n)

X(0)

The sequence: -1, -2, 1, 2, 3, 2, 1, -1X(0)=3;X(1)=2;X(-3)=??

Some special defined sequences:1. Unit-sample sequence: (discrete-time impulse=impulse)

2. Unit step

⎩⎨⎧

=≠

=0,10,0

)(nn

⎩⎨⎧

<≥

=0,00,1

)(nn

nu

⎩⎨⎧

=≠

=0,10,0

)(nn

nδ⎩⎨⎧

<≥

=0,00,1

)(nn

nu

)1()()(

)()(

−−=

= ∑−∞=

nunun

knun

k

δ

δ

Draw a u(n) and u(n-1) ??

3. Real exponential

…….. ……..

Any sequence whose values are of theForm an where a is a real number.

6

Page 7: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

4. Sinusoidal

A sinusoidal sequence has values of the form:

)cos( 0 Φ+nA ω

Periodic:

If x(n)=x(n+N) for all n;N is the period.

Energy: 2

)(∑∞

−∞=

=n

nxε

X(0)What’s the energy for this sequence?

• Sequence calculation: )()( nynxyx ⋅=⋅Product:

)()( nynxyx +=+Sum:

Multiplication: )(nxx ⋅=⋅ αα

0

x(n): -2,-1,3,2,0,1

0

n=0

y(n): 1,0,2,1,2,3,1

n=0

What is the Product, sum, and 2 times ofx(n)?

An arbitrary sequence can be expressed as a sum of scaled, delayedunit samples.

0

Delay or Shift: )()( 0nnxny −= n and n0 are integers

0)(nx )2( +nx0)2( −nx

0

)3()1()()1()2()( 31012 −+−+++++⋅= −− nanananananx δδδδδ

What is a-1 in this case?

∑∞

−∞=

−=k

knkxnx )()()( δ

Generally, an arbitrary sequence:

1.2 Linear Shift-Invariant Systems

• System: a unique transformation or operator that maps an input sequence x(n) into an output sequence y(n).

y(n)=T[x(n)] T: transformation

T[ ] y(n)x(n)

• Linear system: relatively easy to characterize mathematically,used widely for modeling. Non-linear system: complicate.

• Linear system: defined by the principle of superposition. If:y(n)=T[x(n)]

Then a system is linear if and only if:

)()()]([)]([)]()([ 212121 nbynaynxbTnxaTnbxnaxT +=+=+

for any arbitrary constants a and b.

Is y(n)=2 x(n) a linear system?

Is y(n)=[x(n)]2 a linear system???

)()()]()([)]()([ 212

2121 nbynaynbxnaxnbxnaxT +≠+=+

7

Page 8: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

•Cannot have exponents (or powers)For example, x squared or x 2

•Cannot multiply or divide each otherFor example: xy; x/y

•Cannot be found under a root sign or square root sign (sqrt)For example: sqrt (x)

Linear expressions:

x + 42x + 4

2x + 4y

Not linear expressions:

X2

2xy+42x/ySqrt(x)

∑∞

−∞=

−=k

knkxnx )()()( δ

Generally, an arbitrary sequence:

y(n)=T[x(n)]

)()()( ∑∞

−∞=

−=k

knkxTny δ

∑∑∑∞

∞−

∞−

−∞=

−⋅=−⋅=−= )()()()()()()( knhkxknTkxknkxTnyk

δδ

Shift-invariant: y(n) x(n); y(n-k) x(n-k)

For linear shift-invariant system:

)()]([ knhknT −=−δ

h(n) is the unit-sample response / impulse response)()( nhnx ∗

• Convolution:

)(*)()()()( nxnhnhnxny =∗=

The convolution order doesn’t matter.

h1(n) y(n)x(n)

y(n)x(n)

h1(n)*h2(n) y(n)x(n)

h2(n)

h2(n) h1(n)

Above three are same for a linear shift-invariant system.What are the impulse responses of above three?

h1(n)+h2(n) y(n)x(n)

h1(n)y(n)x(n)

h2(n)

Above two are same expressions for a linear shift-invariant system.What is the impulse response?

Example:

)(20,00,2

)( nunn

nh nn

=⎩⎨⎧

<≥

= )4()()( −−= nununx

Let’s calculate y(n):

( )∑∞

−∞=

−==∗=k

knhkxnxnhnhnxny )()(*)()()()(

0

u(n) u(n-4)

x(n)=u(n)-u(n-4)

…………

0

…… ……

4

0 3

Convolution:

⎩⎨⎧

<−≥−

=−−

0,00,2

)(kn

knknh

kn

h(1-k)=21-k (1>=k) h(2-k)=22-k (2>=k)

00…… ……1

2

4

8

…… ……

4

8

2

0 3

x(k)

h(0-k)=20-k (0>=k)

0…… ……

12

4

8

8

Page 9: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

( )∑∞

−∞=

−==∗=k

knhkxnxnhnhnxny )()(*)()()()(

( ) 3012)1()1( =++=−= ∑∞

−∞=kkhkxy

( ) 7124)2()2( =++=−= ∑∞

−∞=kkhkxy

( ) 15148)3()3( =++=−= ∑∞

−∞=k

khkxy

……

( ) 1001)0()0( =++=−= ∑∞

−∞=kkhkxy

……

Make sure you understand how to calculate the convolution.

Convolution:( )∑

−∞=

−==∗=k

knhkxnxnhnhnxny )()(*)()()()(

)(20,00,2

)( nunn

nh nn

=⎩⎨⎧

<≥

= )4()()( −−= nununx

Easy way to do convolution:

0

…… ……1

2

4

8

flip

0 3

0…… ……

12

4

8

0 3

0…… ……

12

4

8

y(0)=1

0 3

…… ……1

2

4

8

y(2)=1+2+4=7

0 3

…… ……1

2

4

8

y(1)=2+1=3

y(3)=15

0 3

…… ……1

2

4

8

0 3

0…… ……

12

4

8

y(-1)=0

Let’s shift to the left for negative n:

⎩⎨⎧

<≥

=0,0

0,2)(

nnn

nh )5()()( −−= nununx

Let’s calculate:

What is y(-1),y(0),y(1)?

y(0)=00…… ……

2

4

8

6

0 4

0

…… ……2

4

8

6

h(n)=2n n>=0

flip

0 4

0

…… ……2

4

8

6

y(1)=2

0 4

0

…… ……2

4

8

6

y(-1)=0

Let’s calculate textbook problems 2.(a):

0

12

1

x(n) h(n)

0

)()()( nhnxny ∗=Draw your y(n)?

9

Page 10: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

1.5 Frequency-domain representation of discrete-time systems and signals

• representations of signals in terms of sinusoids or complex exponentials (i.e. Fourier representations)

Rectangular Function magnitude of the Fourier transform

Suppose the input sequence is: njenx ω=)( ∞<<∞− n

A complex exponential of radian frequency ω

∑∑∞

−∞=

−∞=

−−∞

−∞=

=

===

k

kjj

jnj

k

kjnjknj

k

ekheHhere

eHeekheekhny

ωω

ωωωωω

)()(:

)()()()( )(

Frequency response: H(ej ω) describes the change in complex amplitude of a complex exponential as a function of the frequency ω.

)()()( ωωω jI

jR

j ejHeHeH +=

Example: a system with unit-sample response:

elsewhereNn

nh10

01

)(−≤≤

⎩⎨⎧

=

ω

ωωω

j

NjN

n

njj

eeeeH −

−−

=

−−

== ∑ 11)(

1

0

ωωω sincos je j +=N=5

Nπ2

Nπ2

− π π2π2−

Magnitude of the frequency response H(ejω) of the system With unit-sample response

• For a general sequence x(n), we define the Fourier transform as:

∑∞

−∞=

−=n

njj enxeX ωω )()(

Inverse Fourier transform:

ωπ

ωωπ

πdeeXnx njj )(

21)( ∫−=

• If x(n) is absolutely summable: ∞<∑∞

−∞=n

nx |)(|

The series x(n) is absolutely convergent, the frequency responsefor a stable system will always converge.

• Ideal low-pass filter

ππ− coωcoω− π2π2−

1|)(| ωjeH

⎩⎨⎧

≤<≤

=πωω

ωωω

||0||1

)(co

cojeH

ωπ

ωωπ

πdeeXnx njj )(

21)( ∫−=

Let’s calculate the impulse response h(n):

nnnj

jn

ejn

edjn

dedeeHnh

coco

co

conjnj

njnjj

co

co

co

co

πωω

π

ωω

ππ

ωπ

ωπ

ωω

ω

ω

ω

ω

ωωωπ

π

)sin()sin(22

12

1)(2

1

121)(

21)(

==

−⋅==

⋅==

∫∫

−−

1/2

π1

π1

π31

−π31

π51

π51

0

If 2πω =co

10

Page 11: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

1.6 Symmetry Prosperities of the Fourier Transform

• For a general sequence x(n), we define the Fourier transform as:

∑∞

−∞=

−=n

njj enxeX ωω )()(

Inverse Fourier transform:

ωπ

ωωπ

πdeeXnx njj )(

21)( ∫−=

• Even (symetric): a real-valued sequence x(n) is called even, if xe(-n)=xe (n)

• Odd (antisymetric): a real-valued sequence x(n) is called even, if xo(-n)=-xo (n)

X(0) X(0)

even odd

• Even (symmetric): xe(-n)=xe (n)

• Odd (antisymmetric): xo(-n)=-xo (n)

For an arbitrary real-valued sequence x(n):

)]()([21)(

)]()([21)(

)()()(

nxnxnx

nxnxnx

wherenxnxnx

o

e

oe

−−=

−+=

+=

Test if xe(n) is even and xo(n) is odd???

• Conjugate Symmetric: xe*(-n)=xe (n)

x(1)=a+bj; x(-1)=a-bj;

• Conjugate Antisymmetric: xo*(-n)=-xo (n)

x(1)=a+bj; x(-1)=-a+bj;

For an arbitrary sequence x(n):

)](*)([21)(

)](*)([21)(

)()()(

nxnxnx

nxnxnx

wherenxnxnx

o

e

oe

−−=

−+=

+=

For complex-valued sequence:

Test if xe(n) is even and xo(n) is odd???

A Fourier Transform X(ejω) can be expressed as:

)](*)([21)(

)](*)([21)(

)()()(

ωωω

ωωω

ωωω

jjjo

jjje

jo

je

j

eXeXex

eXeXex

whereeXeXeX

−=

+=

+=

)(*)( ωω je

je eXeX −=Conjugate Symmetric:

)(*)( ωω jo

jo eXeX −−=Conjugate Antisymmetric:

1.7 Sampling of Continuous-Time Signals

• Continuous-time, continuous-amplitude signals are sometimes called analog signals. Example: voltage, current, temperature,…

• Digital signals: discrete both in time and amplitude–Example: attendance of this class, digitizes analog signals,…

• Discrete signals are often derived from continuous-time signals by periodic sampling.

• Understand how the derived sequence is related to the originalsignal

11

Page 12: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Periodic Sampling

• Sampling is a continuous to discrete-time conversion

• Most common sampling is periodic• T is the sampling period in second• fs = 1/T is the sampling frequency in Hz• Sampling frequency in radian-per-second Ωs=2πfs

rad/sec

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

[ ] ( ) ∞<<∞−= nnTxnx aLet’s give an example:

t

xa(t)=sin(t)

0 π2π2π

If sampling period T=4π

.......

1)2

sin()4

2sin()2(

)4

sin()4

1sin()1(

0)4

0sin()0(

)4

sin()4

()()(

==⋅=

=⋅=

=⋅=

⋅=⋅==

ππ

ππ

π

ππ

x

x

x

nnxnTxnx aa

0 4

x(n)

3n

21

• Fundamental issue in digital signal processing– If we lose information during sampling, we cannot recover it

• Under certain conditions an analog signal can be sampled without loss so that it can be reconstructed perfectly

0-1

2 4 6 8 10

0

1

∫∞

∞−

Ω−

+∞

∞−

Ω

ΩΩ=

dtetxjX

dejXtx

tjaa

tjaa

)()(

)(2

1)(π

Fourier representation of an analog signal xa(t):

+∞

∞−

Ω

=

ΩΩ==

π

π

ωω ωπ

π

deeXnx

dejXnTxnx

njj

nTjaa

)(21)(

)(21)()(Sampling:

Discrete FT:

Finally, we can have:

)2(1)(T

rjjXT

eXr

aTj π

+Ω= ∑∞

−∞=

Ω )2(1)(T

rjT

jXT

eXr

aj πωω += ∑

−∞=

)2(1)(T

rjjXT

eXr

aTj π

+Ω= ∑∞

−∞=

Ω )2(1)(T

rjT

jXT

eXr

aj πωω += ∑

−∞=

Ω

Xa(jΩ)

0

1

X(ejΩT))]2([

TjX a

π−Ω⋅

Tπ2

)]2([T

jX aπ

+Ω⋅

Tπ2

T1

)2(1)(T

rjjXT

eXr

aTj π

+Ω= ∑∞

−∞=

Ω

T/ω=Ω

0 4

x(n)

3n

21

So, if you are doing sampling in the time/space domain:

X(ejΩT))]2([

TjX a

π−Ω⋅

Tπ2

)]2([T

jX aπ

+Ω⋅

Tπ2

T1

Your Fourier performance:

Can cut off to go back xa(t)

12

Page 13: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

( )ΩjXs

Ωs 2Ωs 3Ωs-2Ωs Ωs3Ωs

Ωs<Ω0

( )ΩjXa

20Ω

−2

0Ω Ωs 2Ωs 3Ωs-2Ωs Ωs3Ωs

Ωs>Ω0)( ωjeX

20Ω

−2

20Ω

−2

1

1/T

1/T

aliasing

Aliasing: The phenomenon, where in effect a high-frequency Component in Xa(jΩ) takes on the identity of a lower frequency.

X(ejΩT))]2([

TjX a

π−Ω⋅

Tπ2

)]2([T

jX aπ

+Ω⋅

Tπ2

T1

Ω0/2

Tπ2

0 <Ω Can go back to the original xa(t)

We sample at a rate at least twice the highest frequency of Xa(jΩ), Then X(ejw) is identical to Xa(ω/T) in the interval πωπ ≤≤−

X(ejω)

T1 T/ω=Ω)]2([ πω −⋅jX a)]2([ πω +⋅jX a

π2π2−

1.8 Two-dimensional sequences and systems

• 2D unit-sample sequence:

• 2D unit-step sequence:

• 2D exponential sequence:

• 2D sinusoidal sequence:

• Separable sequence:

⎩⎨⎧ ≥≥

=otherwise

nmnmu

,00,0,1

),(

)cos()cos( 10 θωω +Φ+⋅ nmA

⎩⎨⎧

==≠

=0,10,,0

),(nm

nmnmδ

nmba

)()(),( 21 nxmxnmx ⋅=

Above unit-sample, unit-step, exponential, sinusoidal sequences separable?

)cos(),( 0 nmnmx ⋅= ω not separable.

• An arbitrary 2D sequence can be expressed as a linear combinationof shifted unit sample:

∑ ∑∞

−∞=

−∞=

−−⋅=k r

rnkmrkxnmx ),(),(),( δ

∑∞

−∞=

−=k

knkxnx )()()( δRecap: 1D sequence:

• For a linear shift-invariant system:

∑ ∑

∑ ∑

∑ ∑

−∞=

−∞=

−∞=

−∞=

−∞=

−∞=

−−=

−−⋅=

−−⋅=

=

k r

k r

k r

rnkmhrkx

rnkmTrkx

rnkmrkxT

nmxTnmy

),(),(

),(),(

),(),(

)],([),(

δ

δ

Convolution

The convolution order doesn’t matter.

• Stable system: a bounded input a bounded output2D linear shift-invariant systems are stable if and only if

• Casual system: 2D linear shift-invariant systems are casual if and only if

h(m,n)=0 for (m<0, n<0).

∞<= ∑∑∞

−∞=

−∞=

Δ

rkrkhS ),(

• 2D Fourier Transform & Inverse Fourier Transform:

2121

2

21

21

21

),(4

1),(

),(),(

ωωπ

π

π

π

π

ωωωω

ωωωω

ddeeeeXnmx

eenmxeeX

njmjjj

n

njmj

m

jj

∫ ∫

∑∑

− −

−∞=

−−∞

−∞=

=

⋅⋅=

13

Page 14: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Z-transform: a generalization of the Fourier Transform

• For a sequence x(n):

∑∞

−∞=

−⋅=n

nznxzX )()(

• Denote the z-transform as: )]([ nxℑ

Z is a complex variable

• If express the complex variable z in polar form as:

∑∑∑ −−−∞

−∞=

− ⋅⋅==⋅= njnnj

n

n ernxrenxznxzX ωω )())[()()(

If r=1: z-transform Fourier transform

1|| ==⋅=

zeerz jj ωω

Z-transform properties:

1) Shift of a sequence:

+−

+−

<<=+ℑ

<<=ℑ

xxn

xx

RzRzXznnx

thenRzRzXnx

||),()]([

||),()]([

00

***0)0(

0 )()()0()]([ nm

m

nm

m

n

n

zzmxzmxznnxnnx −∞

−∞=

−−∞

−∞=

−∞

−∞=∑∑∑ ⋅=⋅=⋅+=+ℑ

2) Convolution of sequences:

)()()(

)(*)()(

zYzXzWthen

nynxnw

=

=

14

Page 15: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Let’s demonstrate it:

)()(

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

])([)(

)()()()()()(

)(*)()(

)(

zYzX

zmyzkxzzmykx

knmzmykx

zknykxzknykxznwzW

nynxnw

k

m

n

k

k

km

n

k

km

m

k

n

n

n

n k

n

n

=

⋅=⋅=

−=⋅=

−⋅=−==

=

∑ ∑∑ ∑

∑ ∑

∑ ∑∑ ∑∑

−∞=

−∞

−∞=

−∞

−∞=

−−∞

−∞=

−∞=

+−∞

−∞=

−∞=

−∞

−∞=

−∞

−∞=

−∞=

−∞

−∞=

Convergence region: satisfy both

+−

+−

<<<<

yy

xx

RzRRzR

||||

Periodic Sequences Discrete Fourier Series

• Consider a sequence periodic with period N:)(~)(~ kNnxnx += for any integer value of k

∑−

=

=

⋅=

⋅=

1

0

)/2(

1

0

)/2(

)(~1)(~

)(~)(~

N

k

nkNj

N

n

nkNj

ekXN

nx

enxkX

π

π

∑−

=

=

⋅=

⋅=

=

1

0

1

0

)/2(

)(~1)(~

)(~)(~

N

k

nkN

N

n

nkN

NjN

WkXN

nx

WnxkX

eW π

We can also express as:

• are periodic sequences.)(~ kX)(~ nx

15

Page 16: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Let’s see if is periodic:)(~ kX

∑−

=

⋅=

=+=1

0

)/2(

)(~)(~),(~)(~

N

n

nkN

NjN

WnxkX

eWkNnxnx π

We know is periodic:)(~ nx

)(~)]2sin()2[cos()(~)(~

][][)(~

][)(~

][)(~

)(~)(~

2

)/2(1

0

)/2(

1

0

)/2(

1

0

)()/2(

1

0

)(

kX

njnkXekX

eenx

enx

enx

WnxNkX

nj

nNNjN

n

nkNj

N

n

nNnkNj

N

n

NknNj

N

n

NknN

=

−⋅=⋅=

⋅=

⋅=

⋅=

⋅=+

−−

=

=

+−

=

+−

=

+

πππ

ππ

π

π

Let x(n) represent one period of )(~ nx

elsewherenxNnfornxnx

0)(10)(~)(

=−≤≤=

…….…….

)(~ nx

N0-Nx(n)

N0

∑−

=

−=1

0)()(

N

n

nznxzX

∑−

=

⋅=1

0)(~)(~ N

n

nkNWnxkX

kN

kNj WezzXkX −==

= )/2()|()(~π

16

Page 17: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

kN

kNj WezzXkX −=== )/2()|()(~

π

z-plane

ω

ωjezzX =)(

Nπ2

z-plane

kNjezkX )/2()(~ π=

The Discrete Fourier Series corresponds to sampling the z-transformat N points equally spaced in angle around the unit circle.

)(~ kX

)( zX

Look at above figures, what is N in this case??? N=12

Illustration: let’s consider a sequence:

)10/sin()2/sin(

1)(~)(~

)10/4(

4

0

)10/2(

4

010

1

0

kke

e

WWnxkX

kj

n

nkj

n

nkN

n

nkN

πππ

π

=

=

=

=

=

⋅=⋅=

∑∑

…….…….

)(~ nx

40-10 10

N=101

17

Page 18: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

kN

kNj WezzXkX −=== )/2()|()(~

π

)2

sin(

)2

5sin(

)10/5sin(

)2/5sin()(

52

10)/2(

2

)10/5

4(

ω

ωπωπ

πωπ

πω

πω

πω

ω

πω

πω

j

jj

e

eeX

k

kN

=

==

====>

=

Discrete Fourier Series z transform(periodic ) (finite x(n) ))(~ nx

)(nx

40-10 10

1

• Properties of the Discrete Fourier Series:

Linearity:

)(~)(~)(~)(~)(~)(~

213

213

kXbkXakX

nxbnxanx

⋅+⋅=

⋅+⋅=

)(~1 nx )(~

2 nx periodic, both with period N

All sequences are periodic with period N

kXbkXa

enxbenxa

enxbnxa

enxkX

nkNjN

n

nkNj

N

n

nkNj

N

n

nkNj

(~)(~

])(~)(~[

)](~)(~[

)(~)(~

21

)/2(2

1

0

)/2(1

1

0

)/2(21

1

0

)/2(33

⋅+⋅=

⋅⋅+⋅⋅=

⋅⋅+⋅=

⋅=

−−

=

=

=

ππ

π

πLet’s see:

18

Page 19: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Periodic Convolution:

)(~1 nx )(~

2 nx periodic, both with period N )(~)(~??? 21 kXkX ⋅==>

∑∑

∑∑

∑∑

∑∑

=

+−

=

=

=

=

=

=

=

⋅⋅=

⋅⋅=⋅

⋅=⋅=

⋅=⋅=

1

0

)(21

1

0

1

021

1

021

1

02

1

0

)/2(22

1

01

1

0

)/2(11

)(~)(~

)(~)(~)(~)(~

)(~)(~)(~

)(~)(~)(~

N

r

krmN

N

m

N

r

rkN

mkN

N

m

N

r

rkN

N

m

rkNj

N

m

mkN

N

m

mkNj

Wrxmx

WWrxmxkXkX

WrxerxkX

WmxemxkX

π

π

]1)[(~)(~

)(~)(~1

)(~)(~1)(~

)(1

0

1

021

1

0

1

0

)(21

1

0

1

0

21

1

03

krmnN

N

k

N

r

N

m

N

r

krmN

N

m

nkN

N

k

nkN

N

k

WN

rxmx

WrxmxWN

kXkXWN

nx

−−−−

=

=

=

=

+−

=

−−

=

−−

=

∑∑∑

∑∑∑

⋅=

⋅⋅=

⋅=

DFS

Sequence:

⎩⎨⎧ ⋅+−=

=−−−−

=∑ otherwise

NlmnrW

Nkrmn

N

N

k 0)(11 )(

1

0

l is any integer.

∑∑

∑∑∑

=

=

=

−−−−

=

=

=

−⋅=

⋅=

⋅=

1

021

1

021

1

0

)(1

0

1

021

1

03

)(~)(~

)(~)(~

]1)[(~)(~)(~

N

m

N

r

N

m

krmnN

N

k

N

r

N

m

mnxmx

rxmx

WN

rxmxnx

Periodic Convolution

∑∑−

=

=

−⋅=−⋅1

012

1

021 )(~)(~)(~)(~ N

m

N

m

mnxmxmnxmxOrder doesn’t matter

19

Page 20: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

∑−

=

=

−⋅==>⋅

⋅==>−⋅

1

02111

21

1

021

)(~)(~1)(~)(~

)(~)(~)(~)(~

N

l

N

m

lkXkXN

nxnx

kXkXmnxmx

Periodic convolution productProduct 1/N times the periodic convolution of )(~

1 kX )(2~ kX

)(~2 mx

0 N)(~

1 mx

)(~2 mx −

)2(~2 mx −

-N

)2(~)(~21 mxmx −⋅

20

Page 21: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Finite-Duration Sequences Discrete Fourier Transform (DFT)

• Rectangular sequence

⎩⎨⎧ −≤≤

=otherwise

NnnRN 0

101)(

∑∞

−∞=

+=r

rNnxnx )()(~ )()(~)( nRnxnx N=

Discrete Fourier Transform (DFT):

⎪⎩

⎪⎨

⎧−≤≤⋅

=

⎪⎩

⎪⎨

⎧−≤≤⋅

=

=

=

=

otherwise

NnWkXNnx

otherwise

NkWnxkX

eW

N

k

nkN

N

n

nkN

NjN

0

10)(1)(~

0

10)()(

1

0

1

0

)/2( π

)(nx

0 N)(~ nx

)2(~ +nx

Circular Shift of a sequence

)())2(()(1 nRnxnx NN+=

……

……

……

……

x1(n) is not a linear shift of x(n). It is a circular shift.

21

Page 22: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

• Image a finite-duration sequence x(n) displayed around the circumference of a cylinder (circumference of N points)

)())2(()())(()(~)(~

1

1

nRnxnxmnxmnxnx

NN

N

+=+=+=

⎩⎨⎧ −≤≤

=otherwise

NnnRN 0

101)(

)(~)(1 kXWkX kmN−=

DFT:

Symmetry properties of DFT: similar to previous DFS.

Periodic convolution DFS product

We already learned:

)(~)(~)(~)(~21

1

021 kXkXmnxmx

N

m⋅==>−⋅∑

=

• Let’s look at finite-duration sequences x1(n) and x2(n), duration NDFT: X1(k) and X2(k) X1(k)X2(k)??

x3(n) is one period of ∑−

=

−⋅=1

0213 )(~)(~)(~ N

mmnxmxnx

)()(

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

)(])(~)(~[)(

21

1

021

1

0213

nxnx

nRmnxmx

nRmnxmxnx

NN

N

mN

N

N

m

=

−⋅=

−⋅=

∑−

=

=

N

22

Page 23: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

0)(:

101

00)()(

1

0

0

0

01

knNWkXDFT

Nnnnn

nnnnnx

=

⎪⎩

⎪⎨

−≤<=

<≤=

−= δExample 1:

)()( 21 nxnx NLet’s solve ???

0 N

)(nx

)(2 mx

)(1 mx

n0=1

0 N

)(~2 mx −

…………

)())0((2 mRmx NN−

x3(0)

)())1((2 mRmx NN−

…………)1(~

2 mx −

x3(1))()( 21 nxnx Nx3(n)=

23

Page 24: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Example 2:

⎩⎨⎧ −≤≤

==otherwise

Nnnxnx

0101

)()( 21

0 N

)(1 nx

1

)(2 nx1

)(3 nxN

Linear convolution using the DFT

∑−

=

−=1

0213 )()()(

N

mmnxmxnx

Linear convolution: N-point sequences: x1(n) x2(n)

The length of x3(n) is 2N-1

For length of 2N-1:

)()]()([12

1)(

)()(

)()(

12

22

012213

22

012212

22

01211

nRWkXkXN

nx

WnxkX

WnxkX

N

N

k

nkN

N

n

nkN

N

n

nkN

=

−−

=−

=−

⋅⋅−

=

⋅=

⋅=

∑−

=

−=1

0213 )()()(

N

mmnxmxnx is the linear convolution

24

Page 25: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Two-dimensional DFT:

• Rectangular sequence

⎩⎨⎧ −≤≤−≤≤

=otherwise

NnMmnmR NM 0

10,101),(,

),(),(1),(

),(),(),(

,

1

0

ln1

0

,

1

0

ln1

0

nmRWWlkXMN

nmx

lkRWWnmxlkX

NM

N

lN

kmM

M

k

NM

N

nN

kmM

M

m

⋅⋅=

⋅⋅=

∑∑

∑∑−

=

−−−

=

=

=

If x(m,n) is separable, then the 2D DFT is also separable. Linearity:

),(),(),(),(),(),(

213

213

lkbXlkaXlkXnmbxnmaxnmx

+=+=

Flow Graph and Matrix Representation of Digital Filters

4.1 Signal flow graph representation of digital networks

• Basic block-diagram symbols:

+)(1 nx

)(2 nx

)()( 21 nxnx +

a)(nx )(nax

Addition of two sequences

multiplication

Z-1)(nx )1( −nx Unit delay

Shift property of z-transform:Z-transform of x(n-1) is simply z-1 times the z-transform of x(n)

25

Page 26: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

)()2()1()( 21 nbxnyanyany +−+−=

+)(nx b

+

Z-1

a1

Z-1a2

)(ny

)1( −ny

)2( −ny

Digital network

For Digital hardware:We must provide storage for y(n-1) and y(n-2) and also the constants a1, a2, and b, as well as means for multiplication andaddition.

Node j, Wj

Node k, Wk

• Source node: no entering branches.

• The node value at a source node j will be denoted as xj

• The output of a branch connecting source node j to network node k will be denoted as sjk.

Node k

Source node jxj

26

Page 27: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

+

Z-1

+y(n)x(n)

a b

Delay branchSink node

Source node

a by(n)x(n)

1 2 3

4

N=4 network nodes;M=1 source nodes.

jk

N

nodesnetwork

jk

jk

M

nodessource

jjk

N

nodesnetwork

jk

ry

svw

∑∑

=

==

=

+=

)(

1

)(

1

)(

1

w1(n)=s11(n)+v41(n)w2(n)=v12(n)w3(n)=v23(n)+v43(n)w4(n)=v24(n)y(n)=w3(n)

For example:

)([

0001

)1()1()1()1(

0010000000000000

)()()()(

000000

0001000

)()()()(

4

3

2

1

4

3

2

1

10

1

4

3

2

1

nx

nwnwnwnw

nwnwnwnw

bb

a

nwnwnwnw

⎥⎥⎥⎥

⎢⎢⎢⎢

+

⎥⎥⎥⎥

⎢⎢⎢⎢

−−−−

⎥⎥⎥⎥

⎢⎢⎢⎢

+

⎥⎥⎥⎥

⎢⎢⎢⎢

⎥⎥⎥⎥

⎢⎢⎢⎢

=

⎥⎥⎥⎥

⎢⎢⎢⎢

[ ] )(

)()()()(

0100)( 3

4

3

2

1

nw

nwnwnwnw

ny =

⎥⎥⎥⎥

⎢⎢⎢⎢

=

Delay branch y(n)x(n)w1 w2

w3

w4

a1 b1

b0

27

Page 28: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

|H(ejw)|

cωπ −2 π2Frequency response of an ideal lowpass filter

"template" used for the specification of a model lowpass filter in the frequency domain dd

IIR filter design methods:

-- Other computer-aided techniques, etc

A.

28

Page 29: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

transform an analog filter design to a digital filter design:--- choose the unit-sample response of the digital filter as equallyspaced samples of the impulse response of the analog filter

)()( nThnh a= T: sampling period

)()( nThnh a=

Impulse invariance mapping:

Mapping Example:

29

Page 30: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Impulse invariance design example:

)1)(1()cos(1

12/1

12/1)(

2/12/1)(

)(

11

1

11

22

−−−−−

−−

−−−−−

−−−

=

−+

−=

−++

++=

+++

=

zeezeezbTe

zeezeezH

jbasjbas

basassH

jbTaTjbTaT

aT

jbTaTjbTaT

a

If:

∑= −

=N

k k

ka ss

AsH1

)( ∑=

−−=

N

kTs

k

zeAzH

k1

11)(

30

Page 31: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Impulse response truncation: to obtain a finite-length impulse response by truncating an infinite-duration impulse response sequence.

−∞=

=

=

π

π

ωω

ωω

ωπ

deeHnh

enheH

njjdd

n

njd

jd

)(21)(

)()(

Ideal desired frequency response:

Truncation:

⎩⎨⎧ −≤≤

=otherwise

Nnnhnh d

010)(

)(

B.

1.

31

Page 32: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Computer-aided design of FIR filters– Frequency Sampling

• In the Fourier-Window design method: The desired frequency response of the FIR filter is given in thecontinuous frequency; then use a window to deduce the filter.

• In the frequency sampling method:The desired frequency response of the filter is given at discrete frequencies which are the uniform samples of the continuous frequency response, then the inverse DFT is used to obtainthe corresponding discrete-time impulse response.

It allows us to design frequency selective filters, leads to FIR filters whose coefficients are integers, making the computation very fast even less precise.

32

Page 33: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Chapter 6 FFT:

Decimation-in-Time FFT algorithms• To decompose the DFT computation into successively smallerDFT computations.

• Decimation-in-time algorithms: decomposition is based on decomposing the sequence x(n) into successively smaller subsequences. • The principle of decimation-in-time is most conveniently illustrated by considering the special case of N an integer power of 2;

vN 2=• Since N is an even integer, we can consider computing X(k) by separating x(n) into two N/2-point sequences consisting of the even-numbered points in x(n) and the odd-numbered points in x(n). With X(k) given by

1,.....,1,0)()(1

0−== ∑

=

NkWnxkXN

n

nkN

An 8-point sequence, i.e. N=8:

N/2 pointDFT

N/2 pointDFT

x(0)

x(2)

x(4)

x(6)

x(1)

x(3)

x(5)

x(7)

G(0)

G(1)

G(2)

G(3)

H(0)

H(1)

H(2)

H(3)

X(4)WN

4

X(0)WN

0

X(1)WN

1

X(2)WN

2

X(3)WN

3

X(5)WN

5

X(6)WN

6

X(7)WN

7

33

Page 34: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

The efficient FFT algorithm in the computational flow graph representation for N=8 is obtained as shown below:

34

Page 35: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Decimation-in-frequency FFT algorithm:

• The decimation-in-time FFT algorithms were all based upon the decomposition of the DFT computation by forming smaller and smaller subsequences.

• Alternatively decimation-in-frequency FFT algorithms are all based upon decomposition of the DFT computation over X(k). For N, a power of 2:

• We divide the input sequence into first half and the last half of points so that:

signal flow graph for the case of 8-point DFT

35

Page 36: ECE 468 Digital Signal Processing - Engineering | SIUchen/ece468/guide.pdf · ECE 468 Digital Signal Processing 1. History: • Digital signal processing has its roots in 17th and

Proceeding in a manner similar to that followed in deriving the decimation-in-time algorithm, the final signal flow graph for computation is shown as

36