line coding & error correction
TRANSCRIPT
1
LINE CODING &ERROR CORRECTION
Presented By:-Sarbjeet SInghNITTTR -Chandigarh
Contents
Line coding Reasons For Using Line Coding Properties of a Line Code Line coding schemes Error Correction
Line Coding
Line coding is always needed; which is a technique to convert binary data to digital signal.
In the transmission of digital information over wire or optical fiber systems, line coding (also known as modulation/data translation coding) is the method by which 1’s & 0’s are represented as transmitted waveforms.
Reasons For Using Line Coding Spectrum shaping and relocation
without modulation or filtering. This is important in telephone line applications, e.g, where the transfer characteristic has heavy attenuation below 300 Hz.
Error detection capabilities. Bandwidth usage; the possibility of
transmitting at a higher rate than other schemes over the same bandwidth.
Cotnd..
DC component can be eliminated; this allows AC (capacitor or transformer) coupling between stages (as in telephone lines )
Properties of a Line Code:
Self–Synchronization : There is enough timing information built into the code so that bit synchronizers can extract the timing or clock signal. A long series of binary 1’s or 0’s should not cause a problem in time recovery
Contd..
Low Probability of Bit Error : Receivers can be
designed that will recover the binary data with a low probability of bit error when the input data is corrupted by noise or ISI.
A Spectrum that is Suitable for the Channel:
In addition, the signal bandwidth needs to be sufficiently small compared to the channel
bandwidth, so that ISI will not be a problem.
Contd..
Transmission Bandwidth: This should be as small as possible
Error Detection Capability: It should be possible to implement this feature easily by the addition of channel encoders and decoders, or the feature should be incorporated into the line code
Line coding schemes
Unipolar encoding
Unipolar encoding uses only one voltage level
( use only one polarity +ve or -ve).
Unipolar Encoding’s Problems:
Two problems: A dc component Lack of synchronization : If data contain long
sequence of 0’s or 1’s, there is no transition in the signal during this duration that can alert the receiver to synchronization problem.
The receiver receives a continuous voltage and determines how many bits are sent by relaying on its clock (bit-duration), which may not be synchronized with the sender clock.
Polar Encoding
Polar encoding uses two voltage levels (positive and negative).
By using two levels , the average voltage level is reduced and the dc component problem may be alleviated( if balance)
NRZ: NRZ-L
The level of the signal is dependent upon the state of the bit. A positive voltage means 0, while negative means 1.
Has lack of synchronization , when the data contain a long stream of 0s or 1s.
NRZ: NRZ-I
In NRZ-I , the signal is inverted if a 1 is encountered. It is the transition between a +ve and a –ve voltage , not the voltage itself.
A 0 bit is represented by no change NRZ-I is superior to NRZ-L due to
synchronization each time a 1 bit is encountered.
RZ encoding
To ensure synchronization, there must be a signal change (transition) for each bit
RZ uses three values +ve, zero and –ve The signal changes during each bit A1-bit is represented by transition from +ve
to zero A 0-bit by –ve to zero
Bi phase: Manchester encoding
The transition at the middle of the bit is used for both synchronization and bit representation.
It has not Dc component It achieves the same level of
synchronization as RZ but with only two levels and less B-W
Bipolar AMI (Alternate Mark Inversion) Encoding
Bit 0 represents by zero voltage Bit 1s are represented by alternating +ve
and –ve voltages
Contd..
In bipolar encoding AMI , we use three levels: positive, zero, and negative as RZ.
Has DC component AMI has a lack of synchronization when
there is a stream of sequential zeros.
Summary of Line Coding
Error Correction
Hamming distance
The Hamming distance between two words is the number of differences between corresponding bits.
The minimum Hamming distance is the smallest Hamming distance between all possible pairs in a set of words.
Contd..
Let us find the Hamming distance between two pairs of words.The Hamming distance d(000, 011) is 2 because
The Hamming distance d(10101, 11110) is 3 because
Contd..
We first find all Hamming distances.
The dmin in this case is 3.
Contd..
To guarantee the detection of up to s errors in all cases, the minimum Hamming distance in a block code must be
dmin = s + 1.
To guarantee correction of up to t errors in all cases, the minimum Hamming distance in a block code must be
dmin = 2t + 1.
Example
A code scheme has a Hamming distance dmin = 4. What is the error detection and correction capability of this scheme?
SolutionThis code guarantees the detection of up to three errors (s = 3), but it can correct up to one error. In other words, if this code is used for error correction, part of its capability is wasted. Error correction codes need to have an odd minimum distance (3, 5, 7, . . . ).
LINEAR BLOCK CODES
Almost all block codes used today belong to a subset called linear block codes.
A linear block code is a code in which the exclusive OR (addition modulo-2) of two valid code words creates another valid codeword.
Contd..
A simple parity-check code is a single-bit error-detecting code in which n = k + 1 with dmin = 2.
Even parity (ensures that a codeword has an even number of 1’s) and
Odd parity (ensures that there are an odd number of 1’s in the codeword)
Simple Parity-Check Code
Table - Simple parity-check code C(5, 4)
Encoder & Decoder For Simple Parity-Check Code
Cyclic Codes
Cyclic codes are special linear block codes with one extra property.
In a cyclic code, if a codeword is cyclically shifted (rotated), the result is another codeword.
A CRC code with C(7, 4)
CRC encoder and decoder
Division in CRC encoder
Division in the CRC decoder for two cases
References
Optical fiber communications (Gerd Kesior 3rd edition)
Data communications & networking( Behrouz Forouzan 4th edition)
www.google.com
THANK YOU