Lec 9: February 13th, 2018 Downsampling/Upsampling and ...

60
ESE 531: Digital Signal Processing Lec 9: February 13th, 2018 Downsampling/Upsampling and Practical Interpolation Penn ESE 531 Spring 2018 - Khanna

Transcript of Lec 9: February 13th, 2018 Downsampling/Upsampling and ...

ESE 531: Digital Signal Processing

Lec 9: February 13th, 2018 Downsampling/Upsampling and Practical

Interpolation

Penn ESE 531 Spring 2018 - Khanna

Lecture Outline

!  CT processing of DT signals !  Downsampling !  Upsampling

2 Penn ESE 531 Spring 2018 - Khanna

Continuous-Time Processing of Discrete-Time

!  Useful to interpret DT systems with no simple interpretation in discrete time

3 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

!  What is the time domain operation when Δ is non-integer? I.e Δ=1/2

4 Penn ESE 531 Spring 2018 - Khanna

δ[n]↔1

δ[n− nd ]↔ e− jωnd

Example: Non-integer Delay

!  What is the time domain operation when Δ is non-integer? I.e Δ=1/2

5 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

6 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

7 Penn ESE 531 Spring 2018 - Khanna

yc (t) = xc (t −T ⋅ Δ)

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

8 Penn ESE 531 Spring 2018 - Khanna

y[n]= yc (nT ) = xc (nT −T ⋅ Δ)

yc (t) = xc (t −T ⋅ Δ)

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

9 Penn ESE 531 Spring 2018 - Khanna

y[n]= yc (nT ) = xc (nT −T ⋅ Δ)

yc (t) = xc (t −T ⋅ Δ)xc (t) = x[k]

k∑ hr (t − kT )

= x[k]k∑ sinc t − kT

T

⎝⎜

⎠⎟

Reminder: Reconstruction in Time Domain

10 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

11 Penn ESE 531 Spring 2018 - Khanna

y[n]= yc (nT ) = xc (nT −T ⋅ Δ)

yc (t) = xc (t −T ⋅ Δ)xc (t) = x[k]

k∑ hr (t − kT )

= x[k]k∑ sinc t − kT

T

⎝⎜

⎠⎟

Reminder: Reconstruction in Time Domain

12 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

13 Penn ESE 531 Spring 2018 - Khanna

y[n]= yc (nT ) = xc (nT −T ⋅ Δ) xc (t) = x[k]k∑ sinc t − kT

T

⎝⎜

⎠⎟

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

14 Penn ESE 531 Spring 2018 - Khanna

y[n]= yc (nT ) = xc (nT −T ⋅ Δ) xc (t) = x[k]k∑ sinc t − kT

T

⎝⎜

⎠⎟

xc (nT −T ⋅ Δ) = x[k]k∑ sinc nT −T ⋅ Δ − kT

T

⎝⎜

⎠⎟= x[k]

k∑ sinc n−Δ− k( )

Example: Non-integer Delay

!  The block diagram is for interpretation/analysis only

15 Penn ESE 531 Spring 2018 - Khanna

y[n]= yc (nT ) = xc (nT −T ⋅ Δ) xc (t) = x[k]k∑ sinc t − kT

T

⎝⎜

⎠⎟

xc (nT −T ⋅ Δ) = x[k]k∑ sinc nT −T ⋅ Δ − kT

T

⎝⎜

⎠⎟= x[k]

k∑ sinc n−Δ− k( )

!  Delay system has an impulse response of a sinc with a continuous time delay

16 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

y[n]= x[k]k∑ sinc n−Δ− k( )

= x[n]∗sinc n−Δ( )

!  Delay system has an impulse response of a sinc with a continuous time delay

17 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

y[n]= x[k]k∑ sinc n−Δ− k( )

= x[n]∗sinc n−Δ( )

⇒ h[n]= sinc(n−Δ)

Example: Non-integer Delay

!  What is the time domain operation when Δ is non-integer? I.e Δ=1/2

18 Penn ESE 531 Spring 2018 - Khanna

δ[n]↔1

δ[n− nd ]↔ e− jωnd

!  My delay system has an impulse response of a sinc with a continuous time delay

19 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

!  My delay system has an impulse response of a sinc with a continuous time delay

20 Penn ESE 531 Spring 2018 - Khanna

Example: Non-integer Delay

Downsampling

!  Definition: Reducing the sampling rate by an integer number

21 Penn ESE 531 Spring 2018 - Khanna

Downsampling

!  Similar to C/D conversion "  Need to worry about aliasing "  Use anti-aliasing filter to mitigate effects

22 Penn ESE 531 Spring 2018 - Khanna

Downsampling

!  Similar to C/D conversion "  Need to worry about aliasing "  Use anti-aliasing filter to mitigate effects

