You are on page 1of 32

Interpolation & Decimation

j T
z

e
Sampling period T ,
INPUT

at the output

OUTPUT

Interpolation by m:
Let the OUTPUT be Y (z ) [i.e. Samples
exist at all instants nT]
m
then INPUT is X ( z ) [i.e. Samples exist
at instants mT]
Professor A G Constantinides

Interpolation & Decimation


Let Digital Filter transfer function be H (.)
m
then Y ( z ) X ( z ).H (.)
Hence H (.) is of the form H (z ) i.e. its
impulse response exists at the instants mT.
Write
1

H ( z ) h(0) z .h(1) h(2).z


h(m).z
h(2m).z
2

2 m

h(m 1).z

( m 1)

h(2m 1).z

... h(m 1).z

... h(2m 1).z

( 2 m 1)

( m 1)

( 2 m 1)

... h(3m 1) z

( 3m 1)

Professor A G Constantinides

Interpolation & Decimation


m
1
m
2
m
H
(
z
)

H
(
z
)

z
H
(
z
)

z
H
(
z
) ...
Or
1
2
3

Where
H1 ( z m ) h(0) h(m).z m h(2m).z 2 m ...
m
m
2 m
H 2 ( z ) h(1) h(m 1).z h(2m 1).z
...
H 3 ( z ) h(2) h(m 2).z
m

h(2m 2).z

2m

...

So that
1

Y ( z ) H1 ( z ). X ( z ) z H 2 ( z ). X ( z )
m

z 2 H 3 ( z m ). X ( z m ) ...
3

Professor A G Constantinides

Interpolation & Decimation


Hence the structure may be realised as
H1 ( z m )
INPUT

H2 (zm )
+

OUTPUT

H3 (zm )
Samples across here are
phased
by T secs. i.e. they do not
interact in the adder.
Can be replaced by a
commutator switch.

Professor A G Constantinides

Interpolation & Decimation


Hence

H1 ( z m )
m

INPUT

H2 (z )
H3 (zm )

Commutator

OUTPUT

Professor A G Constantinides

Interpolation & Decimation


Decimation by m:
Let Input be X (z ) (i.e. Samples exist at
all instants nT)
m
Y
(
z
) (i.e. Samples exist at
Let Output be
instants mT)
With digital filter transfer function H (z )
we have
Y ( z ) X ( z ).H ( z )
m

Professor A G Constantinides

Interpolation & Decimation


Set

H ( z ) H1 ( z ) z H 2 ( z ) z H 3 ( z ) ...
m

... z

( m 1)

.H m ( z )

And X ( z ) X 1 ( z m ) z 1 X 2 ( z m ) z 2 X 3 ( z m ) ...
... z ( m1) X m ( z m )

Where in both expressions the subsequences


are constructed as earlier. Then

Y ( z m ) H1 ( z m ) z 1H 2 ( z m ) ... z ( m1) H m ( z m )
7

X ( z
1

) z X 2 ( z ) ... z
m

( m 1)

X (z )

mG Constantinides
Professor A

Interpolation & Decimation


Any products that have powers of z 1 less
m
than m do not contribute to Y ( z ) , as this
is required to be a function of z m .
Therefore we retain the products
H1 ( z ) X 1 ( z ) z m H m ( z m ) X 2 ( z m )
m

H m1 ( z ) X 3 ( z )...
... z m H 2 ( z m ) X m ( z m )

Professor A G Constantinides

Interpolation & Decimation


The structure realising this is
Commutator

H1 ( z m )

Hm (zm )
INPUT

H m1 ( z m )

OUTPUT

H2 (zm )

Professor A G Constantinides

Interpolation & Decimation


For FIR filters why Downsample and then
Upsample?
fs

LOW PASS

fs

LENGTH N

#MULT/ACC N . f s

fs

DOWNSAMPLE M:1
LOW PASS

LENGTH N
N. fs
#MULT/ACC M

TOTAL #MULT/ACC

10

UPSAMPLE 1:M
LOW PASS

fs
M

fs

LENGTH N
N. fs
#MULT/ACC M

2. N . f s
M
Professor A G Constantinides

Interpolation & Decimation


A very useful FIR transfer function special
case is for : N odd, h(n) symmetric
with additional constraints on h(n) to be
zero at the points shown in the figure.

11

Professor A G Constantinides

Interpolation & Decimation


For the impulse response shown
1

H ( z ) h(0) h(1).z h(2).z h(3).z h(4).z h(5).z


h(1).z h(2).z 3 h(3).z 5 h(4).z 7 h(5).z 9

The amplitude response is then given


A( ) h(0) h(1).2 cos(T ) h(2).2 cos(3T )
h(3).2 cos(5T )
In general
r 1

A( ) h(0) 2 h
. cos(rT )
r odd
12

Professor A G Constantinides

Interpolation & Decimation

Now consider 1 2 1 2
T
Then
r 1

A(1 ) h(0) 2 h
. cos(rT )
r odd 2
r 1

A(2 ) h(0) 2 h
. cos r 1 T
r odd 2

T
r 1

h(0) h
. cos(r1T )
r odd 2
13

Professor A G Constantinides

Interpolation & Decimation


Hence A(1 ) A(2 ) 2h(0)

r 1

Also
A h(0) 2 h
.cos r. .T
2T

r odd

2T

h ( 0)

A(1 ) A(2 ) 2 A
2T

Or
For a normalised response

A
A(0) 1
T

14

Professor A G Constantinides

Interpolation & Decimation


