<<

Department of University of Arkansas

ELEG 5173L Digital Processing Ch. 3 Discrete-Time

Dr. Jingxian Wu [email protected] 2 OUTLINE • The Discrete-Time Fourier Transform (DTFT)

• Properties

• DTFT of Sampled

and downsampling

3 DTFT • Discrete-time Fourier Transform (DTFT)

 X ()   x(n)e jn n –  (radians): digital frequency • Review: Z-transform:  X (z)   x(n)zn n0 j X ()  X (z) | j – Replace z with e . ze

• Review: Fourier transform:

 X ()  x(t)e jt  –  (rads/sec): analog frequency

4 DTFT • Relationship between DTFT and Fourier Transform

– Sample a continuous time signal x a ( t ) with a sampling period T   xs (t)  xa (t)  (t  nT )   xa (nT ) (t  nT ) n n

– The Fourier Transform of ys (t)

   jt  jnT X s ()  xs (t)e dt  xa (nT)e   n – Define:   T •  : digital frequency (unit: radians) •  : analog frequency (unit: radians/sec)

– Let x(n)  xa (nT)

   X ()  X s    T  5 DTFT • Relationship between DTFT and Fourier Transform (Cont’d) – The DTFT can be considered as the scaled version of the Fourier transform of the sampled continuous-time signal

   jt  jnT X s ()  xs (t)e dt  xa (nT)e   n    x(n)  x (nT) T a

     jn X ()  X s     x(n)e  T  n 6 DTFT • Discrete Frequency  – Unit: radians (the unit of continuous frequency is radians/sec) – X (  ) is a periodic function with period 2

    j2 n  jn  j2n  jn X (  2 )   x(n)e   x(n)e e  x(n)e  X () n n n

– We only need to consider for      • For Fourier transform, we need to consider      

  1 –         f    T 2 2T   1 –        f   T 2 2T 7 DTFT • Example: find the DTFT of the following signal – 1. x(n)   (n)

n – 2. x(n)   u(n),  1 8 DTFT • Example – Find the DTFT of x(n)  u(n)  u(n  N)

9 DTFT • Example – Find the DTFT of the following signal x(n)  |n|,  1

• Existence of DTFT – The DTFT of x(n) exists if x(n) satisfies  | x(n) |   n 10 DTFT • Inverse DTFT

1 jn x(n)  X ()e d 2 2 

• Example

– Find the inverse DTFT of  (  0 ) 11 DTFT • Example

– Find the DTFT of cos(0n ) 12 OUTLINE • The Discrete-Time Fourier Transform (DTFT)

• Properties

• DTFT of Sampled Signals

• Upsampling and downsampling

13 PROPERTIES • Periodicity

X (  2)  X()

• Linearity x (n)  X () – If x1(n)  X1() 2 2

– Then

x1(n)  x2(n) X1()  X2 () 14 PROPERTIES • Time shifting – If x(n)  X () – Then  jn0 x(n  n0 )  X ()e

• Frequency shifting – If x(n)  X () – Then

j0n e x(n)  X (  0 ) 15 PROPERTIES • Differentiation in Frequency – If x(n)  X () – Then dX () nx(n)  j d

d nx(n)  z X (z) – Review dz • Example n – Find the DTFT of n u(n) | |1 16 PROPERTIES • – If y(n)  h(n) x(n) – Then Y()  H()X ()

• Example

– Find the frequency response of the system y(n)  x(n  n0 ) 17 PROPERTIES

• Example n  1  – A LTI system with h(n)    u(n) n 2 if the input is  1    x(n)    u(n)  3 Find the output

18 PROPERTIES • Example – The frequency response of an ideal low pass filter is 1, 0     H()  c  0, c     find the impulse response.

(1) Assume  c  0 . 5  . If the sampling rate of the input signal is 1 KHz, what is the cutoff frequency for the ? (2) If the sampling rate of the input signal is 2 KHz, what is the cutoff frequency of the analog signal?

19 PROPERTIES •

– If y(n)  x1(n)x2 (n) – Then 1 2 Y()  X1( p)X 2 (  p)dp 2 0 20 OUTLINE • The Discrete-Time Fourier Transform (DTFT)

• Properties

• Application: DTFT of Sampled Signals

• Upsampling and downsampling

21 APPLICATION: SAMPLING THEOREM • Sampling theorem: – Sampling: convert the continuous-time signal to discrete-time signal.

xa (t)

 p(t)   (t  nT ) n sampling period

xs (t)  xa (t)p(t) 22 APPLICATION: SAMPLING THEOREM • Sampling theorem: – Fourier transform of the impulse train • impulse train is periodic  1  p(t)   (t  nT )  1 e jnst 2   s  n T n T • Find Fourier transform on both sides 2  P()   (  ns ) T n • Time domain multiplication  Frequency domain convolution 1 x(t) p(t)  X ()  P() 2 a 1   2  xs (t)  x(t) p(t)  X s ()   X a   n  T n  T  23 APPLICATION: SAMPLING THEOREM • Sampling theorem: frequency domain – Sampling in time domain  Repetition in frequency domain 24 APPLICATION: SAMPLING THEOREM • Sampling theorem – If the sampling rate is twice of the bandwidth, then the original signal can be perfectly reconstructed from the samples.

s  2B

s  2B

s  2B

