You are on page 1of 26

Chapter Two

Sampling and Reconstruction


Lecture #5

Rediet Million

AAiT, School Of Electrical and Computer Engineering


rediet.million@aait.edu.et

February, 2020

(Rediet Million) DSP-Lecture #5 February, 2020 1 / 26


2.2 Analog Reconstruction(D/A Conversion)
Ideal reconstructor

As stated in the sampling theorem, if xc (t) is strictly band-limited


and if Ωs ≥ 2Ωmax then xc (t) may be uniquely reconstructed from its
sample x(n) = xc (nTs ).
The reconstruction process involves two steps
I First the sample x(n) are converted into a sequence of impulses i.e
P∞
xs (t) = x(n)δ(t − nTs )
n=−∞
I Then xr (t) i.e xc (t) is filtered with an ideal reconstruction filter,
which is an ideal low-pass filter that has a frequency response given
π Ωs
Ω Ts , |Ω| ≤
 =
by Hr (jΩ), Hr (jΩ) = Ts rect( ) = Ts 2
Ωs π Ωs
0
 , |Ω| > =
Ts 2

(Rediet Million) DSP-Lecture #5 February, 2020 2 / 26


Analog Reconstruction(D/A Conversion)
Ideal reconstructor

I This system is called an ideal Discrete-to-Continuous (D/A) converter.

(Rediet Million) DSP-Lecture #5 February, 2020 3 / 26


Analog Reconstruction(D/A Conversion)
Ideal reconstructor

I The corressponding impulse response, hr (t), is the inverse Fourier


π
transform of Hr (jΩ), & for cut-off frequency it is given by
Ts
sin(πt/Ts )
hr (t) =
πt/Ts

(Rediet Million) DSP-Lecture #5 February, 2020 4 / 26


Analog Reconstruction(D/A Conversion)
Ideal reconstructor

I The output of the filter in time domain is expressed as:



P
xr (t) = x(n)hr (t − nTs ) = x(n) ∗ hr (t)
n=−∞
P∞ sin(π(t − nTs )/Ts )
xr (t) = x(n)
n=−∞ π(t − nTs )/Ts
- This ideal interpolation formula shows how xr (t) is reconstructed from
its samples x(n)

(Rediet Million) DSP-Lecture #5 February, 2020 5 / 26


Analog Reconstruction(D/A Conversion)
Ideal reconstructor

I In frequency domain the interpolation formula becomes :



x(n)Hr (jΩ)e −jnΩTs
P
Xr (jΩ) =
n=−∞

x(n)e −jnΩTs
P
= Hr (jΩ)
n=−∞
= Hr (jΩ)X (e −jnΩTs )
= Hr (jΩ)X (e −jnωs )
- which is 
equivalent to
π Ωs
Ts X (e −jnΩTs ) , |Ω| ≤
 =
Xr (jΩ) = Ts 2
π Ωs
0
 , |Ω| > =
Ts 2
I Thus, X (e −jω ) is frequency scaled (ω = ΩTs ) and then the low-pass
filter removes all frequencies in the periodic spectrum X (e −jnΩTs ) above
π
the cutoff frequency .
Ts
(Rediet Million) DSP-Lecture #5 February, 2020 6 / 26
Analog Reconstruction(D/A Conversion)
Staircase reconstructor

Staircase reconstructor is a simple and most widely used reconstructor


in practice.
Because it is not possible to implement an ideal low-pass filter, many
D/A converts use staircase (Zero-Order Hold) for the reconstruction
filter.
The staircase reconstructor may be realized by holding the current
samples value constant up to the next sample.

(Rediet Million) DSP-Lecture #5 February, 2020 7 / 26


Analog Reconstruction(D/A Conversion)
Staircase reconstructor

The impulse response of a staircase


