100% found this document useful (1 vote)
288 views

Chapter 2: Problem Solutions: Discrete Time Processing of Continuous Time Signals

This document discusses sampling of continuous time signals and determining their discrete time Fourier transforms (DTFTs). Problem 2.1 considers sampling a sinusoidal signal at 2 kHz and calculating its DTFT, continuous time Fourier transform (CTFT), and verifying they are the same. Problem 2.2 repeats this for a higher frequency signal that aliases. Problem 2.3 gives the CTFT X(F) of several signals and asks to determine the corresponding DTFT X(ω) using the relationship between the two transforms and the sampling frequency Fs.

Uploaded by

Neslyn Bocio
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
288 views

Chapter 2: Problem Solutions: Discrete Time Processing of Continuous Time Signals

This document discusses sampling of continuous time signals and determining their discrete time Fourier transforms (DTFTs). Problem 2.1 considers sampling a sinusoidal signal at 2 kHz and calculating its DTFT, continuous time Fourier transform (CTFT), and verifying they are the same. Problem 2.2 repeats this for a higher frequency signal that aliases. Problem 2.3 gives the CTFT X(F) of several signals and asks to determine the corresponding DTFT X(ω) using the relationship between the two transforms and the sampling frequency Fs.

Uploaded by

Neslyn Bocio
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

Chapter 2: Problem Solutions

Discrete Time Processing of Continuous Time Signals

Sampling

à Problem 2.1.

Problem:

Consider a sinusoidal signal


xt  3cos1000t  0.1
and let us sample it at a frequency Fs  2kHz.
a) Determine and expression for the sampled sequence xn  xnTs  and determine its Discrete
Time Fourier Transform X  DTFTxn;
b) Determine XF  FTxt;
c) Recompute X from the XF and verify that you obtain the same expression as in a).

Solution:

a) xn  xt tnTs  3cos0.5n  0.1. Equivalently, using complex exponentials,


xn  1.5ej0.1 ej0.5n  1.5ej0.1 ej0.5n
Therefore its DTFT becomes

2   3e 2 
 
j0.1   
X  DTFTxn  3ej0.1   
with     
b) Since FTej2F0 t   F  F0  then
2 Solutions_Chapter2[1].nb

XF  1.5ej0.1 F  500  1.5ej0.1 F  500


for all F.
c) Recall that X  DTFTxn and XF  FTxt are related as

X  Fs   XF  kFs  FFs 2



k

within Fs  2  1kHz. Therefore, in the interval      we can write


with Fs the sampling frequency. In this case there is no aliasing, since all frequencies are contained

X  Fs XF FFs 2


with Fs  2000Hz. Substitute for XF from part b) to obtain
 
j0.1 2000 
X  20001.5ej0.1 2000 
2  500  1.5e 2  500

Now recall the property of the "delta" function: for any constant a  0,

a 
a  
at  
1 t

Therefore we can write


   3ej0.1   
X  3ej0.1     
2 2

same as in b).

à Problem 2.2.

Problem

Repeat Problem 1 when the continuous time signal is


xt  3cos3000t

Solution

Following the same steps:


a) xn  3cos1.5n. Notice that now we have aliasing, since
F0  1500Hz  
2  1000Hz. Therefore, as shown in the figure below, there is an aliasing at
Fs

Fs  F0  2000  1500Hz  500Hz. Therefore after sampling we have the same signal as in
Problem 1.1, and everything follows.
Solutions_Chapter2[1].nb 3

X (F )

 1 .5 1.5 F (kHz )

Fs  X ( F  kFs )
k

 1 .5  0.5 0.5 1.5 F (kHz )


 F2s  1.0 Fs
2  1 .0

à Problem 2.3.

Problem

xn  xnTs  is the sampled sequence. The Sampling frequency Fs is given for each case.
For each XF  FTxt shown, determine X  DTFTxn, where

a) XF  F  1000, Fs  3000Hz;


b) XF  F  500  F  500, Fs  1200Hz

1000 , Fs  2000Hz;
c) XF  3rect 
F

1000 , Fs  1000Hz;
d) XF  3rect 
F

F3000
1000    rect 
e) XF  rect  F3000
1000  , Fs  3000Hz;

Solution

For all these problems use the relation

X  Fs   X Fs  2  kFs 




