Você está na página 1de 11

Chapter 11: Multirate Digital Signal Processing

Multirate DSP

ECEN 644: Chapter 11


I sampling rate conversion: process of converting a given
discrete-time signal at a given rate to a different rate
Dr. Deepa Kundur

Texas A&M University I multirate digital signal processing systems: systems that employ
multiple sampling rates
Spring 2010

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 1 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 2 / 41

Chapter 11: Multirate Digital Signal Processing Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Sampling vs. Sampling Rate Conversion Sampling Rate Conversion

Sampling:
I conversion from cts-time to dst-time by taking “samples” at original/bandlimited x(n)
discrete time instants interpolated signal x(t) 1 y(n)
I E.g., uniform sampling: x(n) = xa (nT ) where T is the sampling
n
period 0

Sampling rate conversion approaches:


I convert original samples to analog domain and then resample to
generate new samples I x(n): original samples at sampling rate Fx
I filter original samples with a discrete-time linear time-varying I y (n): new samples at sampling rate Fy
system to generate new samples

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 3 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 4 / 41
Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Ideal Sampling Rate Conversion Parameter Relationships


1
I x(n): original samples at sampling rate Fx = Tx
I y (n): new samples at sampling rate Fy = T1y
SAMPLING RATE
CONVERSION

x(t) 1 x(n)

Parameter/Variable x(n) ≡ x(nTx ) y (m) ≡ y (mTy )

0
Rate
Period
Fx
Tx
Fy
Ty n
Dst-time Frequency ωx ωy
y(n) Cts-time Frequency F F

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 5 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 6 / 41

Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Bridging the Parameter Relationships Implementation of Sampling Rate Conversion


We relate the original samples x(nTx ) to the new samples y (mTy ) by
Ty
I related to the ratio: Tx assuming we convert the signal to analog and resample. Using the
interpolation formula
Tx
Fy = · Fx ∞
Ty X
2πF y (t) = x(nTx )g (t − nTx )
ωx = 2πfx = n=−∞
Fy
2πF where
ωy = 2πfy =
Fy sin(πt/Tx )

F Tx |F | ≤ Fx < 2
Fy Tx g (t) = ←→ G (F ) =
ωx = · ωy = · ωy πt/Tx 0 otherwise
Fx Ty
Note: y (t) = x(t) if x(t) is sampled above Nyquist.

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 7 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 8 / 41
Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Implementation of Sampling Rate Conversion Implementation of Sampling Rate Conversion


X ∞
X
y (t) = x(nTx )g (t − nTx ) y (t) = x(nTx )g (t − nTx )
n=−∞ n=−∞
X∞ X∞
y (mTy ) = x(nTx ) g (mTy − nTx ) y (mTy ) = x(nTx )g (mTy − nTx )
| {z } | {z } | {z }
n=−∞ n=−∞
desired samples original samples samples of g (t)
∞   
X mTy
= x(nTx )g Tx −n
n=−∞
T x

mTy
= km + ∆ m
Tx

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 9 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 10 / 41

Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Implementation of Sampling Rate Conversion Implementation of Sampling Rate Conversion



  
X mTy
y (mTy ) = x(nTx )g Tx −n
n=−∞
T x

mTy X
= km + ∆ m = x(nTx )g (Tx (km + ∆m − n))
Tx |{z} |{z}
n=−∞
integer remainder

mTy
 let k = km − n
km = ∞
X
Tx = x((km − k)Tx )g (Tx (k + ∆m ))
 
mTy mTy k=−∞
∆m = − ∈ [0, 1) ∞
Tx Tx X
= g ((k + ∆m )Tx )x((km − k)Tx )
k=−∞
| {z }
weighted linear combination of orig samples

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 11 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 12 / 41
Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Implementation of Sampling Rate Conversion Implementation of Sampling Rate Conversion