!  If your discrete time signal is finely sampled almost like a CT signal "  Downsampling is just like sampling (C/D conversion)

23 Penn ESE 531 Spring 2018 - Khanna

Downsampling

24 Penn ESE 531 Spring 2018 - Khanna

Downsampling

25 Penn ESE 531 Spring 2018 - Khanna

!  Want to relate Xd(ejω) to X(ejω) not Xc(jΩ)

!  Separate sum into two sums—fine sum and coarse sum (i.e like counting minutes within hours)

Downsampling

26 Penn ESE 531 Spring 2018 - Khanna

!  k=rM+i "  i = 0, 1, …, M-1 "  r = -∞, ..., ∞

Downsampling

27 Penn ESE 531 Spring 2018 - Khanna

k = rM + i

Downsampling

28 Penn ESE 531 Spring 2018 - Khanna

Downsampling

29 Penn ESE 531 Spring 2018 - Khanna

Example

30 Penn ESE 531 Spring 2018 - Khanna

Example

31 Penn ESE 531 Spring 2018 - Khanna

Example

32 Penn ESE 531 Spring 2018 - Khanna

4π 2π

Example

33 Penn ESE 531 Spring 2018 - Khanna

Example

34 Penn ESE 531 Spring 2018 - Khanna

6π 2π

Example

35 Penn ESE 531 Spring 2018 - Khanna

6π 4π 2π

Example

36 Penn ESE 531 Spring 2018 - Khanna

Example

37 Penn ESE 531 Spring 2018 - Khanna

Upsampling

!  Much like D/C converter !  Upsample by A LOT # almost continuous

!  Intuition: "  Recall our D/C model: x[n] # xs(t)#xc(t) "  Approximate “xs(t)” by placing zeros between samples "  Convolve with a sinc to obtain “xc(t)” 

38 Penn ESE 531 Spring 2018 - Khanna

Upsampling

!  Definition: Increasing the sampling rate by an integer number

39 Penn ESE 531 Spring 2018 - Khanna

x[n]= xc (nT )xi[n]= xc (nT ')

Upsampling

40 Penn ESE 531 Spring 2018 - Khanna

xi[n]

Upsampling

41 Penn ESE 531 Spring 2018 - Khanna

Frequency Domain Interpretation

42 Penn ESE 531 Spring 2018 - Khanna

Frequency Domain Interpretation

43 Penn ESE 531 Spring 2018 - Khanna

Frequency Domain Interpretation

44 Penn ESE 531 Spring 2018 - Khanna

Frequency Domain Interpretation

45 Penn ESE 531 Spring 2018 - Khanna

Example

46 Penn ESE 531 Spring 2018 - Khanna

Example

47 Penn ESE 531 Spring 2018 - Khanna

Example

48 Penn ESE 531 Spring 2018 - Khanna

Example

49 Penn ESE 531 Spring 2018 - Khanna

Example

50 Penn ESE 531 Spring 2018 - Khanna

Example

51 Penn ESE 531 Spring 2018 - Khanna

Practical Interpolation

!  Interpolate with simple, practical filters "  Linear interpolation – samples between original samples

fall on a straight line connecting the samples "  Convolve with triangle instead of sinc

52 Penn ESE 531 Spring 2018 - Khanna

Practical Interpolation

!  Interpolate with simple, practical filters "  Linear interpolation – samples between original samples

fall on a straight line connecting the samples "  Convolve with triangle instead of sinc

53 Penn ESE 531 Spring 2018 - Khanna

Frequency Domain Interpretation

54 Penn ESE 531 Spring 2018 - Khanna

Linear Interpolation -- Frequency Domain

55 Penn ESE 531 Spring 2018 - Khanna

xi[n]= xe[n]∗hlin[n]

LPF approx

Linear Interpolation -- Frequency Domain

56 Penn ESE 531 Spring 2018 - Khanna

xi[n]= xe[n]∗hlin[n]

LPF approx

Linear Interpolation -- Frequency Domain

57 Penn ESE 531 Spring 2018 - Khanna

xi[n]= xe[n]∗hlin[n]

LPF approx

Linear Interpolation -- Frequency Domain

58 Penn ESE 531 Spring 2018 - Khanna

xi[n]= xe[n]∗hlin[n]

LPF approx

Big Ideas

!  CT processing of DT signals "  Allows for interpretation of DT systems

!  Downsampling "  Like a C/D converter

!  Upsampling "  Like a D/C converter

!  Practical Interpolation "  Linear interpolation "  Approximate sinc function with triangle

59 Penn ESE 531 Spring 2018 - Khanna

Admin

!  HW 4 due Friday

60 Penn ESE 531 Spring 2018 - Khanna