0% found this document useful (0 votes)
18 views91 pages

Communication Systems

The document provides an overview of communication systems, detailing the components involved such as information sources, transmitters, channels, and receivers. It explains modulation, its necessity for wireless communication, and introduces concepts like Hilbert Transform and correlation functions. Additionally, it discusses random processes, particularly wide sense stationary processes, and their properties in the context of linear time-invariant systems.

Uploaded by

Revanth Kushal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views91 pages

Communication Systems

The document provides an overview of communication systems, detailing the components involved such as information sources, transmitters, channels, and receivers. It explains modulation, its necessity for wireless communication, and introduces concepts like Hilbert Transform and correlation functions. Additionally, it discusses random processes, particularly wide sense stationary processes, and their properties in the context of linear time-invariant systems.

Uploaded by

Revanth Kushal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 91

Communication Systems

Dhruva Hegde

1 Introduction to Communication
Communication is the process of exchanging (sending and receiving) data or
information.

1.1 Block Diagram of Communication System

Information source generates information in different forms such as text, au-


dio, picture, video, etc.These are non-electrical signals, which need to be
converted to electrical (or electromagnetic) signals which is done by input
transducer.

Transmitter is a device (or group of devices) that is used to modulated the


input electrical signal and send it over a channel.

Channel is the physical medium in which the signal carrying the informa-
tion travels. It can be wired (like optical fibre or copper cable) or wire-less.

Receiver is a device (or group of devices) that is used to recover back the
original information from the signal obtained through the channel.

1
The signal at the receiver end will be in electrical form, which again needs
to be converted back to it’s original form. This is accomplished using output
transducer, which outputs the data to the destination in it’s original form.

Noise is any distortion or loss or data or addition of unwanted data on the


original signal. This can happen due to various practical reasons in any of
the blocks, but for convenience, noise is modelled to be added during the
transportation of the signal in the channel.

1.2 Modulation
Modulation is the process of varying some feature of a high frequency carrier
signal with respect to a low frequency message signal.
In simpler words, modulation is implanting the low frequency message on a
high frequency carrier due for transmission and reception.

1.2.1 Need for Modulation


Wired communication generally does not required modulation. However,
wireless communication is more extensively used because wired communi-
cation requires man-made connections to exist between the source and the
destination.

In wireless communication, the information is converted to electromagnetic


waves. This is accomplished with the help of a transmitting antenna, which
is transmitted through air. And the receiving antenna converts the received
electromagnetic wave to an electrical signal which is processed by the receiver.

For the antenna to be able to transmit or receive an electromagnetic signal,


it’s length should be of the order of the wavelength of the electromagnetic
signal. Typically, if λ is the wavelength of the EM wave, then the antenna
length should be around λ/4.
Now audio signals are usually in the frequency range of 300-3000 Hz, mean-
ing their wavelengths will be of the order 100-1000 km (λ = c/f ), for which
the antenna lengths are impossible to realize practically.
Hence, to reduce the length of antenna, a high frequency carrier (in the order
of GHz) is modulated with respect to the message, which can be transmitted
and received using antennae whose lengths would be of the order cm or mm.

2
Modulation also have other advantages such as allowing for multiplexing,
increasing signal to noise ratio, etc..
Note that the received signal can’t directly be used, it has to be demodu-
lated. Meaning, the low frequency message has to be re-obtained from the
modulated signal before sending to the output destination.

1.2.2 Types of Modulation


The various types of modulation schemes are shown in the flowchart.

3
1.3 Hilbert Transform
Hilbert Transform a time domain transformation, i.e it transforms a time
domain signal to another time domain signal.
Hence, a Hilbert Transformer can be thought of as an LTI system of impulse
response hH (t) which operates on a signal x(t) to give Hilbert transform of
x(t) which is denoted by x̂(t).
=⇒ x̂(t) = hH (t) ∗ x(t)

Taking Fourier Transform on both sides for the above equation,


X̂(f ) = HH (f ) X(f ).

−j
 :f >0
HH (f ) = −j sgn(f ) = 0 :f =0

j :f <0

