Mohammed Ali Dhaga
Introduction To Error Detection And Correction
When a transmission of digital signal takes place between two systems such as computers
as shown in given figure. The get contaminated due to the addition of NOISE to it.
It is necessary to detect and correct errors because these errors can become a serious threat
To the accuracy of the digital system.
TYPES OF ERRORSThere are two types of errors1.CONTENT ERRORS
2.FLOW INTEGRITY ERRORS
The content errors are nothing but errors in the content of a message For e.g. ”0” may
Receive as “1“or vice versa. Such errors are introduced due to noise added into the in data
signals during its transmission.
Types Of Bit Errors
1.SINGLE BIT ERROR
SINGLE BIT ERROR:• The term single bit error suggests that only one bit in the given data unit such as a
byte is in a error.
• That means only one bit can be change from 1 to 0 or 0 to 1, as shown in the figure.
0 1 1 1 0 0 1 1
0 1 1 1 0 0 1 0
BURST ERRORS:• If two or more bits from a data unit such as byte change from 1 to 0 or from 0 to 1
then burst errors are said to have occurred.
• The length of the burst is measured from the first corrupted bit to the last corrupted
bit. Some of the bits in between may not have been corrupted.
• Burst errors are illustrated in the given figure.
0 1 1 1 0 0 1 1
0 1 0 1 1 0 0 1
Important Definitions Related To Codes
CodewordThe Codeword is the encoded block of bits. As already seen it contains message bits &
parity or redundant, as shown in given figure.
The code rate is defined as the Ratio of the number of message bits(k) to the total number
of bits(n) in a codeword.
Code rate (r) = k
Code efficiencyThe Code efficiency is defined as the ratio as the ratio of message bits to the number of
transmitted bits per block.
Code efficiency = Code rate = k
When a code word is transmitted, one or more number of transmitted bits will be reserved
(0 & 1 or vice versa) due to transmission impairments. Thus the errors will be introduced.
It is possible for the receiver to detect these errors if the received codeword (corrupted) is
not one of the valid codeword's.
When the errors are introduced, the distance between the transmitted & received
codeword's will be equal to the number of errors as illustrated in given figure.
Hence to detect the errors at the receiver, the valid codeword's should be separated by a
distance of more than 1.
Otherwise the incorrect received codeword’s will also become some other valid codeword’s
& the error detection will be impossible.
Error Detection Methods
What is ERROR DECTECTION METHODS?
Before thinking of correcting the errors introduced in the data bits is necessary to first
For error detection & correction it is necessary to add some check bit to a block of data
bits. These check bits are also known as “Redundant bits” because they do not carry any
Some of the most important error detection methods are as follows1. Parity Checking.
2. Checksum Error Detection.
3. Cyclic Redundancy Check (CRC).
Error Detection Methods
The simplest technique foe detecting errors is add an extra bit known as PARITY
bit to each word being transmitted.
As shown in given figure generally the MSB of an 8-bit word is used as the parity
bit & the remaining 7 bits are used as data or message bits.
d5 d4 d3 d2 d1 d0
7- data bits
The parity of the 8-bit transmitted word can be either even parity or odd parity.
Even Parity means the number of 1’s in the given word including the parity bit
should be even (2,4,6,8,…..).
Odd Parity means the number of 1’s in the given word including the parity bit
should be odd (1,3,5,7,…..).
Two Dimensional Check
When a large number of binary words are being transmitted or
received in succession, the resulting collection of bits is considered
as a block of data, with rows & columns as shown in given figure.
The parity bits are produced for each row & column of such block of
The two sets of parity bits so generated are known as:
• Longitudinal Redundancy Check (LRC) bits.
• Vertical Redundancy Check (VRC) bits.
Cyclic Redundancy Check (CRC)
This is a type of polynomial code in which a bit string is represented in the form of
polynomials with coefficient of 0 and 1 only
Polynomial arithmetic uses a modulo-2 arithmetic i.e. addition and subtraction
are identical to EXOR.
For CRC code the sender and receiver should agree upon a generator polynomial
G(x). A codeword can be generated for a given data word (message)
polynomial M(x) with the help of long division.
This technique is more powerful than the parity check and checksum error
CRC is based on binary division. A sequence of redundant bits called CRC or CRC
remainder is appended at the end of a data unit such as byte.
The resulting data unit after adding CRC remainder becomes exactly divisible by
another predetermined binary number.
At the receiver, this data unit is divided by the same binary number.
There is no error if this division does not yield any remainder. But a non-zero
remainder indicates presence of errors in the received data unit.
Such an erroneous data unit is then rejected.
Error Correction Technique
Codes are generated by adding a group of parity bits or check bits.
The source generates the binary data which is accepted by encoder to add the
check bits to them to produce the code words.
The check bits are used by decoder to detect and correct the errors.
The encoder adds check bits to the data bits according to the prescribed rule.
Decoder uses parity bits to detect and correct errors after separating data and
The data bits are then applied to the destination.
FEC (Forward Error Correction)
In FEC the receiver searches for the most likely correct code word.
When a Error is detected, the distance between the received invalid code word &
all the possible valid code words in measured.
The nearest valid code word (the one having minimum distance) is the most likely
correct version of the received code word as shown in given figure.
Concept of FEC
Valid Code Word 1
Received Code Word
Valid Code Word 2
Valid Code Word 3
In given figure, The valid code word 1 has the minimum distance (1), hence it is
the most likely correct code word.
The codeword at the receiver of data & CRC.
The receiver treats it as one unit & divides it by the same (n+1) bit divider which
was used at the transmitter.
The reminder of this division is then checked.
If the reminder is Zero, then the received codeword is error free & hence should
Nut non-zero reminder presence of errors hence the corresponding codeword
should be rejected.
If reminder is 0 then no errors.
ARQ Technique (Retransmission)
There are two basic systems of error detection & correction they are
•Automatic repeat request (ARQ).
•Forward error correction (FEC).
In ARQ system when error is detected, a request is made for the retransmission of
The points differs ARQ & FEC are:•In ARQ system less number of check bits (parity bits) are required to be sent. This
will increase the (k/n) ratio for an (n,k) block code if transmitted using the ARQ
•A return transmission path & additional hardware in order to implement repeat
transmission of codeword's will be needed.
•The bit rate of forward transmission must make allowance for the backward
Operations of ARQ System
The encoder produces codeword's for each message signal and its input. Each
codeword at the encoder output is stored temporarily and transmitted over the
forward transmission channel.
At the destination a decoder will decode the code words and look for errors.
If decoder doesn’t get a error than it is positive (ACK), and if he gets negative than
its negative (NAK).
If its NAK than its will return back to “controller” and it will correct the word and
pass it back to input buffer.
A word can be retransmitted twice or more no of times.
The output will be displayed as the errors are being cleared.