k
 
a) X  3000   
2  1000  k3000  2    
3000
3  k2;
2
k k
4 Solutions_Chapter2[1].nb


b) X  1200   
2  500  k1200   
1200
2  500  k1200
1200
k

 2    0  k2    0  k2

0  2  500  1200    1.2;


k

1000   6000  rect 


   shown
 
20002 k2
c) X  2000  3  rect 
  k 
1000
2000
k k
below.
X ( )

 2  
2
  2 
2

1000   3000  rect 


2   shown below
 
10002 k2
d) X  1000  3  rect 
  k 
1000
1000
k k

X ( )

 2   2 
1000   rect  1000 

300023000 300023000
e) X  3000  rect 
1000  k 
3000
1000  k 
3000

2  3  3k   rect 


k

 3000  rect 
3
2  3  3k
3

 
k

k2
 6000  rect 
23
k

shown below.

X ( )
6000

 2   26 2
6
 2 
Solutions_Chapter2[1].nb 5

à Problem 2.4.

Problem

In the system shown, let the sequence be


yn  2cos0.3n    4

Fs  2.
and the sampling frequency be Fs  4kHz. Also let the low pass filter be ideal, with bandwidth

s (t )
y[n] ZOH LPF y (t )

Fs
a) Determine an expression for SF  FTst. Also sketch the frequency spectrum
(magnitude only) within the frequency range Fs  F  Fs ;
b) Determine the output signal yt.

Solution.

From what we have seen, recall that


SF  ejFFs   Fs Y 2FFs
Fs sinc 
1 F


From Y  2   ej4   0.3  k2  ej4   0.3  k2 we obtain

Y 2FFs 
k


2  ej4 2  j4 2 
Fs  0.3  k2  e Fs  0.3  k2
F F
k

 2  
2   e
Fs j4 F  600  k4000 
k
e j4 2 
F
 600  k4000
Fs

and then

 ej4 F  600  k4000 



SF  Fs   Ts ej600k40004000sinc 
600k4000

4000  e


k 4000
j600k40004000 600k4000 j4 2 
Ts e sinc  F
 600  k4000

where we used the fact that the ZOH has frequency response Ts ejFFs sincF  Fs .
Fs
6 Solutions_Chapter2[1].nb

This can be simplified to



SF   1k ej 
20 sinc 
3
20  ke
3 j4 F  600  k4000 

1 ej 


k
3 3
20 sinc  j4 F  600  k4000
20  ke
k

In the interval Fs  4000  F  Fs  4000 we have only terms corresponding to


k  1, 0, 1. The reader can verify that all other frequencies are outside this interval. Therefore, for
4000  F  4000 we have
SF  0.17ej2.827F  3400  0.9634ej0.1  F  600 
 0.9634ej0.1  F  600  0.17ej2.827F  3400
shown below.

| S (F ) |

 5.6  3.4 0.6 3.4 5.6 F (kHz )

b) Since the Low Pass Filter stops all the frequencies above Fs  2 the output signal yt has only
the frequencies at F   600Hz, and therefore
yt  IFT0.9634ej0.1  F  600  0.9634ej0.1  F  600 
 2  0.9634 cos1200t  0.1

à Problem 2.5.

Problem

We want to digitize and store a signal on a CD, and then reconstruct it at a later time. Let the signal
xtbe
xt  2cos500t  3sin1000t  cos1500t
Solutions_Chapter2[1].nb 7

x(t ) x[n] x[n]


ZOH LPF

Fs Fs
and let the sampling frequency be Fs  2000Hz.
a) Determine the continuous time signal yt after the reconstruction.
b) Notice that yt is not exactly equal xt. How could we reconstruct the signal xt exactly
from its samples xn?

Solution

a) Recall the formula, in absence of aliasing,

Fs XF
YF  ejFFs sinc 
F

mum frequency is 750Hz smaller than Fs  2  1000Hz. Therefore, each sinusoid at frequency F
with Fs  2000Hz being the sampling frequency. In this case there is no aliasing, since the maxi-

has magnitude and phase scaled by the above expression. Define



jF
e  F
 sin 
2000
GF  
 
2000

2000
F

which yields

G250  0.9745ej0.392, G500  0.9003ej0.785, G750  0.784ej1.178