X ∞
y (mTy ) = g ((k + ∆m )Tx )x((km − k)Tx ) X
y (mTy ) = g ((k + ∆m )Tx )x((km − k)Tx )
k=−∞
k=−∞
X∞
I ∆m : determines the set of weights = g ((k + ∆m )Tx )x((km − k)Tx )
I km : specifies the set of input samples k=−∞
I represents a discrete-time linear time-varying system
I every output sample m requires use of a different impulse I gm (nTx ) may have to be retrieved or computed
response/ceofficient set: I in general, there are as many weights/coefficients required as
input samples × output values to compute
gm (nTx ) = g ((n + ∆m )Tx )
  I in general, no simplification is possible making computation of
mTy mTy
∆m = − ∈ [0, 1) y (mTy ) from x(nTx ) impractical
Tx Tx

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 13 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 14 / 41

Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Linear Periodically Time-Varying Implementation Linear Periodically Time-Varying Implementation

I significant simplification possible for TTyx = Fx


Fy
= D
I
Note:
where D, I ∈ Z+ and GCD(D, I ) = 1
(mD)I ∈ {0, 1, 2, . . . , I − 1}
1
   
mTy mTy mD mD
∆m = − = − ∆m = (mD)I ∈ {0, 1/I , 2/I , . . . , (I − 1)/I }
Tx T I I I
 x  
1 mD 1
= mD − I = (mD) mod I
I I I I gm (nTx ) = g ((n + ∆m )Tx ) consists only of I distinct sets of
1 coefficients!
= (mD)I
I

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 15 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 16 / 41
Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

Linear Periodically Time-Varying Implementation Linear Periodically Time-Varying Implementation

Furthermore, for r ∈ Z:
1 1
∆m+rI =((m + rI )D)I = (mD + rlD)I
I I
1
= (mD)I = ∆m
I
∴ gm+r I (nTx ) = gm (nTx ), r ∈ Z

I gm (nTx ) = gm+rI (nTx ) represents a discrete-time periodically


time-varying system!

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 17 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 18 / 41

Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

original/bandlimited
Decimation/Downsampling interpolated signal 1
original/bandlimited
interpolated signal 1 SAMPLING RATE n
0
CONVERSION

0
n

X
y (mTy ) = g ((n + ∆m )Tx )x((km − n)Tx )
Ty n=−∞
Ty = DTx =⇒ = D, D ∈ Z+ ∞
Tx X
  = g ((n + 0)Tx )x((mD − n)Tx )
mTy
km = = bmDc = mD ∵ mD ∈ Z n=−∞
Tx X∞
 
mTy mTy = g (nTx )x((mD − n)Tx )
∆m = − = mD − bmDc = mD − mD = 0
Tx Tx n=−∞
| {z }
dst-time convolution

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 19 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 20 / 41
Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.1 Introduction

original/bandlimited
interpolated signal 1
Interpolation/Upsampling
n
0 original/bandlimited
interpolated signal 1


X 0
n
y (mTy ) = g (nTx )x((mD − n)Tx )
n=−∞ Ty 1
∞ Tx = ITy =⇒ = , I ∈ Z+
X sin(πn) T I
= x((mD − n)Tx )   xj k
πn mTy m
n=−∞ km = =

X Tx I
= δ(n)x((mD − n)Tx ) = x(mDTx )
 
mTy mTy m jmk
n=−∞
∆m = − = −
Tx Tx I I
See Figure 11.1.3 of text . ∈ {0, 1/I , 2/I , . . . , (I − 1)/I }

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 21 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 22 / 41

Chapter 11: Multirate Digital Signal Processing 11.1 Introduction Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D

Interpolation/Upsampling Downsampling with Anti-Alaising Filter



X Decimator
y (mTy ) = x(nTx )g (mTy − nTx ) LTI Filter Downsampler
n=−∞

X Tx
= x(nTx )g (m − nTx )
n=−∞
I

X sin(π mI − πn)
= x(nTx )
n=−∞
π mI − πn

