Download as pdf or txt
Download as pdf or txt
You are on page 1of 33

Advanced Wireless Network Security

Channel Encoding Techniques –


Error Correction and Detection
Dr. Zafar Iqbal
Assistant Professor
Department of Cyber Security, FCAI.
Air University, Islamabad.

2
Channel Coding

Channel
Encoding

Channel
Decoding

2
Error Detection and Correction

Why Error Types of


Detection? Error?

Due to impairments/ noise, Data can be corrupted


during transmission.

Alteration of critical data, leading to incorrect or


incomplete results

3
Error s

• Single Bit Error

• Burst Error

How we
can detect
and correct
errors?

4
Error Detection and Correction

5
Parity Bit

• A parity bit is a check bit, which is added to a block of data for error detection
purposes.

Error Error Error


Detection Detection – Correction
Capability ? Single Bit Capability?

6
Horizontal and Vertical Parity Bit

Error
Detection/
Correction
Capability
?
7
Horizontal and Vertical Parity Bit

Error ? ?
Detection/
Correction:
>=1 errors, if
occur in diff
Rows/ Columns

PPT - Chapter 4 Data Link Layer PowerPoint Presentation, free download - ID:4706704 (slideserve.com)
8
Retransmission Drawbacks

Latency
Famous
Error
Why we
Detection
need Error Bandwidth Usage and
Correction?
Correction
Techniques?

Limited Availability of Channel

9
Cyclic Redundancy Check (CRC)

Polynomial representations of cyclic redundancy checks

Cyclic redundancy check - Wikipedia

10
Cyclic Redundancy Check (CRC)

CRC
Encoder

CRC
Decoder

11
Cyclic Redundancy Check (CRC)

Online CRC-8 CRC-16 CRC-32 Calculator (crccalc.com)

12
Convolution Codes

Convolutional codes are used extensively to achieve reliable data transfer in


numerous applications:
• Digital video,
• Radio,
• Mobile communications e.g., in GSM, GPRS, EDGE and 3G networks
• Satellite communications.

13
Convolution Encoder

Rate = ½ k=3

k=3

14
Convolution Codes

Digital Communication By Skalr - Page 416

15
Convolution Decoder

16
Convolution Decoder

17
Convolution Decoder

18
Block Codes

Message Block 1 Message Block N

Datawords Redundant Bits

k r

n-bit blocks
19
Block Codes

• The 4B/5B block coding is a good example of this type of coding.


• In this coding scheme, k = 4 and n = 5.
• As we saw, we have 2k = 16 data words and 2n = 32 code words.
• We saw that 16 out of 32 code words are used for message transfer
and the rest are either used for other purposes or unused.

An error-detecting code can detect


only the types of errors for which it is designed; other types of
errors may remain undetected.

20
Block Codes

• Let us assume that k = 2 and n = 3. Table shows the list of datawords and
codewords. Later, we will see how to derive a codeword from a dataword.

• Assume the sender encodes the dataword 01 as 011 and sends it to the receiver.

• The receiver receives 011. It is a valid codeword.

• The receiver extracts the dataword 01 from it.


21
Block Codes
• Assume the sender encodes the dataword 01 as 011 and sends it to the receiver.
Consider the following cases:

The codeword is corrupted during transmission, and


111 is received. This is not a valid codeword and is
discarded.

• The codeword 011 is corrupted during transmission, and becomes 000 is received.
• This is a valid codeword. The receiver incorrectly extracts the dataword 00.
• Two corrupted bits have made the error undetectable.
22
Hamming Distance

The Hamming distance between two words is the


number of differences between corresponding bits.

24
Hamming Distance

The minimum Hamming distance is the smallest


Hamming distance between
all possible pairs in a set of words.

The dmin in this case is 2.

25
Hamming Distance

The minimum Hamming distance is the smallest


Hamming distance between
all possible pairs in a set of words.

The dmin in this case is 3.

26
Hamming Distance

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.
• The minimum Hamming distance for our first code
scheme (Table) is 2.
• This code guarantees detection of only a single
error.
• For example, if the third codeword (101) is sent and
one error occurs, the received codeword does not
match any valid codeword.
• If two errors occur, however, the received codeword
may match a valid codeword and the errors are not
detected.
27
Hamming Distance

To guarantee correction of up to t errors in all cases, the minimum


Hamming distance in a block code
must be dmin = 2t + 1.

A code scheme has a Hamming distance dmin = 4.


What is the error detection and correction capability of this scheme?

This code guarantees the:


• Can detect three errors
• Can correct up to one error

28
Reed Solomon (RS) Code

• Storage areas like CDs, DVDs, Blu-ray Discs, RAID 6

• High speed data transmission technologies such as DSL and WiMAX

• High speed modems

• QR Codes

• Storage systems such as RAID 6

What is Blu-Ray (BD)Disc? | Dell Pakistan RAID 6: Definition, function, pros, and cons - IONOS

29
Reed Solomon (RS) Code

Error Correcting Codes - Reed-Solomon codes (tutorialspoint.com)


30
Reed Solomon (RS) Parameters

• A Reed-Solomon code is specified as RS(n,k).


• n  Block length
• k  Message size
• Parity check size is (n - k) bits
• Error Correction Capability is called t, where (2t = n - k).

31
Reed Solomon (RS) Parameters

• A Reed-Solomon code is specified as RS(n,k).


• n  Block length
• k  Message size
• Parity check size is (n - k) bits
• Error Correction Capability is called t, where (2t = n - k).

32
Interleaving

Interleaved Data Burst Errors

Deinterleaving

33
34

Thank you !

You might also like