Modulo-2 Arithmetic - University of Tulsa

Modulo-2 Arithmetic - University of Tulsa

Block Coding Messages are made up of k bits. Transmitted packets have n bits, n > k:

k-data bits and r-redundant bits. n=k+r 1

Modulo-2 Arithmetic Addition and subtraction are described by the logical exclusive-or operation. 2 Modulo-2 Arithmetic (logical xor)

3 Chapter 10 Error Detection and Correction 4 Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Interference

Example causes of interference: Heat Noise due to interference (EM fields)

Attenuation Distortion Interference causes bit errors.

Bit Error Classifications Single bit error Burst error

Single Bit Error Single bit error A one is interpreted as a zero (or vice-versa)

Refers to only one bit modified in a specified transmission unit of data An uncommon type of error for serial data due to the duration of a bit being much less than the duration of interference. Figure 10.1 Single-bit error

8 Burst Error More than one bit is damaged by interference. 9 Figure 10.2

Burst error of length 8 10 Error Detection

Detection of errors is necessary to determine if data should be rejected. Possible responses to error detection include: Retransmission request Forward error correction (corrected on the receiving end)

Forward correction saves bandwidth & time 11 Redundancy Extra bits can be included with the data transmission to assist in the detection and

correction of errors For digital transmissions that implies using block-coding 12 Redundant Bits 13

Detection vs Correction Detection is easier than correction 14 Data Coding Schemes

Block coding described in this course or Convolution coding this is covered in advanced Math or EE signal processing courses. 15 Block Coding

Data-words are made up of k bits. Codewords are made up of k data bits (a dataword) and r redundant bits. n=k+r Where n is the number of bits in a codeword

16 Figure 10.5 Datawords and codewords in block coding 17 Examples

No block coding for 10base-T Ethernet, Manchester coding. 4B/5B block coding (Fast Ethernet), MLT-3 line coding. 8B/10B block coding (Gigabit Ethernet), PAM-5

line coding. 18 19 Error Detection With Block Coding The receiver can detect an error if

The receiver has a list of valid code words A received codeword is not a valid code word 20

Table 10.2 A code for error correction (Example 10.3) 21 Possible Transmission Outcomes A codeword is sent and received without

incident A codeword is sent but is modified in transmission. The error is detected if the codeword is not in the valid codeword list.

A codeword is sent but is modified in transmission. The error is not detected if the resulting new codeword is in the list of valid codewords. 22 Error-Detecting Code Error detecting code can only detect the types

of errors it was designed to detect. Other types of errors may go undetected. 23 The Hamming Distance The Hamming Distance, d(x,y), between two words of the same size is the number of

differences between corresponding bits. Examples d(000,011) = 2 d(10101,11110) = 3 24

Example 10.4 Let us find the Hamming distance between two pairs of words. 1. The Hamming distance d(000, 011) is 2 because 2. The Hamming distance d(10101, 11110) is 3 because 25

Note The minimum Hamming distance is the smallest Hamming distance between all possible pairs in a set of words. 26 Table 10.1 A code for error detection (Example 10.2)

10.27 Example 10.5 Find the minimum Hamming distance of the coding scheme in Table 10.1. Solution We first find all Hamming distances. The dmin in this case is 2.

28 Table 10.2 A code for error correction (Example 10.3) 29 Example 10.6 Find the minimum Hamming distance of the coding

scheme in Table 10.2. Solution We first find all the Hamming distances. The dmin in this case is 3. 30 Note

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. 31 Hamming Code Notation What is the maximum number of detectable errors for each of the two previous coding schemes?

d-min = 2, s = d-min = 3, s = 32

Figure 10.8 Geometric concept for finding dmin in error detection 33 Note To guarantee correction of up to t errors in all cases, the minimum Hamming distance in a block code must be dmin = 2t + 1.

34 Figure 10.9 Geometric concept for finding dmin in error correction 35 How many errors can be corrected for the two example coding schemes: d-min = 2, t =

d-min = 3, t = Note To guarantee correction of up to t errors in all cases, the minimum Hamming distance in a block code must be dmin = 2t + 1. 37

Example A code scheme has dmin = 5. What is the maximum number of detectable errors?

What is the maximum number of correctable errors? 38 Linear Block Codes

A linear block code is a code where the logical exclusive-or of any two valid codewords creates another valid codeword. 39 Linear Block Codes The min Hamming distance for a LBC is the

minimum number of ones in a non-zero valid codeword. 40 Exercise: For each of the next two examples, Compute the

Hamming distance, the number of detectable errors, number of correctable errors Show that the code is linear Table 10.1 A code for error detection C(3,2)

42 Table 10.2 A code for error correction C(5,2) 43 Parity Check Count the number of ones in a data word.

If the count is odd, the redundant bit is one If the count is even, the redundant bit is zero 44

Note A simple parity-check code is a single-bit error-detecting code in which n = k + 1 with dmin = 2. 45 Note

A simple parity-check code can detect an odd number of errors. 46 Table 10.3 Simple parity-check code C(5, 4) 47