X sin( πI (m − nI )) I Downsampling alone may cause aliasing, therefore, it is desirable
= x(nTx ) π
(m − nI ) to introduce an anti-aliasing filter Hd (ωx )
n=−∞ | I {z }
sinc centered at n = m/I
Interpolator Decimator
See Figure 11.1.4 of text . Upsampler LTI Filter LTI Filter Downsamp

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 23 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 24 / 41
Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D

Decimator
LTI Filter Downsampler
Downsampling: Frequency Domain Perspective
Goal: determine relationship between input-output spectra

Create an intermediate signal ṽ (n) at rate Fx but with the equivalent


information as y (m).

v (n) n = 0, ±D, ±2D, . . .
ṽ (n) =
0 otherwise

X ∞
v (n) = h(k)x(n − k) = v (n) · p(n) where p(n) =
X
δ(n − kD)
k=−∞
k=−∞

Interpolator X Decimator Note: y (m) = v (mD) · 1 = v (mD) · p(mD) = ṽ (mD)
Upsamplery (m) = v (mD) = h(k)x(mD − k)
LTI Filter LTI Filter Downsampler
k=−∞ y (m) ←→ ṽ (n) (equiv info)
| {z }
linear time-varying system
See Figure 11.2.2 of text .

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 25 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 26 / 41

Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D

Aside: Impulse Train p(n) Downsampling: Frequency Domain Perspective



X ∞
X

X Y (z) = y (m)z −m = ṽ (mD)z −m
p(n) = δ(n − lD) (periodic with period D) m=−∞ m=−∞
l=−∞
= · · · + ṽ (−D)z + ṽ (0)z + ṽ (D)z −1 + · · ·
1 0
D−1 ∞
1 X
ck = p(n)e j2πkn/D 0
X
D = ṽ (m0 )z −m /D since ṽ (m) = 0 for m 6∈ {0, ±D, ±2D, . . .}
n=0 m0 =−∞
D−1 ∞
X X ∞ ∞ D−1
= δ(n − lD) e j2πkn/D
X X 1 X j2πkm/D −m0 /D
= v (m)p(m)z −m/D = v (m) e z
n=0 l=−∞ D
| {z } m0 =−∞ m=−∞ k=0
zero for l 6= 0 D−1 ∞
1 X X
D−1 = v (m)(e −j2πk/D z 1/D )−m
1 X
j2πkn/D 1 D
= δ(n)e = k=0 m=−∞
D n=0
D | {z }
≡V (e −j2πk/D z 1/D )=Hd (e −j2πk/D z 1/D )X (e −j2πk/D )
D−1 D−1
X 1 X j2πkm/D D−1
p(n) = ck e j2πkm/D = e 1 X
D = Hd (e −j2πk/D z 1/D )X (e −j2πk/D z 1/D )
k=0 k=0 D
k=0

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 27 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 28 / 41
Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D

Decimator Let z = e jωy :


LTI Filter Downsampler D−1
1 X
Y (z) = Hd (e −j2πk/D z 1/D )X (e −j2πk/D z 1/D )
D
k=0
D−1
1 X
Y (e jωy ) = Hd (e −j2πk/D e jωy 1/D )X (e −j2πk/D e jωy 1/D )
D
k=0
D−1
1 X
= Hd (e j(ωy −2πk)/D )X (e j(ωy −2πk)/D )
D
k=0
In the preceding analysis, we employed:
D−1    
Z 1 X ωy − 2πk ωy − 2πk
v (n) ←→ V (z) Y (ωy ) = Hd X
D D D
Z k=0
hd (n) ←→ Hd (z)
Decimator
Interpolator
x(n) ←→
Z
X (z) Decimator LTI Filter Downsampler
Upsampler LTI Filter X∞ LTI Filter Downsampler
V (z) = v (m)z −m
m=−∞
V (z) = Hd (z) · X (z)

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 29 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 30 / 41

Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D Chapter 11: Multirate Digital Signal Processing 11.2 Decimation by a Factor D
Interpolator Decimator
Upsampler LTI Filter LTI Filter Downsample
D−1    
1 X ωy − 2πk ωy − 2πk Therefore, for −π ≤ ωy ≤ π,
Y (ωy ) = Hd X
D D D
k=0 D−1    
1 X ωy − 2πk ωy − 2πk
For −π ≤ ωy ≤ π, Y (ωy ) = Hd X
D D D
ωy −2πk k=0
− Dπ ≤ D ≤ Dπ for k = 0  ω   ω  1 D−1    
− 3π
ωy −2πk
≤ − Dπ 1 y y
X ωy − 2πk ωy − 2πk
D ≤ D for k = 1 = Hd X + Hd X
.. .. D | {zD } D D D D
k=1 |
. . =1
{z }
π ωy −2πk 3π =0
−2π + D ≤ D ≤ −2π + D for k = D − 1

