Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter...

41
Communication Systems, 5e Chapter 6: Sampling and pulse modulation A. Bruce Carlson Paul B. Crilly © 2010 The McGraw-Hill Companies

Transcript of Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter...

Page 1: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Communication Systems, 5e

Chapter 6: Sampling and pulse modulation

A. Bruce CarlsonPaul B. Crilly

© 2010 The McGraw-Hill Companies

Page 2: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Chapter 6: Sampling and pulse modulation

• Sampling theory and practice– Basis for digital signal processing

• Pulse-amplitude modulation• Pulse-time modulation

© 2010 The McGraw-Hill Companies

Page 3: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling Theory and Practice

• The spectrum of a sampled signal– The time domain and spectrum of a sampling waveform

(periodic square and pulse signals from Chap. 2)

• Minimum sampling frequency– Based on the maximum allowable aliasing error,

message BW, LPF characteristics, etc.– The Nyquist Rate

• Practical sampling versus ideal sampling• Signal reconstruction• PAM, PDM and PPM

Page 4: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling

• Multiplicative periodic sampling waveform tptxtxs

tpFtxFtxF s

spulse

ns T

trecttpTnttp

sspulsen ss

TfTtpT

nfT

tp

sinc11

sT2sT

sT 2sT

tppulse

p(t) sampling waveform

Page 5: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling Waveforms

• Unit level sampling

• Narrow rect function (mult in time, conv. in freq.)

• “Time limited” sampling function both frequency and time can be derived. (Cos pulse)

ffPtp pulsepulse 1

sss

TfTfPTtrecttp

sinc

ccpulsecpulse fffffPtftp 2cos

scsscs TffTTffTfP sincsinc

Page 6: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling Waveforms

• Impulse– Pulse as an impulse … FT is impulses spaced at 1/Ts

• Sampling signal spectrum

• Sampled Signal Spectrum (spectral replication!)

1 fPttp

n ssn ss Tnf

TTnf

TfPtp 11111

n sss T

nfT

txFtxF 11

n

sTnttp

Page 7: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling Waveforms

• Narrow rect– Pulse as a narrow rect function … “scaled impulses”

• Sampling signal spectrum

• Sampled Signal Spectrum (weighted spec. replicas!)

ffPtrecttp pulsepulse sinc

n ssn ss Tnff

Tf

Tnf

TtpF 1sincsinc11

n ssss T

nfTn

TtxFtxF 1sinc1

Page 8: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling Waveforms

• Wide rect– Pulse as a wide rect function … filling the sampling

period (a degenerate case, not practical but …)– If you draw this it is a constant “1”

• Sampling signal spectrum

• Sampled Signal Spectrum (degenerate case)

sspulses

pulse TfTfPTtrecttp

sinc

txFftxFtxF s

n ss

sss

n ss Tnfn

TTTfT

Tnf

TtpF 1sincsinc11

fTfTT

nfT

tpF ssn ss

sinc11

Page 9: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Convolution with Sampling Spectrum

• Spectral replication of F[x(t)]– If x(t) is not band limited, there will be an overlapping

of the adjacent impulses specrtrum– If sampling pulse not “appropriate” some of the replicas

will be smaller than others … periodically (narrow rect pulse example or the “pulses” spectral envelope)

tpFtxFtxF s

Page 10: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Replicas and Spectral Overlap

• As seen, the spectral replicas occur at a spacing of 1/Ts or fs, the sampling rate.

• To avoid any chance of overlap, the sampled signal must be band limited to:

• If you want to pick a sampling rate based on W

s

s

TfW

21

2

Wfs 2W

Ts

21

Page 11: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Nyquist Sampling Rate

• The Nyquist sampling rate defines the minimum sampling frequency for “distinct” replicated spectrum.– It also means you should be able to reconstruct the

original continuous time signal

• Aliasing is when spectral replicas overlap into adjacent spectral regions– occurs when there is an insufficient guard band– Remember the filter transition bands,

there will always be some aliasing, but are the aliased signal level sufficiently attenuated (at the stopband level)

Page 12: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Bandpass SamplingAdvanced Concept

• If a complex signal to be sampled is band limited

• What will happen after ideal (impulse) sampling?

• This also works for real signal with

22

ss

ss

ffnfXffn

2

sss

ffnfXfn

Page 13: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

(a) functional (b) waveforms (c) circuit

Switching sampler

tstxtxs

See LTSpice

Page 14: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Chopper Sampling

• Sampling function– The mathematical description

– The Fourier Series of repeated rects

n

Tnttrectts

2Tt2

