ekt343-principles of communication engineering 1

54
EKT343-Principles of Communication Engineering 1

Upload: stella-edwards

Post on 21-Dec-2015

236 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: EKT343-Principles of Communication Engineering 1

EKT343-Principles of Communication Engineering

1

Page 2: EKT343-Principles of Communication Engineering 1

Digital Pulse Modulation

EKT343-Principles of Communication Engineering

2

Page 3: EKT343-Principles of Communication Engineering 1

Pulse Modulation

• Analog pulse modulation: Sampling, i.e., information is transmitted only at discrete time instants. e.g. PAM, PPM and PDM

• Digital pulse modulation: Sampling and quantization, i.e., information is discretized in both time and amplitude. e.g. PCM

EKT343-Principles of Communication Engineering

3

Page 4: EKT343-Principles of Communication Engineering 1

Analog input signal

Sample at discrete time instants

Analog pulse modulation, PAM signal

Digital pulse modulation, PCM code

EKT343-Principles of Communication Engineering

4

Page 5: EKT343-Principles of Communication Engineering 1

PCM- PULSE CODE MODULATION

• DEFINITION: Pulse code modulation (PCM) is essentially analog-to-digital (A/D) conversion where the information contained in the instantaneous samples of an analog signal is represented by digital words in a serial bit stream.

EKT343-Principles of Communication Engineering

5

Page 6: EKT343-Principles of Communication Engineering 1

PCM Block Diagram

EKT343-Principles of Communication Engineering

6

• Most common form of analog to digital modulation

• Four step process1. Signal is sampled using PAM

(Sample)2. Integer values assigned to signal

(PAM)3. Values converted to binary

(Quantized)4. Signal is digitally encoded for

transmission (Encoded)

Page 7: EKT343-Principles of Communication Engineering 1

EKT343-Principles of Communication Engineering

7

4 Steps Process

Page 8: EKT343-Principles of Communication Engineering 1

PCM-Sampling, Quantizing, and Encoding The PCM signal is generated by carrying out three basic

operations: 1. Sampling 2. Quantizing3. Encoding

Sampling operation generates a flat-top PAM signal. Quantizing operation approximates the analog values by

using a finite number of levels, L. PCM signal is obtained from the quantized PAM signal by

encoding each quantized sample value into a digital word.

EKT343-Principles of Communication Engineering

8

Page 9: EKT343-Principles of Communication Engineering 1

EKT343-Principles of Communication Engineering

9Eeng 360 9

Sampling Makes the signal discrete in time. If the analog input has a bandwidth of

B Hz, then the minimum sample frequency such that the signal can be reconstructed without distortion, fs >= 2B

Quantization Makes the signal discrete in

amplitude. Round off to one of q discrete levels.

Encode Maps the quantized values to digital

words that are n bits long.

ADC

Sample

Quantize

AnalogInputSignal

Encode

111110101100011010001000

Digital OutputSignal

111 111 001 010 011 111 011

Page 10: EKT343-Principles of Communication Engineering 1

Definition of Quantization

• A process of converting an infinite number of possibilities to a finite number of conditions (rounding off the amplitudes of flat-top samples to a manageable number of levels).

• In other words, quantization is a process of assigning the analog signal samples to a pre-determined discrete levels. The number of quantization levels, L determine the number of bits per sample, n.

EKT343-Principles of Communication Engineering

10

nL 2 Ln 2log

Page 11: EKT343-Principles of Communication Engineering 1

Quantization The output of a sampler is still continuous in amplitude.

– Each sample can take on any amplitude value e.g. 3.752 V, 0.001 V, etc.

– The number of possible values is infinite. To transmit as a digital signal we must restrict the number of

possible values. Quantization is the process of “rounding off” a sample

according to some rule.– E.g. suppose we must round to the nearest discrete value,

then: 3.752 --> 3.8 0.001 --> 0

EKT343-Principles of Communication Engineering

11

Page 12: EKT343-Principles of Communication Engineering 1

Quantization Example

Analogue signal

Sampling TIMING

Quantization levels. Quantized to 5-levels

Quantization levelsQuantized 10-levels

EKT343-Principles of Communication Engineering

12

Page 13: EKT343-Principles of Communication Engineering 1