1 ωy 
Y (ωy ) = D
X D

Ty
Note: ωy = Tx ωx = Dωx .

Note: For −π ≤ ωy ≤ π, − Dπ ≤ ωx ≤ π
of X (ωx ) is stretched into −π ≤ ωy ≤ π for Y (ωy ).
D
  
ωy − 2πk 1 for k = 0 See Figure 11.2.3 of text .
Hd =
D 0 for k = 1, 2, . . . , D − 1

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 31 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 32 / 41
Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I

Goal: determine relationship between input-output spectra


Interpolation by a Factor I
Consider an intermediate signal v (n) at rate Fy but with the equivalent
information as x(m).
Interpolator
Upsampler LTI Filter

x(m/I ) m = 0, ±I , ±2I , . . .
v (m) =
0 otherwise
X∞
V (z) = v (m)z −m = · · · + v (−I )z I + v (0)z 0 + v (I )z −I + · · ·
m=−∞
∞ ∞
X
−mI
X −m
= x(m)z = x(m)(z I ) = X (z I )
m=−∞ m=−∞
jωy jωy I
V (e ) = X (e ) =⇒ V (ωy ) = X (ωy I )
I Interpolation only increases the visible resolution of the signal. Interpolator
Upsampler LTI Filter
I No information gain is achieved. At best Hu (ωy ) maintains the
same information in y (n) as exists in x(n).
Interpolator Decimator
LTI Filter LTI Filter Downsampler

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 33 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 34 / 41

Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I

Interpolator
Interpolator Decimator
Upsampler LTI Filter LTI Filter LTI Filter Downsample
V (ωy ) = X (ωy I )
See Figure 11.3.1 of text .

0 ≤ |ωy | ≤ π/I
I
Hu (ωy ) =
0
otherwise

IX (ωy I ) 0 ≤ |ωy | ≤ π/I
Y (ωy ) = Hu (ωy )V (ωy ) =
0 otherwise

X
 y (m) = hu (m − k)v (k)
I X (ωy I ) 0 ≤ |ωy | ≤ π/I k=−∞
Y (ωy ) =
0 otherwise

m = 0, ±I , ±2I , . . .
x(m/I )
∵ v (m) = ⇒ v (k) = 0 for (k)I 6= 0
Interpolator
0
otherwise Decimator
Note: ωy =
Ty
= ωx
. X∞ LTI Filter ∞
X LTI Filter Downsamp
Tx I
∴ y (m) = hu (m − kI ) v (kI ) = hu (m − kI )x(k)
| {z }
k=−∞ k=−∞
−π ≤ ωx ≤ π is compressed into −π/I ≤ ωy ≤ π/I =x(k) | {z }
linear time-varying system


Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 35 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 36 / 41
Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I

Return Return

Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 37 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 38 / 41

Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I

Return

Return
Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 39 / 41 Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 40 / 41
Chapter 11: Multirate Digital Signal Processing 11.3 Interpolation by a Factor I

Return
Dr. Deepa Kundur (Texas A&M University) ECEN 644: Chapter 11 Spring 2010 41 / 41

Você também pode gostar