Finally, apply to each sinusoid to obtain.
yt  2  0.9745  cos500t  0.392  3  0.9003  sin1000t  0.785 
0.784cos1500t  1.178
b) In order to compensate for the distortion we can design a filter with frequency response 1  GF,
Fs
when 
2   F  
Fs
2 .The magnitude would be as follows
8 Solutions_Chapter2[1].nb

à Problem 2.6.

Problem

In the system shown below, determine the output signal yt for each of the following input signals

bandwidth Fs  2:
xt. Assume the sampling frequency Fs  5kHz and the Low Pass Filter (LPF) to be ideal with

x(t ) x[n]
ZOH LPF y (t )

Fs Fs
a) xt  ej2000t ;
b) xt  cos2000t  0.15;
c) xt  2cos5000t;
d) xt  2sin5000t;
e) xt  cos2000t  0.1  cos5500t.

Solution

Recall the frequency response, in case of no aliasing, is

ÅÅ Å 
jpF pF
‰- ÅÅÅÅÅÅÅÅ
ÅÅÅÅ Sin ÅÅÅÅÅÅÅÅ
GF = ÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅÅ
pÅÅÅÅÅÅÅÅ
F ÅÅÅÅÅÅÅÅÅÅ
5000
5000
ÅÅÅÅÅÅÅÅ
ÅÅÅÅÅ
5000

with 2500  F  2500. Then:

a) G1000  0.935ej0.628 and then yt  0.935ej2000t0.628


b) Using the same number for 1000Hz we obtain
yt  0.935  cos2000 t  0.15   0.628

c) G2500  0.637ej1.5708 , therefore yt  2  0.637cos5000t  1.5708


d) same: yt  2  0.637sin5000t  1.5708
Solutions_Chapter2[1].nb 9

e) the term cos2 2750 t has aliasing, since it has a frequency above 2500Hz. From the
figure, the aliased frequency is

X (F )



 

X ( F  Fs )  2.75 F (kHz )
X ( F  Fs )
2.75
 2.75  5  2.25
Faliased  5.00  2.75  2.25kHz. Therefore it is as if the input signal were
xt  cos2000t  0.1  cos4500t. This yields G1000  0.935ej0.628
and G2250  0.699ej0.393 , and finally
yt  0.935cos2000t  0.1  0.628  0.699cos4500t  1.41372

à Problem 2.7.

Problem

Suppose in the DAC we want to use a linear interpolation between samples, as shown in the figure
below. We can call this reconstructor a First Order Hold, since the equation of a line is a polynomial
of degree one.

y[n] y (t ) y (t )
y[n] FOH

Fs
Ts
n
a) Show that yt   xngt  nTs , with gt a triangular pulse as shown below;

n
10 Solutions_Chapter2[1].nb

g (t )
1

 Ts Ts t
b) Determine an expression for YF  FTyt in terms of Y  DTFTyn and
GF  FTgt;

filter be ideal with bandwidth Fs  2. Determine the output signal yt.


c) In the figure below, let yn  2cos0.8n , the sampling frequency Fs  10kHz and the

y[n]
FOH LPF y (t )

Fs
Solution

a) From the interpolation yt   xngt  nTs  and the definition of the interpolating

n

interval nTs  t  n  1Ts it is easy to see that only two terms in the summation are nonzero, as
function gt we can see that yt is a sequence of straight lines. In particular if we look at any

yt  xngt  nTs   xn  1gt  n  1Ts , for nTs  t  n  1Ts


This is shown in the figure below. Since g Ts   0 we can see that the line has to go through the
two points xn and xn  1, and it yields the desired linear interpolation.
Solutions_Chapter2[1].nb 11

y (t )
x[n]g (t  nTs )
x[ n  1]g (t  ( n  1)Ts )

 
nTs (n  1)Ts t
Interpolation by First Order Hold (FOH)

b) Taking the Fourier Transform we obtain



YF  FTyt   xnGFej2FnTs
 GFX 2FFs
n

where GF  FTgt. Using the Fourier Transform tables, or the fact that (easy to verify)
gt   Ts   rect 
Ts rect  Ts 
1 t t

Fs  , since FTrect 


Ts   Ts sinc 
Fs .
2
we determine GF  Ts sinc 
F t F

à Problem 2.8.

Problem