13

1. Uniform type : The levels of the quantized amplitude are uniformly spaced. 2. Non-uniform type : The levels are not uniform.

Page 14: EKT343-Principles of Communication Engineering 1

Types of Uniform Quantization

14

Midtread: Origin lies in the middle of a tread of the staircase like

graph in (a), utilized for odd levels

Midrise: Origin lies in the middle of a rising part of the staircase like graph

(b), utilized for even levels

Page 15: EKT343-Principles of Communication Engineering 1

EKT343-Principles of Communication Engineering

15Eeng 360 15

Most ADC’s use uniform quantizers.

The quantization levels of a uniform quantizer are equally spaced apart.

Uniform quantizers are optimal when the input distribution is uniform. When all values within the Dynamic Range of the quantizer are equally likely.

Input sample X

Example: Uniform n =3 bit quantizer

L=8 and XQ = {1,3,5,7}

2 4 6 8

1

5

3

Output sampleXQ

-2-4-6-8

Dynamic Range:

(-8, 8)

7

-7

-3

-5

-1

Quantization Characteristic

Page 16: EKT343-Principles of Communication Engineering 1

Dynamic Range (DR)• Largest possible magnitude/smallest possible magnitude.

• Where • DR = absolute value of dynamic range• Vmax = the maximum voltage magnitude• Vmin = the quantum value (resolution)• n = number of bits in the PCM code

resolution

V

V

VDR max

min

max

12 nDR