Tfor,trectts

n

00n T1ffor,tfn2jexpcts

2

T

2T

0n dttfn2jexptsT1c

Page 15: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Chopper Sampling (2)

• Sampling function Fourier series coefficients

n

Tnttrectts

2

20

02

2

0n fn2jtfn2jexp

T1dttfn2jexp

T1c

0

0

0

0n fn2j

2fn2jexp

fn2j2fn2jexp

T1c

0

0

0

0

0n fnsinc

Tfnfnsin

T1

fn2j2fn2sin2j

T1c

Page 16: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Chopper Sampling (3)

• Sampling function Fourier series coefficients

n

Tnttrectts

0sinc fnT

cn

1n

0tfn2jtfn2j

n0 T1ffor,eeccts 00

1n

00n0 T1ffor,tfn2cosc2cts

1n

000n0 T1ffor,fnffnfcfcfS

n T

fforfnffnT

fS 1,sinc 000

Page 17: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Chopper Sampling (4)

• Time waveform with Fourier coefficients txtstxs

1n

000n0s T1ffor,fnfXfnfXcfXcfX

1n

00n0s T1ffor,tfn2costxc2txctx

• Spectral replicates at a spacing of fo=1/T– For unity gain, the chopper should have gain 1/co

Page 18: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Spectra for switching sampling

Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

(a) message (b) sampled message (c) sampled message 2sf W 2sf W

Replica envelope due to sampling pulse shape

Aliasing/overlapping due to signal bandwidth

Page 19: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Nyquist Sampling Rate

• Reduce the sampling rate to the minimum

WWfs min,

Wfs 2min,

ss T

f 1

WTs

21sT

W

21

Page 20: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Practical Filter Construction

W2fs

• For practical applications, we usually sample at greater than the Nyquist rate. This allows for a guard band around the signal of interest (SOI)

• If DSP systems are involved, many times we use 4x to 8x sampling, 2 to 4 times the Nyquist rate.

Page 21: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Filter Reminder

• Passband– Frequencies where signal is

meant to pass

• Stopband– Frequencies where some defined

level of attenuation is desired

• Transition-band– The transitions frequencies

between the passband and the stopband

PBBW

SBBW

passbandstopbandpracticals fff ,

Page 22: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Minimum Filter Construction

Wfff stopbandpassbands 2

• For practical applications, we usually sample at greater than the Nyquist rate. This allows for a guard band around the signal of interest (SOI)

• If ADC systems are involved, many times we use 4 x W sampling, 2 times the Nyquist rate or even higher (For the 1st order derivative approx to be valid may use – 5x to 8x)

sfWsf WWfs Wfs

stopbandpassbands fff Wf passband Wff sstopband

Page 23: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Aliasing by an ADC

• The desired baseband signal spectrum prior to sampling.

sF2Fs

sF2Fs

Page 24: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Aliasing (2)

• The frequency domain response of the perfect sampling function is:

• Convolve with the input signal spectrum …

sF sF2 sF3 sFsF3 sF2

kn T

k2jjT2TnjexpjP

0

Page 25: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Aliasing (3)

• The frequency bands that “could” be aliased when sampled are

sF sF2 sF3 sFsF3 sF2

0

k

Tk

p jkjGT1

Tk2jjG

T1jG

Page 26: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Aliasing Example (1)

• Predict the aliasing result for

sF2Fs

2F3 s

sF2 sF2Fs

Page 27: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Aliasing Example (2)

Original spectrum

sF2Fs

2F3 s

sF2 sF2Fs

2Fs

2Fs

2F

f2F3 ss

2F

f2F ss

2F3

f2F ss

2F5f

2F3 ss

2Fs

2Fs 0

Aliased Baseband Spectrum

Page 28: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Ideal Sampling

• Remembering delta function approximations from Chapter 2

nn0

TntTnttrect1ts lim

txtstx

nnTntTnxTnttxtx

sXfSfX

n T1nfX

T1fX

Page 29: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling in Matlab

• Using the 16x interpolated message from before …• A sampling rate of fs/4 can be used

0 1 2 3 4 5 6

x 104

-150

-100

-50

0Sequenctial FFTs of the message

Frequency (Hz)

Pow

er (d

B)

0 2 4 6 8 10 12 14

x 104

-160

-140

-120

-100

-80

-60

-40

-20Sequenctial FFTs of the Sampled Waveform

Frequency (Hz)

Pow

er (d

B)

Question, what if I wanted to shift a baseband signal to a higher frequency …

Page 30: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Sampling in Matlab

0 1 2 3 4 5 6

x 104

