Dr. Paramjeet Singh HoD,Dept. of CSE PTU GZS Campus Bathinda
Subject: Computer Networks Topic: Encoding and modulating Punjab
EDUSAT Society1
Slide 2
Encoding is the process of converting data from one form to
another. Types of encoding 1.Analog to analog encoding 2.Analog to
digital encoding 3.Digital to analog encoding 4.Digital to digital
encoding Encoding Punjab EDUSAT Society2
Slide 3
Analog Signals Analog signal is a continuous waveform that
changes smoothly over time. It has three characteristics
1.Amplitude - Height of the signal 2.Frequency Rate of change
w.r.t. time 3.Phase Position of waveform relative to time zero.
Punjab EDUSAT Society3
Slide 4
Digital Signal refers to something that is discrete. Bit
interval (instead of period) and Bit rate (instead of frequency)
The bit interval is the time required to send one single bit. The
bit rate is the number of bit intervals in one second, usually
expressed in bits per second (bps). 4
Slide 5
Data rate and Baud rate The baud or signal rate can be
expressed as: S = c x N x 1/r bauds where N is data rate c is the
case factor (worst, best & avg.) r is the ratio between data
element & signal element Punjab EDUSAT Society5
Slide 6
Analog to analog encoding Analog modulation: Modulation is the
process by Which some characteristics of the carrier signal is
varied in accordance with the modulating signal. These
characteristics may be 1.Amplitude 2.Frequency 3.Phase Punjab
EDUSAT Society6
Slide 7
Need of modulation 1.To reduce the height of antena,
h=wavelength/4 Where wavelength = C/ F, C = Speed of light and
F=Frequency 2. To avoid the intermixing of signals of different
stations. 3. It increases the radiation power. Punjab EDUSAT
Society7
Slide 8
Amplitude modulation It is the process by which the amplitude
of the carrier signal is varied in accordance with the amplitude of
the modulating signal. The frequency and phase of the carrier
remain the same Punjab EDUSAT Society8
Amplitude modulation Band Allocation Punjab EDUSAT
Society11
Slide 12
Frequency modulation It is the process by which the frequency
of the carrier signal is varied in accordance with the amplitude of
the modulating signal. The amplitude and phase of the carrier
remain the same. Punjab EDUSAT Society12
Slide 13
Frequency Modulation Punjab EDUSAT Society13
Slide 14
FM Bandwidth Punjab EDUSAT Society14
Slide 15
FM Band Allocation Punjab EDUSAT Society15
Slide 16
Phase modulation It is the process by which the phase of the
carrier signal is varied in accordance with the amplitude of the
modulating signal. The amplitude and frequency of the carrier
remain the same. Punjab EDUSAT Society16
Slide 17
Analog to Digital Encoding Punjab EDUSAT Society17
Slide 18
Pulse amplitude modulation (PAM) This technique takes analog
signal, sample it and generate a series of pulses based on the
sampling. The term sampling means measuring the amplitude of the
signal at equal interval. Punjab EDUSAT Society18
Quantizing Using Sign and Magnitude Punjab EDUSAT
Society21
Slide 22
Pulse amplitude modulation (PAM) PAM is not much useful in data
communications. The reason behind this that, although it translates
the original wave form to a series of pulses but these pluses are
still of any amplitude (still an analog signal, not digital). To
make them digital,we must modify them by using pulse code
modification(PCM). PAM is the foundation of PCM technique. Punjab
EDUSAT Society22
Slide 23
Pulse code modulation (PCM) It modify the pulses created by PAM
to create a completely digital signals. To do so, the PCM first
quantities the PAM pulses. Then each value is translated into its
seven bits binary equivalent. The eighth bit indicates the sign. It
uses digital to digital encoding techniques. Punjab EDUSAT
Society23
Slide 24
Pulse code modulation (PCM) Phases of PCM PAM Quantization
Binary encoding Digital to digital encoding Punjab EDUSAT
Society24
Slide 25
From Analog to PCM Punjab EDUSAT Society25
Slide 26
Quantization Quantization is the method of assigning internal
values in a specific range to sampled instances. Punjab EDUSAT
Society Binary Encoding Binary encoding calculate 7 bit binary
equivalent of each quantized value. The eighth bit indicate the
sign. 26
Slide 27
Nyquist Theorem PCM is based on the sampling theorem, which
states that if a signal f(t) is sampled at regular intervals of
time and at a rate higher then twice the highest signal frequency,
then the samples contains all the information of the original
signal and the function f(t) may be reconstructed from these
samples. Sampling (fs)>=2*f(highest signal frequency )
samples/seconds Punjab EDUSAT Society27
Slide 28
Nyquist Theorem Punjab EDUSAT Society28
Slide 29
Delta Modulation (DM) The basic idea in delta modulation is to
approximate the derivative of analog signal rather than its
amplitude. The analog data is approximated by a staircase function
that moves up or down by one quantization level at each sampling
time. Output of DM is a single bit. PCM preferred because of better
SNR characteristics. Punjab EDUSAT Society29
Slide 30
Delta Modulation Punjab EDUSAT Society30
Slide 31
Punjab EDUSAT Society DM is the simplest form of differential
pulse- code modulation (DPCM) where the difference between
successive samples are encoded into n- bit data streams. In this,
the transmitted data is reduced to a 1-bit data stream. Its main
features are:differential pulse- code modulation 1. The analog
signal is approximated with a series of segments. 2. Each segment
of the approximated signal is compared to the original analog wave
to determine the increase or decrease in relative amplitude.
31
Slide 32
Punjab EDUSAT Society 3. The decision process for establishing
the state of successive bits is determined by this comparison 4.
Only the change of information is sent, that is, only an increase
or decrease of the signal amplitude from the previous sample is
sent whereas a no-change condition causes the modulated signal to
remain at the same 0 or 1 state of the previous sample. 32
Slide 33
Digital to Analog Encoding: Process of changing one of the
characteristics of an analog signal based on the digital signal (1
or 0). It has following types: 1.Amplitude Shift Keying (ASK)
2.Frequency Shift Keying (FSK) 3.Phase Shift Keying (PSK)
4.Quadrature Amplitude Modulation (QAM) Punjab EDUSAT
Society33
Slide 34
Punjab EDUSAT Society ASK: Strength of the carrier signal is
varied to represent binary 1 or 0. 34
Slide 35
Bandwidth for ASK Punjab EDUSAT Society35
Slide 36
FSK: Frequency of the carrier signal is varied to represent
binary 1 or 0. Punjab EDUSAT Society36
Slide 37
Bandwidth for FSK Punjab EDUSAT Society37
Slide 38
Punjab EDUSAT Society PSK: Phase of the carrier signal is
varied to represent binary 1 or 0. 38
Slide 39
PSK Constellation Punjab EDUSAT Society39
Slide 40
4-PSK Punjab EDUSAT Society40
Slide 41
4-PSK Characteristics Punjab EDUSAT Society41
Slide 42
8-PSK Characteristics Punjab EDUSAT Society42
Slide 43
PSK Bandwidth Punjab EDUSAT Society43
Slide 44
Punjab EDUSAT Society QAM: Combining ASK and PSK in such a way
that we have maximum contrast between each bit, dibit, tribit,
quadbit, and so on. 44
Slide 45
8-QAM Signal Punjab EDUSAT Society45
Slide 46
16-QAM Constellation Punjab EDUSAT Society46
Slide 47
Digital to digital encoding It is the representation of digital
information to digital signal. Punjab EDUSAT Society47
Slide 48
Types of Digital to Digital Encoding Punjab EDUSAT
Society48
Slide 49
Unipolar :- It uses only one level of value and polarity (all
signal elements have the same algebraic sign i.e. all positive or
negative). Advantages :- Very simple. Disadvantages :- DC
component. Synchronization. Punjab EDUSAT Society49
Slide 50
DC component :- The average amplitude of a unipolar encoded
signal is non zero. This creates direct current (DC) component(with
zero frequency). Synchronization :- when a signal is unvarying, the
receiver can not determine the beginning and ending of each bit.
Therefore, A synchronization problem in unipolar can occur when
ever the data stream includes a long uninterrupted series of 1s or
0s. Punjab EDUSAT Society50
Slide 51
Effect of lack of synchronization Punjab EDUSAT Society51
Slide 52
Unipolar Encoding Punjab EDUSAT Society52
Slide 53
Polar :- It uses two levels of amplitude. One is positive and
another is negative. Types of Polar Encoding Punjab EDUSAT
Society53
Slide 54
Non return to zero(NRZ) In this encoding technique, the level
of the signal is always either positive and negative. It has two
types: NRZ-Level, NRZ-Invert NRZ L :- In NRZ-L the level of the
signal is dependent upon the state of the bit. A positive voltage
usually means the bit is a zero, and a negative voltage means the
bit is one or (vice-versa). Advantages-Eliminate DC component.
Disadvantages-Lack of synchronization. Punjab EDUSAT Society54
Slide 55
Non return to zero(NRZ) NRZ-1 :- In this the signal is inverted
if a one is encountered and zero bit is represented by no change.
Advantages- Synchronization provided by the signal change.
Disadvantages- String of zeros can still cause problems. Punjab
EDUSAT Society55
Slide 56
NRZ-L and NRZ-I Encoding Punjab EDUSAT Society56
Slide 57
Return to zero (RZ) :- RZ uses three values: positive, negative
and zero. In this, the signal changes not between bits but during
each bit. A positive voltage means one and negative voltage means
zero and halfway Through each bit interval, the signal returns to
zero. one bit is represented by positive-to-zero and a zero bit by
negative-to-zero, rather than by positive and negative alone.
Punjab EDUSAT Society57
Slide 58
RZ Encoding Punjab EDUSAT Society58
Slide 59
Advantages :- Better synchronization. Disadvantage :- It
requires two signal changes to encode one bit and therefore
occupies more bandwidth. Punjab EDUSAT Society59
Slide 60
Biphase In this method, the signal changes at the middle of the
bit interval but does not return to zero. It can be implemented in
two ways:- Manchester Differential Manchester. Punjab EDUSAT
Society60
Slide 61
Manchester encoding:- It uses the inversion at the middle of
each bit interval for both synchronization and bit representation.
A negative to positive translation represent binary one and a
positive to negative translation represent binary zero. By using
the single translation for a dual purpose, manchester encoding
achieves the same level of synchronization as RZ but with only two
levels of amplitude. Punjab EDUSAT Society61
Slide 62
Differential Manchester:- In this, the transition at the middle
of the bit is used only for synchronization. The bit representation
is shown by the inversion or non inversion at the beginning of the
bit. Punjab EDUSAT Society62
Slide 63
Manchester and Diff. Manchester Encoding Punjab EDUSAT
Society63
Slide 64
Polar biphase: Manchester and differential Manchester schemes
Punjab EDUSAT Society64
Slide 65
Bipolar encoding :- It uses three levels of voltage or
amplitude: positive, negative and zero. The zero level is used to
represent binary zero. The 1s are represented by alternative
positive and negative voltages. If the first one bit is represented
by the positive amplitude, second will be represented by negative
amplitude, third by the positive amplitude, and so on. Punjab
EDUSAT Society65
Slide 66
Types of Bipolar Encoding Alternate mark inversion(AMI).
Bipolar 8-zero substitution(B8ZS). High density bipolar-3(HDB3).
Punjab EDUSAT Society66
Slide 67
Alternate mark inversion :- Mark means one, so AMI means
alternate one inversion. zero voltage represent binary zero and1s
are represented by alternating positive and negative voltages. AMI
accomplishes two things: 1. DC component is zero. 2. Long sequence
of 1s stays syncronization but there is no mechanism to ensure the
synchronization of a long string of 0s. Punjab EDUSAT
Society67
Slide 68
Bipolar AMI Encoding Punjab EDUSAT Society68
Slide 69
Bipolar 8 zero substitution:- In this if 8 zeros come one after
another, we change the pattern in one of two ways based on the
polarity of the previous. The difference between B8ZS and AMI
occurs whenever eight or more consecutive 0s are encountered in the
data stream. Solution provided by B8ZS is to force artificial
signal changes, called violations, within the zero string. Punjab
EDUSAT Society69
Slide 70
B8ZS Encoding Punjab EDUSAT Society70
Slide 71
Bipolar 8 zero substitution:- If the previous 1 bit was
positive, the eight 0s will be encoded as zero, zero, zero,
positive, negative, zero, negative, positive. When receiver finds
two consecutive positive changes surrounding three 0s, it
recognizes the pattern as deliberately introduced violation and not
an error. It then looks for the 2 nd pair of the expected
violations. When it finds them, the receiver translates all eight
bits to 0s and reverts back to normal bipolar AMI mode. Punjab
EDUSAT Society71
Slide 72
Bipolar 8 zero substitution:- If the polarity of the previous 1
bit is negative, then pattern of violation will be same but with
inverted polarities. Punjab EDUSAT Society72
Slide 73
High density bipolar-3 :- In this if four zeros come one after
another, we change the pattern based on the polarity of the
previous 1 and the number of 1s since the last substitution. When
the no. of 1s since the last substitution is odd, HDB3 Puts a
violation in the places of 4 th consecutive zeros. if the polarity
of the previous bit was positive, then the violation is positive.
if the polarity of the previous bit was negative, then the
violation is negative. Punjab EDUSAT Society73
Slide 74
High density bipolar-3 :- When the no. of 1s since the last
substitution is even, HDB3 Puts violations in the places of both
the first and the fourth consecutive zeros. if the polarity of the
previous bit was positive, both violations are negative. if the
polarity of the previous bit was negative, both violations are
positive. Punjab EDUSAT Society74
Slide 75
HDB3 Encoding Punjab EDUSAT Society75
Slide 76
Unipolar NRZ NRZ-Inverted (Differential Encoding) Bipolar
Encoding Differential Manchester Encoding Polar NRZ Manchester
Encoding 101 0 11001 Punjab EDUSAT Society76
Slide 77
For example: B8ZS substitutes eight consecutive zeros with
000VB0VB. The V stands for violation, it violates the line encoding
rule B stands for bipolar, it implements the bipolar line encoding
rule Punjab EDUSAT Society77
Slide 78
Two cases of B8ZS scrambling technique Punjab EDUSAT
Society78
Slide 79
HDB3 substitutes four consecutive zeros with 000V or B00V
depending on the number of nonzero pulses after the last
substitution. If # of non zero pulses is even the substitution is
B00V to make total # of non zero pulse even. If # of non zero
pulses is odd the substitution is 000V to make total # of non zero
pulses even. Punjab EDUSAT Society79
Slide 80
Different situations in HDB3 scrambling technique Punjab EDUSAT
Society80