Unit1-Chapter1 - CS-2-uddar Sir
Unit1-Chapter1 - CS-2-uddar Sir
1
Message
Signal
2
The purpose of a communication system is to transport an information-
bearing signal from a source to a user destination via a communication
channel.
Communication
System
Analog CS Digital CS
1. The impact of the computer, not only as a source of data but also as a tool
for communications, and the demands other digital services such as telex and
facsimile.
Indeed, the trend toward digital communications (and away from analog
communications) will continue, so much so that the second half of the
twentieth century will be recorded in history as the era of digital
communications.
A source of information generates a message
Ex: human voice
television picture
teletype data
atmospheric temperature and pressure.
Since the source encoder mapping is one- to-one, the source decoder
simply performs the inverse mapping and thereby delivers to the user
destination a reproduction of the original digital source output.
The primary benefit thus gained from the application of source coding is a
reduced bandwidth requement.
In channel coding, the objective is for the encoder to map the incoming
digital signal into a channel input and for the decoder to map the channel
output into an output digital signal in such a way that the effect of channel
noise is minimized.
That is, the combined role of the channel encoder and decoder is to provide
reliable communication over a noisy channel.
In the latter case, naturally, the source encoding is performed first, followed
by channel encoding in the transmitter as illustrated in Fig.
• In PCM method of signal coding, the message signal is sampled and the
amplitude of each sample is rounded off (approximated) to the nearest
one of a finite set of discrete levels, so that both time and amplitude are
represented in discrete form.
• This allows the message to be transmitted by means of a digital (coded)
waveform, thereby distinguishing pulse-code modulation from all analog
modulation techniques.
• With PCM, the continuously-varying analog signals are converted into
pulses of fixed amplitude and fixed duration.
• PCM is a binary system where a pulse or no pulse within a prescribed time
slot represents either a logic 1 or logic 0 condition.
• Importantly, PCM is a digital pulse modulation technique also known as
time domain waveform coding technique.
• It is the only digitally encoded modulation technique used for baseband
digital transmission.
Where PCM is used ?
Analog Digital
Signal Signal
Sampling Quantizing Encoding
--------------------------------------------- OR
--------------------------------------------------
The LPF is included to prevent aliasing of the message signal.
The quantizing and encoding operations are usually performed in the same
circuit, which is called an analog-to-digital converter.
Quantized
Signal
Digital
Signal
In the sampling operation, only sample values of the analog signal at uniformly
spaced discrete instants of time are retained.
The code word consists of four binary digits (bits), with the last bit assigned the
role of a sign bit that signifies whether the sample value is positive or negative.
The remaining three bits are chosen to provide a numerical representation for
the absolute value of a sample in accordance with Table.
Binary representation of quantized levels
As a result of sampling and quantizing operations, errors are introduced into
the digital signal.
The errors due to sampling and quantizing can be made so small that the
difference between the analog signal and its digital reconstruction is not
discernible by a human observer.
Sampling:
The sampling operation is performed in accordance with the sampling theorem. Specifically,
we may state the sampling theorem for band-limited signals of finite energy in two equivalent
parts.
1. A band-limited signal of finite energy, which has no frequency components higher than W
hertz, is completely described by specifying the values of the signal at instants of time
separated by seconds.
2. A band-limited signal of finite energy, which has no frequency components higher than W
hertz, may be completely recovered from a knowledge of its samples taken at the rate of 2W
per second.
Part 1 of the sampling theorem is exploited in the transmitter; part 2 of the theorem is
exploited in the receiver. The sampling rate 2W is called the Nyquist rate, and its reciprocal is
called the Nyquist interval.
The sampling process is usually described in the time domain. It is an
operation that is basic to digital signal processing and digital
communications.
Fig. (b)
Let gδ(t) denote the signal obtained by individually weighting the elements of
a periodic sequence of Dirac delta functions spaced Ts seconds apart by the
sequence of numbers { g(nTs) }, as shown by (see Fig. b)
We refer to gδ(t) as the ideal sampled signal. The term δ(t - nTs) represents a
delta function positioned at time t = nTs.
From the definition of the delta function, we recall that such an idealized
function has unit area.
We may therefore view the multiplying factor g(nTs) in the above Eq. as a
“mass” assigned to the delta function δ(t - nTs).
By applying, and using the fact that a delta function is an even function of
time, we get the result:
where G(f) is the Fourier transform of the original signal g(t), and f s is the
sampling rate. Above Eq. states that the process of uniformly sampling a
continuous-time signal of finite energy results in a periodic spectrum with a
period equal to the sampling rate.
Problem 1
Find the nyquist rate and nyquist interval for following signals.
Solution:
Solution Contd. :
Types of Sampling/PAM
Types of Sampling/PAM
Fig. (a)
Fig. (b)
Fig. (c)
Figure: Flat-top Samples
Quantizing/Quantization:
(1) The peak-to-peak range of input sample values is subdivided into a finite
set of decision levels or decision thresholds that are aligned with the "risers"
of the staircase
(2) The output is assigned a discrete value selected from a finite set of
representation levels or reconstruction values that are aligned with the
"treads" of the staircase.
• In the use of PCM for the transmission of speech signals, the quantizer
has to accommodate input signals with widely varying power levels.
• For example, the range of voltage amplitude levels covered by normal
speech signals, from the peaks of loud speech levels to the lows of weak
speech levels, is on the order of 1000 to 1.
• So it is highly desirable that signal-to-quantization noise ratio should
remain essentially constant for a wide range of input signal levels.
• This requirement is met by a non-uniform quantizer, as explained with
the help of following example.
Example: Consider a 4 bit PCM coded system. The normalized peak-to-
peak input voltage range is ±16 V for a uniform quantizer. Justify that
non-uniform quantization would have yielded better results.
Solution:
For given 4 bit PCM coded system, number of levels, M = 24 = 16 levels
For input signal amplitude level of 2 V (say), Qemax = 1 V, i.e. 50% of input
voltage 59
For input signal amplitude level of 3 V (say), Qemax = 1 V, i.e. 33% of input
voltage
For input signal amplitude level of 15 V (say), Qemax = 1 V, i.e. 6.7% of input
voltage
For input signal amplitude level of 16 V (say), Qemax = 1 V, i.e. 6.3% of input
voltage
That means, for low-signal amplitude levels, the maximum quantization error
is relatively much higher than that for high-signal amplitude levels. This is
because of uniform quantization.
Advantages of Nonuniform Quantization:
Transmitter Receiver
Input Output
Uniform
Compressor Expander
Quantizer
65
• The μ = 0 corresponds to uniform quantization.
• For a relatively constant signal-to-quantization ratio and a 40 dB
dynamic range, the value of μ ≥ 100 is required.
• The practical value of μ is approximately 255.
Example: An analog information signal at the input to a µ-law compressor (μ
= 255) is positive, with its voltage level one-half the maximum value. What
proportion of the maximum output voltage level would be produced at the
output of compressor?
• Thus, it is observed that 87.6% of the maximum output voltage level would be
produced at the output of µ-law compressor having μ = 255.
• Figure shows the comparison of S/N versus signal level for both cases – without
companding and with µ-law companding.
• It is observed that the signal-to-noise (S/N) ratio of PCM system remains constant
with companding
A-law companding:
Thus, it is observed that 87.6% of the maximum output voltage level would
be produced at the output of A-law compressor having A = 100, which is
exactly same as that in µ-law compressor having μ = 255.
Encoding:
Any plan that represents each of this discrete set of values as a particular
arrangement of discrete events is called a code. One of the discrete events in
a code is called a code element or symbol.
Return-to-zero implies that the pulse shape used to represent the bit
always returns to the 0 volts or the neutral level before the end of the bit.
Nonreturn-to-zero indicates that the pulse does not necessarily return to
the neutral level before the end of the bit.
1. Unipolar Nonreturn-to-Zero (NRZ) Signaling:
This line code uses three amplitude levels as indicated in Figure. Specifically,
positive and negative pulses of equal amplitude (i.e., +A and -A) are used
alternately for symbol 1, with each pulse having a half-symbol width. No
pulse is always used for symbol 0.
This line code is also called alternate mark inversion (AMI) signaling.
5. Split-Phase (Manchester Code):
For a uniform quantizer, the quantization error Q e or ε will have its sample values
bounded by
With the mean of the quantization error being zero, its variance is the same as
the mean-square value
SQNR (Linear Quantization)
𝑆 𝑁𝑜𝑟𝑚𝑎𝑙𝑖𝑧𝑒𝑑 𝑠𝑖𝑔𝑛𝑎𝑙𝑝𝑜𝑤𝑒𝑟
=𝑆𝑁𝑅 𝑂 =
𝑁 𝑁𝑜𝑟𝑚𝑎𝑙𝑖𝑧𝑒𝑑 𝑛𝑜𝑖𝑠𝑒 𝑝𝑜𝑤𝑒𝑟
Let P denote the average/normalized power of the message signal m(t), and
denote the normalized noise power, then we write the SNRO as follows
If input signal is normalized to minimum and maximum value
1, then
𝑚𝑚𝑎𝑥 =1
We assume that x(t) is normalized
𝑆 2𝑅
Then, =𝑆𝑁𝑅 𝑂 =3 × 𝑃 × 2
𝑁
(𝑁) (𝑁)
For
𝑆 normalized values of power, SNR𝑆
O in decibels is, 2𝑅
=( 𝑆𝑁𝑅𝑂 )𝑑𝐵 =10 𝑙𝑜𝑔10 𝑑𝐵=10 𝑙𝑜𝑔10 (3 × 2 )=( 4 . 8+6 𝑅) 𝑑
𝑑𝐵
SQNR for Sinusoidal Wave:
Then
( )
𝑆
𝑁 𝑑𝐵
=10 𝑙𝑜𝑔10 ( )
𝑆
𝑁
3
𝑑𝐵=10 𝑙𝑜𝑔10 ( ×22 𝑅 )=(1. 8+ 6 𝑅) 𝑑𝐵
2
89
Transmission Bandwidth in PCM:
Let the quantizer use R bits to represent each level, then the number of
levels are L=2R for a L-level quantizer.
Here the No. of bits per second is also called signaling rate of PCM, r
The signaling rate of PCM, r = R fs ; here fs ≥ 2W
Since, fs ≥ 2W
𝐵𝑊 𝑃𝐶𝑀 ≥ 𝑅𝑊
Problem:
Solution
Cont.….
Problem: An audio signal is required to be digitally transmitted with a
sampling rate of 40 kHz and 14 bits per sample using linear PCM system.
Calculate the minimum transmission data rate needed in the
communications channel.
95
Problem: Discrete samples of an analog signal are uniformly quantized to
PCM. If maximum value of analog sample is to be represented within 0.1%
accuracy, find minimum number of binary digits required per sample.
97
The signal-to-quantization noise ratio,
Problem: Consider an analog input signal to PCM whose bandwidth is
limited to 4 kHz and varies in amplitude from – 3.8 V to + 3.8 V, with an
average power of 30 mW. The required signal-to-quantization error ratio is
given to be 20 dB. Assuming uniform quantization, determine the number of
bits required per sample.
99
Therefore,
We know that
• In addition to the quantization noise, the channel noise also affects the
performance of the PCM system.
• Channel noise may get introduced anywhere along the transmission path
between transmitter and receiver.
• Due to channel noise, the receiver may not be able to reconstruct the
signal exactly all the time.
• As a result, a binary signal 0 may be decoded as binary signal 1 or vice
versa.
• Such type of errors must be minimized so as to improve the performance
of PCM system which is measured in terms of error probability.
Error Probability:
where Pmax is the maximum or peak signal power, Tb is the bit duration, and
N0 is noise spectral density.
Rewriting the above equation
• Above this value, the error probability is very low whereas below this, the
error probability is high and the effect of channel noise is significant.
• The effect of channel noise can be minimized using the regenerative
repeaters.
Error Threshold in PCM:
In PCM, the main effect of channel noise is to introduce bit errors into the
received signals which may be measured in terms of the average
probability of symbol error, Pe or Bit Error Rate (BER).
Bit Error Rate (BER) is defined as the probability that the reconstructed
symbol at the receiver output is different from the transmitted symbol, on an
average.
• The average noise power in the PCM system is increased by the number of
bits used in each sample multiplied by increase in bandwidth.
Following figure depicts the receiver for the detection of the binary PCM
wave.
A matched filter is a linear filter designed to provide the maximum SNR at its
output for a given transmitted symbol waveform.
Let us assume that the symbols 1 and 0 occur with equal probability. Then the
decision boundary or the threshold is set at middle, i.e, between two message
points and is .
The decision boundary divides the signal-space diagram into two regions Z1
and Z2.
If the received signal falls in the region Z1, we take decision in favor of symbol
1. If the received signal falls in the region Z2, we take decision in favor of
symbol 0.
1. Symbol 0 is sent, but the received signal fall inside the region Z1, and
receiver takes a decision in favour of symbol 1.
2. Symbol 1 is sent, but the received signal fall inside the region Z2, and
receiver takes a decision in favour of symbol 0.
The input to the decision device x1 will have a coordinate along axis is given by
The received signal point x1 is the sample value of a random variable X1.
The mean of X1 is that of si1 where i=1,2 and the variance of X1 is that of AWGN,
a random variable W1 having a sample w1.
Hence, the RV X1 with sample value x1, having a Gaussian distribution with
zero mean and variance N0/2 has a conditional PDF or likelihood function as
follows (assuming that a 0 is sent)
The likelihood function is sketched as follows.
Then
Similarly, the RV X1 with sample value x1, having a Gaussian distribution with
mean and variance N0/2 has a conditional PDF or likelihood function as
follows (assuming that a 1 is sent)
The above likelihood function is Gaussian distributed and peak at its mean
value . The sketch of this likelihood function is given below. The shaded area
represents the probability of error when symbol 1 is sent and decision is
taken in favour of symbol 0
Differential PCM (DPCM):
• For the digitization of analog voice or video information signal using PCM,
the sampling is usually carried out at a rate slightly higher than the Nyquist
rate.
• It is observed that the resulting sampled signal does not change much from
one sample value to the adjacent one.
• In other words, adjacent samples carry same information with a little
difference, resulting in redundant information.
• DPCM is specifically designed to take advantage of the sample-to-sample
redundancies in typical speech waveforms.
• Since the range of sample differences is typically less than the range of
individual samples, fewer bits are required for DPCM as compared to that
needed for conventional PCM.
• The number of bits required to transmit one sample will also be reduced.
• Overall bit rate will be decreased.
• Less bandwidth will be needed.
• More efficient encoded signal will be obtained.
• If a part of the redundant information is known, it is possible to predict
the future values due to correlation between the samples.
e(nTs) =
Where is the prediction of x(nTs).
The receiver for constructing the quantized version of the input is given
below.
Delta Modulation:
The present sample value is compared with the previous sample value.
Thus, the difference between the actual input signal and the approximation
signal is quantized into two representation levels only: +Δ and -Δ,
corresponding to positive and negative difference respectively.
• Hence, for each sample, only one binary bit is transmitted.
• Following figure shows an ideal delta modulation waveform.
Where Ts is sampling instant,
xq(nTs-Ts) is recent approximation of
x(nTs),
e(nTs) is error signal representing the
difference between the present sample
x(nTs) and latest approximation to it,
and
eq(nTs) is quantized version of e(nTs)
The quantizer output eq(nTs) is the desired delta modulated wave for
different values of n. The rate of information transmission is 1/Ts.
The output of quantizer is +Δ , if e(nTs) > 0 and -Δ, if e(nTs) < 0, i.e, eq(nTs) is
Δsgn{e(nTs)}. The quantizer output is applied to accumulator producing
At the sampling instant nTs , the accumulator increments xq(nTs - Ts) by a step
±Δ depending on the sign of the error signal e(nTs).
Following figure shows the block diagram of a DM receiver.
Every signal has a definable upper frequency, that decides the fastest rate at
which it can change.
To get the fastest change in the signal, both Δ and fs must be increased or one
of them must be increased.
If the step size is small, it results in slope overload condition, where the staircase
cannot track rapid changes in the analog signal.
If steps are too large compared to small variations in the input signal,
Granular noise occurs.
This means that for very small variations in the input signal, the staircase
signal is changed by a large amount because of the large step size.
Slope overload is very common in analog signals that have steep slopes or
whose amplitudes vary rapidly.
The delta modulation with uniform step size, is called as “Linear delta
modulation”
Quantization Noise in Delta Modulation:
Let the random variable Q denote the quantization error and qe its sample
value. Then,
Q = x(t) - xq(t)
Let us assume that the sampling rate fs and step size Δ are chosen in order to
avoid slope overload.
Then, we conclude that the error is uniformly distributed over the range
between -Δ and +Δ as shown in figure below.
The output quantizing noise power within the bandwidth fM of the LPF in the
receiver is
If P is the average signal power, then output signal-to-noise ratio is
Adaptive delta modulation (ADM)
ADM is a delta modulation where the step size δ of the staircase waveform is
varied depending upon the slope or amplitude characteristics of the analog
input signal.
The effects of slope overload distortion and granular noise can be overcome
by making the staircase step size δ(nTs), a function of the slope of the input
analog signal.
When the slope of the input analog signal is large, δ(nTs) is increased and
when the slope is fairly constant, δ(nTs) is decreased. In practice, the
staircase step size δ(nTs) is bounded by lower and upper limits δmin and δmax,
respectively.
δmin ≤ δ(nTs) ≤ δmax
References:
146
THANK YOU
147