How Useful is a Parity Check? Detecting any odd number of errors is pretty good, can we do better? 48 2-Dimensional Parity Check

It is possible to create a 2-D parity check code that detects and corrects errors. 49 Figure 10.11 Two-dimensional parity-check code 50

Figure 10.11 Two-dimensional parity-check code 51 Figure 10.11 Two-dimensional parity-check code 52 Figure 10.11 Two-dimensional parity-check code

53 Interleaving By interleaving the columns into slots, it becomes possible to

detect up to n-row errors. The example is 70%efficient. The efficiency can be improved by adding more rows. Cyclic Codes If a codeword is shifted cyclically, the result is another codeword. (highest order bit becomes the lowest order bit)

Cyclic codes are linear codes 55 C(7,4) Assume d-min = 3. Answer the following about table 10.6: What is the codeword size?

What is the data-word size? Table 10.6 is this C(7, 4) cyclic? 57 C(7,4)

Is the table 10.6 code cyclic? Is it linear? What is d-min? How many detectible errors? How many correctible errors? Hamming Codes d-min >= 3 Minimum number of detectable errors: 2 Minimum number of correctable errors: 1

For C(n,k), n = 2^r 1 r = n k (number of redundant bits) k >= 3 Which are Hamming Codes?

C(7,4) C(7,3) Error Correction 1. Using CRC codes computing bit syndromes 2. Using interleaving with multiplexing. Use a parity bit in each frame

Check for invalid code words (see example exercises) Checksum Adding the codewords together at the source

and destination. If the sum at the source and destination match, there is a good chance that no errors occurred.

Checksums are not as reliable as the CRC. 62 Checksum Examples 1's complement

16 bit checksum used by the Internet 63 Sender: Checksum Calculation 1. Divide into 16 bit unsigned words 2. Add the 16 bit words using 1s complement addition. 3. Complement the total

4. Send all the above words. Receiver: Checksum Calculation 1. Divide into 16 bit words 1.Add the 16 bit words and the checksum value using 1s complement arithmetic. 2.The complement of the total should be zero. Example: Sender 0x466f

0x726f 0x757a +_______ 0x12e58 partial sum 0x2e59 sum 0xd1a6 complement Example: Receiver 0x466f 0x726f

0x757a 0xd1a6 (senders checksum) +_______ 0x1fffe (partial sum) 0xffff (sum) 0x0000 (complement)

Recently Viewed Presentations

  • 21st CiCea Conference 2019, Prague. Europe at a

    21st CiCea Conference 2019, Prague. Europe at a

    There is a change from a participatory citizenship (1996), understood in relation to specific criteria (having a knowledge of facts, gaining certain skills, and self-reflecting in ways that will enable students to become participatory citizens) to participation as part of...
  • Decolonising Urban Planning

    Decolonising Urban Planning

    Decolonising Urban Planning. Lena Henry. Reflections, Aspirations& Plans. Acknowledgement. Former Auckland City Council - PaeHerengaTangata. IHI Action Group. Independent Māori Statutory Board. NgāAho. Papa Pounamu. Te Kotahi ResearchInstitute. Te Whaihanga Project Team.
  • Day x 1. 5-10 minute quiz SVD demo

    Day x 1. 5-10 minute quiz SVD demo

    Linear constraints on F let x = (x,y,1) and x' = (x',y',1) be a point correspondence between 2 images, and let F be the fundamental matrix of the images we know that the point pair satisfies x' F x =...
  • New York State Office of Children and Family

    New York State Office of Children and Family

    * ROB * * ROB * ROB * Presentation Overview Welcome and Introductions CCTA Enhancements (Year 2A, 2B, and 3) Q & A Livingston County Promotes CCTA web-submittal Biometric Devices & CCTA Monroe County - Managing and Monitoring the Child...
  • Introduction to Computer Systems 15-213/18-243, spring 2009 ...

    Introduction to Computer Systems 15-213/18-243, spring 2009 ...

    Redesign of slides created by Randal E. Bryant and David R. O'Hallaron
  • Headquarters U. S. Air Force Integrity - Service

    Headquarters U. S. Air Force Integrity - Service

    Full & Sub-scale Aerial Targets Overview 2 locations -- Tyndall AFB and Holloman AFB (WSMR) 20 x QF-4s required to maintain full-time test capability at each operating location HQ USAF/TEP manages kill authorizations (KAs) "Honest broker" among all requestors Non-OSD...
  • ACI Multi-Site Architecture and Deployment Max Ardica Principal

    ACI Multi-Site Architecture and Deployment Max Ardica Principal

    GOLF Routers (ASR 9000, ASR 1000, Nexus 7000) Direct or indirect connection from spines to WAN Edge routers. Better scalability, one protocol session for all VRFs, no longer constraint by border leaf HW table. VXLAN handoff with MP-BGPEVPN.
  • Polk County School Board Employee Health Clinic

    Polk County School Board Employee Health Clinic

    POLK COUNTY SCHOOL BOARD EMPLOYEE HEALTH CLINIC. ... Two welcoming waiting rooms, one for well patients and one for sick patients, are available for your comfort while waiting for your appointment. Sick waiting room ...