s  2B Department of Engineering Science Sonoma State University 25 APPLICATION: SAMPLING THEOREM

• Analog signal x a ( t ) v.s. sampled signal x s ( t ) v.s. discrete-time x(n) signal x(n)  xa (nT )

Discrete-time signal Samples of continuous-time signal

   x (t)  (t  nT )  x (nT ) (t  nT )  x(n) (t  nT ) xs ( t)  a   a  n n n

 xs (t)   x(n) (t  nT ) n 26 APPLICATION: SAMPLING THEOREM • Fourier transform of sampled signal

   jt  jnT X s ()  xs (t)e dt  x(n)e   n

• DTFT of discrete-time signal

 X ()   x(n)e jn n • Relationship    X ()  X s    T 

DTFT of discrete-time signal Fourier transform of continuous-time signal 27 APPLICATION: SAMPLING THEOREM

• Relationship among X (), X s (), X a () –    X ()  X s    T 

1   2  X s ()   X a   n  T n  T 

1    2  X ()   X a   n  T n  T T 

   T 28 APPLICATION: SAMPLING THEOREM • Example

– Consider the analog signal x a ( t ) with Fourier transform shown in the figure. The signal has a one-sided bandwidth 5 Hz. The signal is sampled with a sampling period T  . 25ms X () Draw X s (  ) and 1 29 APPLICATION: SAMPLING THEOREM • Reconstruction of sampled signal – If there is no aliasing during sampling, the analog signal can be reconstructed by passing the sampled signal through an ideal low pass filter with cutoff frequency B   T, | | s H()   2 0, otherwise  t  h(t)  sin c   T 

 xs (t)   x(n) (t  nT ) n

  t  nT  xˆa (t)  xs (t)  h(t)   x(n)sinc  n  T  30 OUTLINE • The Discrete-Time Fourier Transform (DTFT)

• Properties

• Application: DTFT of Sampled Signals

• Upsampling and downsampling

31 UPSAMPLING AND DOWNSAMPLING • Sampling rate conversion – In many applications, we may have to change the sampling rate of a signal as the signal undergoes successive stage of processing. • E.g.

Rate h1(n) h2 (n) conversion h3(n) T Sampling period T1 T1 2  – If h ( n ) is a low pass filter with the cut-off frequency being   2 0 u then what is the largest value of T 2 ? 32 UPSAMPLING AND DOWNSAMPLING • Sampling rate conversion – Sampling rate conversion can be directly performed in the digital domain – Downsampling (decimation) • Reduce the sampling frequency (less samples per unit time) – Upsampling (interpolation) • Increase the sampling frequency (more samples per unit time) 33 UPSAMPLING AND DOWNSAMPLING • Downsampling (decimation)

– Assume a digital signal,x ( n ) , is obtained by sampling an analog signal x a ( t ) at a sampling period T (or a sampling frequency 1/T).

x(n)  xa (nT ) – The signal can also be sampled with a sampling period MT (or a lower sampling frequency 1/(MT) )

xd (n)  xa (nMT)

– Relationship between x ( n ) and xd (n)

xd (n)  x(nM )

– x d ( n ) is the downsampled (or decimated) version of x(n) • can be obtained by picking one sample out of every M consecutive samples of x(n)  decimation. x(n)  [x(0), x(1), x(2), x(3), x(4), x(5), x(6), x(7), x(8),]

x (n)  [x(0), x(3), x(6), ,] M  3 d 34 UPSAMPLING AND DOWNSAMPLING • Downsampling (decimation): frequency domain – Assume all the sampling rates are higher than the Nyquist sampling rate – The DTFT of x(n) with a sampling period T 1         X ()  X a   T  T  – The DTFT of x d ( n ) with a sampling period MT 1    X d ()  X a   MT  MT 

1    X d ()  X   M  M  35 UPSAMPLING AND DOWNSAMPLING • Example – Consider the frequency response of an ideal low pass filter    1,     H()  2 2    0,      ,      2 2 • Determine h(n) • If we downsample h(n) with a factor of M = 2. Find the downsampled response in both the time and frequency domains. 36 UPSAMPLING AND DOWNSAMPLING • Upsampling (interpolation)

– Assume a digital signal, x ( n ) , is obtained by sampling an analog signal x a ( t ) at a sampling period T (or a sampling frequency 1/T).

x(n)  xa (nT ) – Upsampling by a factor of L • Inserting L-1 zeros between the original samples x(n)  [x(0), x(1), x(2), x(3),]

L  3 xu (n)  [x(0),0,0, x(1),0,0, x(2),0,0, x(3),]

T – The effective sampling period of the upsampled signal (sampling L rate: L ) T

xu (n)  xu (kL)  x(k) if n / L  k is an integer

xu (n)  0, if n / L  integer 37 UPSAMPLING AND DOWNSAMPLING • Upsampling (interpolation): frequency domain

– The DTFT of x u ( n ) with a sampling period T/L

   jn  jkL X u ()   xu (n)e   x(k)e  X (L) n k

• The DTFT of X (  ) is compressed in the frequency domain

38 UPSAMPLING AND DOWNSAMPLING • Example – A discrete pulse is given by x(n) = u(n)-u(n-4). Suppose we upsample x(n) by a factor of L = 3. Find the DTFT of the original and upsampled signals.