The magnitude and phase of the above function will give more clarity on the
nature of behaviour of Hilbert transformer in the frequency domain.
(
1 : f 6= 0
|HH (f )| =
0 :f =0

The magnitude is unaffected except for the zero frequency (i.e DC) compo-
nent on x(t), which is completely attenuated. Hence, Hilbert transform kills
DC input.


−π/2 : f > 0

∠HH (f ) = 0 :f =0

π/2 :f <0

The phase is shifted by −90o for all positive frequencies and by 90o for all
negative frequencies. Hence, Hilbert transform is basically a 90o phase shifter.

From the expression of HH (f ), using derivative and duality properties of


Fourier Transform, it can be deduced that the impulse response of the Hilbert
1
transformer is given by, hH (t) = πt .
1
=⇒ x̂(t) = ∗ x(t)
πt
4
Properties of Hilbert Transform

• ax(t) + by(t) ↔ ax̂(t) + bŷ(t)

• ax(t − t0 ) ↔ ax̂(t − t0 )

• x(at) ↔ sgn(a)x̂(t)
d[x(t)] d[x̂(t)]
• dt
↔ dt

• x(t) ∗ y(t) ↔ x̂(t) ∗ y(t) = x(t) ∗ ŷ(t)

If X(f ) is a complex quantity i.e X(f ) = a + jb, then X̂(f ) = b − ja. Hence,
Hilbert transform swaps the real and imaginary components in the frequency
domain.

1.3.1 Complex Envelope


Let x(t) be a pass-band signal centered around frequency fc .
The signal x(t)+j x̂(t) is called the ”Complex pre-envelope” of the signal x(t).

The spectrum of the complex pre-envelope is X(f ) + j X̂(f ). Upon spectral


analysis, it can be observed that this will result in,
(
2X(f ) : f > 0
X(f ) + j X̂(f ) =
0 :f <0

If the above spectrum is shifted such that it is centered around the 0 fre-
quency, the obtained signal is called the ”Complex envelope”.
Shifting by fc in the frequency domain corresponds to multiplying the signal
by e−2jπfc in time domain. Hence, the complex envelope in time domain is
given by,

x̃(t) = [x(t) + j x̂(t)]e−2jπfc

The Complex envelope represents the complex base-band equivalent signal


of the band-pass signal x(t).
Observe that x(t) =Re[x̃(t)e2jπfc ].

5
1.4 Correlation Functions
Correlation functions compare two signals and measure the extent of simi-
larity between them with respect to a certain lag. Note that a correlation
function is not a function of time, but a function of time delay.

1.4.1 Cross-correlation Function


Consider 2 signals x(t) and y(t).
The cross-correlation function between these signals is defined as,
Z ∞
Rxy (τ ) = x(t)ȳ(t − τ )dt
−∞

This function characterizes the extent of similarity between x(t) and y(t) for
a lag τ .
Note that the cross-correlation operation is same as the convolution between
x(τ ) and ȳ(−τ ).

=⇒ Rxy (τ ) = x(τ ) ∗ ȳ(−τ )

Taking FT on both sides of the above equation,

Sxy (f ) = X(f ) Ȳ (f )

The frequency domain representation of the cross-correlation function is rep-


resented using Sxy (f ).

1.4.2 Auto-correlation Function


The Auto-correlation function is a special case of cross-correlation in which
both the signals being considered are the same.
Meaning, this function characterizes the extent of similarity of a signal with
itself for a lag τ .
Hence, the auto-correlation function of a signal x(t) is given by,
Z ∞
Rxx (τ ) = x(t)x̄(t − τ )dt = x(τ ) ∗ x̄(−τ )
−∞

Note that the auto-correlation function is an even function i.e Rxx (τ ) =


Rxx (−τ ) since the both signals are same so lag being positive or negative

6
changes nothing.

The Fourier transform of auto-correlation function is represented as Sxx (f ).


Taking FT on both sides of the above equation,

Sxx (f ) = X(f ) X̄(f ) = |X(f )|2

Evaluating Rxx (τ ) at τ = 0 i.e no lag, it is found that


Z ∞ Z ∞
2
Rxx (0) = |x(t)| dt = |X(f )|2 df
−∞ −∞

Note that the above equation shows Parseval’s Theorem.


Rxx (0) is the same as integrating the square of the signal for all time, and
hence it is equal to the energy of the signal x(t).

Also, since τ = 0 means the function is comparing a signal with itself, the
similarity has to be maximum. Hence, Rxx (0) is the maximum value that
Rxx (τ ) can take.

The function Sxx (f ) represents the spread or distribution of energy of the


signal in the frequency domain, and hence it is called Energy Spectral
Density of the signal x(t).

Energy of the signal x(t) over a band of frequencies [−W, W ] is given by,
Z W
E= Sxx (f ) df
−W

Note that ESD is a non-negative real quantity i.e Sxx (f ) > 0 ∀ f and it is
an even function i.e Sxx (f ) = Sxx (−f ).

1.5 Random Process


A random process is a time indexed random variable.
This means, a random process is a process which at every instant of time,
takes values from the distribution corresponding to a random variable.
Hence, a random process X(t) is characterized by a probability distribution
function fX (x, t).

7
The mean of the random process X(t) is given by,
Z ∞
µx (t) = E[X(t)] = X(t)fX (x, t)dx
−∞

Note that here, x is the dummy variable in the PDF.

The variance of a random process is given by,

σ 2 (t) = E[X 2 (t)] − [µx (t)]2

The auto-correlation function can be defined for a random process as,

Rxx (t1 , t2 ) = E[X(t1 )X(t2 )]

Hence, the ACF of a random process gives the relation between the same
process at two different instances of time.

1.5.1 Wide Sense Stationary Random Process


A WSS random process is a special type of random process whose mean is a
constant value (i.e mean does not depend on t) and whose auto-correlation
function is only a function of time delay and not of time instances (i.e ACF
is a function of τ only and not t).

=⇒ µx (t) = k

If t1 = t and t2 = t + τ , then the ACF of a WWS random process is given


by,

Rxx (t1 , t2 ) = Rxx (t, t + τ ) = E[X(t), X(t + τ )] = Rxx (τ )

Hence for a WSS random process, the ACF will be stationary for a given
time delay and mean will always be stationary.

If the time delay τ = 0, then the ACF will be,

Rxx (0) = E[X(t)X(t)] = E[X 2 (t)]

The value of ACF at τ = 0 gives the average power of the random process.

8
Note that for a zero mean WSS process (µx (t) = 0), the variance and the
ACF at τ = 0 are the same i.e mean of square of X(t). Hence, for a WSS
process with zero mean, the power of the process is also equal to its variance.

Power Spectral Density of a WSS random process is given by the Fourier


transform of the auto-correlation function.
Z ∞
=⇒ Sxx (f ) = Rxx (τ )e−j2πf τ dτ
−∞

PSD of a WSS random process has same properties as ESD of a signal i.e it
is always positive, real and even (symmetric).

It can be noted that Rxx (0) is equal to the area under PSD. Hence, area
under PSD also gives the average power of the WSS random process.

Power of a random process in a band of frequencies f1 to f2 is given by,


Z −f1 Z f2 Z f2
P = Sxx (f )df + Sxx (f )df = 2 Sxx (f )df
−f2 f1 f1

Few observations regarding applications of ACF of a WSS random process:

• Rxx (τ ) as τ → ∞ gives the DC power of X(t) if X(t) is an ergodic


random process.
=⇒ Rxx (∞) = [E[X(t)]]2
The square root of this is simply the mean µx (t), which gives the DC
value of X(t).

• Rxx (τ ) at τ = 0 gives the total average power of X(t).


=⇒ Rxx (0) = E[X 2 (t)].
The square root of this gives the RMS value of X(t).

• AC power can be found as Rxx (0) − Rxx (∞).


=⇒ Rxx (0) − Rxx (∞) = E[X 2 (t)] − [E[X(t)]]2 .
This is same as variance of X(t).

Note that for a non WSS random process, the ACF will be a function of both
t and τ , so it has to be denoted as Rxx (t, τ ).

9
1.5.2 Random Process’ & LTI Systems
Consider a random process X(t) being transmitted through an LTI system
of impulse response h(t).
The output Y (t) is given by,
Z ∞
Y (t) = X(t) ∗ h(t) = X(t − k)h(k)dk
−∞

This indicates that Y (t) is also a random process.

If X(t) is a WSS process, then a few interesting properties can be obtained.


Since the mean of X(t) is constant, the following result can be derived.
Z ∞
E[Y (t)] = µx h(k)dk = µy
−∞

The resulting random process Y (t) will also have mean that is constant with
time.

Similarly, the auto-correlation function of Y (t) is obtained as,

Ryy (t, t + τ ) = Rxx (τ ) ∗ h(τ ) ∗ h(−τ )

Y (t) has ACF that depends only on the delay τ and not on time instances,
meaning the ACF is constant of a given time delay.

Therefore, if the input to an LTI system is a WSS random process, then the
output of the system will also be a WSS random process.

Since h(τ ) ↔ H(f ) and h(−τ ) ↔ H̄(f ), the PSD of the output random
process Y (t) is given by,

Syy (f ) = Sxx (f )H(f )H̄(f ) = Sxx (f )|H(f )|2

This result is very useful in finding the power of a random signal which is
output from LTI systems (such as filters).

10
2 Analog Communication
As mentioned earlier, modulation and demodulation of message signals are
essential for communication systems. In analog communication, a high fre-
quency carrier is modulated to embed a low frequency message.

Consider a sinusoidal carrier c(t) = Ac cos(2πfc t + φ) where Ac is its ampli-


tude, fc is its frequency and φ is its phase where 2πfc t+φ represents the angle.

Obviously, analog modulation can be done in 3 ways i.e by changing one of


the 3 parameters mentioned above with respect to the message signal.

2.1 Amplitude Modulation


For a high frequency carrier sinusoid of the form c(t) = Ac cos(2πfc t + φ),
if its amplitude Ac is varied according to the message signal m(t), then the
carrier is said to be ”amplitude modulated”.

2.1.1 Standard Amplitude Modulation


The amplitude modulated signal is given by,
x(t) = Ac [1 + ka m(t)] cos(2πfc t)
where ka is the ”sensitivity” of the modulated signal

11
Observe that the message signal is encoded in the envelope of the modulated
carrier signal.

Consider a single-tone message signal m(t) = Am cos(2πfm t).


Then the modulated signal will be,
x(t) = Ac [1 + µ cos(2πfm t)] cos(2πfc t)
where µ = ka Am which is called ”Modulation Index”

The above equation can be further modified as


µAc µAc
x(t) = Ac cos(2πfc t) + cos(2π(fc − fm )t) + cos(2π(fc + fm )t)
2 2
where the first term is simply the carrier while the second and third terms
represent the lower and upper side bands respectively.

Hence, standard amplitude modulation is also called Double side band full
carrier (DSB-FC) modulation.

The value of µ should be such that envelope distortion should not occur
while demodulating the modulated signal, which will happen if zero ampli-
tude crossing occurs in the modulated signal.

If µ > 1, then the carrier is said to be over-modulated and it will result


in envelope distortion. Hence, for proper recovery of the modulated signal,
µ ≤ 1.

For any arbitrary message signal m(t), the modulation index is given by
µ = ka |min[m(t)]|.

Spectrum of Standard AM Signal


Consider that the message signal m(t) is band-limited to frequency fc , and
M (f ) is the spectrum of m(t).
The spectrum of the carrier is found using Fourier transform of a sinusoidal
signal which will be two shifted impulses.
Then using modulation property of Fourier transform, the spectrum of the
modulating signal x(t) i.e X(f ) can be obtained as follows.
Ac  
X(f ) = δ(f − fc ) + ka M (f − fc ) + δ(f + fc ) + ka M (f + fc )
2
12
It can be noted that the bandwidth of an amplitude modulated signal is twice
the maximum frequency component of the message signal.
BW = (fc + fm ) − (fc − fm ) = 2fm

For a sinusoidal message signal, the spectrum of the modulated signal will
be as illustrated.

Power in AM signal
An AM modulated signal x(t) = Ac [1 + ka m(t)] cos(2πfc t) can be split into
two components i.e the carrier itself and the modulated message.

The power of the carrier is obviously Pc = A2c /2.


The power of the message can be approximated by treating it as a sinusoid
of amplitude Ac ka m(t) and hence, the power is given by, Pmod ≈ A2c ka2 Pm
where Pm is the power of the message signal m(t).

The total power of x(t) will be

A2c
1 + ka2 Pm

Pt =
2

13
Since only the message part of the modulated signal carrier information, the
efficiency of AM is given by the ratio of modulated message power and the
total power.

ka2 Pm
η=
1 + ka2 Pm

Considering the specific case of a sinusoidal message signal m(t) = Am cos(2πfm t),
the power of the message signal will be Pm = A2m /2.
Hence, the total power is given by,

A2c 2
A2c µ2
   
2 Am
Pt = 1 + ka = 1+
2 2 2 2

Note that the power is LSB and USB will be µ2 A2c /8 and hence the side band
power (i.e power of the components that carry the message) is µ2 A2c /4.

And the efficiency will be,

ka2 A2m µ2
η= =
2 + ka2 A2m 2 + µ2

Since to avoid envelope distortion the value of µ ≤ 1, maximum efficiency is


obtained when µ = 1.
=⇒ ηmax = 13 i.e 33.33%.

If Ic is the antenna current before modulation and It is the antenna current


after modulation, the relation between them is,
r
µ2
It = Ic 1 +
2
Some useful results for standard AM calculations:

• Maximum amplitude of modulated signal, Vmax = Ac (1 + µ)

• Minimum amplitude of modulated signal, Vmin = Ac (1 − µ)


max −Vmin
• =⇒ µ = VVmax +Vmin
Am
In case of single tone modulation, µ = Ac

14
For a multi-tone
p modulated signal, the effective Modulation Index is given
by, µT = µ1 + µ22 + .... Hence, the total power will be,
2

µ21 + µ22 + ...


 
P t = Pc 1 +
2
Square Law Modulator

Standard AM signal is generated using the square law modulator. The mes-
sage and carrier are added to obtain v1 (t) = m(t) + c(t), which is passed
through a non-linear system which generates v2 (t) = a v1 (t) + b v12 (t).
v2 (t) = a m(t) + a c(t) + b m2 (t) + b c2 (t) + 2b m(t)c(t)
The above signal is then passed through a band pass filter of cut-off frequen-
cies fc − fm and fc + fm .
=⇒ x(t) = a c(t) + 2b m(t)c(t) = aAc cos(2πfc t) + 2bAc m(t) cos(2πfc t)
The same can be expressed in standard AM form as,
2b 
x(t) = aAc 1 + m(t) cos(2πfc t)
a
Envelope Detector

The envelope detector is a simple circuit that is used to recover back the
message signal from a modulated signal by tracking the envelope of the mod-
ulated signal.
This is done using a diode and an RC circuit with appropriate time constant.

When the modulated signal amplitude is increasing, the diode will be forward
biased and hence the capacitor charges. When the modulated signal ampli-
tude is decreases, the diode is reverse biased so the capacitor can’t discharge

15
back through the same path, but it has to discharge through the load.
If the charging time constant (τc = Rs C) is low and discharging time constant
(τd = RL C) is appropriately high, then the message signal will be tracked by
the envelope detected.

1 1 1
For enveloped detected to work properly, τc << fc
and fc
<< τd << fm
.

• If τd is too close to f1c , then it will start tracking the carrier itself instead
of the envelope, which is not desirable.

• If τd is too close to f1m , then it the capacitor discharges too slow and
hence will not track any fast changes in the message signal. This is
called ”diagonal clipping”.

Note that envelope detector will not work if the value of Modulation Index
is greater than 1.
In general, the output of a properly designed envelope detector will be |m(t)|.

Ideal value of discharging time constant is given by,


p
1 1 − µ2
τd (= RL C) =
2πfm µ

2.1.2 Double Side Band, Suppressed Carrier


In standard amplitude modulation, the carrier is also sent along with the
modulated signal. This caused low efficiency.
The DSB-SC scheme only sends the modulated signal and does not send the
carrier (hence the name).

s(t) = m(t) Ac cos(2πfc t)

The spectrum of a DSB-SC signal is given by,


Ac  
S(f ) = M (f − fc ) + M (f + fc )
2
The bandwidth of DSB-SC signal is same as that of standard AM signal.
However, since the carrier is completely suppressed, there is no component

16
in the signal which does not contain the message.

Meaning, the total power is same as the modulated message signal power
which is given by Pt = A2c Pm /2 and hence the efficiency of DSB-SC is 100%.

Consider single tone modulation i.e the message is m(t) = Am cos(2πfm t).
Then the power of the modulated signal is given by Pt = A2c A2m /4.

Similarly for multi-tone modulation i.e the message is m(t) = Am1 cos(2πfm1 t)+
Am2 cos(2πfm2 t) + .... Then the power of the modulated signal is given by
Pt = A2c (A2m1 + A2m2 + ...)/4.

Balanced Modulator

DSB-SC signal can be generated using a balanced modulator which is done


by generated two standard AM signals and subtracting them to remove the
carrier component.

Here, s1 (t) = Ac [1+ka m(t)] cos(2πfc t) and s2 (t) = Ac [1−ka m(t)] cos(2πfc t)
and hence the final DSB-SC signal is s1 (t) = 2Ac ka m(t) cos(2πfc t).

Ring Modulator

A more efficient way to generate a DSB-SC signal is by using ring modulator.

17
• When the carrier is positive, diodes D1 and D3 are on, while D2 and
D4 are off. Hence, s(t) = m(t).
• When the carrier is negative, diodes D2 and D4 are on, while D1 and
D3 are off. Hence, s(t) = −m(t).
The signal s(t) changes back and forth between m(t) and −m(t) at the high
frequency of the carrier, and hence DSB-SC signal is generated.

Synchronous Demodulator

It is obvious that enveloped detector can’t be used to demodulate a DSB-SC


signal. Hence, the synchronous (or coherent) detector is employed.

The output of the product modulator is given by,


A2c A2
v(t) = m(t) cos φ + c cos(4πfc t + φ)m(t)
2 2
18
If the cut-off frequency of the low-pass filter is chosen to be less than 2fc −
fm , then the demodulated output will be a scaled version of the message
signal multiplied by the phase difference between the original carrier and
then locally generated carrier.

A2c
md (t) = m(t) cos φ
2
Ideally, the phase difference φ = 0 and hence the demodulated signal is sim-
ply scaled version of the message.
But due to mobile receivers, when the distance between the transmitter and
sender keeps changing, a phase difference is noticed in the modulated signal
when it arrives as the received signal.
Note that if φ = π/2, then the output will be 0. This effect is called ”Quadra-
ture nulling” and it must be avoided.

In coherent demodulation of DSB-SC signal, in-phase component of noise will


be retained whereas quadrature-phase component of noise will be rejected.

2.1.3 Quadrature Carrier Multiplexing


QCM is a technique where two message signals are transmitted over the same
channel at the same carrier frequency using orthogonal carrier signals.

Orthogonal signals are those signals that are independent of each other i.e
they have 90o phase shift.
Example - cos(2πfc t) and sin(2πfc t)

Condition for two 2 real value signals f1 (t) and f2 (t) to be orthogonal is,
Z ∞
f1 (t)f2 (t)dt = 0
−∞

If m1 (t) and m2 (t) are the two message signals, then the QAM signal will be
s(t) = m1 (t) cos(2πfc t) + m2 (t) sin(2πfc t)

Usually, demodulation is done using coherent demodulation.

19
This technique of using orthogonal carriers of same frequency will reduce the
bandwidth necessary to transmit signals.

The message signals can be referred to as mI (t) i.e the in-phase message and
−mQ (t) i.e the quadrature-phase message.
=⇒ s(t) = mI (t) cos(2πfc t) − mQ (t) sin(2πfc t)

The complex pre-envelope of the band-pass QCM signal will be,

sp (t) = [mI (t) + mQ (t)]e2πfc t

Now by shifting it to base-band (i.e centered around 0 frequency), the com-


plex envelope is given by,

s̃(t) = sp (t) e−2πfc t = mI (t) + j mQ (t)

Hence, the base-band equivalent of the QCM signal is simply the in-phase and
quadrature-phase messages that are phase-shifted by 90o i.e are orthogonal.

2.1.4 Single Side Band, Suppressed Carrier


Since signal spectrum is always symmetric, there is no need to transmit both
LSB and USB. The entire information in the message can be recovered by
transmitting either one of the side bands, which will reduce the power con-
sumption and bandwidth.

Frequency Discrimination Method


Ideally, SSB-SC signal can be generated by first generating DSB-SC signal

20
and then passing it through ideal band pass filter with appropriate cut-off
frequencies to get either only USB or only LSB (and hence obtaining SSB-SC
signal).

The disadvantage with this method is that ideal filters can’t actually be de-
signed. There will always be a transition band in practical filters which will
allow some parts of unwanted frequency components to pass as well.

Phase Discrimination Method


An alternative, more practical way to generate SSB-SC signal uses the con-
cept of Hilbert transform.

The SSB-SC signal in time domain will be as follows.


USB only transmission:
Ac  
s(t) = m(t) cos(2πfc t) − m̂(t) sin(2πfc t)
2
LSB only transmission:
Ac  
s(t) = m(t) cos(2πfc t) + m̂(t) sin(2πfc t)
2
The above equations indicate that either USB or LSB signal can be generated
by adding or subtracting the message and its phase shifted version that are
DSB-SC modulated using orthogonal carriers.

21
Demodulation of SSB-SC
Envelope detector can’t be used since the output will be constant DC (Ac /2).
Synchronous detector must be used.

SSB-SC signal demodulated using carrier Ac cos(2πfc t + φ) and necessary


BPF is given by,

0 A2c A2c
m (t) = m(t) cos φ ± m̂(t) sin φ
2 2
• If φ = 0, then m0 (t) ∝ m(t)

• If φ = π/2, then m0 (t) ∝ m̂(t)

Hence, quadrature nulling will not occur in case of synchronous demodula-


tion of SSB-SC signal.

The spectra of both DSB-SC and SSB-SC are illustrated.

22
2.2 Angle Modulation
For a high frequency carrier sinusoid of the form c(t) = Ac cos(2πfc t + φ),
if its angle θ(t) = 2πfc t + φ is varied according to the message signal m(t),
then the carrier is said to be ”angle modulated”.

Note that there are two variable components in the angle, which are phase φ
and frequency fc . Meaning, there are broadly two types of angle modulation
schemes.

2.2.1 Phase Modulation


In phase modulation, the phase φ of a high frequency carrier c(t) = Ac cos(2πfc t+
φ) is varied according to message signal m(t).

Assume the unmodulated carrier is c(t) = Ac cos(2πfc t) where the angle


θ(t) = 2πfc t.
In Phase modulation, the angle is modulated along with the message such
that instantaneous phase varies proportionally with the message.
=⇒ θi (t) = 2πfc t + kp m(t).

23
Hence, the phase modulated signal will be,

x(t) = Ac cos(θi (t)) = Ac cos(2πfc t + kp m(t))

The maximum phase deviation is obviously ∆φmax = kp max[m(t)].

Instantaneous frequency is calculated as follows.

1 d[θi (t)] kp 0
fi (t) = = fc + m (t)
2π dt 2π
where m0 (t) is the derivative of the message signal m(t)

Hence, the maximum frequency deviation is given by,


kp
∆fmax =max(fi (t) − fc ) = 2π max[m0 (t)].

For a single tone sinusoidal message signal, m(t) = Am cos(2πfm t), the phase
modulated signal will be,

x(t) = Ac cos(θi (t)) = Ac cos(2πfc t + kp Am cos(2πfm t))

Hence, the modulation index is β = kp Am .

• ∆φmax = kp Am = β

• ∆fmax = kp Am fm = βfm

2.2.2 Frequency Modulation


Assume the unmodulated carrier is c(t) = Ac cos(2πfc t) where the angle
θ(t) = 2πfc t.
In Frequency modulation, the frequency is modulated along with the message
such that instantaneous frequency varies proportionally with the message.
=⇒ fi (t) = fc + kf m(t).

The instantaneous angle is given by,


Z t Z t
θi (t) = 2π fi (τ )dτ = 2πfc t + 2πkf m(τ )dτ
0 0

24
And hence, the frequency modulated signal will be,
Z t
x(t) = Ac cos(θi (t)) = Ac cos(2πfc t + 2πkf m(τ )dτ )
0

The maximum frequency deviation is obviously ∆fmax = kf max[m(t)].


R
The maximum phase deviation is given by ∆φmax = 2πkf max[ m(τ )dτ ].

For a single tone sinusoidal message signal, m(t) = Am cos(2πfm t), the fre-
quency modulated signal will be,
kf Am
x(t) = Ac cos(θi (t)) = Ac cos(2πfc t + sin(2πfm t))
fm
kf Am
Hence, the modulation index is β = fm
.
kf Am
• ∆φmax = fm

• ∆fmax = kf Am = β fm
If the modulating signal consists of both sin and cos terms such as,
m(t) = A1 sin(2πfmp t) + A2 cos(2πfm t), then the maximum value m(t) can
take is |m(t)|max = A21 + A22 .
This result will be useful while calculating maximum phase and frequency
deviations.

Narrow Band FM

Narrow band FM signal is a frequency modulated signal where the modula-


tion index is significantly smaller than 1. β << 1 =⇒ ∆fmax << fm .

Consider an FM signal (with single tone sinusoidal message).


s(t) = Ac cos(2πfc t + β sin(2πfm t))
Upon expanding and substituting since β << 1, cos β ≈ 1 and sin β ≈ β,
the equation for narrow band FM can be obtained as follows.
s(t) = Ac cos(2πfc t) − Ac β sin(2πfc t) sin(2πfm t)
Note that the narrow band FM signal is similar to standard AM signal and
it can be generated using product modulator.

25
So if β << 1, the FM signal behaves somewhat similar to a standard AM
signal, which is not very useful.

Wide Band FM

Wide band FM signal is a frequency modulated signal where the modulation


index is a larger quantity. In general, β > 0.5 for it to be considered as a
wide band FM signal.

Wide band FM signal is usually generated by passing a narrow band FM


signal through a frequency multiplier.
A frequency multiplier consists of a non-linear device of order n followed by
band-pass filter to remove unwanted frequency components. This is called
”Indirect method”.

If the instantaneous frequency of NBFM signal is fi (t) = fc + kf m(t),


the output of frequency multiplier (of factor n) will be fo (t) = nfi (t) =
nfc + nkf m(t).
Hence, both the carrier frequency and the modulation index (β) are multi-
plied by a factor of n, which increases the value of β making it a WBFM
signal.

26
Spectral analysis of FM signal

A frequency modulated signal can be expressed as,

s(t) = Re[Ac ej(2πfc t+β sin(2πfm t)) ] = Re[Ac ejβ sin(2πfm t) ej2πfc t ]

From the above expression, it can be noted that Ac ejβ sin(2πfm t) is the complex
base-band equivalent of the FM signal s(t).
Hence, the spectrum of FM signal can be found by first finding the spectrum
of its complex envelope and then frequency translating it.

Let s̃(t) = Ac ejβ sin(2πfm t) . This signal is periodic with period T0 = 1/fm . So
the spectrum will be given by complex Fourier series coefficients.

X
s̃(t) = Ck ej2πfm kt
k=−∞
Z T0
1
Ck = Ac eβ sin(2πfm t) e−j2πkfm t dt
T0 0
Upon solving the above integral, it is found that the complex Fourier series
coefficients can be represented using Bessel’s Function of 1st kind and k th
order.
Z 2π
1
Ck = A c eβ sin x−kx dx = Ac Jk (β)
2π 0

X
=⇒ s̃(t) = Ac Jk (β)ej2πfm kt
k=−∞

Now the expression for original FM signal is obtained as,



 X  ∞
X
j2πfm kt 2πfc t
 
s(t) = Re Ac Jk (β)e e = Ac Jk (β) cos(2π(fc +kfm )t)
k=−∞ k=−∞

Finally, the spectrum of FM signal is obtained by using Fourier transform.


∞  
Ac X  
S(f ) = Jk (β) δ(f − fc − kfm ) + δ(f + fc + kfm )
2 k=−∞
Properties of Bessel’s Function:

27
• Jn (x) = (−1)n J−n (x)
P 2
• Jn (x) = 1
Magnitude of carrier in the FM signal depends on the value of β. For
β = 2.4, 5.5, 8.6, 11.8, ..., the carrier magnitude will turn out to be zero and
hence, 100% modulation efficiency is obtained.
A2c
Power of FM signal is same as the power of the carrier. =⇒ Pt = Pc = 2
.

From the spectrum, it can be observed that the bandwidth of the FM signal
is infinite since k ranges from −∞ to ∞. However, practically the Bessel
function values decay rapidly with increasing k and hence most of the power
is contained in the first few frequency components.

The method to calculate practical bandwidth of an FM signal is given by


Carson’s Rule.
 
1
BW = 2 1 + ∆fmax = 2(1 + β)fm
β
∆fmax
Note that β = fm

• If β >> 1, then BW ≈ 2∆fmax


• If β << 1, then BW ≈ 2fm
It is observed that approximately 98% of the power of an FM signal is con-
tained within the bandwidth calculated using Carson’s rule.

Demodulation of FM signal
FM signal is demodulated by first passing it through a differentiator which
will convert it to a signal in standard AM form, and then using envelope
detector.

28
Note that the condition for envelope detector to work without distortion is
fc > ∆fmax , which will pretty much always be naturally satisfied.

Relation between PM and FM


From the equations of PM and FM signals, it is obvious that one can be
realized by modifying the other as follows.

2.3 Frequency Translation


In signal processing and communication systems, it will be necessary to shift
a particular signal centred around frequency fc to a different centre frequency
fIF . This process is called frequency translation or ”Heterodyning”.
The new frequency at which the original signal is shifted to is usually referred
to as ”intermediate frequency”.

For example, all AM radio signals that are in the range of 540 kHz to
1600 kHz are shifted around the intermediate frequency of 455 kHz.

Frequency translation is done by using a mixer and a band pass filter. A


mixer is simply a product modulator which multiplies the modulated signal
with another sinusoid of different frequency.

If the modulated signal s(t) = Ac m(t) cos(2πfc t) is multiplied with signal


generated by local oscillator l(t) = cos(2π(fc + fIF )t), then the output will
consist of, sm (t) = 0.5Ac m(t) [cos(2πfIF t) + cos(2π(2fc + fIF )t).

29
The signal sm (t) can be passed through BPF to obtain st (t) = 0.5Ac m(t) cos(2πfIF t)
which is the same modulated signal centered around fIF rather than fc .
(note that l(t) = cos(2π(fc − fIF )t) can also be used for the same purpose)

Note that if there is another modulated signal being transmitted, say


r(t) = Ac m(t) cos(2π(fc + 2fIF )t), then after frequency translation,
rm (t) = 0.5Ac m(t) [cos(2πfIF t) + cos(2π(2fc + 3fIF )t) is obtained which
upon filtering will provide rt (t) = 0.5Ac m(t) cos(2πfIF t).

Note that in this case, s(t) = rt (t). Meaning, modulated signals of two differ-
ent frequencies can be translated to the same intermediate frequency, which
will cause interference between the two. This effect is not desirable.
For a modulated signal of frequency fc , the frequencies of fc ± 2fIF can cause
interference. These are called ”image frequencies”.

In order to properly receive the required message signal without interfer-


ence from image frequencies, the image frequency components have to be
attenuated by a pre-filter.

2.3.1 Super-heterodyne Receiver


The super-heterodyne receiver is a system used to receive the modulated sig-
nal using the concepts discussed above.

30
As mentioned, to suppress image frequency components before mixing with
a local oscillator, a filter is used (tuned RF filter).

The image frequency rejection ratio of the tuned filter is given by,
p fimg fc
α = 1 + P 2 Q2 ; P = −
fc fimg
where Q is the quality factor of the antenna coupling circuit

The local oscillator frequency is adjusted using capacitors.


The capacitance ratio is given by,
 2
Cmax fmax
R= =
Cmin fmin
where fmax = fcmax + fIF and fmin = fcmin + fIF .

Multiple such filters can be cascaded to obtain overall rejection ratio as prod-
uct of individual ratios.

2.4 Frequency Division Multiplexing


Frequency Division Multiplexing (FDM) is a process of combining multiple
signals centred at different carrier frequencies and transmitting them through
the same channel.

31
If x1 (t), x2 (t) and x3 (t) are band-limited to frequency W , they are translated
to different frequencies using different carriers as shown.
Hence, y1 (t), y2 (t) and y3 (t) will be centred at f1 , f2 and f3 respectively.
These signals are added and transmitted.

At the receiving end, band pass filters of relevant cut-off frequencies are used
to receive only the required signal (for example BPF of cut-off frequencies
f1 − W and f1 + W for signal y1 (t) and so on), which are then demodulated
to recover the original signals.

The figure below illustrates how base-band signals are frequency translated
to different center frequencies.

The translated signals are then added to obtain the FDM signal as shown.

32
3 Digital Communication
Noise immunity of digital signals is significantly higher than that of analog
signals. Also, designing systems that deal with digital systems is more mem-
ory efficient and more structured when compared to analog systems.
Hence, digital communication schemes are more widely used. The block di-
agram shown illustrates a general digital communication system.

3.1 Basics of Digital Communication Systems


Before going into how digital signals are modulated, transmitted and re-
ceived, some basic concepts regarding digital pulses and digital channel need
to be covered.

3.1.1 Digital Pulses


Digitally modulated symbols are transmitted using pulses. A generic pulse
will have amplitude 1 for a duration T and is denoted by p(t).
A digital signal will be a combination of several shifted and scaled pulses.
Hence the structure of a typical digitally transmitted signal is,

X
X(t) = ak p(t − kT )
k=−∞

The two most generic coding schemes are polar and unipolar.
 
+A : 1 +A : 1
Polar =⇒ ak = Unipolar =⇒ ak =
−A : 0 0:0

33
Since ak is a discrete random variable, x(t) is a random process.
Assuming ”0” and ”1” are equally likely to occur, it can be calculated that
the expected value of ak , and hence X(t) as well as X(f ) are all 0.

Hence, the relevant way to measure the spectral components of a random


process is by using Power Spectral Density (for which Auto-correlation func-
tion needs to be computed).

A more general form of a binary random sequence is,



X
X(t) ak p(t − kT + Td )
k=−∞

where Td is the starting delay due to absence of time synchronization. The


value of Td is not deterministic, it can take any value between 0 to T with
equal probability.

The auto-correlation function (ACF) of X(t) is derived to be,



1X
Rx (τ ) = Ra (n)rp (τ + nT )
T −∞

where Ra (n) is the ACF of the discrete random variable ak and rP (τ ) is the
ACF of the deterministic pulse signal p(t).

The above expression can be simplified for different schemes.

For polar coding, it can be found that


(
A2 : n = 0
Ra (n) =
0 : n 6= 0

Hence, the ACF expression reduces to:


A2
Rx (τ ) = E[x(t)x(t + τ )] = Rp (τ )
T
And the power spectral density is given by,
A2
Sx (f ) = |P (f )|2
T
34
The energy spectral density of the pulse is, |P (f )|2 = T 2 sinc2 (f T ).
Hence, the final expression for PSD of the digital signal is,

Sx (f ) = A2 T sinc2 (f T )

Note that the polar scheme is the most common and simplest scheme for
random binary pulse transmission. More complicated schemes are illustrated
in the following section.

3.1.2 Line Codes


A line code is a pattern of voltage, current, or photons used to represent
digital data.
There are 4 types of line coding, which are further sub-divided as follows.
• Unipolar:
– Non Return to Zero (U-NRZ)

BW = Rb
– Return to Zero (U-RZ)

BW = 2Rb
• Polar:
– Non Return to Zero (P-NRZ)

BW = Rb

35
Polar Non Return to Zero is the line code which was considered
earlier for the derivation of ACF and PSD of pulse of a random
binary sequence.

– Return to Zero (P-RZ)

BW = 2Rb

• Bipolar:

– Non Return to Zero (B-NRZ)

BW = Rb
– Return to Zero (B-RZ)

BW = Rb

• Manchester:

BW = 2Rb

36
3.1.3 Digital Channel
The most commonly used digital channel is called AWGN Channel i.e the
Additive White Gaussian Noise Channel.

If a digital signal x(t) is transmitted through an AWGN channel, then the


received signal y(t) is given by,

y(t) = x(t) + n(t)

Here, n(t) represents the noise signal.

In an AWGN channel, the noise is characterized by the following properties.

• n(t) is additive in nature i.e it adds to the input signal.

• n(t) is a Gaussian random process.

• n(t) adds equally to all frequencies of the input.

The auto-correlation of n(t) is given by,

N0
Rn (τ ) = δ(τ )
2
The above equation indicates that the correlation exists only at one instant
and hence, the noise signal is highly uncorrelated.

Taking Fourier transform, the power spectral density of n(t) is found.

N0
Sn (f ) = ∀f
2
Since the PSD is flat, noise adds equally to all frequencies.

37
3.1.4 Digital Receivers
The transmitted signal, after being sent through a channel (AWGN) has to be
received such that the noise is minimized and signal component is maximized.

As shown above, received signal y(t) is passed through a filter (which is an


LTI system), and then sampled at the duration of pulse to obtain the infor-
mation.
The filter h(t) is to be designed such that the Signal to Noise ratio (SNR) is
maximum.

By calculating the signal power and the noise power, the following inequality
can be obtained.
R∞
S −∞
|X(f )|2 df

N N0 /2
The numerator term is simply the energy of the input signal (E) and the
denominator term is obtained by the PSD of the Gaussian Noise.
S 2Emax
=⇒ =
N max N0
The energy of the input signal will be maximum if the transfer function of
the filter satisfies,
H(f ) = X̄(f ) e−j2πf T
Therefore, the impulse response of the filter must be
h(t) = x̄(T − t)

For real signals, h(t) = x(T − t).

Such a filter is called Matched Filter and the receiver which uses this is
called ”Matched Filter Receiver”.

38
3.1.5 Probability of Error
Due to the addition of noise, there is always the chance for error, even if the
signal to noise ratio is maximized.

The output of the matched filter is sampled at every T duration. Since the
input signal is a random process, the output will be a random variable.

For a binary sample space S = [0, 1], let s0 correspond to ”0” and s1 cor-
respond to ”1”. n0 (t) represents that noise component in the output of the
filter.

If ”0” is transmitted, then the output random variable will be r = s0 +n0 (T ).


If ”1” is transmitted, then the output random variable will be r = s1 +n0 (T ).

Hence, depending on the channel and the noise model, the probability density
function of the output random variable is obtained.
If the noised model is Gaussian (as it will be for an AWGN channel), then
the PDFs of the output random variables will be as illustrated.

P (r|s0 ) is the PDF of the received symbol if 0 was transmitted and P (r|s1 )
is the PDF of the received symbol of 1 was transmitted.

Vth = s1 −s
2
0
is the threshold value which makes the decision in the output, i.e
if the received value is greater than Vth , it is assumed that 1 was sent and if
the received value is lesser than Vth , it is assumed that 0 was sent.

If the two PDFs coincide/overlap, it means there is a chance for error. This
probability is found by integrating the PDFs over the region of the graph
beyond Vth .

39
Note that if the noise that adds to both the symbols equally (as does AWGN),
then the probability of errors for both 1 and 0 will be the same.

For a system with AWGN Channel which uses Matched Filter Receiver, the
probability of error is given by the complementary error function or the Q-
function:
r 
Ed
Pe = Q
2N0

Ed is the difference of signal energy i.e


Z T Z T Z T Z T
2 2
Ed = (s1 (t)−s0 (t)) dt = s1 (t) dt+ s20 (t) dt−2 s1 (t) s0 (t) dt
0 0 0 0

r 
Es1 + Es0 − 2Es1s0
=⇒ Pe = Q
2N0

The Q-function expression is:


Z ∞
1 2
Q(x) = √ e−z /2 dz
2π z=x
Using the given expression, probability of error for each of the modulation
schemes can be found (which will be introduced soon).

In case of there is a phase shift of φ between the modulation and demod-


ulation carriers, then the bit energy at the receiver end will be multiplied
by cos2 (φ), and so will the parameter inside the Q-function in probability of
error.

In case of polar signaling, since s1 = −s0 , the energies are given by Es1 =
Es0 = Ep and Es1s0 = −Ep .
Average energy per bit, Eb = 0.5(Ep + Ep ) = Ep .
r 
2Eb
=⇒ Pe = Q
N0

40
For any orthogonal binary signaling (such as on-off), since s0 = 0, the energies
are given by Es1 = Ep , Es0 = 0 and Es1s0 = 0.
Average energy per bit, Eb = 0.5(Ep + 0) = 0.5Ep .
r 
Eb
=⇒ Pe = Q
N0
The above results indicate that any orthogonal binary signaling is inferior to
polar signaling by 3 dB.

It is known that using orthogonal pulses will save bandwidth. Hence, there
is a trade-off between probability of error and bandwidth required for trans-
mission between the two different schemes.
• Polar signaling gives lower probability of error and power consumption
• Orthogonal signaling gives lower bandwidth consumption

3.1.6 Maximum Aposteriori Probability (MAP) Rule


Consider a binary sample space S = [0, 1] where s0 corresponds to ”0” and
s1 corresponds to ”1”.
Note that s0 and s1 are mutually exclusive and exhaustive.

Probability of generating s1 is given by P (s1 ) = P1 and probability of gener-


ating s0 is given by P (s0 ) = P0 . Hence, P1 and P2 are the prior probabilities.
Assume the channel is binary symmetric channel as illustrated as below with
p being probability of error or probability of flipping.

If r is the event corresponding to receiving ”1” and r̃ is the event correspond-


ing to receiving ”0”, then the likelihoods are given by,
P (r|s0 ) = P (r̃|s1 ) = 1 − p P (r|s1 ) = P (r̃|s0 ) = p

41
Using Bayes theorem, the aposteriori probabilities of the transmitted symbol
given the received symbol can be calculated.

Consider the aposteriori probabilities given that 1 was received i.e r has
occurred.
P (s0 )P (r|s0 ) P0 (1 − p)
P (s0 |r) = =
P (s0 )P (r|s0 ) + P (s1 )P (r|s1 ) P0 (1 − p) + P1 p

P (s1 )P (r|s1 ) P1 p
P (s1 |r) = =
P (s0 )P (r|s0 ) + P (s1 )P (r|s1 ) P0 (1 − p) + P1 p
MAP rule states that, choose the symbol with maximum aposteriori proba-
bility. Meaning in the above case, if P (s0 |r) > P (s1 |r), then choose s0 and
if P (s1 |r) > P (s0 |r), then choose s1 .

Similarly, consider the aposteriori probabilities given that 0 was received i.e
r̃ has occurred.
P (s0 )P (r̃|s0 ) P0 p
P (s0 |r̃) = =
P (s0 )P (r̃|s0 ) + P (s1 )P (r̃|s1 ) P0 p + P1 (1 − p)

P (s1 )P (r̃|s1 ) P1 (1 − p)
P (s0 |r̃) = =
P (s0 )P (r̃|s0 ) + P (s1 )P (r̃|s1 ) P0 p + P1 (1 − p)
Here if P (s0 |r̃) > P (s1 |r̃), then choose s0 and if P (s1 |r̃) > P (s0 |r̃), then
choose s1 .

Therefore if a receiver operates on MAP rule, the decision is taken by com-


paring the aposteriori probabilities.

The optimal receiver is the one that operates on MAP Rule since it mini-
mizes the probability of error.

3.1.7 Maximum Likelyhood (ML) Rule


If the decision is taken based on likelihoods rather than aposteriori probabil-
ities, then the receiver is said to operate on maximum likelihood rule.
ML rule states that, choose the symbol with maximum likelihood.

42
Note that the MAP rule reduces to ML rule if the symbols are equiprobable
i.e if P (s1 ) = P (s0 ) = P .
Therefore, if the probability of generation of 0 and 1 are the same (0.5 since
they are mutually exclusive and exhaustive), then the decision taken by ML
rule and MAP rule will be exactly the same.
• Received symbol is r:
– P (r|s0 ) > P (r|s1 ) or 1 − p > p; choose s0
– P (r|s1 ) > P (r|s0 ) or p > 1 − p; choose s1
• Received symbol is r̃:
– P (r̃|s0 ) > P (r̃|s1 ) or p > 1 − p; choose s0
– P (r̃|s1 ) > P (r̃|s0 ) or 1 − p > p; choose s1

3.2 Base Band Modulation


Message signals that occur naturally are analog in nature. In a digital com-
munication system, the analog message signals need to be digitized using
some modulation techniques before being transmitted.

43
3.2.1 Sampling
Sampling is the process of converting an analog signal to discrete signal.

The process of sampling has been discussed from time domain point of view
in Signals. Here, sampling from the frequency domain perspective is elabo-
rated in detail.

Sampling period, Ts is the time duration at which samples of the continuous


signal are taken. Sampling frequency is given by fs = 1/Ts .

Let x(t) be a continuous time signal and X(f ) be its Fourier Transform.
A band-limited signal is a signal which is zero outside a specific range of
frequencies.

• Low pass signal : X(f ) = 0 : f > |W |

• Band pass signal : X(f ) = 0 : |W1 | < f < |W2 |

Consider x(t) to be low pass signal for now.


Nyquist Rate is the sampling rate/frequency which is equal to twice the
maximum frequency of the signal. =⇒ fs = 2W .

The figure shown below represent the original spectrum (a) and the spectra
obtained after sampling above Nyquist rate (b), at Nyquist rate (c) and below
Nyquist rate (d).
It can be observed that there will be loss of higher frequency components if
sampled at a rate lower than the Nyquist rate. This phenomenon is called
”Aliasing”.

In the other two cases, there is no loss of any information as the original
spectrum has just repeated itself. And hence, it can be recovered by simply
using a filter with cut-off frequency W and gain Ts .

The expression for spectrum of the sampled signal is obtained as,



X ∞
X
Xs (f ) = X(f ) ∗ fs δ(f − kfs ) = fs X(f − kfs )
k=−∞ k=−∞

44
The transfer function of the required ideal filter is given by,
(
Ts : f ≤ W
H(f ) =
0 :f >W

Obviously this is a rectangular function, and its inverse Fourier transform


will give the impulse response of the required filter.
 
sin(πfs t)
=⇒ h(t) = sinc(fs t) =
πfs t

The recovered signal xr (t) is given by,



X ∞
X
xr (t) = xs (t)∗h(t) = x(kTs )δ(t−kTs ) ∗ sinc(fs t) = x(kTs ) sinc(fs (t−kTs ))
k=−∞ k=−∞

Practically, sampling through impulses can’t be done since impulse function


does not actually exist. Hence, flat top sampling is generally employed.

45
Here, a train of periodic pulses of duration T and period Ts is multiplied
with the message signal. This is generally done using a ”sample and hold
circuit”.

This process is also called ”Pulse Amplitude Modulation” and the signal
obtained is the PAM signal.

X
xp (t) = x(kTs )p(t − kTs )
k=−∞

where p(t) is a simple pulse signal given by,


(
1 :0<t<T
p(t) =
0 : T < t < Ts

3.2.2 Quantization
Quantization is the process of converting a discrete signal to quantized signal.

Meaning, a few discrete levels are defined and the amplitudes of the discrete
samples are mapped to the nearest levels, so that the discrete samples can
take only finite number of predefined values which can be encoded in a finite
number of bits.

Uniform Quantization is the simplest form of quantization where the differ-


ence between two consecutive levels is constant and is denoted by ∆.
Quantization levels are the midpoints of the intervals. Hence, a sample value
which lies in a particular interval is mapped to its midpoint.

Mid-Tread Quantization:
The number of quantization levels are odd. Hence, the midpoint of the input-
output characteristics will be horizontal.

Mid-Rise Quantization:
The number of quantization levels are even. Hence, the midpoint of the
input-output characteristics will be vertical.

46
The dynamic range of a discrete signal is the range of values/amplitudes the
signal can take.
Hence, the dynamic range is given by [−Vmin , Vmax ].
Usually this is assumed to be symmetric, so in that case, the range will be
[−Vm , Vm ] and the length of the dynamic range is Vm − (−Vm ) = 2Vm .

Hence, the number of quantization levels is given by,


Vmax − (−Vmin ) 2Vm
L= = .
∆ ∆
Since quantization is a process of approximating the actual amplitude to the
nearest fixed amplitude level, there is bound to be loss of information or error.

Quantization error/noise, Qe is the difference between the actual value


of a sample and the quantized value.
For a uniform quantizer, the maximum value that Qe can take is ∆/2.

Note that all quantization need not be uniform. Quantization can be cus-
tomized to have any number of levels, any step size and any number in each
step can be the mapped value (instead of midpoint).

3.2.3 Pulse Code Modulation


The process of converting a quantized signal to encoded digital signal is called
”Pulse Code Modulation”.

47
If L is the number of quantization levels and n is the number of bits necessary
to encode the quantized signal (also termed as the ”resolution”), n can be
found using the relation L = 2n (where n is an integer).

This means n bits can be used to encode upto L = 2n levels and hence, n
bits can naturally be used to encode any number of levels less than 2n , so it
is not necessary that all combinations of bits have to be used.

The Quantization noise can be considered as a uniform distribution in the


range (−∆/2, ∆/2).
Hence, Quantization noise power (Q) is given by expectation of square of the
uniform distribution. =⇒ Q = ∆2 /12

The signal power can be calculated based on the nature of input signal.
If the input signal is sinusoidal, then the signal power (P ) is given by A2m /2
where Am is peak amplitude. In this case, the dynamic range of the quantizer
can be approximated as 2Am .
=⇒ P = A2m /2 and ∆ = 2Am /2n .

The Signal to Noise Ratio (SNR) is the ratio of signal power to quantization
noise power. SN R = P/Q =⇒ SN R = 6A2m /∆2 = 3(22n−1 )

Expressing the same in dB,


SN R = 1.8 + 6n dB
Note that this will vary if the input signal is not sinusoidal.

Another important observation is that the signal to noise ratio increases by


6 dB for 1 bit increase in the resolution.

Since there are n bits for every period Ts , the duration of each bit is given
by Tb = Ts /n.
Hence, the bit rate is Rb = 1/Tb .

Maximum bandwidth required is equal to the bit rate.


Minimum bandwidth required is equal to half the bit rate.

48
=⇒ Increasing quantization levels for more accuracy will reduce error but
will increase bandwidth.

Note that the above expressions and methods for calculating SNR are valid
if the input signal is deterministic and uniform quantization is used.

Random Signal and Arbitrary Quantization Scheme:

Consider the case where input signal is a random signal X(t) which follows
some distribution fX (x).
The signal power is calculated using:
Z ∞
2
S = E[X (t)] = X 2 (t)fX (x)dx
−∞

Consider the case where quantization is non-uniform, with mapped values


given by xq for different intervals. The quantization error in general will be
X(t) − xq .
The quantization noise is calculated using:
Z ∞
2
N = E[(X(t) − xq ) ] = (X(t) − xq )2 fX (x)dx
−∞

For illustration, assume that 3 quantization intervals are defined between


intervals l1 to l2 , l2 to l3 and l3 to l4 and these intervals are mapped to levels
xq1 , xq2 , xq3 respectively.
Z l2 Z l3 Z l4
2 2
N= (X(t)−xq1 ) fX (x)dx+ (X(t)−xq2 ) fX (x)dx+ (X(t)−xq3 )2 fX (x)dx
l1 l2 l3

This method works for uniform quantization as well, so it is the general pro-
cedure to find the quantization noise given any quantization scheme.

Differential Pulse Code Modulation


DPCM is a modified version of PCM where instead of directly encoding the
quantized samples, the difference between consecutive samples is quantized.
This can potentially decrease the dynamic range, which will decrease the
quantization error without changing the bandwidth.

49
3.2.4 Delta Modulation
A modified version of DPCM where only 2 quantization levels exist. Hence,
it is also called 1-bit DPCM.

• If difference between current and previous samples is positive, then ∆


is added.

• If difference between current and previous samples is negative, then


−∆ is added.

Since n = 1, Tb = Ts and Rb = 1/Ts = fs .


Therefore, the bandwidth has decreased from previous schemes.

Delta Modulation works very well if the correlation between samples is high
i.e the samples are not changing rapidly.

There are however, 2 problems that are encountered in Delta modulation.

Granular Noise Distortion occurs if ∆ value is too large and hence slight
variations in the output is causing unnecessary ups and downs in modulated
signal.

Slope Overload Distortion occurs if ∆ value is too small and hence the
modulator will be unable to track rapid changes in the original signal.

It can be observed that there will be a trade-off in performance with respect


to the above two problems. Hence, an optimal value for ∆ has to be found.

50
dm(t)
∆opt fs =
dt max

• ∆ fs << |m0 (t)| Will result in slope overload


• ∆ fs >> |m0 (t)| Will result in granular noise

3.3 Time Division Multiplexing


Time division multiplexing (TDM) is a method of transmitting and receiv-
ing independent signals over a common signal path by means of synchronized
switches at each end so that each signal appears in an alternating pattern.

If M is the number of message signals, n is the number of encoding bits, fs


is sampling frequency and Ts (= 1/fs ) is the sampling period, the bit rate
necessary for synchronization is given by:
M n
Rb = = M n fs
Ts
Overhead bits are usually added for marking/indication. If a extra bits are
added, then
M n+a
Rb = = (M n + a) fs
Ts
The above formulae work only when the multiple signals are band-limited to
the same frequency.
If the signals are band-limited to different frequencies, then TDM can be
achieved using 2 different methods. For example, consider message signals
are band-limited to fm , 2fm and 3fm .

51
• Choose sampling rate to be twice the maximum frequency among the
messages i.e fs = 2fmax .
Ex: fs = 6fm . =⇒ Rb = 6fm × 3 × n

• Divide the higher frequency signal into multiple lower frequency signals
by feeding the same signal into the commutator multiple times. This
will work if the frequencies present are integral multiples of the lowest
frequency.
Ex: fs = 3fm ; feed the second signals twice, the third signal thrice. So
total number of signals will be 6. =⇒ Rb = 3fm × 6 × n

3.4 Band Pass Data Transmission


Digital signals (like PCM or DM signals) need to be modulation with high
frequency carriers before transmission.
This is done using Digital Carrier Modulation techniques, which converts the
base band digital signals to band pass digital signals of high frequency.

3.4.1 Signal Space


The signal space is a framework to better understand and design band-pass
transmission of digital signals.

Consider two pulses p1 (t) and p2 (t) that are orthogonal to each other i.e
Z ∞
p1 (t) p2 (t) dt = 0
−∞

Also, let the energy of both the pulses be equal to unity i.e
Z ∞ Z ∞
2
|p1 (t)| dt = |p2 (t)|2 dt = 1
−∞ −∞

Here, p1 (t) and p2 (t) are called ”Orthonormal basis functions”.


A signal space consists of all linear combinations of the pulses p1 (t) and p2 (t).

Example for orthonormal basis functions of a signal space:


r
2
p1 (t) = cos(2πf1 t) : 0 < t < T
T

52
r
2
p2 (t) = sin(2πf2 t) : 0 < t < T
T
where f1 and f2 are integral multiples of same fundamental frequency f0

T is the symbol duration such that integer number of cycles of f1 and f2


occur in the duration i.e. T = k1 /f1 = k2 /f2 where k1 and k2 are integers.

The signal space is mainly used to draw the constellation diagram, which
is a plot of the symbols to be transmitted using the orthonormal basis func-
tions as the axes.

The probability of error will vary inversely with the change is distance be-
tween the symbols as represented in the signal space constellation diagram.

3.4.2 Amplitude Shift Keying


Binary data is represented using on-off (unipolar NRZ) signaling. Hence it
is also called ”on-off keying” (OOK).

The digital message signal a which is +Aq for ”1” or 0 for ”0” is simply
multiplied with the carrier pulse p(t) = T2 cos (2πfc t) which lasts for the
duration 0 < t < T such that T = k/fc (k is an integer).

Note that the carrier is normalized to unit energy (i.e Ep = 1).


( q
s1 = A T2 cos (2πfc t) : a = 1
s(t) =
s2 = 0 :a=0
Energy of bit if s1 occurs is A2 and energy of bit if s2 occurs is 0.
If s1 and s2 are equally likely to occur, then the average energy per bit is
give by,
A2 p
Eb = ; A = 2Eb
2
Hence the modified expression of ASK modulated signal is given by,
( q
s1 = 4E T
b
cos (2πfc t) : a = 1
s(t) =
s2 = 0 :a=0

53
The bandwidth of the base-band polar NRZ pulse is 1/T but now since it
is modulated to be a pass-band signal, the bandwidth of ASK modulated
signal will be 2/T .

Difference energy is given by,

Ed = Eb + 0 − 2(0) = Eb

Assuming AWGN channel, the received symbol will be r(t) = s(t) + n(t),
which will be sampled at t = T . In detection of ASK modulated signal using
matched filter receiver and threshold decision device, the optimal threshold
will be A/2.
• r(T ) > A/2 =⇒ : a = 1

• r(T ) < A/2 =⇒ : a = 0


The probability of error in ASK detection is given by,
r 
Eb
Pe = Q
2N0

3.4.3 Frequency Shift Keying


Binary data is represented using polar non-return to zero signaling.
Two carriers of different frequencies are generated.

54
f1 = fc + Kf V → Mark Frequency
f2 = fc − Kf V → Space Frequency

Note that here, f1 = k1 /T and f2 = k2 /T where T is the bit duration and


k1 , k2 are integers.

For orthogonality of the two carriers, the constraint that must be satisfied is:
kRb k
f1 − f2 = =
2 2Tb
where k is an integer.

Since the minimum value k can take is 1, the FSK system where
f1 − f2 = Rb /2 is known as ”Minimum Shift Keying” (MSK).

The binary data a represented in polar NRZ form is multiplied to one of the
two carriers depending on its value, which is done using Voltage Controlled
Oscillator (VCO).

 q
s1 = A 2 cos (2πf1 t) : a = 1
s(t) = qT
s2 = A 2 cos (2πf2 t) : a = 0
T

Energy of bit if s1 occurs is A2 and energy of bit if s2 occurs is also A2 .


If s1 and s2 are equally likely to occur, then the average energy per bit is
give by,

A2 A2 p
Eb = + = A2 ; A= 2Eb
2 2
Hence the modified expression of FSK modulated signal is given by,
 q
s1 = 2Eb cos (2πf1 t) : a = 1
s(t) = q T
s = 2Eb cos (2πf t) : a = 0
2 T 2

55
Bandwidth of FSK modulated signal is f1 − f2 + 2/T or (k1 − k2 + 2)/T .

Difference energy is given by,

Ed = Eb + Eb − 2(0) = 2Eb

Assuming AWGN channel, the received symbol will be r(t) = s(t) + n(t),
which will be sampled at t = T . In detection of FSK modulated signal using
matched filter receiver and threshold decision device, the decision has to be
taking by measuring the frequency instead of amplitude.

• r(T ) > fc =⇒ : a = 1

• r(T ) < fc =⇒ : a = 0

The probability of error in FSK detection is given by,


r  r 
2Eb Eb
Pe = Q =Q
2N0 N0

Note that the bandwidth needed for FSK is higher when compared to ASK
but since the symbols are place further apart, the probability of error will be
reduced.

56
3.4.4 Binary Phase Shift Keying
Binary data is represented using polar non-return to zero signaling.
The digital message signal a which is +A qfor ”1” or −A for ”0” is simply
multiplied with the carrier pulse p(t) = T2 cos (2πfc t) which lasts for the
duration 0 < t < T such that T = k/fc (k is an integer).

Note that the carrier is normalized to unit energy (i.e Ep = 1).


 q
s1 = A 2 cos (2πfc t) : b(t) = 1
T
s(t) = q
s2 = −A 2 cos (2πfc t) : b(t) = 0
T

Energy of bit if s1 occurs is A2 and energy of bit if s2 occurs is also A2 .


If s1 and s2 are equally likely to occur, then the average energy per bit is
give by,
A2 A2 p
Eb = + = A2 ; A = Eb
2 2
Hence, the modified expression of BPSK modulated signal is give by,
 q
s1 = 2Eb cos (2πfc t) :a=1
=⇒ s(t) = qT
s = − 2Eb cos (2πf t) : a = 0
2 T c

Since cos(x + π) = − cos(π), it can be noted that the transmitted wave-forms


for ”1” and ”0” are phase shifted by 180o .

57
The bandwidth of the base-band polar NRZ pulse is 1/T but now since it
is modulated to be a pass-band signal, the bandwidth of BPSK modulated
signal will be 2/T .

Difference energy is given by,

Ed = Eb + Eb − (−2Eb ) = 4Eb

Assuming AWGN channel, the received symbol will be r(t) = s(t) + n(t),
which will be sampled at t = T . In detection of BPSK modulated signal using
matched filter receiver and threshold decision device, the optimal threshold
amplitude will be 0.

• r(T ) > 0 =⇒ : a = 1

• r(T ) < 0 =⇒ : a = 0

The probability of error in BPSK detection is given by,


r  r 
4Eb 2Eb
Pe = Q =Q
2N0 N0

Note that the bandwidth required for BPSK is same ASK (and hence lower
than FSK) and since the symbols are place further apart, the probability of
error will less than both the previous schemes.

3.4.5 Differential Phase Shift Keying


The disadvantage of BPSK is that it requires the carrier used in demodula-
tion need to be phase synchronized with the carrier used in demodulation.

If the carriers are out of phase, then quadrature nulling can occur and distort
the original signal.
DPSK is a scheme designed so that no carrier is necessary at the receiver
end, hence quadrature nulling effect is eliminated entirely.

DPSK modulator is shown in the figure below.

58
Reference signal for the first XNOR operation is generally taken as 1.

Hence, the basic working is as follows:


• Previous bit is 0 =⇒ Complement current bit

• Previous bit is 1 =⇒ Retain current bit

DPSK demodulator is shown in the figure below.

59
3.4.6 Quadrature Phase Shift Keying
QPSK is a simple case of using quadrature carrier multiplexing technique.
The binary data is represented using 2 bits (n = 2) and 4 levels (M = 4).
q
Let the two orthogonal carrier pulses be p1 (t) = T2 cos(2πfc t) and p2 (t) =
q
2
T
sin(2πfc t). Note that these two are normalized to unit energy, hence
they form an orthonormal basis for a signal space.

A linear combination of the two carriers is given by s(t) = a1 p1 (t) + a2 p2 (t).


If binary data (i.e the messages a1 and a2 ) can take values A or −A, then
the possible combinations of transmitted signals are,
 q q
2 2


 s 1 = A T
cos(2πfc t) + A T
sin(2πfc t)

 q q
s2 = A 2 cos(2πfc t) − A 2 sin(2πfc t)

T T
s(t) = q q


 s3 = −A T cos(2πfc t) + A T2 sin(2πfc t)
2

 q q
s = −A 2 cos(2πf t) − A 2 sin(2πf t)

4 T c T c

Hence, there will be 4 distinct symbols to transmit using only 2 carriers.


Upon simplifying the above expressions, the modified QPSK wave-forms are
obtained as:


2A

 s1 = √
T
cos (2πfc t − 45o ) : a1 a2 = 11

2A
cos (2πfc t + 45o )

s
2 = √
T
: a1 a2 = 10
s(t) = 2A o


 s3 = √
T
cos (2πfc t + 135 ) : a1 a2 = 01
2A
cos (2πfc t + 225o ) : a1 a2 = 00

s
4 = √
T

The phase shift between each of the successive symbols is 90o .

The waveform illustrates the phase shifted cosine signal as per the QPSK
scheme given.

60
For receiving the QPSK signal, two matched filters have to be used i.e one
corresponding to each carrier.

h1 (t) is used for s1 (t) and optimal decision boundary is 0 to determine is the
message sent with p1 (t) i.e a1 is +A or −A. Similarly, h2 (t) is used for s2 (t)
and optimal decision boundary is 0 to determine is the message sent with
p2 (t) i.e a2 is +A or −A.

Now the received symbol has error if error has occurred in detection of either
a1 or a2 or both.

Since the scheme is phase shift keying, the probability of error in detection
of a1 or a2 is,
r 
2Eb
Pe1 = Pe2 = Q
N0

Overall probability of error is,


Pe = Pe1 (1 − Pe2 ) + Pe2 (1 − Pe1 ) + (1 − Pe1 )(1 − Pe2 ) = 1 − (1 − Pe1 )2
r  r 
2Eb 2 2Eb
=⇒ Pe = 2Q −Q
N0 N0

Since Pe1 << 1, the square term will be even smaller and can usually be
neglected.
r 
2Eb
∴ Pe ≈ 2Q
N0

61
3.4.7 M-ary Pulse Amplitude Modulation
So far, all the schemes studied were binary i.e a pulse could take one of two
values (except for QPSK).
In M-ary schemes, a pulse can take one of M distinct values. Hence, the
number of bits per symbol (level) if M levels are present is n = log2 M .

If the transmitted symbol is generalized as s(t) = ap(t), then a = ±(2i + 1)A


where i = 0, 1, 2, ... M2 − 1 and 2A is the spacing between two consecutive
levels.

Average symbol energy is given by,


M
2
−1
2 X A2
Es = (2i + 1)2 A2 = (M 2 − 1)
M i=0 3
r
3Es
=⇒ A =
M2 − 1
The constellation diagram of M-ary PAM scheme with M = 8 is illustrated
below.

At the receiver end, decision device follows nearest neighbor decision rule.
For example in the above scenario:

• r(T ) < −6A : =⇒ a = −7A

• −6A < r(T ) < −4A : =⇒ a = −5A

• −4A < r(T ) < −2A : =⇒ a = −3A

• −2A < r(T ) < 0 : =⇒ a = −A

• 0 < r(T ) < 2A : =⇒ a = A

• 2A < r(T ) < 4A : =⇒ a = 3A

62
• 4A < r(T ) < 6A : =⇒ a = 5A

• r(T ) > 6A : =⇒ a = 7A
Assuming AWGN channel and matched filter receiver, the probability can be
calculated as follows.
Consider the message signal a = A (or any intermediate level). Then the
received signal will be r(T ) = s + ñ. Now if r(T ) is less than 0 or greater
than 2A, there will be an error in detection.

Pe1 = P (r(T ) > 2A)+P (r(T ) < 0) = P (ñ > A)+P (ñ < −A) = 2P (ñ < A)

Hence, probability of error in receiving an intermediate level is give by,


s 2   
A A
=⇒ Pe1 = 2Q = 2Q
N0 /2 σ

Now consider the message signal a = 7A (or a = −7A i.e an end point).
Then the received signal will be r(T ) = s + ñ. Now if r(T ) greater than 7A
only there will be an error in detection.

Pe2 = P (r(T ) > 7A) = P (ñ > A)

Hence, probability of error in receiving the first or last level is give by,
s 2   
A A
=⇒ Pe2 = Q =Q
N0 /2 σ

Assuming all M levels occur at equal probabilities of 1/M , since there are
M − 2 intermediate levels and 2 end levels, the average probability of error
will be,
   
M −2 A 2 A
Pe = 2Q + Q
M σ M σ
Upon simplifying and substituting for A and σ,
s 
1 6Es
∴ Pe = 2 1 − Q
M N0 (M 2 − 1)

63
3.4.8 M-ary Quadrature Amplitude Modulation

M-ary QAM is a scheme which uses two M-ary PAM signals with two or-
thogonal carrier pulses.
The number of bits required transmitted per symbol is again, n = log2 M .

The transmitted symbol


√ is generalized as s(t) = a1 p1 (t)+a2 p2 (t), where both
a1 and a2 can take M levels. √
a1 = ±(2i + 1)A where i = 0, 1, 2... √2M − 1
a2 = ±(2j + 1)A where j = 0, 1, 2... 2M − 1
2A is the spacing between two consecutive levels.

Average symbol √ energy of M-ary QAM is Es and since it consists of two


independent M-ary PAM signals, the average symbol energy of each PAM
signal is Es /2.
s
Es A2 3Es
= (M − 1) ; =⇒ A =
2 3 2(M − 1)

Since M-QAM is orthogonal combination of M-PAM, the constellation di-
agram will have a square structure in the signal space formed by the two
orthonormal pulses.

64
The M-QAM signal has to be received using two matched filters (similar to
QPSK) since there are two different pulses.

h1 (t) is used for receiving a1 p1 (t), which is sampled and nearest neighbor
decision rule is applied on r2 (T ) to get a1 .
Similarly, h2 (t) is used for receiving a2 p2 (t), which is sampled and nearest
neighbor decision rule is applied on r2 (T ) to get a2 .

Now the received symbol has error if error has occurred in detection of either
a1 or a2 or both. √
Since the individual scheme is M-PAM, the probability of error in detection
of a1 or a2 is,
s 
1  3Es
Pe1 = Pe2 = 2 1 − √ Q
M N0 (M − 1)

Overall probability of error is, Pe = 1 − (1 − Pe1 )2 = 2Pe1 − Pe1


2

Since Pe1 << 1, the square term will be even smaller and can usually be
neglected.

s 
1  3Es
∴ Pe ≈ 4 1 − √ Q
M N0 (M − 1)

3.4.9 M-ary Phase Shift Keying


M-ary PSK is a more general scheme of BPSK which modulates M sym-
bols by differentiating each of them using M phases (as opposed to just 2 in
BPSK).
The number of bits per symbol is obviously n = log2 M .

Each symbol is modulated at a phase of 2πi/M where i = 0, 1..M − 1.

For example, consider 8 − P SK i.e M = 8.


The phases at which each of the symbols are modulated are 0, π4 , π2 , 3π
4
, π, 5π
4
, 3π
2
, 7π
4
, 2π.

It can easily be observed that in this scheme, the signal constellation dia-
gram takes a circular shape since all the symbols are separated only by phase

65
difference and hence they are equidistant from the origin of the signal space.

Optimal decision rule is selecting the symbol in the constellation diagram


with the least distance from the received symbol.

Average energy per symbol is Es = A2 . Hence, A = Es .

Probability of error is calculated by using an approximate formula which is


obtained using number of nearest neighbors and minimum distance.
Here, each signal in the signal space diagram has α = 2 nearest neighbors
separated by dmin .
The minimum distance can be calculated using basic geometry as,
p π
dmin = 2 Es sin
M
The probability of error is given by,
s
2Es sin2 π
    
dmin M
Pe = α Q √ =2Q
2N0 N0

66
Some general results:

• Given a constellation diagram of an arbitrary scheme, the average en-


ergy per bit can be found as follows.

1. Find the total energy per symbol by finding the square of the
distance from each symbol to origin and adding them all up.
2. If the symbols are equiprobable, then the average energy is the
total energy divided by number of symbols.
3. If the symbols occur with certain given
P probabilities, then the
average energy is given by Eave = i pi Ei (where i represents
each symbol).

• Two schemes having different constellation diagrams have the same


probability of error if the minimum distance between adjacent points
are equal.
Higher the minimum distance, lower the probability of error.

67
3.5 Inter Symbol Interference
If a pulse is limited to a finite time interval, then in reality the bandwidth
occupied by it will be infinite (though 95% of the power will be present within
major lobe).
Similarly, if a pulse is band-limited to a certain range of frequencies, it can’t
be time limited i.e its time response will be non-zero for all time.

Spreading of a pulse beyond its allocated time interval will cause it to in-
terfere with neighbouring pulses. This phenomenon is called ”Inter symbol
interference” (ISI).

ISI can’t be avoided completely since time-limited pulse are not band-limited
and band-limited pulse are not time-limited.
However, pulse amplitude can be detected correctly despite this by properly
shaping the pulse.

3.5.1 Nyquist Pulse Shaping Criteria


Zero ISI can be achieved by using a pulse shape that has a non-zero amplitude
at its center (t = 0) and zero amplitudes at t = nTb where Tb is the separation
between successive pulses and n = 1, 2, 3....
(
1 :t=0
p(t) =
0 : t = nTb

If the duration is Tb , then the bit-rate will be Rb = 1/Tb , which means mini-
mum transmission bandwidth is Rb /2.

The only pulse p(t) that will satisfy the Nyquist criterion and has bandwidth
Rb /2 is the sinc function i.e,
 
1 f
p(t) = sinc(πRb t) ←→ P (f ) = rect
Rb Rb

68
The reason why it works is because addition of time shifted versions of the
sinc pulse will note interfere with itself at integral multiples of Tb as illustrated
below.

Since the sinc function decays as 1/t, it is too slow and hence is not very
practical to use because even slight jitters might cause ISI.
In order to obtain a pulse that decays much faster the sharp transition edge
of the rectangular spectrum has to be smoothed.
Hence, making the signal decay faster comes at the expense of extra band-
width.

If the excess bandwidth required is fx and α is the roll-off factor of the


smoothed spectrum (beyond 0.5Rb ), the relation between them is given by,
fx
α= = 2fx T b
0.5Rb
fx has to be less than 0.5Rb and hence 0 < α < 1.

The new overall bandwidth required to transmit the reshaped pulse will be
(1 + α)Rb
BW = 0.5 Rb + fx =
2
The spectrum of the shaped signal is called Raised Cosine Spectrum.

69
The sinc pulse obtained after smoothening the transition band in the spec-
trum for few standard roll-off rates are illustrated.

Note that for maximum value of α i.e 1, the sinc pulse decays almost instan-
taneously and the signal is pretty much non-existent outside the major lobe,
which makes it desirable.

The signal bandwidth of any arbitrary M -ary scheme for different types of
pulses can be generalized as follows.
• If rectangular pulses are used, signal bandwidth is given by
2Rb
BW =
log2 M

• If sinc pulses are used, signal bandwidth is given by


Rb
BW =
log2 M

• If raised cosine pulses are used, signal bandwidth is given by


Rb (1 + α)
BW =
log2 M

70
Bandwidth efficiency or Spectral efficiency is the ratio of the bit-rate
to the signal bandwidth. Hence, it specifies the number of bits that can be
transmitted per second in 1 Hz of bandwidth usage.
Rb
=⇒ ηs =
BW
• Rectangular pulse : ηs = 0.5 log2 M

• Sinc pulse : ηs = log2 M


log2 M
• Raised cosine pulse : ηs = 1+α

If the type of pulse is not specified, sinc pulse is to be considered as the


default since it gives highest spectral efficiency.

3.5.2 Raised Cosine Filter


The raised cosine filter is the filter used to shape a pulse in such a way that
the raised cosine spectrum i.e one which satisfies the Nyquist criterion is
obtained.
One such practical filter that realizes this has frequency response as follows.

1  : f < 0.5Rb − fx



 
Hrc (f ) = 0.5 1 − sin π f −0.5R b)

2f x
: 0.5Rb − fx < f < 0.5Rb + fx



0 : f > 0.5Rb + fx

If the filter has such a frequency response, it will shape the signal such that
Nyquist criterion is obeyed and hence zero ISI transmission is achieved.

However practical communications systems since a matched filter is used in


the receiver, for zero ISI, it is the net response of the transmit and receive
filters that must give the frequency response of the raised cosine filter Hrc (f ).
=⇒ Hrc (f ) = HR (f ) Hp T (f )
∴ |HR (f )| = |HT (f )| = |Hrc (f )|
p
These filters with the response |Hrc (f )| are called ”Root Raised Cosine
Filters”.

71
4 Information Theory
Information theory studies the quantification, storage, and communication
of digital information.

As noted before, a message signal produced is encoded into a stream of bits


hence producing a binary signal, which is used in digital communication
systems.
Information theory deals with various schemes of encoding a message signal,
quantifying different schemes in order to figure out how to maximize the
information content per bit or minimize probability of error or minimize
bandwidth usage, etc.

4.1 Characterizing Information


An information source can either be digital or analog. But usually analog
information is converted to digital information anyway.

A digital source sequentially produces symbols from a given finite set of sym-
bols. For example, S set of M symbols: S = [s0 , s1 , s2 , ...sM −1 ].

The source will generate symbols based on a probability distribution function.


Meaning, each of the discrete symbols is generated with some probability.
Hence, s0 is generated with probability p0 , s1 is generated with probability
p1 and so on.
(note that p0 + p1 + ... + pM −1 = 1)

It is generally assumed that the generation of symbols are uncorrelated and


generation of a symbol is independent of what is going to be generated next
or what has already been generated.

The information content in a symbol is characterized as follows:


 
1
Isi = log2
pi

where Isi is the information of symbol si and pi is the probability of occur-


rence of the symbol

72
Information content is measured in bits.

The above quantification of information says that symbols (or events) that
have high probability of occurrence carry less information and symbols (or
events) that have low probability of occurrence carry high information.

4.1.1 Entropy
Entropy of a digital source S is defined as the expected value of information
or the average information content present in the source. H(S) = E[I(S)]

M −1
X 1
=⇒ H(S) = pi log2
i=0
pi

Note that the entropy is a sum of non-negative terms, hence H(S) ≥ 0 and
it is measured in bits/symbol.

1

If pi = 1, then log2 pi 
=0
1
If pi = 0, then log2 pi
= 0 (use L-Hospital’s rule to evaluate limit)

Another property of entropy is : H(S n ) = nH(S).

Consider a binary information source S = [s0 , s1 ] where probability of occur-


rence of s0 is p and probability of occurrence of s1 is 1 − p.
Entropy of the binary source is given by,
1 1 
H(S) = p log2 + (1 − p) log2
p 1−p

Note at as p → 0 or as p → 1, the value of H(s) → 0.

This is because if p = 0, then the source will always generate s0 and if p = 1,


the source will always generate s1 and hence in either case there is no average
information content.

The maximum value of entropy H(S) can be obtained by differentiating it


w.r.t p and equating to 0. This will show that H(S)max = 1 when p = 1 − p
i.e p = 0.5.

73
Therefore, the entropy is maximum when all the symbols are equally likely
to occur (this result can be extended to more than just binary sources).

In case of an analog information source S, the source has to be modelled such


that it takes values based on some probability distribution function. Hence,
S can be considered a random process and the value it takes is a random
variable that follows some distribution fS (x).

In this case, the entropy of the source is also called ”differential entropy” and
can be calculated as follows.
Z ∞  
1
H(S) = fS (x) log2 dx
−∞ fS (x)

4.1.2 Information Rate & Symbol Rate


The information rate of a source is the number of bits transmitted per second
and is denoted by R.

The symbol rate of a source is the number of symbols transmitted per sec-
ond and is denoted by r. Note that the number of symbols can also be the
number of quantization levels.

Since the entropy of the source (H) is the average information content, it
gives the average number of bits present in each symbol. Hence, the relation
between the average information, information rate and symbol rate is given
by R = H r.

74
4.1.3 Joint Entropy
Consider two sources X = [s0 , s1 , ..., sM −1 ] and Y = [r0 , r1 , ...rN −1 ].
A joint probability distribution can be obtained from the two sources.
pij = P (X = si ∩ Y = rj ) = P (si , rj )

The joint entropy of the two sources X and Y is given by,


M −1 N −1   M −1 N −1  
X X 1 X X 1
H(X, Y ) = pij log2 = P (si , rj ) log2
i=0 j=0
pij i=0 j=0
P (si , rj )

Some useful relations in the joint distribution:


M
X −1 N
X −1
→ P (si , rj ) = 1
i=0 j=0
M
X −1
→ P (X = si ∩ Y = ra ) = P (Y = ra )
i=0
N
X −1
→ P (X = sb ∩ Y = rj ) = P (X = sb )
j=0

Probabilities P (X = sb ) and P (Y = ra ) are called ”Marginal Probabilities”.

The entropies of individual sources i.e H(X) and H(Y ) can be calculated
from the usual entropy formula using the marginal probabilities.

Properties of joint entropy:

• The joint entropy of two sources is always greater than or equal to the
individual entropies of the two sources.
=⇒ H(X, Y ) ≥ H(X); H(X, Y ) ≥ H(Y )

• The joint entropy of two sources is always lesser than or equal to the
sum of individual entropies of the two sources.
=⇒ H(X, Y ) ≤ H(X) + H(Y )

The second property gives rise to Jensen’s inequality that says,


H(X, Y ) − H(X) − H(Y ) ≤ 0.

75
4.1.4 Conditional Entropy
Conditional entropy is the average information content present in one source,
given another source.
Consider two sources X having M symbols [s0 , s1 , ...sM −1 ] and Y having
N symbols [r0 , r1 , ...rN −1 ]. Then the conditional entropy on source Y given
source X is defined as,
M −1 N −1  
X X 1
H(Y |X) = P (si ) P (rj |si ) log2
i=0 j=0
P (rj |si )

By taking P (si ) inside the second summation and using P (si , rj ) = P (si )P (rj |si ),
the equation becomes
M −1 N −1  
X X 1
H(Y |X) = P (rj , si ) log2
i=0 j=0
P (rj |si )

Relation between Joint entropy and Conditional entropy:


• H(X, Y ) = H(Y |X) + H(X)

• H(X, Y ) = H(X|Y ) + H(Y )


From the above relations, it can be intuitively concluded that the conditional
entropy is the information content left in one source when the other source
has already been observed.

4.1.5 Mutual Information


Mutual information gives the common information content contained in two
different sources.

Consider two sources X and Y . The mutual information between the two
sources is given by,

I(X; Y ) = H(X) − H(X|Y ) = H(Y ) − H(Y |X)

Using the relations between joint and conditional entropies, mutual informa-
tion can also be expressed as, I(X; Y ) = H(X) + H(Y ) − H(X, Y ).

76
If X denotes the set of symbols transmitted through a channel and Y denotes
the set of symbols received from a channel, then mutual information can be
interpreted as the amount of information in X obtained after observing Y .

Ideally the value of I(X, Y ) has to be as large as possible since maximum


information has to obtained regarding X by observing Y .

Note that I(X; Y ) = I(Y ; X) and I(X; Y ) ≥ 0.

Consider a binary source X with s0 = 0 and s1 = 1 and let Y be the received


symbol with r0 = 0 and r1 = 1.
Let the probability of generation of s0 be α and hence the probability of
generation of s1 will be 1 − α.
Assume binary symmetric channel with flipping probabilities of p.
P (r0 |s0 ) = P (r1 |s1 ) = 1 − p P (r0 |s1 ) = P (r1 |s0 ) = p
The following notation will be used for convenience.
 
1 1
H(k) = k log2 + (1 − k) log2
k (1 − k)
Now the conditional entropy of Y given X can be calculated as,
H(Y |X) = P (s0 )H(Y |s0 ) + P (s1 )H(Y |s1 ) = αH(p) + (1 − α)H(p) = H(p)
To calculate mutual information, H(Y ) is necessary. It can be computed as,
H(Y ) = H(p + α − 2pα).
=⇒ I(X; Y ) = H(p + α − 2pα) − H(p)

77
4.1.6 Probability matrices
While performing calculations in information theory, it is convenient to rep-
resent the systems in matrix form.

Consider a system with source X having M symbols [s0 , s1 , ...sM −1 ] and


received symbols Y having N symbols [r0 , r1 , ...rN −1 ].

• The matrix [P (X)] is an M × 1 matrix consisting of probabilities of


occurrence of each of the source symbols in X.

• The matrix [P (Y )] is an N × 1 matrix consisting of probabilities of


occurrence of each of the received symbols in Y .

• The matrix [P (Y |X)] is an M × N matrix consisting of probabilities of


receiving a symbol of Y , given that a symbol in X is transmitted. This
is called the ”channel matrix” or the ”conditional probability matrix”.

– The sum of each row in a channel matrix is equal to 1.

• The matrix [P (X, Y )] is an M × N matrix consisting of probabilities


of a symbol transmitted from X being received as a symbol in Y . This
is called the ”joint probability matrix”.

– The individual probabilities of the source symbols i.e elements of


[P (X)] can be obtained by adding the corresponding row elements
of [P (X, Y )].
– The individual probabilities of the received symbols i.e elements
of [P (Y )] can be obtained by adding the corresponding column
elements of [P (X, Y )].

• The matrix [P (X|Y )] is an M × N matrix consisting of probabilities of


the transmitted symbol being a symbol in X provided that a symbol in
Y has been received. This is called the ”posterior probability matrix”.

– The sum of each column in a channel matrix is equal to 1.

The elements of joint matrix [P (X, Y )] are usually obtained by multiplying


corresponding elements of [P (X)] and [P (Y |X)] (because source probabili-
ties [P (X)] and channel matrix [P (Y |X)] are usually available data).

78
The elements of posterior probability matrix [P (X|Y )] (which are helpful
in MAP decoding) are obtained by dividing the elements of joint matrix
[P (Y |X)] with the corresponding received symbol probabilities from [P (Y )].

The entorpies can be obtained more clearly from these probability matrices.
H(X) is calculated from [P (X)]. H(Y ) is calculated from [P (Y )].

H(X, Y ) is calculated from P (X, Y ) i.e,


 
X 1
H(X, Y ) = P (X, Y ) log2
P (X, Y )
H(Y |X) is calculated as:
 
X 1
H(Y |X) = P (X, Y ) log2
P (Y |X)
H(X|Y ) is calculated as:
 
X 1
H(X|Y ) = P (X, Y ) log2
P (X|Y )
From the calculated entropies, mutual information I(X; Y ) can be obtained
using all the 3 formulae and verified. They must turn out to be equal.

4.1.7 Types of Channels


A binary channel is a channel that has 2 input symbols (say s0 and s1 ) and
2 output symbols (say r0 and r1 ).
• A binary channel is said to be symmetric if the flipping probabilities
(or probabilities of error) are the same i.e P (r1 |s0 ) = P (r0 |s1 ).
• A binary channel is said to be asymmetric if the flipping probabilities
(or probabilities of error) are the different i.e P (r1 |s0 ) 6= P (r0 |s1 ).
In general, there can be some special types of channels. They are:
1. Lossless channel:
A lossless channel is a channel such that for every received symbol,
there is no uncertainty in which symbol is transmitted i.e H(X|Y ) = 0
and hence I(X; Y ) = H(X).
In a lossless channel matrix P (Y |X), every column has only one non-
zero element.

79
2. Deterministic channel:
A deterministic channel is a channel such that for every transmit-
ted symbol, there is no uncertainty in which symbol is received i.e
H(Y |X) = 0 and hence I(X; Y ) = H(Y ).
In a deterministic channel matrix P (Y |X), every row has only one
non-zero element, which will be equal to 1.

3. Noiseless channel:
A noiseless channel is a channel that is both lossless and deterministic.
This means there will be certain one to one mapping between source
symbols and received symbols i.e H(Y |X) = H(X|Y ) = 0 and hence
I(X; Y ) = H(X) = H(Y ).
The noiseless channel matrix P (Y |X) is an identity matrix.

4. Useless channel:
A useless channel is a channel which has 0 mutual information and
hence 0 channel capacity (more on channel capacity to be explained).

4.2 Channel Capacity


Channel capacity is defined as the maximum rate at which information can
be transmitted over a channel.
It is given by the maximum of all values of mutual information calculated
for a channel for different probability distributions of the source.

This is also obvious since a good channel must have high capacity meaning
mutual information should be maximized.
=⇒ C = max[I(X; Y )]

Capacity of Binary Symmetric Channel


For a binary symmetric channel considered earlier, the channel capacity can
be calculated by maximizing the expression for mutual information.
I(X; Y ) is maximum if H(p + α − 2pα) is maximum since H(p) is constant
for a given channel.
H(p + α − 2pα) will be equal to 1 when p + α − 2pα = 0.5 and hence α = 0.5.

=⇒ C = 1 − H(p)
Since H(p) = H(1 − p), it is obvious that C = 1 − H(1 − p).

80
The channel capacity will be maximum if p = 1 or p = 0 i.e it will be 1 bit
per channel use.
The channel capacity will be minimum if p = 0.5 i.e it will be 0 bits per
channel use.

Capacity of Gaussian Channel


For a Gaussian channel (i.e a channel which adds white Gaussian noise to
the input), the channel capacity can be calculated from Shannon-Hartley
theorem.
The Shannon–Hartley theorem states the channel capacity C, i.e the upper
bound on the information rate of data that can be communicated at an
arbitrarily low error rate using an average received signal power S through
an analog communication channel subject to additive white Gaussian noise
(AWGN) of power N is,
 
S
C = BW log2 1 + bits/s
N

where BW is the bandwidth of the channel and hence N is the average power
of the noise and interference over the bandwidth.
(note that the SNR is expressed as a linear power ratio, not as logarithmic
decibels)

The above expression is obtained by considering the fact that the maximum
number of distinguishable pulse levels that can be transmitted and received
reliably over a communications channel is limited by the dynamic range of
the signal amplitude and the precision with which the receiver can distinguish
amplitude levels.
The number of levels M is given by,
r r
N +S S
M= = 1+
N N
It can be observed that the channel capacity can also be expressed as,

C = 2BW log2 M

For a channel of infinite bandwidth, the channel capacity can be derived

81
using the same expression (BW → ∞).

S
=⇒ C = 1.44
N0
N0 is the amplitude of the noise (AWGN) power spectral density.

4.3 Source Coding


It has been established that in digital communication, a digital source sequen-
tially generates symbols. Usually, the source will be a discrete memoryless
source and hence the probabilities of occurrence of any symbol at any instant
of time is independent of previous symbols.
Therefore, the symbols are independent and identically distributed.

Source coding refers to the process of encoding (or mapping) these symbols
into a sequence of digits like bits which is called the ”code”.
The goal of source coding would be to minimize the average number of bits
used to represent the symbols in a source.

For a source that generates M symbols s0 , s1 , ...sM −1 with probabilities p0 , p1 , ...pM −1


respectively, the average code-word length (obtained by using any coding
technique) is,
M
X −1
L= pi li
i=0

where l0 , l1 , ...lM −1 are the lengths of the corresponding code-words.

There are two types of source coding techniques.

1. Fixed Length Coding

2. Variable Length Coding

Fixed Length Coding


In fixed length coding, the length of the code-word for each of the symbols
is equal and fixed. For example, consider a source that generates 4 sym-
bols s0 , s1 , s2 and s3 and the code-words corresponding to the 4 symbols are

82
00,01,10 and 11 respectively. Here, each code-word is of length 2.

A fixed length code is always ”Uniquely Decodable”. Meaning, the original


sequence of symbols can be extracted from the sequence of code-words.
Even though the decoding complexity is low, fixed length coding does not
minimize the average length of the code-words and hence is not the most
efficient technique.

Variable Length Coding


In variable length coding, the length of the code-word for different symbols
is different. There are various schemes in which variable length codes can be
generated, and all aim to minimize the average length of the code-words.

A variable length code if not constructed properly will not be uniquely decod-
able. For example, for the same source illustrated before, if the code-words
are 0,1,00 and 11 respectively, it can be noted that given an arbitrary se-
quence of code-words, the original sequence of symbols can not be obtained.

Therefore, source coding mainly involves in finding uniquely decodable vari-


able length codes that minimize the average length of the code-words.

The most convenient way to obtain uniquely decodable codes is to ensure that
the code-words are prefix-free. Meaning, no code-word is a prefix of another
code-word. Such codes are called ”Prefix-Free Codes” or ”Instantaneous
Codes” (since they can be decoded instantaneously without the necessity of
waiting for arrival of next code-word).

For example, for the same source illustrated before, if the code-words are
1,01,001 and 000 respectively, it can be noted that given an arbitrary se-
quence of code-words, the original sequence of symbols can be obtained.

To generate a prefix-free code, the following inequality called ”Kraft Inequal-


ity” has to be followed. It is given by,
M
X −1
2−li ≤ 1
i=0

The coding efficiency is defined as the ratio of the entropy of the source to

83
the average code-word length.
PM −1
H(s) i=0 pi log2 pi
η= =− P M −1
L i=0 pi li

The maximum efficiency that can be obtained is 1, which is possible using


prefix-free coding.

4.4 Channel Coding


It is quite obvious that there is finite non-zero probability of error in the re-
ceived information/signal when compared to the transmitted information/signal.
Therefore, it is necessary for the receiver to have mechanisms that can detect
and correct the potential errors in the received bits of information.

The basic idea used is to transmit extra bits called ”Parity bits” along with
the data bits. These parity bits will contain some data about the data bits
that can help detect and correct errors. This technique is called ”Channel
Coding” or ”Error Correction Coding”.
=⇒ Code-word = Data (message) bits + Parity bits

If there are k data bits and m parity bits, then the length of the code word
will consist of n = k + m bits. Such a code is represented as (n, k) code.

The Code Rate of an (n, k) code is the ratio k/n.


Hence, the code rate denotes the fraction of a code-word that actually con-
sists of the data (message).
Note that code rate is always less than 1 (a code rate of 1 means no parity
bits have been added and hence no coding has been done).

There are mainly two types of channel coding techniques.


1. Linear Block Codes
2. Convolution Codes
Linear block codes will be covered in detail, convolution codes are left to
more advanced study. A sub-division in linear block codes called ”Cyclic
codes” will also be introduced.

84
Linear Block Code properties:

• Sum of two code-words belonging to a code is also a code-word belong-


ing to the code

• The all zero code-word is always a valid code-word

• The minimum distance of the code will be equal to the minimum weight
among all code-words of the code (excluding the all zero code-word).

Hamming Distance:
The Hamming distance between two code-words is the number of elements
(or bits) that are different between them. Hamming distance of any two
arbitrary code-words c1 and c2 (both of same length) is denoted as d(c1 , c2 ).
Example: c1 = 01101, c2 = 11100; =⇒ d(c1 , c2 ) = 2

The minimum distance of a code is the minimum Hamming distance between


any two code-words in the code.
Consider a code C = (c0 , c1 , ...cM −1 ), then the minimum distance is given by,
d∗ = min [d(ci , cj )] i 6= j.

This is denoted as dmin and is an important parameter in error correction


codes as it gives the error detection and correction capacity of a code.

• An LBC can detect up-to t errors provided dmin ≥ t + 1

• An LBC can detect up-to t errors provided dmin ≥ 2t + 1

Hamming Weight:
The Hamming weight of any code-word is the number of non-zero elements
(or bits) present in the code-word. Hamming weight of any code-word c is
denoted as w(c).
Example: c = 11010; =⇒ w(c) = 3

Note that the Hamming distance of two code-words is equal to the Hamming
weight of the difference between the code-words i.e d(c1 , c2 ) = w(c1 − c2 ).

The minimum weight of a code is the minimum Hamming weight of any non-
zero code-word in the code and is denoted by w∗ .

85
Generator matrix G is the matrix that converts a data sequence of length
k to an encoded sequence of length n.

Consider a message block (data sequence) given by (d1 ,d2 ,...dk ) which needs
to be encoded to a code-word given by (c1 ,c2 ,...ck , ck+1 ,...ck+m ).
Hence, the generator matrix takes input dk×1 and gives output cn×1 .
=⇒ c = dG. This means that the generator matrix G is of size k × n.

The first k bits in the code-word will be same as the message bits. The last
m bits i.e the parity bits will be linear combinations of the k message bits.
ck+1 = p11 d1 + p12 d2 + ...p1k dk , . . . . , ck+m = pm1 d1 + pm2 d2 + ...pmk dk .
This means that the generator matrix G has rank k.

The coefficients of the data bits that result in the parity bits can be expressed
in matrix form, called the ”Coefficient Matrix” P .
 
p11 p12 . . . p1k
=⇒ Pm×k =  ... .. .. .. 

. . . 
pm1 pm2 . . . pmk
The generator matrix can be expressed by combining the above observations.
It will consist of an identity matrix of dimensions k followed by the transpose
of the coefficient matrix.
=⇒ Gk×n = [Ik : P T ].

Parity Check matrix H is the matrix that decodes the encoded sequence
back to the original data sequence.
H is obtained such that GH T = 0. Hence, it can be deduced that the parity
check matrix should be H = [P : In−k ].
This implies that the parity check matrix H is of size (n − k) × n.

Since GH T = 0 and c = dG, it can be concluded that cH T = 0.


Meaning, any valid code-word generated from the generator matrix, when
multiplied with the transpose of the parity check matrix, will give [0].
This property is used for detecting and correcting errors.

Syndrome Decoding: The algorithm used to detect and correct errors in


the received code-word using the Parity check matrix.

86
If the transmitted code-word is c and the received code-word is r (both will
be rows of n elements), then the error pattern e = c + r, which can be mod-
ified as r = c + e.
The error pattern e will have 0 if there is no error in the corresponding bit
position i.e r and c are same and will have 1 if there is an error in the corre-
sponding bit position i.e r and c are different.

Consider rH T = cH T + eH T = eH T . This matrix is called the Syndrome


(S).

• If S = 0, then no error has occurred.

• If S 6= 0, then error has occurred.

S = eH T will give the row of the parity check matrix which corresponds to
the position of the error. So the algorithm simply compares the obtained
syndrome S with each row of the matrix H T and the index of the row which
matches with S indicates the position of the error in r, which has to be in-
verted to obtain back c.

If none of the rows of H T matches with a non-zero S, then it means error has
occurred in more than one position and the algorithm has to check for linear
combinations of rows of H T which match with S to identify error positions.

An (n, k) LBC will have 2n−k distinct syndromes and 2n−k − 1 distinct non-
zero syndromes.

4.4.1 Hamming Code


Hamming coding is the most fundamental error correction code. It can be
used correct 1 error.
Hamming codes are (n, k) codes with n = 2m − 1 and k = 2m − 1 − m and
minimum distance m = 2t + 1 where t is the number of errors the scheme is
capable of correcting (which is 1 here and hence m = 3).
The most popular Hamming code is (7, 4) code.

(7, 4) Hamming code consists of 7 bits overall with 4 message bits and 3 par-
ity bits. The parity bits occupy positions that are powers of 2 i.e positions

87
1,2 and 4. The remaining positions are occupied by the data bits.
Hence, in general the Hamming code can be represented as (d7 , d6 , d5 , p4 , d3 , p2 , p1 ).

A general algorithm can be deduced from the following description:

• Number the bits starting from 1: bit 1, 2, 3, 4, 5, 6, 7, etc.

• Write the bit numbers in binary: 1, 10, 11, 100, 101, 110, 111, etc.

• All bit positions that are powers of two (have a single 1 bit in the binary
form of their position) are parity bits: 1, 2, 4, 8, etc. (1, 10, 100, 1000)

• All other bit positions, with two or more 1 bits in the binary form of
their position, are data bits.

• Each data bit is included in a unique set of 2 or more parity bits, as


determined by the binary form of its bit position.

– Parity bit 1 covers all bit positions which have the least significant
bit set: bit 1 (the parity bit itself), 3, 5, 7, 9, etc.
– Parity bit 2 covers all bit positions which have the second least
significant bit set: bit 2 (the parity bit itself), 3, 6, 7, 10, 11, etc.
– Parity bit 4 covers all bit positions which have the third least
significant bit set: bits 4–7, 12–15, 20–23, etc.
– Parity bit 8 covers all bit positions which have the fourth least
significant bit set: bits 8–15, 24–31, 40–47, etc.

(In general each parity bit covers all bits where the AND of the parity position
and the bit position is non-zero)
The parity bits are calculated by finding the bits necessary to be placed in
their respective positions described earlier so as to obtain even parity for
their corresponding positions.
In (7,4) Hamming code:

• p1 is responsible for setting even parity to p1 , d3 , d5 , d7

• p2 is responsible for setting even parity to p2 , d3 , d6 , d7

• p4 is responsible for setting even parity to p4 , d5 , d6 , d7

88
After Hamming code is generated by adding the parity bits to the data bits
and transmitted, the received bit sequence is tested for errors.
If due to error any bit is flipped, then the corresponding parity will be found
to be odd instead of even and hence it can be concluded that error has been
detected.
Process of error correction:

• From the error detection process, a binary number has to be found


whose decimal equivalent gives the position of the error.

• For all parity bits that satisfy even parity, set the corresponding binary
number bit to 0.

• For all parity bits that do not satisfy even parity (i.e error is detected),
set the corresponding binary number bit to 1.

• Write the binary number in order of highest parity to lowest parity


bit and convert this binary number to decimal equivalent to get the
position of the error.

• Flip the bit in this position to correct the error.

Example: Data bits are (0,1,1,0). =⇒ (0,1,1,p4 ,0,p2 ,p1 ).

p1 = 1, p2 = 1 and p4 = 0 to set even parities.


The Hamming code sequence is (0,1,1,0,0,1,1) which is transmitted.

If the received sequence is (1,1,1,0,0,1,1), then error is detected because on


finding the parity bits again for the data, p1 should be 0 but it is 1; p2 should
be 0 but it is 1; p4 should be 1 but it is 0. Here all parity bits are wrong but

89
in general if any one is wrong, it still means error has occurred.

For error correction, note that all 3 parity bits are wrong meaning the binary
value of the error location is 111 which corresponds to d7 . Therefore, d7 has
error and it should be 0 instead of 1.

(Note that if two errors have occurred, then Hamming code does not work)

4.4.2 Cyclic Redundancy Check (CRC)


Cyclic redundancy check (CRC) is an error-detecting code based on the the-
ory of cyclic error-correcting codes.

A CRC for a sequence of data bits (message) is generated by the sender using
a particular algorithm and another sequence which is known by the receiver
as well called the ”divisor”.

CRC Generation:

• Find length of divisor, L.

• Append L − 1 zeros (0s) at the end of the data bit sequence.

• Perform binary division i.e the message with appended zeros divided
by the divisor.

– Subtracting or adding is same as performing XOR operation.


– If MSB of divisor is 1 and MSB of dividend is 1, then the corre-
sponding quotient bit is 1.
– If MSB of divisor is 1 and MSB of dividend is 0, then the corre-
sponding quotient bit is 0.
– If MSB of divisor is 0, then the corresponding quotient bit is
always 0.

• The obtained remainder is the CRC.


Note that the length of the CRC will also be L − 1 bits.

• The encoded message to be transmitted will be the original sequence


appended by the CRC bits.

90
Error Detection using CRC:
Once the encoded data is received, the receiver performs the same binary
division operation on the received data using the same divisor (note that the
common divisor is predetermined by the protocol).

• If the remainder obtained by the division performed by the receiver is


a sequence of L − 1 zeros (0s), then there is no error in the transmitted
data.

• If the remainder obtained by the division performed by the receiver


is any other sequence, then there is error in the transmitted data and
hence error detection is achieved.

91

You might also like