-150

-100

-50

0Sequenctial FFTs of the message

Frequency (Hz)

Pow

er (d

B)

0 2 4 6 8 10 12 14

x 104

-160

-140

-120

-100

-80

-60

-40

-20Sequenctial FFTs of the Sampled Waveform

Frequency (Hz)

Pow

er (d

B)

… sample and BPF ?!

Question, what if I wanted to shift a baseband signal to a higher frequency …

This is called interpolation-filtering (ECE 6560)

Page 31: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Subsampling Theorem

• Also called bandpass sampling …• What would happen if a had a sampling waveform that

was an integer fraction of the carrier? (i.e. fs=fc/4)– Spectral comb function goes to infinite at nfs !!– Convolve in the frequency domain with a complex

narrowband bandpass signal …..

– Where do the replicas appear … at all the combs, even zero– Apply a low pass filter … and you have downconverted the

complex RF to Baseband! (who needs an RF mixers !)– There are numerous commercial ADCs that allow this to

occur.

Page 32: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Bipolar Chopper: Example 6-1Square wave mixing!

• Using the Fourier Series of a Square Wave

nTnt

Ttrect

Ttrectts2

2

tf52cos54tf32cos

34tf2cos4ts 000

• Generating odd sample rate spectrum

00

00

00

f5ff5f52

f3ff3f32

ffff2fS

Page 33: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Bipolar Chopper (2)

• Using the Fourier Transform

n T

nfT

TfTTfTtsF 11sinc2

sinc2

2

nTnt

Ttrect

Ttrectts2

2

n T

nfTfTftsF 1sinc2

sinc

n TnffntsF 1

2sinc

• The odd harmonics of the period are scaled by sinc(n/2),all others are zero … now convolve with the signal!

Page 34: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Bipolar Chopper (3)

• Using the Fourier Transform

Tf

Tf

TftsF 5

25sinc3

23sinc1

21sinc

Tf

Tf

TftsF 5

523

3212

t

Tt

Tt

Tts 52cos

5432cos

3412cos4

• Same result as Fourier Series for a square wave!• math should work both ways …

Page 35: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Bipolar Chopper Application

• Chopper-Stabilized Amplifier– Chop the input signal– Filter and apply gain to bandpass signal centered at fs

– Chop to return the signal to DC– Filter to keep just the low pass signal

• A technique used for the first low frequency analog MOSFET amplifiers due to 1/f noise.

Page 36: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Reconstruction

• Reconstruction of a discrete time waveform into a continuous time waveform needs an appropriate filter!

• Perfect Reconstruction Filter– Derived from rect (perfect passband) in the frequency domain– The convolution of the samples with a sinc function

delayttBBKth 2sinc2

delaytf2jxpeB2frectKfH

Ttt

nTtnTxtx delay

nsincˆ

thtxtx̂ s

BKLet 21

Page 37: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Reconstruction (2)

• Perfect Reconstruction Filter– Derived from a rect in the frequency domain– The convolution of the samples with a sinc function

Ttt

sincnTtnTxtx̂ delay

n

TtnTt

sincnTxtx̂ delay

n

0delaytLet

nTtnTxtx

nsincˆ

-5 -4 -3 -2 -1 0 1 2 3 4 5

-0.2

0

0.2

0.4

0.6

0.8

1

Page 38: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Reconstruction (3)

• Perfect Reconstruction Filter

nTtnTxtx

nsincˆ

-80 -60 -40 -20 0 20 40 60 80-0.4

-0.2

0

0.2

0.4

0.6

0.8

1

-80 -60 -40 -20 0 20 40 60 80-0.2

0

0.2

0.4

0.6

0.8

1

1.2

Page 39: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Alternate Functions Used for Reconstruction

• Zero Order Hold– Should be followed by a LPF

• First Order Hold (Triangle)

TnTtectrnTxtx̂

nrect

TnTttrinTxtx̂

nrect

Page 40: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Signal reconstruction from sample (a) ZOH

Figure 6.1-8

ZOH

-80 -60 -40 -20 0 20 40 60 800

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

-80 -60 -40 -20 0 20 40 60 800

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

sTnf 1

Page 41: Chapter 6: Sampling and pulse modulation A. Bruce Carlson ...bazuinb/ECE4600/Ch06_01.pdf · Chapter 6: Sampling and pulse modulation • Sampling theory and practice – Basis for

Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Signal reconstruction from sample (b) FOH

Figure 6.1-8

FOH

-80 -60 -40 -20 0 20 40 60 800

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

-80 -60 -40 -20 0 20 40 60 800

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1