4. multirate systems and their applications. we compute here … and throw away most of them...

28
4. Multirate Systems and their Applications

Upload: darren-bryant

Post on 25-Dec-2015

213 views

Category:

Documents


0 download

TRANSCRIPT

4. Multirate Systems and their Applications

N][nx

zH

][my

We compute here … and throw away most of them here!!!!

N

Inefficient Implementation of Downsampling

N][nx

zH

][my

Most terms here are zero … and waste time to process them here!!!!

N zH

][my

$$$$

Inefficient Implementation of Upsampling

N][nx

NzH

][my

N][nx

zH][my

Same!!!

N][nx

NzH

][my

N][nx

zH][my

Recall the Noble Identities

2

6422 2.15.15.10.2 zzzzH

2zH

2

321 2.15.15.10.2 zzzzH

zH

][nx

][nx

][my

][my

Example…

][nh

)(...]4[]2[]0[][)( 242 zHzhzhhnhzHn

odd for 0][ nnh

2

zH

][nx ][my 2zH

2][nx ][my

n

][mh

m

][nh

… continued

2

321 2.15.15.10.2 zzzzH

zH][nx ][my

6422 2.15.15.10.2 zzzzH

2zH2][nx ][my

Example…

Same ][nh

2 zH][nx ][my

2zH2][nx ][my

][mh

m][nh

n

… continued

21

120 zHzzHzH

In general: Polyphase Decomposition.

Take N=2:

...]5[]3[]1[

...]4[]2[]0[521

42

zhzhhz

zhzhhzH

General Filter: Polyphase Decomposition

m

m

m

m

zmhzH

zmhzH

221

220

]12[)(

]2[)(with Polyphase

Components

][nx zH

][my

NOBLE IDENTITY

][nx

20 zH

21 zH

1z][my

POLYPHASE

2

2

][nx zH0

zH1

1z

2][my

2

Downsampling using Polyphase Decomposition

][nx1z

2

2

This is a Serial to Parallel (a Buffer):

][nx S/P

2 ][0 mx

][1 mx

0 0 0 1 2 3 4 5 6 7 0 2 4 6

0 1 3 5

0n

1[ ] [2 1]x m x m

0[ ] [2 ]x m x m

0m

Serial to Parallel (Buffer)

][nx zH

][my

][nx zH0

zH1

1z

2 ][my

2

NOBLE IDENTITY2

][nx 20 zH

21 zH

1z

][my2

POLYPHASE

NOBLE IDENTITY

Upsampling using Polyphase Decomposition

1z

2 [ ]y m

2

][0 ny

][1 ny

This is a Parallel to Serial (an Unbuffer):

[ ]y mP/S

2

0[ ]y n

1[ ]y n0 2 4 6

0 1 3 5

0n

0 0 0 1 2 3 4 5 6 7

0m

Parallel to Serial (Unbuffer or Interlacer)

1

0

][][N

k

Nk

n

n zkNhzznhzH

Given any integer N:

NN

NNN zHzzHzzHzH 1)1(

11

0 ...)(

Nk zH

Example: take N=3

7654321 7.02.04.16.02.43.5.1.2)( zzzzzzzzH

6330 2.02.41.2)( zzzH

6331 7.06.05.)( zzzH

332 4.13.)( zzH

General Polyphase Decomposition

N][nx zH ][my

POLYPHASE

][nx 0

NH z

1NH z

1z][my

N

1z 2

NH z

1N

NH z

1z

Apply to Downsampling…

][nx 0H z

1H z1z

][my

N

1z

2H z

1NH z

1z

N

N

N

… apply Noble Identity

][nx1z

N1z

N

N

][nx S/P

N ][0 mx

1[ ]Nx m

0n0m

0[ ] [ ]x m x mN

1[ ] [ 1]x m x mN

1[ ] [( 1) 1]Nx m x m N

n N

1 2 3 4 5

1

26

3

4

5

6

Serial to Parallel (Buffer):

Serial to Parallel (Buffer)

N][nx zH ][my

][nx NzH0

NzH1

1z

N ][my

POLYPHASE

NN zH 1

1z

Same for Upsampling…

N][nx zH ][my

][nx zH0

zH1

1z

][my

NOBLE IDENTITY

zH N 1

1z

N

N

N

… apply Noble Identity

1z

N [ ]y m

N

][0 ny

1[ ]Ny n

This is a Parallel to Serial (an Unbuffer):

[ ]y mP/S

N

0[ ]y n

1[ ]Ny n

0n

1

2

3

4

5

6

0m m N

1 2 3 4 5 6

1n

Parallel to Serial (Unbuffer or Interlacer)

Processing Data by Blocks

• In most efficient implementations we process data by blocks, rather than one sample at a time.

• Real Time simulation and design software such as Simulink are designed to take advantages of block processing for two purposes:

• efficient computations, thus faster simulations;

• efficient design.

“Sample Based” and “Frame Based” Signals

][ NM

Sample Based:

time

M

N

They are MN distinct signals arranged in a matrix

Particular Case:

[ 1]M

is like M distinct signals ][nx

1[ ]x n

[ ]Mx n

“Sample Based” and “Frame Based” Signals

][ NM

Frame Based:

They are N distinct signals, each one represented as a sequence of frames of length M

Particular Case:

[ 1]M

one signal as a sequence of frames of length M

][nx

1[ ]x n

[ ]Nx n

M

M

5

y0= Frame based

y1= Sample based5

y2=y0= Frame based

Convert “to Sample” and “to Frame”

Example:

Serial to Parallel in Simulink

Serial to Parallel is implemented by the “Buffer” Simulink block in

Signal Processing Blcokset > Signal Management > Buffers:

Buffer

]11[ [ 1]N

][nx S/P

N ][0 mx

1[ ]Nx m

Sample based Frame based

x0[m]

x1[m]

1

y[m]

DF FIR

H1(z)

DF FIR

H0(z)

Buffer Add

1

x[n]

[2x1]

[2x1]

][nx zH 0

zH1

1z

2 ][my

2

0[ ]x m

1[ ]x m

x0[m]

x1[m]

1

y[m]

DF FIR

H1(z)

DF FIR

H0(z)

Buffer Add

1

x[n]

[2x1]

[2x1]

][nx zH 0

zH1

1z

2 ][my

2

0[ ]x m

1[ ]x m

Example of Downsampling

Parallel to Serial in Simulink

Parallel to Serial is implemented by the “UnBuffer” Simulink block in

Signal Processing Blcokset > Signal Management > Buffers:

]11[ [ 1]N

Frame based Sample based

[ ]y mP/S

N

0[ ]y n

1[ ]Ny n

Unbuffer

][nx zH0

zH1

1z

2 ][my

2

][0 ny

1[ ]y n

y0[n]

y1[n]

1

y[m]

UnbufferDF FIR

H1(z)

DF FIR

H0(z) ToFrame

Frame Conversion

1

x[n] 2

2

[2x1]

[2x1]

][nx zH0

zH1

1z

2 ][my

2

][0 ny

1[ ]y n

y0[n]

y1[n]

1

y[m]

UnbufferDF FIR

H1(z)

DF FIR

H0(z) ToFrame

Frame Conversion

1

x[n] 2

2

[2x1]

[2x1]

Example of Upsampling