In the system below, let the sampling frequency be Fs  10kHz and the digital filter have difference
equation
yn  0.25xn  xn  1  xn  2  xn  3

Fs  2.
Both analog filters (Antialiasing and Reconstruction) are ideal Low Pass Filters (LPF) with bandwidth

x (t ) ADC DAC y(
x[ n] y[ n ]
LPF H ( z) ZOH LPF

anti-aliasing Ts Ts Ts reconstruction
filter filter
clock
12 Solutions_Chapter2[1].nb

a) Sketch the frequency response H of the digital filter (magnitude only);
b) Sketch the overall frequency response YF  XF of the filter, in the analog domain (again
magnitude only);
c) Let the input signal be
xt  3cos6000t  0.1  2cos12000t
Determine the output signal yt.

Solution.

a) The transfer function of the filter is Hz  0.251  z1  z2  z3   0.25 
4
1z  , where
1z1
we applied the geometric sum. Therefore the frequency response is
H  Hz zej  0.25  
j4
1e
1ej  0.25 ej1.5  
sin 
sin2
 

2

whose magnitude is shown below.

b) Recall that the overall frequency response is given by

XF  H 2FFs e Fs 



YF jFFs sinc 
F

In our case Fs  10kHz, and therefore we obtain

  
YF
XF
1.4
1.2
1
0.8
0.6
0.4
0.2
F
4000 2000 2000 4000
Solutions_Chapter2[1].nb 13

c) The input signal has two frequencies: F1  3kHz  Fs  2, and F2  6kHz  Fs  2, with
Fs  10kHz the sampling frequency. Therefore the antialising filter is going to stop the second
frequency, and the overall output is going to be
yt  3  0.156 cos6000  t  0.1  0.1  
 0.467745 cos6000  t  0.62832
since, at F  3kHz, YF  XF  0.156ej0.1 .

Quantization Errors

à Problem 2.9

Problem

In the system below, let the signal xn be affected by some random error en as shown. The
error is white, zero mean, with variance e2  1.0. Determine the variance of the error n after the
filter for each of the following filters Hz:

e[n]
x[n] y[n]
H (z )


e[n]  [n]
H (z )

y[n]
x[n] H (z )
14 Solutions_Chapter2[1].nb

a) Hz an ideal Low Pass Filter with bandwidth   4;


b) Hz  
z
z0.5  ;
c) yn  
1 sn  sn  1  sn  2  sn  3, with sn  xn  en;
4

d) H  e , for     .

Solution.

 1  



2 d
Recall the two relationships in the frequency and time domain:

2  
 
 
 

 2   



  e
    
  H 2

    hn 2  e2


 1  
 
  1 4 
  2 d


a) 2      2   
 2  
  






  e 
    2
2   d e  
     
H  4 e ;
1 2
 4

b) the impulse response in this case is hn  0.5n un therefore

2     hn 2  e2    0.52n  e2  


 
1
10.25 e2  
3 e
4 2
 0

c) in this case n  


4 en  en  1  en  2  en  3 . Therefore the impulse
1

response is
hn  
4 n  n  1  n  2  n  3
1

and therefore

2     
42 e  4  
3
16 e  
4 e
1 2 1 2 1 2

 1  w 
d) 2   d
n0

 
 2   e

e  0.3045 e
 
2 2


à Problem 2.10.

Problem

using 8bits/sample. The signal is properly scaled so that  xn   128 for all n.
A continuous time signal xt has a bandwidth FB  10kHz and it is sampled at Fs  22kHz,

a) Determine your best estimate of the variance of the quantization error e2 ;
b) We want to increase the sampling rate by 16 times. How many bits per samples you would use in
order to maintain the same level of quantization error?
Solutions_Chapter2[1].nb 15

Solution

a) Since the signal is such that 128  xn  128 it has a range VMAX  256. If we digitize it with

  VMAX  2Q1  256  256  1. Therefore the variance of the noise is e2  1  12 if we assume
Q1  8 bits. we have 28  256 levels of quantization. Therefore each level has a range

uniform distribution.
b) If we increase the sampling rate as Fs2  16  Fs1 , the number of bits required for the same
quantization error becomes
Q2  Q1  
1 log   1 4  6 bits  sample
2 Fs2  8  
Fs1
2 2

You might also like