EKT343-Principles of Communication Engineering 16

)log(20)( DRdBDR

ndBDR 6)( for n > 4

Page 17: EKT343-Principles of Communication Engineering 1

Coding Efficiency

• A numerical indication of how efficiently a PCM code is utilized.

• The ratio of the minimum number of bits required to achieve a certain dynamic range to the actual number of PCM bits used.

EKT343-Principles of Communication Engineering

17

Coding Efficiency = Minimum number of bits x 100Actual number of bits

Page 18: EKT343-Principles of Communication Engineering 1

Example 1

1. Calculate the dynamic range for a linear PCM system using 16-bit quantizing.

2. Calculate the number of bits in PCM code if the DR = 192.6 dB. Determine the coding efficiency in this case.

EKT343-Principles of Communication Engineering

18

Page 19: EKT343-Principles of Communication Engineering 1

The quantization interval @ quantum = the magnitude difference between adjacent steps,

The resolution = the magnitude of a quantum = the voltage of the minimum step size.

The quantization error = the quantization noise

= ½ quantum = (orig. sample voltage – quantize level)

The quantization range: is the range of input voltages that will be converted to a particular code.

EKT343-Principles of Communication Engineering

19

Cont’d…

v

Page 20: EKT343-Principles of Communication Engineering 1

• A difference between the exact value of the analog signal & the nearest quantization level.

• Quantization error is a round-off error in the transmitted signal that is reproduced when the code is converted back to analog in the receiver.

20

Quantization Error

Page 21: EKT343-Principles of Communication Engineering 1

Quantization Noise The process of quantization can be interpreted as an additive

noise process.

• The signal to quantization noise ratio (SNR)Q=S/N is given as:

EKT343-Principles of Communication Engineering

21

SignalX

Quantized Signal, XQ

Quantization Noise, nQ

Average Power{ }( )

Average Power{ }QQ

XSNR

n

Page 22: EKT343-Principles of Communication Engineering 1

Signal to Quantization Noise Ratio (SQR)

• The worst possible signal voltage-to-quantization noise voltage ratio (SQR) occurs when the input signal occurs when input signal is at its minimum amplitude. SQR is directly proportional to resolution.

• The worst-case voltage SQR

EKT343-Principles of Communication Engineering

22

eQ

resolutionSQR (min)

Page 23: EKT343-Principles of Communication Engineering 1

Cont'd

• SQR for a maximum input signal

• The signal power-to-quantizing noise power ratio

eQ

VSQR max

(max)

EKT343-Principles of Communication Engineering 23

q

vv

R

SQR

qq

Rv

dB

log208.10log10)(

log10

power noiseon quantizati average

power signal averagelog10

12

2

12

)(

22

2

R =resistance (ohm)

v = rms signal voltage

q = quantization interval

Qe = quantization error

Page 24: EKT343-Principles of Communication Engineering 1

Example 2

1. Calculate the SQR (dB) if the input signal = 2 Vrms and the quantization noise magnitudes = 0.02 V.

2. Determine the voltage of the input signals if the SQR = 36.82 dB and q =0.2 V.

EKT343-Principles of Communication Engineering

24

Page 25: EKT343-Principles of Communication Engineering 1

Nonuniform QuantizationMany signals such as speech have a nonuniform distribution.

The amplitude is more likely to be close to zero than to be at higher levels.

Nonuniform quantizers have unequally spaced levels The spacing can be chosen to optimize the SNR for a particular type of signal.

EKT343-Principles of Communication Engineering

25

2 4 6 8

2

4

6

-2

-4

-6

Input sampleX

Output sampleXQ

-2-4-6-8

Example: Nonuniform 3 bit quantizer

Page 26: EKT343-Principles of Communication Engineering 1

• Nonuniform quantizers are difficult to make and expensive.• An alternative is to first pass the speech signal through a

nonlinearity before quantizing with a uniform quantizer.• The nonlinearity causes the signal amplitude to be

Compressed.▫ The input to the quantizer will have a more uniform distribution.

• At the receiver, the signal is Expanded by an inverse to the nonlinearity.

• The process of compressing and expanding is called Companding.

EKT343-Principles of Communication Engineering

26

Page 27: EKT343-Principles of Communication Engineering 1

Cont'd

EKT343-Principles of Communication Engineering

27

• The process of compressing and then expanding.

• The higher amplitude analog signals are compressed

prior to transmission and then expanded in receiver.

• Improving the DR of a communication system.

Page 28: EKT343-Principles of Communication Engineering 1

Companding Functions

EKT343-Principles of Communication Engineering

28

Page 29: EKT343-Principles of Communication Engineering 1

Method of Companding For the compression, two laws are adopted: the -law in US and Japan

and the A-law in Europe.

-law

A-law

The typical values used in practice are: =255 and A=87.6. After quantization the different quantized levels have to be represented in

a form suitable for transmission. This is done via an encoding process.

)1ln(

)1ln(maxmax

VV

out

inVV

11

ln1

)ln(1

10

ln1

max

maxmax

max

max

V

V

AA

AAV

V

A

AV

VinV

V

inVV

out in

in

EKT343-Principles of Communication Engineering 29

Vmax= Max uncompressed analog input voltage

Vin= amplitude of the input signal at a particular of instant time

Vout= compressed output amplitude

A, = parameter define the amount of compression

Page 30: EKT343-Principles of Communication Engineering 1

Cont’d...

EKT343-Principles of Communication Engineering

30

μ-law A-law

Page 31: EKT343-Principles of Communication Engineering 1

Example 3

• A companding system with µ = 255 used to compand from 0V to 15 V sinusoid signal. Draw the characteristic of the typical system.

EKT343-Principles of Communication Engineering

31

Page 32: EKT343-Principles of Communication Engineering 1

Example 4 • A companding system with µ = 200 is used to compand -4V to

4V signal. Calculate the system output voltage for Vin = -4, -2, 0, 2 and 4V.

Equation:

EKT343-Principles of Communication Engineering

32

Vin (V) -4 -2 0 2 4

Vout (V) -4 -3.48 0 3.48 4

)1ln(

)1ln(maxmax

VV

out

inVV

Page 33: EKT343-Principles of Communication Engineering 1

Plot the compression characteristic that will handle input voltage in the given range and draw an 8 level non-uniform quantizer characteristic that corresponds to the given µ.

EKT343-Principles of Communication Engineering

33

Page 34: EKT343-Principles of Communication Engineering 1

SNR Performance of Compander

EKT343-Principles of Communication Engineering

34

• The output SNR is a function of input signal level for uniform quantizing.

• But it is relatively insensitive for input level for a compander.

• α = 4.77 - 20 Log ( V/xrms) for Uniform Quantizer V is the peak signal level and xrms is the rms value

• α = 4.77 - 20 log[Ln(1 + μ)] for μ-law companding• α = 4.77 - 20 log[1 + Ln A] for A-law companding

Page 35: EKT343-Principles of Communication Engineering 1

EKT343-Principles of Communication Engineering

35Eeng 360 35

The output of the quantizer is one of L possible signal levels. If we want to use a binary transmission system, then we need to map

each quantized sample into an n bit binary word.

Encoding is the process of representing each quantized sample by n bit code word. The mapping is one-to-one so there is no distortion introduced by

encoding.

nL 2 Ln 2log

Page 36: EKT343-Principles of Communication Engineering 1

PCM encoding example

Chart 1. Quantization and digitalization of a signal. Signal is quantized in 11 time points & 8 quantization segments.

Chart 2. Process of restoring a signal.PCM encoded signal in binary form:101 111 110 001 010 100 111 100 011 010 101Total of 33 bits were used to encode a signal

Table: Quantization levels with belonging code words

Levels are encoded using this table

L=8

EKT343-Principles of Communication Engineering

36

Page 37: EKT343-Principles of Communication Engineering 1

PCM Example

EKT343-Principles of Communication Engineering

37

Page 38: EKT343-Principles of Communication Engineering 1

Nonlinear Encoding

• Quantization levels not evenly spaced

• Same concept as non-uniform quantization

• Reduces overall signal distortion

• Can also be done by companding

EKT343-Principles of Communication Engineering

38

Page 39: EKT343-Principles of Communication Engineering 1

PCM Line Speed• The data rate at which serial PCM bits are clocked out

of the PCM encoder onto the transmission line.

• Where• Line speed = the transmission rate in bits per

second• Sample/second = sample rate, fs• Bits/sample = no of bits in the compressed PCM

code

• Line speed also known as bit rate

sample

bitsX

second

samples speed line

EKT343-Principles of Communication Engineering 39

Page 40: EKT343-Principles of Communication Engineering 1

Example 5

• For a single PCM system with a sample rate fs = 6000 samples per second and a 7 bits compressed PCM code, calculate the line speed.

EKT343-Principles of Communication Engineering

40

Page 41: EKT343-Principles of Communication Engineering 1

Channel Bandwidth

• The channel bandwidth, B required to transmit a pulse is given by

• Where• κ = a constant with a value between 1 to 2• n = number of bits• W = signal bandwidth

• Channel BW = transmission BW

EKT343-Principles of Communication Engineering 41

nWB

Page 42: EKT343-Principles of Communication Engineering 1

Bandwidth of PCM Signals The spectrum of the PCM signal is not

directly related to the spectrum of the input signal.

The bandwidth of (serial) binary PCM waveforms depends on the bit rate R and the waveform pulse shape used to represent the data.

The Bit Rate R is

R=nfs

Where n is the number of bits in the PCM word (M=2n) and fs is the sampling rate.

EKT343-Principles of Communication Engineering

42

Page 43: EKT343-Principles of Communication Engineering 1

For no aliasing case (fs≥ 2B), the MINIMUM Bandwidth of PCM Bpcm(Min) is:

Bpcm(Min) = R/2 = nfs//2

The Minimum Bandwidth of nfs//2 is obtained only when sin(x)/x pulse is used to generate the PCM waveform.

For PCM waveform generated by rectangular pulses, the First-null Bandwidth is:

Bpcm = R = nfs

EKT343-Principles of Communication Engineering

43

Page 44: EKT343-Principles of Communication Engineering 1

Example 6

A signal with a bandwidth of 4.2 MHz is

transmitted using binary PCM. The number of

representation levels is 512. Calculate

(a)The code word length

(b)The bit rate

(c)The transmission bandwidth, assuming that, κ = 2

(d)Find the SQR in dB for the signal given that peak

signal voltage is 5Vp

EKT343-Principles of Communication Engineering

44

Page 45: EKT343-Principles of Communication Engineering 1

PCM transmitter/receiver

EKT343-Principles of Communication Engineering

45

LPFBW=B

Sampler& Hold

QuantizerNo. of levels=M

Encoder

Analogsignal

BandlimitedAnalog signal

Flat-topPAM signal

QuantizedPAM signal

PCMsignal

Channel, Telephone lines with regenerative repeater

DecoderPCMsignal

QuantizedPAM signal

ReconstructionLPF

AnalogSignaloutput

Page 46: EKT343-Principles of Communication Engineering 1

Noise in PCM Systems Two main effects produce the noise or distortion in the PCM output:

– Quantizing noise that is caused by the M-step quantizer at the PCM transmitter. – Bit errors in the recovered PCM signal, caused by channel noise and improper

filtering.

• If the input analog signal is band limited and sampled fast enough so that the aliasing noise on the recovered signal is negligible, the ratio of the recovered analog peak signal power to the total average noise power is:

EKT343-Principles of Communication Engineering

46

Page 47: EKT343-Principles of Communication Engineering 1

Cont’d

• The ratio of the average signal power to the average noise power is

– M is the number of quantized levels used in the PCM system.

– Pe is the probability of bit error in the recovered binary PCM signal at the

receiver DAC before it is converted back into an analog signal.

EKT343-Principles of Communication Engineering

47

Page 48: EKT343-Principles of Communication Engineering 1

Effects of Quantizing Noise• If Pe is negligible, there are no bit errors resulting from channel noise and no ISI, the Peak SNR

resulting from only quantizing error is:

• The Average SNR due to quantizing errors is:

• Above equations can be expresses in decibels as,

EKT343-Principles of Communication Engineering

48

Where, M = 2n

α = 4.77 for peak SNR

α = 0 for average SNR

Page 49: EKT343-Principles of Communication Engineering 1

Virtues & Limitation of PCMThe most important advantages of

PCM are:– Robustness to channel noise and

interference.– Efficient regeneration of the coded

signal along the channel path.– Efficient exchange between BT and SNR.– Uniform format for different kind of

base-band signals.– Flexible TDM.

EKT343-Principles of Communication Engineering

49

Page 50: EKT343-Principles of Communication Engineering 1

Cont’d…– Secure communication through the use of

special modulation schemes of encryption.

– These advantages are obtained at the cost of more complexity and increased BT.

– With cost-effective implementations, the cost issue no longer a problem of concern.

– With the availability of wide-band communication channels and the use of sophisticated data compression techniques, the large bandwidth is not a serious problem.

EKT343-Principles of Communication Engineering

50

Page 51: EKT343-Principles of Communication Engineering 1

Application: PCM in Wired Telephony

• Voice circuit bandwidth is 3400 Hz.

• Sampling rate is 8 KHz (samples are 125 s apart) above Nyquist rate,

6.8KHz to avoid unrealizable filters required for signal reconstruction.

• Each sample is quantized to one of 256 levels (n=8).

• The 8-bit words are transmitted serially (one bit at a time) over a digital

transmission channel. The bit rate is 8x8,000 = 64 Kb/s.

• The bits are regenerated at digital repeaters.The received words are

decoded back to quantized samples, and filtered to reconstruct the analog

signal.

51

Page 52: EKT343-Principles of Communication Engineering 1

PCM in Compact Disk (CD)• High definition Audio signal bandwidth is band

limited to 15kHz. • Although the Nyquist rate is only 30kHz, the

actual sampling of 44.1kHz is used to avoid unrealizable filters required for signal construction

• The signal is quantized into a rather large number of levels, L=65,536 (n=16) to reduce quantization noise

EKT343-Principles of Communication Engineering

52

Page 53: EKT343-Principles of Communication Engineering 1

Exercise 1

• A compact disc(CD) records audio signals digitally by using PCM. Assume the audio signal bandwidth to be 15 kHz.– (a) What is the Nyquist rate?– (b) If the Nyquist samples are quantized into L= 65,

536 levels and then binary coded, determine the number of binary digits required to encode the sample.

– (c) Determine the number of binary digits per second(bits/s) required to encode the audio signals.

EKT343-Principles of Communication Engineering

53

Page 54: EKT343-Principles of Communication Engineering 1

Exercise 2

• This problem addresses the digitization of a television signal using pulse code modulation. The signal bandwidth is 4.5 MHz. Specifications of the modulator include the following:– Sampling : 15% in excess of Nyquist rate– Quantization: uniform with 1024 levels– Encoding : binary

• Determine (a) sampling rate and (b) minimum permissible bit rate

EKT343-Principles of Communication Engineering

54