( reconstructor is defined as :
1 , 0 ≤ t ≤ Ts
hr (t) = u(t) − u(t − Ts ) =
0 , otherwise

The frequency response of the staircase reconstructor is obtained


using the Fourier transform
RTs RTs 1
Hr (jΩ) = hr (t)e −jΩt dt = 1.e −jΩt dt = (1 − e −jΩTs )
0 0 jΩ
sin(ΩTs /2)
Hr (jΩ) = Ts e (−jΩTs /2)
ΩTs /2
(Rediet Million) DSP-Lecture #5 February, 2020 8 / 26
Analog Reconstruction(D/A Conversion)
Staircase reconstructor

The staircase reconstructor has the following properties:


I |Hr (jΩ)| vanishes at integral multiples of Ωs , exactly where the
replicas caused by sampling are centered;
I The staircase reconstructor does not completely eliminate the
replicated spectral images as the ideal reconstructor does;
IIt does not have uniform gain over the Nyquist interval. It is about
4dB below the ideal reconstructor at the Nyquist frequency.
(Rediet Million) DSP-Lecture #5 February, 2020 9 / 26
2.3 Changing the sampling rate using discrete-time processing

It is often necessary to change the sampling rate of a discrete-time


signal to obtain a new discrete-time signal representation.

There are two ways that sample rate conversion maybe done
I The sampled signal maybe converted back into analog signal and
then re-sampled.
I Alternatively, the signal maybe re-sampled in the digital domain.
This approach has the advantage of not introducing additional
distortion in passing the signal through an additional D/A and A/D
converter.

(Rediet Million) DSP-Lecture #5 February, 2020 10 / 26


Changing the sampling rate using discrete-time processing
2.3.1 Sampling rate reduction by an integer factor(Downsampling)

Suppose that we would like to reduce the sampling rate by an integer


0 0 fs
factor, M with a new sampling period Ts = MTs i.e fs =
M
the re-sampled signal is
0
xd (n) = xc (nTs ) = xc (nMTs ) = x(nM)

The time domain behavior of the downsampler(by a factor of M) is


that in every block of M samples of the input sequence it keeps every
M th sample and discards (M − 1)samples of the input sequence.

(Rediet Million) DSP-Lecture #5 February, 2020 11 / 26


Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

If X (jΩ) = 0 for |Ω| > Ωmax , i.e X (jΩ) is band-limited, then xd (n)
will be an exact representation of xc (t) if the following Nyquist
criterion
0
is satisfied .
Ωs 0 π π
> Ωmax ⇒ πfs > Ωmax ⇒ 0 = > Ωmax
2 Ts MTs
The above equation states the following:
The sampling rate can be reduced by a factor of M without aliasing if the
original sampling rate was at least M times the Nyquist rate or if the
bandwidth of the sequence is first reduced by a factor of M by discrete-time
filtering.
(Rediet Million) DSP-Lecture #5 February, 2020 12 / 26
Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

The frequency domain behavior of the downsampler are helpful in


understanding the downsampling operation.
I The DTFT of x(n) = x(nTs ) expressed as :
1 ∞
P w 2πm
X (w ) = Xc ( − )
Ts m=−∞ Ts Ts
0
I Similarly, the DTFT of xd (n) = xc (nMTs ) = xc (nTs ) expressed as :

1 ∞
P w 2πk 1 ∞
P w 2πk
Xd (w ) = Xc ( 0 − 0 ) = Xc ( − )
Ts0 k=−∞ Ts Ts MTs k=−∞ MTs MTs

(Rediet Million) DSP-Lecture #5 February, 2020 13 / 26


Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

I To see the r/ships between X (w ) and Xd (w ), make change of variables


for k as k = i + rM where −∞ < r < ∞ & 0 ≤ i ≤ M − 1, are integers.
I Then the equation Xd (w ) maybe expressed as :
1 M−1
P 1 ∞
P w 2πr 2πi
Xd (w ) = [ Xc ( − − )]
M i=0 Ts r =−∞ MTs Ts MTs

1 M−1
P w 2πi
Xd (w ) = X( − )
M i=0 M M
⇒ Xd (w ) is composed of M copies of the periodic X (w ) frequency scaled

by M & shifted by integer multiples of .
M

(Rediet Million) DSP-Lecture #5 February, 2020 14 / 26


Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

Downsampling can be done without aliasing if we reduce the


bandwidth of the signal x(n) before downsampling.That is , x(n) is
π
first filtered by an ideal low-pass filter with cutoff frequency .
M

I Such a filter-downsampler arrangement is known as a decimator,


and down sampling by low-pass filtering followed by compression is
termed decimation.

(Rediet Million) DSP-Lecture #5 February, 2020 15 / 26


Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

Example-1

(Rediet Million) DSP-Lecture #5 February, 2020 16 / 26


Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

Example-2

(Rediet Million) DSP-Lecture #5 February, 2020 17 / 26


Changing the sampling rate using discrete-time processing
Sampling rate reduction by an integer factor(Downsampling)

(Rediet Million) DSP-Lecture #5 February, 2020 18 / 26


Changing the sampling rate using discrete-time processing
2.3.2 Increasing the sampling rate by an integer factor(upsampling)

Consider a signal x(n) whose sampling rate is to be increased by a


factor of L. The upsampled signal is
n nTs 0
xi (n) = x( ) = xc ( ) = xc (nTs ) n = 0, ±L, ±2L..
L L
0 Ts 0
Where Ts = or fs = Lfs
L
I The expander
( n output is :
x( ) , n = 0, ±L, ±2L..
xe (n) = L
0 , otherwise
P∞
equivalently , xe (n) = x(k)δ(n − kL)
k=−∞
Thus, the expander simply insert (L − 1) zeros in between two low
rated samples.

(Rediet Million) DSP-Lecture #5 February, 2020 19 / 26


Changing the sampling rate using discrete-time processing
Increasing the sampling rate by an integer factor(upsampling)

The FIR interpolation filter is a low-pass filter, with cutoff frequency


π/L and gain L, that performs the computation of the missing
samples between the two low-rate samples.
I Thus, the upsampling operation is often called interpolation.

(Rediet Million) DSP-Lecture #5 February, 2020 20 / 26


Changing the sampling rate using discrete-time processing
Increasing the sampling rate by an integer factor(upsampling)

The Fourier transform of xe (n) is expressed as:



xe (n)e −jωn
P
Xe (ω) =
n=−∞
∞ ∞
x(k)δ(n − kL)]e −jωn
P P
Xe (ω) = [
n=−∞ k=−∞

x(k)e −jωkL
P
Xe (ω) =
k=−∞
Xe (ω) = X (ωL)
IThis shows that the Fourier transform of the output of the expander
is a frequency-scaled version of the Fourier transform of the input.

(Rediet Million) DSP-Lecture #5 February, 2020 21 / 26


Changing the sampling rate using discrete-time processing
Increasing the sampling rate by an integer factor(upsampling)

(Rediet Million) DSP-Lecture #5 February, 2020 22 / 26


Changing the sampling rate using discrete-time processing
sample rate conversion by a rational factor

The cascade of a decimator that reduce the sampling rate by a factor


of M with an interpolator that increase the sampling rate by a factor
of L result in a system that change the sampling rate by a rational
L
factor of .
M
The cascade of two low-pass filters with cutoff frequencies π/M and
π/L is equivalent to a single low-pass filter with a cutoff frequencies
π π
wc = min{ , }
M L

(Rediet Million) DSP-Lecture #5 February, 2020 23 / 26


Chapter two reading assignment
Quantization and Encoding
Discrete time processing of analog signals

(Rediet Million) DSP-Lecture #5 February, 2020 24 / 26


(#2 ) Class exercises & Assignment
1) Each of the following part lists an input signal x(n) and the upsampling
and downsampling rate L & M. Determine the corresponding xd− (n)
sin(2πn/3
a. x(n) = ) , L = 4 and M = 3
πn
b. x(n) = sin(3πn/4) , L = 3 and M = 4
2) Consider the following system for processing a continuous -time signal
with a discrete -time system

The frequency response of the discrete-time filter is


2(1/3 − e −jω )
H(e jω ) =
1 − 1/3e −jω
If fs = 2KHz and xa (t) = sin(1000πt), find the output ya (t)
(Rediet Million) DSP-Lecture #5 February, 2020 25 / 26
3) A signal xa (t) that is band-limited to 10KHz is processed by the
following system

express the output ya (t) in terms of the input xa (t)

(Rediet Million) DSP-Lecture #5 February, 2020 26 / 26

You might also like