Thus 2h(0) 1 1
The shifted response
1
~
A( ) A( )
2
is useful

15

1
h(0)
2

Professor A G Constantinides

Design of Decimator and


Interpolator
Example Develop the specs suitable for the
design of a decimator to reduce the
sampling rate of a signal from 12 kHz to
400 Hz
The desired down-sampling factor is
therefore M = 30 as shown below

16

Professor A G Constantinides

Multistage Design of
Decimator and Interpolator
Specifications for the decimation filter H(z)
are assumed to be as follows:
Fp 180 Hz , Fs 200 Hz ,
p 0.002 , s 0.001

17

Professor A G Constantinides

Polyphase Decomposition
The Decomposition
Consider an arbitrary sequence {x[n]} with
a z-transform X(z) given by
n
X ( z )
x
[
n
]
z
n
We can rewrite X(z) as
M 1 k
M
X ( z ) k 0 z X k ( z )
where

n
n
X k ( z ) n xk [n] z n x[Mn k ] z
18

0 k M 1
Professor A G Constantinides

Polyphase Decomposition
The subsequences {xk [n]} are called the
polyphase components of the parent
sequence {x[n]}
The functions X k (z ), given by the
z-transforms of {xk [n]}, are called the
polyphase components of X(z)

19

Professor A G Constantinides

Polyphase Decomposition
The relation between the subsequences {xk [n]}
and the original sequence {x[n]} are given
by
xk [n] x[Mn k ], 0 k M 1
In matrix form we can write

X ( z ) 1 z 1 .... z ( M 1)
20

X0(zM )

M
X1.( z )
..

X . ( z M )
Professor

M
1
A G Constantinides

Polyphase Decomposition
A multirate structural interpretation of the
polyphase decomposition is given below

21

Professor A G Constantinides

Polyphase Decomposition
The polyphase decomposition of an FIR
transfer function can be carried out by
inspection
For example, consider a length-9 FIR
transfer function:
H ( z)

h[n] z

n 0
22

Professor A G Constantinides

Polyphase Decomposition
Its 4-branch polyphase decomposition is
given by
4
1
4
2
4
3
4
H ( z ) E0 ( z ) z E1( z ) z E2 ( z ) z E3 ( z )

where
1
2
E0 ( z ) h[0] h[4]z h[8]z
E1( z ) h[1] h[5]z 1

23

E2 ( z ) h[2] h[6]z
1
E3 ( z ) h[3] h[7]z

Professor A G Constantinides

Polyphase Decomposition
The polyphase decomposition of an IIR
transfer function H(z) = P(z)/D(z) is not that
straight forward
One way to arrive at an M-branch polyphase
decomposition of H(z) is to express it in the
M
P
'
(
z
)
/
D
'
(
z
) by multiplying P(z) and
form
D(z) with an appropriately chosen
polynomial and then apply an M-branch
polyphase decomposition to P '( z )
24

Professor A G Constantinides

Polyphase Decomposition
1 2 z 1
H ( z)
13 z 1

Example - Consider

To obtain a 2-band polyphase decomposition we


rewrite H(z) as

H ( z)

(1 2 z 1 )(13 z 1 )
(13 z 1 )(13 z 1 )

15 z 1 6 z 2

19 z 2

1 6 z 2

19 z 2

5 z 1

19 z 2

Therefore,
1

where H ( z ) E0 ( z ) z E1( z )
2

25

1 6 z 1
E0 ( z )
,
1
19 z

E1( z )

5
19 z 1

Professor A G Constantinides

Polyphase Decomposition
The above approach increases the overall
order and complexity of H(z)
However, when used in certain multirate
structures, the approach may result in a
more computationally efficient structure
An alternative more attractive approach is
discussed in the following example
26

Professor A G Constantinides

Polyphase Decomposition
Example - Consider the transfer function of
a 5-th order Butterworth lowpass filter with
a 3-dB cutoff frequency at 0.5:
H ( z)

27

0.0527864 (1 z 1 )5

1 0.633436854 z 2 0.0557281 z 4

It is easy to show that H(z) can be expressed


as
2
2
1 0.52786 z
1 0.105573 z
H ( z )
z

2
2
2 1 0.105573 z
1 0.52786 z
Professor A G Constantinides

Polyphase Decomposition
Therefore H(z) can be expressed as
2
1
2
H ( z ) E0 ( z ) z E1( z )
where

28

E0 ( z )

1
1 0.105573 z
2 1 0.105573 z 1

E1( z )

1
1 0.52786 z
2 1 0.52786 z 1

Professor A G Constantinides

Polyphase Decomposition
In the above polyphase decomposition,
branch transfer functions Ei (z ) are stable
allpass functions (proposed by
Constantinides)
Moreover, the decomposition has not
increased the order of the overall transfer
function H(z)
29

Professor A G Constantinides

FIR Filter Structures Based on


Polyphase Decomposition
We shall demonstrate later that a parallel
realization of an FIR transfer function H(z)
based on the polyphase decomposition can
often result in computationally efficient
multirate structures
Consider the M-branch Type I polyphase
decomposition of H(z):
30

M 1 k
H ( z ) k 0 z Ek ( z M )
Professor A G Constantinides

FIR Filter Structures Based on


Polyphase Decomposition
A direct realization of H(z) based on the
Type I polyphase decomposition is shown
below

31

Professor A G Constantinides

FIR Filter Structures Based on


Polyphase Decomposition
The transpose of the Type I polyphase FIR
filter structure is indicated below

32

Professor A G Constantinides