3. Discrete-time Processing of Continuous-time Signals
๏ฎ A major application of discrete-time systems is in the processing of
continuous-time signals.
๏ฎ The overall system is equivalent to a continuous-time system, since it
transforms the continuous-time input signal ๐ฅ ๐ ๐ก into the continuous
time signal ๐ฆ๐ ๐ก .
3
4. Continuous to discrete (Ideal C/D) converter
๏ฑ The impulse train (sampling Signal) is
๏ฑ Where
๏ฑ The sampled signal in Time-domain (Time domain multiplication) is
4
๏จ ๏ฉ ๏จ ๏ฉ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ๏ฝ๏ฝ
n
cs nTttxtstxtx ๏ค)()()(
๏จ ๏ฉ ๏จ ๏ฉ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ๏ฝ
n
nTtts ๏ค ๏จ ๏ฉ ๏จ ๏ฉ๏ ๏๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏๏ญ๏๏ฝ๏
n
snj
T
jS ๏ค
๏ฐ2
continuous
F. T.
Ts /2๏ฐ๏ฝ๏
5. Continuous to discrete (Ideal C/D) converter (Cont.)
๏ฑ The sampled signal in Frequency-domain is
๏ฑ Hence, the continuous Fourier transforms of ๐ฅ ๐ (๐ก) consists of
periodically repeated copies of the Fourier transform of ๐ฅ ๐(๐ก).
๏ฑ Review of Nyquist sampling theorem:
๏ง Aliasing effect: If ๐บ ๐ < 2๐บโ, the copies of ๐๐(๐๐บ) overlap, where ๐บโ is the
highest nonzero frequency component of ๐๐(๐๐บ). ๐บโ is referred to as the
Nyquist frequency.
5
)()(
2
1
)( ๏๏ช๏๏ฝ๏ jSjXjX cs
๏ฐ
๏จ ๏ฉ ๏จ ๏ฉ๏ ๏๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏๏ญ๏๏ฝ๏
n
scs njX
T
jX
1
7. Continuous to discrete (Ideal C/D) converter (Cont.)
๏ฑ In the above, we characterize the relationship of ๐ฅ ๐ (๐ก) and ๐ฅ ๐(๐ก) in the
continuous F.T. domain.
๏ฑ From another point of view, ๐๐ (๐๐บ) can be represented as the linear
combination of a serious of complex exponentials:
๏ฑ If ๐ฅ(๐๐) โก ๐ฅ[๐], its DTFT is
๏ฑ The relation between digital frequency and analog frequency is ๐ = ๐๐ 7
๏จ ๏ฉ ๏จ ๏ฉ ๏จ ๏ฉ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ๏ฝ
n
cs nTtnTxtx ๏คsince
๏จ ๏ฉ ๏จ ๏ฉ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏๏ญ
๏ฝ๏
n
Tnj
cs enTxjX
๏ฅ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ
๏ฝ๏ฝ
n
nj
n
njj
enTxenxeX ๏ท๏ท๏ท
)(][)(
8. Continuous to discrete (Ideal C/D) converter (Cont.)
๏ฑ Combining these properties, we have the relationship between the
continuous F.T. and DTFT of the sampled signal:
where
: represent continuous F.T.
: represent DTFT
๏ฑ Thus, we have the input-output relationship of C/D converter
8
๏จ ๏ฉ ๏จ ๏ฉ๏ ๏ ๏ฅ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ฅ
๏ญ๏ฅ๏ฝ
๏บ
๏ป
๏น
๏ช
๏ซ
๏ฉ
๏ท
๏ธ
๏ถ
๏ง
๏จ
๏ฆ
๏ญ๏ฝ๏๏ญ๏๏ฝ
n
s
c
n
sc
jw
T
n
T
jX
T
njX
T
eX
๏ท๏ท11
๏จ ๏ฉjw
eX
๏จ ๏ฉ๏jXc
๏จ ๏ฉ ๏จ ๏ฉ ๏จ ๏ฉTj
T
j
s eXeXjX ๏
๏๏ฝ
๏ฝ๏ฝ๏
๏ท
๏ท
10. Ideal reconstruction filter
๏ฑ The ideal reconstruction filter
is a continuous-time filter,
with the frequency response
being H ๐(๐๐บ) and impulse
response โ ๐(๐ก).
10
)/(
)/sin(
)(
Tt
Tt
thr
๏ฐ
๏ฐ
๏ฝ
11. Combine C/D, discrete-time system, and D/C
๏ฑ Consider again the discrete-time processing of continuous signals
๏ฑ Let ๐ป(๐ ๐๐) be the frequency response of the discrete-time system in
the above diagram. Since Y ๐ ๐๐ = ๐ป ๐ ๐๐ ๐(๐ ๐๐)
11
12. D/C converter revisited
๏ฑ An ideal low-pass filter ๐ป(๐ ๐๐) that has a cut-off frequency ฮฉ ๐ = ฮฉ ๐ /2
= ๐/๐ and gain ๐ด is used for reconstructing the continuous signal.
๏ฑ Frequency domain of D/C converter: [๐ป(๐ ๐๐) is its frequency response]
๏ฑ Remember that the corresponding impulse response is a ๐ ๐๐๐ function, and
the reconstructed signal is
12
๏จ ๏ฉ ๏ ๏ ๏จ ๏ฉ๏จ ๏ฉ
๏จ ๏ฉ๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ ๏ญ
๏ญ
๏ฝ
n
r
TnTt
TnTt
nyty
/
/sin
๏ฐ
๏ฐ
๏จ ๏ฉ ๏จ ๏ฉ ๏จ ๏ฉ ๏จ ๏ฉ
๏ฎ
๏ญ
๏ฌ ๏ผ๏
๏ฝ๏๏ฝ๏
๏
๏
otherwise
TeYA
eYjHjY
Tj
Tj
rr
,0
/, ๏ฐ
14. Practical Reconstruction
๏ฑ We cannot build an ideal Low-Pass-Filter.
๏ฑ Practical systems could use a zero-order hold block
๏ฑ This distorts signal spectrum, and compensation is needed
14
15. Practical Reconstruction (Zero-Order Hold)
๏ฑ Rectangular pulse used to analyze zero-order hold reconstruction
15
๏ฎ
๏ญ
๏ฌ
๏พ๏ผ
๏ผ๏ผ
๏ฝ
s
s
Ttt
Tt
th
,0,0
0,1
)(0
๏ฅ
๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ๏ฝ
๏ญ๏ช๏ฝ
๏ช๏ฝ
n
s
n
s
nTthnx
nTtnxth
thtxtx
)(][
)(][)(
)()()(
0
0
00
๏ค
๏ค
๏
๏
๏ฝ๏
๏๏๏ฝ๏
๏๏ญ )2/sin(
2)(
)()()(
2/
0
00
sTj T
ejH
jXjHjX
s
๏ค
16. Practical Reconstruction
(Zero-Order Hold)
๏ฑ Effect of the zero-order hold in the
frequency domain.
a) Spectrum of original continuous-time
signal.
b) spectrum of sampled signal.
c) Magnitude of Ho(j๏ท).
d) Phase of Ho(j๏ท).
e) Magnitude spectrum of signal
reconstructed using zero-order hold.
16
17. Practical Reconstruction (Anti-imaging Filter)
๏ฑ Frequency response of a compensation filter used to eliminate some of
the distortion introduced by the zero-order hold.
17
๏ฏ๏ฎ
๏ฏ
๏ญ
๏ฌ
๏ญ๏พ
๏ผ
๏
๏
๏ฝ๏
ms
m
s
s
c T
T
jH
๏ท๏ท๏ท
๏ท๏ท
||,0
||,
)2/sin(2)(
Anti-imaging filter.
19. Analog Processing using DSP
๏ฑ Block diagram for discrete-time processing of continuous-time signals.
19
(b) Equivalent continuous-time system.
(a) A basic system.
20. Idea: find the CT system
๏ฑ 0th-order S/H:
20
)()()(such that)()( ๏ท๏ท๏ท๏ท jXjGjYjGtg FT
๏ฝ๏พ๏ฎ๏ฌ
๏ท
๏ท
๏ท ๏ท )2/sin(
2)( 2/
0
sTj T
ejH s๏ญ
๏ฝ
)()()( ๏ท๏ท๏ท jXjHjX aa ๏ฝ
๏จ ๏ฉ
๏จ ๏ฉ๏ฅ
๏ฅ
๏ฅ
๏ฅ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ฅ
๏ญ๏ฅ๏ฝ
๏ญ๏ญ๏ฝ
๏ญ๏ญ๏ฝ
๏ฝ๏ญ๏ญ๏ฝ
๏ญ๏ฝ
n
ssa
Tj
c
s
n
ssa
Tj
s
ss
n
ssa
s
n
sa
s
kjXkjHeHjHjH
T
jY
kjXkjHeH
T
jY
TkjXkjH
T
kjX
T
jX
s
s
))(())(()()(
1
)(
))(())((
1
)(
/2,))(())((
1
))((
1
)(
0 ๏ท๏ท๏ท๏ท๏ท๏ท๏ท
๏ท๏ท๏ท๏ท๏ท
๏ฐ๏ท๏ท๏ท๏ท๏ท
๏ท๏ท๏ท
๏ท
๏ท
๏ค
๏ค
21. Idea: find the CT system (Cont.)
๏ฑ If no aliasing, the anti-imaging filter Hc(jw) eliminates frequency
components above ๏ทs/2, leaving only k=0 terms
๏ฑ If anti-aliasing and anti-imaging filters are chosen to compensate the
effects of sampling and reconstruction, then
21
๏จ ๏ฉ
๏จ ๏ฉ )()()(
1
)(
)()()()(
1
)(
0
0
๏ท๏ท๏ท๏ท
๏ท๏ท๏ท๏ท๏ท
๏ท
๏ท
jHeHjHjH
T
jG
jXjHeHjHjH
T
jY
a
Tj
c
s
a
Tj
c
s
s
s
๏ฝ
๏ฝ
๏จ ๏ฉsTj
acs
eHjG
jHjHjHT
๏ท
๏ท
๏ท๏ท๏ท
๏ป
๏ป
)(Thus,
1)()()()/1( 0
23. Digital Signal Processing
๏ฑ Provided that :
๐ป ๐ ๐ฮฉ =
1 ฮฉ โค
ฮฉ ๐
2
0 ฮฉ >
ฮฉ ๐
2
๐บ ๐๐๐ ๐ฮฉ =
๐ป ๐ ๐ฮฉ ๐บ ๐ ๐ฮฉ๐
๐ป ๐ ๐ฮฉ ๐ป๐ ๐ฮฉ ฮฉ โค
ฮฉ ๐
2
0 ฮฉ >
ฮฉ ๐
2 23
Digital Signal
Processor
C/D
Sample
nT
๐ฅ(๐ก)
๐(๐ฮฉ)
Antialiasing
Analog
Filter
๐ฏ ๐(๐๐)
๐ฅ ๐(๐ก)
๐ ๐(๐ฮฉ)
๐ฅ[๐]
๐(๐ ๐๐
)
Reconstruction
Analog
Filter
๐ฏ ๐(๐๐)
๐ฎ(๐๐๐)
๐ฆ[๐]
๐(๐ ๐๐
)
๐ฆ๐(๐ก)
๐๐(๐ฮฉ)๐ฏ ๐(๐๐)
D/C
Zero order
hold
๐ฆ(๐ก)
๐(๐ฮฉ)
๐ฎ ๐๐๐(๐๐)
๐ฆ(๐ก)
๐(๐ฮฉ)๐(๐ฮฉ)
๐ฅ(๐ก)
24. Introduction
๏ฑ In single-rate DSP systems, all data is sampled at the same rate no
change of rate within the system.
๏ฑ In Multirate DSP systems, sample rates are changed (or are different)
within the system
๏ฑ Multirate can offer several advantages
๏ง reduced computational complexity
๏ง reduced transmission data rate.
24
25. Example: Audio sample rate conversion
๏ฑ Recording studios use 192 kHz
๏ฑ CD uses 44.1 kHz
๏ฑ wideband speech coding using 16 kHz
๏ฑ Master from studio must be rate-converted by a factor 44.1/192
25
26. Example: Oversampling ADC
๏ฑ Consider a Nyquist rate ADC in which the signal is sampled at the
desired precision and at a rate such that Nyquistโs sampling criterion is
just satisfied.
๏ง Bandwidth for audio is 20 Hz < f < 20 kHz
๏ง The required Antialiasing filter has very demanding specification
๏ง Requires high order analogue filter such as elliptic filters that have very
nonlinear phase characteristics
โข hard to design, expensive and bad for audio quality.
26
27. ๏ฑ Nyquist Rate Conversion Anti-aliasing Filter.
๏ฑ Building a narrow band filters ๐ป ๐(๐ฮฉ) and ๐ป ๐(๐ฮฉ) is difficult &
expensive.
27
28. ๏ฑ Consider oversampling the signal at, say, 64 times the Nyquist rate but
with lower precision. Then use multirate techniques to convert sample
rate back to 44.1 kHz with full precision.
๏ง New (over-sampled) sampling rate is 44.1 ร 64 kHz.
๏ง Requires simple antialiasing filter
๏ฑ Could be implemented by simple filter (eg. RC network)
๏ฑ Recover desired sampling rate by downsampling process.
28
30. Multirate Digital Signal Processing
๏ฑ The solution is changing sampling rate using downsampling and
upsampling.
๏ฑ Low cos:
๏ง Analog filter (eg. RC circuit)
๏ง Storage / Computation
๏ฑ Price:
๏ง Extra Computation for โ ๐ด ๐ and โ ๐ด ๐
๏ง Faster ADC and DAC
30
DSPC/D
Sample
nT
๐ฅ(๐ก)
๐(๐ฮฉ)
Antialiasing
Analog
Filter
๐ฏ ๐(๐๐)
๐ฅ ๐(๐ก) ๐ฅ[๐]
Reconstruction
Analog
Filter
๐ฏ ๐(๐๐)
๐ฎ(๐๐๐
)
๐ฆ[๐] ๐ฆ๐(๐ก)
๐ฏ ๐(๐๐)
D/C
Zero order
hold ๐ฆ(๐ก)
๐(๐ฮฉ)
โ ๐ด ๐
Downsampler
๐ฅ1[๐]
โ ๐ด ๐
Upsampler
๐ฆ2[๐]
31. Example (1)
๏ฑ Given a 2nd order analog filter
๏ฑ Evaluate ๐ป ๐ ๐ฮฉ for
๏ง Anti-aliasing filter
๏ง Zero-Order-Hold
๏ง Anti-imaging filter
๏ฑ At sampling frequency:
๏ง Sampling frequency = 300Hz.
๏ง Sampling frequency = 2400Hz. (8x Oversampling)
31
๐ป ๐ ๐ฮฉ =
(200๐)2
(๐ฮฉ + 200๐)2
, ๐ ๐๐๐๐๐ ๐ต๐ โ 50 < ๐ < 50
32. Example (1): Ideal Anti-aliasing Filter
๏ฑ The required specification is
๐ป ๐ ๐ฮฉ =
1 ฮฉ โค 100๐
0 ฮฉ > 100๐
๏ง In case of ฮฉ ๐ = 600๐
๏ง In case of ฮฉ ๐ = 4800๐
๏ฑ Passband constraint same for both cases
๏ง ๐ป ๐ ๐100๐ =
(200๐)2
200๐(๐
1
2
+1)
2 =
4
5
= 0.8
๏ฑ Stopband actual
๏ง ๐ป ๐ ๐500๐ =
(200๐)2
200๐(๐
5
2
+1)
2 =
4
29
โ 0.14
๏ง ๐ป ๐ ๐4700๐ =
(200๐)2
200๐(๐
47
2
+1)
2 =
4
472+4
โ 0.002
32
76๐ ๐๐ก๐ก๐๐๐ข๐๐ก๐๐๐ ๐๐ 1
33. Example (1): Ideal Anti-imaging Filter
๏ฑ The required specifications are shown in the figure
๏ฑ In case of ฮฉ ๐ = 600๐,
๏ง Desired at ฮฉ = 100๐
โข ๐ป๐ ๐100๐ =
๐/6
๐ ๐๐ ๐/6
โ 1.06
๏ง Actual filter at
โข Passband: ๐ป ๐ ๐100๐ =
(200๐)2
200๐(๐
1
2
+1)
2 =
4
5
= 0.8
โข Stopband: ๐ป ๐ ๐500๐ =
(200๐)2
200๐(๐
5
2
+1)
2 =
4
29
โ 0.14
๏ฑ In case of ฮฉ ๐ = 4800๐
๏ง Desired at ฮฉ = 100๐
โข ๐ป๐ ๐100๐ =
๐/48
๐ ๐๐ ๐/48
โ 1.007
๏ง Actual filter at
โข Passband: ๐ป ๐ ๐100๐ =
(200๐)2
200๐(๐
1
2
+1)
2 =
4
5
= 0.8
โข Stopband: ๐ป ๐ ๐500๐ =
(200๐)2
200๐(๐
5
2
+1)
2 =
4
29
โ 0.002
33
๏จ ๏ฉ
)/sin(
/
)2/sin(2 s
s
s
s
r
T
T
jH
๏๏
๏๏
๏ฝ
๏
๏
๏ฝ๏
๏ฐ
๏ฐ
34. Downsampling (Decimation ):
๏ฑ To relax design of anti-aliasing filter and anti-imaging filters, we wish to
use high sampling rates.
๏ง High-sampling rates lead to expensive digital processor
๏ง Wish to have:
โข High rate for sampling/reconstruction
โข Low rate for discrete-time processing
๏ง This can be achieved using downsampling/upsampling
34
35. Downsampling
๏ฑ Let ๐ฅ1 ๐ and ๐ฅ2 ๐ be obtained by sample ๐ฅ(๐ก) with sampling interval ๐ and MT,
respectively.
35
๐ฅ ๐(๐ก)
๐ ๐(๐ฮฉ) ๐1(๐ ๐๐)
๐ฅ1[n]A/D
Sample @T
ฮฉ ๐
๐ฅ ๐(๐ก)
๐ ๐(๐ฮฉ) ๐2(๐ ๐๐
)
๐ฅ2[n]A/D
Sample @MT
ฮฉ ๐ /๐
T๏๏ฝ๏ท
MT๏๏ฝ๏ท
๐๐ ๐๐ ๐๐ ๐๐ T๐ ๐T๐ ๐
๐๐ ๐๐ ๐๐ ๐๐
36. Downsampling Block
๐ฅ[n]
๐(๐ ๐๐
)
Discrete Time
Low-Pass Filter
๐ป ๐(๐ ๐๐
)
๐ค[n]
๐(๐ ๐๐
) ๐(๐ ๐๐
)
๐ฆ n = ๐ค[Mn]Discard Values
๐ โ ๐๐
๐
๐ด
๐
๐
๐ด
(d) Spectrum after Downsampling.
(c) Spectrum of filter output.
(b) Filter frequency response.
(a) Spectrum of oversampled input signal.
Noise is depicted as the shaded portions
of the spectrum.
๐(๐ ๐๐)
๐ฆ nDownsampler
โ ๐
๐ฅ[n]
๐(๐ ๐๐)
37. Downsampling Block
๏ฑ Note: if ๐ฆ n = ๐ค[Mn], then
๐ ๐ ๐๐ =
1
๐
๐=0
๐โ1
๐ ๐ ๐(๐โ2๐๐)/๐
๏ฑ What does ๐ ๐ ๐๐
=
1
๐ ๐=0
๐โ1
๐ ๐ ๐(๐โ2๐๐)/๐
represent?
๏ง Stretching of ๐(๐ ๐๐) to ๐(๐ ๐๐/๐)
๏ง Creating M โ 1 copies of the stretched versions
๏ง Shifting each copy by successive multiples of 2๐ and superimposing (adding)
all the shifted copies
๏ง Dividing the result by M
37
Discrete Time
Low-Pass Filter
๐ป ๐(๐ ๐๐
)
๐ค[n]
๐(๐ ๐๐) ๐(๐ ๐๐
)
๐ฆ n = ๐ค[Mn]Discard Values
๐ โ ๐๐
38. Upsampling
๏ฑ Let ๐ฅ1 ๐ and ๐ฅ2 ๐ be obtained by sample ๐ฅ(๐ก) with sampling interval ๐ and T/M,
respectively.
38
๐ฅ ๐(๐ก)
๐ ๐(๐ฮฉ) ๐1(๐ ๐๐)
๐ฅ1[n]A/D
Sample @T
ฮฉ ๐
๐ฅ ๐(๐ก)
๐ ๐(๐ฮฉ) ๐2(๐ ๐๐
)
๐ฅ2[n]A/D
Sample @T/M
๐ ฮฉ ๐
M
T๏
๏ฝ๏ท
T๏๏ฝ๏ท
๐๐ ๐๐ ๐๐ ๐๐
๐๐ ๐๐ ๐๐ ๐๐
39. Upsampling (zero padding) Block Diagram
39
Insert (M-1) zeros
between each two
successive samples
๐ฅ2[n]
๐2(๐ ๐๐
)
Discrete Time
Low-Pass Filter
๐ป๐(๐ ๐๐
)
๐๐(๐ ๐๐
)
๐ฅ๐ nUpsampler
โ ๐
๐ฅ[n]
๐(๐ ๐๐
)
41. Upsampling (zero padding) Block Diagram
41
๐ฅ[n]
๐(๐ ๐๐
)
Insert (M-1) zeros
between each two
successive samples
๐ฅ2[n]
๐2(๐ ๐๐
) ๐๐(๐ ๐๐
)
๐ฅ๐ nDiscrete Time
Low-Pass Filter
๐ป๐(๐ ๐๐
) ๐๐(๐ ๐๐)
๐ฅ๐ nUpsampler
โ ๐
๐ฅ[n]
๐(๐ ๐๐
)
(a) Spectrum of original sequence.
(b) Spectrum after inserting (M โ 1) zeros in
between every value of the original sequence.
(c) Frequency response of a filter for removing
undesired replicates located at ๏ฑ 2๏ฐ/M, ๏ฑ 4๏ฐ/M, โฆ, ๏ฑ
(M โ 1)2๏ฐ/M.
(d) Spectrum of interpolated sequence.
๐
42. Continuous Signal Processing Using DSP
๏ฑ Block diagram of a system for discrete-time processing of continuous-
time signals including decimation and interpolation.
42
43. Assignment
๏ฑ For the shown Digital Signal Processing system, find the DTFT and FT
representations for ๐ฅ ๐ , ๐ฅ ๐ ๐ , ๐ฆ ๐ , ๐๐๐ ๐ฆ๐ข ๐ .
๏ฑ If the input is a real signal with its Fourier transform shown in Fig.2 (a). Where
๐ฏ ๐๐(๐) is a Low Pass Filter and ๐ฏ ๐ฉ๐ท๐ญ(๐๐๐) is an ideal digital Band Pass Filter
with passband from ๐1๏ฝ
๐
4
to ๐2๏ฝ
3๐
4
, and their frequency response is given as
sown in Fig.2 (b).
43
Fig. (b) Fig. (a)