CSN Telecommunications. 5: Error Coding. Data, Audio, Video and Images Prof Bill Buchanan

Similar documents
LECTURE #34. Data Communication (CS601)

CMSC 2833 Lecture 18. Parity Add a bit to make the number of ones (1s) transmitted odd.

CS321: Computer Networks Error Detection and Correction

Ch. 7 Error Detection and Correction

Advanced Computer Networks. Rab Nawaz Jadoon DCS. Assistant Professor COMSATS University, Lahore Pakistan. Department of Computer Science

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

UNIT-II 1. Discuss the issues in the data link layer. Answer:

MYcsvtu Notes DATA REPRESENTATION. Data Types. Complements. Fixed Point Representations. Floating Point Representations. Other Binary Codes

Chapter 10 Error Detection and Correction 10.1

Communication Fundamentals in Computer Networks

4. Error correction and link control. Contents

SPM90 MODBUS PROTOCOL AND REGISTER LIST V1.0

Data Link Layer. Srinidhi Varadarajan

Lecture 2 Error Detection & Correction. Types of Errors Detection Correction

Announcement. (CSC-3501) Lecture 3 (22 Jan 2008) Today, 1 st homework will be uploaded at our class website. Seung-Jong Park (Jay)

Data Link Control. Surasak Sanguanpong Last updated: 11 July 2000

Fault Tolerance & Reliability CDA Chapter 2 Additional Interesting Codes

(Refer Slide Time: 2:20)

Implementing CRCCs. Introduction. in Altera Devices

ISO/OSI Reference Model. Data Link Layer. 7. Application. 6. Presentation. 5. Session. 4. Transport. 3. Network. 2. Data Link. 1.

EC500. Design of Secure and Reliable Hardware. Lecture 9. Mark Karpovsky

I. INTRODUCTION. each station (i.e., computer, telephone, etc.) directly connected to all other stations

TYPES OF ERRORS. Data can be corrupted during transmission. Some applications require that errors be detected and corrected.

CHAPTER 2 Data Representation in Computer Systems

PART III. Data Link Layer MGH T MGH C I 204

Lecture 6: Reliable Transmission. CSE 123: Computer Networks Alex Snoeren (guest lecture) Alex Sn

CHAPTER 2 Data Representation in Computer Systems

Basic operators, Arithmetic, Relational, Bitwise, Logical, Assignment, Conditional operators. JAVA Standard Edition

CSE 123: Computer Networks Alex C. Snoeren. HW 1 due Thursday!

Digital Fundamentals

Chapter 3. The Data Link Layer. Wesam A. Hatamleh

CSE 123A Computer Networks

Data Link Protocols. High Level Data. Control Protocol. HDLC Framing ~~~~~~~~ Functions of a Data Link Protocol. Framing PDUs. Addressing Destination

COMPUTER NETWORKS UNIT I. 1. What are the three criteria necessary for an effective and efficient networks?

Error Correction and Detection using Cyclic Redundancy Check

DATA LINK LAYER UNIT 7.

Link Layer: Error detection and correction

Fault-Tolerant Computing

2.4 Error Detection Bit errors in a frame will occur. How do we detect (and then. (or both) frames contains an error. This is inefficient (and not

SRI RAMAKRISHNA INSTITUTE OF TECHNOLOGY DEPARTMENT OF INFORMATION TECHNOLOGY COMPUTER NETWORKS UNIT - II DATA LINK LAYER

Some portions courtesy Robin Kravets and Steve Lumetta

ENEE x Digital Logic Design. Lecture 3

Lecture 5. Homework 2 posted, due September 15. Reminder: Homework 1 due today. Questions? Thursday, September 8 CS 475 Networks - Lecture 5 1

CHW 261: Logic Design

Where we are in the Course

Positional Number System

Chapter Six. Errors, Error Detection, and Error Control. Data Communications and Computer Networks: A Business User s Approach Seventh Edition

CSMC 417. Computer Networks Prof. Ashok K Agrawala Ashok Agrawala Set 4. September 09 CMSC417 Set 4 1

P( Hit 2nd ) = P( Hit 2nd Miss 1st )P( Miss 1st ) = (1/15)(15/16) = 1/16. P( Hit 3rd ) = (1/14) * P( Miss 2nd and 1st ) = (1/14)(14/15)(15/16) = 1/16

Chapter 4. Operations on Data

P( Hit 2nd ) = P( Hit 2nd Miss 1st )P( Miss 1st ) = (1/15)(15/16) = 1/16. P( Hit 3rd ) = (1/14) * P( Miss 2nd and 1st ) = (1/14)(14/15)(15/16) = 1/16

BINARY SYSTEM. Binary system is used in digital systems because it is:

SPM33. MODBUS Protocol and register List V1.5

GO - OPERATORS. This tutorial will explain the arithmetic, relational, logical, bitwise, assignment and other operators one by one.

Chapter 2. Data Representation in Computer Systems

CSMC 417. Computer Networks Prof. Ashok K Agrawala Ashok Agrawala. Nov 1,

by Pearson Education, Inc. All Rights Reserved. 2

Digital Fundamentals. CHAPTER 2 Number Systems, Operations, and Codes

Error Detection Codes. Error Detection. Two Dimensional Parity. Internet Checksum Algorithm. Cyclic Redundancy Check.

Basic Communication Concepts

EE 6900: FAULT-TOLERANT COMPUTING SYSTEMS

Lecture / The Data Link Layer: Framing and Error Detection

Divide: Paper & Pencil

Achieving Reliable Digital Data Communication through Mathematical Algebraic Coding Techniques

Lecture 5: Data Link Layer Basics

INPUT TO (TM/TC) CHANNEL CODING GREEN BOOK(s) AS DISCUSSED AT THE MEETING IN CRYSTAL CITY, VA (USA) on 12 March Frame Error Control Field

Data Link Layer (part 2)

Point-to-Point Links. Outline Encoding Framing Error Detection Sliding Window Algorithm. Fall 2004 CS 691 1

Telecom Systems Chae Y. Lee. Contents. Flow Control Error Detection/Correction Link Control (Error Control) Link Performance (Utility)

Lecture 2: Number Systems

Floating-Point Data Representation and Manipulation 198:231 Introduction to Computer Organization Lecture 3

CSE123A discussion session

FAULT TOLERANT SYSTEMS

CS254 Network Technologies. Lecture 2: Network Models & Error Detection and Correction. Dr Nikos Antonopoulos

Chapter 5: Computer Arithmetic. In this chapter you will learn about:

CSE 461: Framing, Error Detection and Correction

Learning Objectives. Binary over Decimal. In this chapter you will learn about:

Lecture 4: CRC & Reliable Transmission. Lecture 4 Overview. Checksum review. CRC toward a better EDC. Reliable Transmission

Chapter 2. Data Representation in Computer Systems. Objectives (1 of 2) Objectives (2 of 2)

COMPUTER NETWORKS UNIT-3

Digital Fundamentals

JAVA OPERATORS GENERAL

CHAPTER 17 INFORMATION SCIENCE. Binary and decimal numbers a short review: For decimal numbers we have 10 digits available (0, 1, 2, 3, 9) 4731 =

3. Data Link Layer 3-2

Chapter 2. Positional number systems. 2.1 Signed number representations Signed magnitude

Data Link Layer. Overview. Links. Shivkumar Kalyanaraman

Overview. Data Link Technology. Role of the data-link layer. Role of the data-link layer. Function of the physical layer

Computer and Network Security

Chapter 03: Computer Arithmetic. Lesson 09: Arithmetic using floating point numbers

CHAPTER NINE. 9.1 Bitwise Operations. Binary Operation Applications

T325 Summary T305 T325 B BLOCK 4 T325. Session 3. Dr. Saatchi, Seyed Mohsen. Prepared by:

For decimal numbers we have 10 digits available (0, 1, 2, 3, 9) 10,

Digital Fundamentals

Inst: Chris Davison

A Novel Approach for Error Detection using Double Redundancy Check

Universal Asynchronous Receiver Transmitter Communication

Digital Systems and Binary Numbers

1. How many white tiles will be in Design 5 of the pattern? Explain your reasoning.

Data Link Networks. Hardware Building Blocks. Nodes & Links. CS565 Data Link Networks 1

CRC GENERATION AND CHECK

Transcription:

CSN874 Telecommunications 5: Error Coding Data, Audio, Video and Images http://asecuritysite.com/comms Prof Bill Buchanan

CSN874 Telecommunications 5: Error Coding: Modulo-2 Data, Audio, Video and Images http://asecuritysite.com/comms Prof Bill Buchanan

Modulo-2 Digital coding uses modulo-2 arithmetic where addition becomes the following operations: += += += += It performs the equivalent operation to an exclusive-or (XOR) function. For modulo-2 arithmetic, subtraction is the same operation as addition: = = = = Multiplication is performed with the following: = = = = which is an equivalent operation to a logical AND operation.

Binary Manipulation Link. x 4 +x 2 +x+ x 7 + x +x +x 9 +x 8 +x 7 +x 6 +x 5 +x 4 +x 3 +x 2 +x+ x 6 +x 4 +x 2 +x For example: is represented as: (x 2 +)(x 2 +x) which equates to: x 4 +x 3 +x 2 +x which is thus:

Binary Manipulation x 4 +x 4 +x 2 ++ becomes x 2 as x 4 +x 4 =

Binary Manipulation Link. Thus: is represented as: (x 4 +x 2 +)(x 3 +x 2 +x) which equates to: x 7 +x 6 +x 5 +x 5 +x 4 +x 3 +x 3 +x 2 +x which equates to: x 7 +x 6 +x 4 +x 2 +x which is thus:

Modulo-2 Division Link.

Hamming distance Hamming difference between and? Link. The Hamming distance can be used to determine how well the code will cope with errors. The minimum Hamming distance min{d(c,c 2 )} defines by how many bits the code must change so that one code can become another code. A code C can detect up to N errors for any code word if d(c) is greater than or equal to N+ (that is, d(c)n+). A code C can correct up to M errors in any code word if d(c) is greater than or equal to 2M+ (that is, d(c)2m+).

Error detection For example: {,,, } has a Hamming distance of 3. Link. d(c)n+ d(c) is 3, thus N must be 2. So we can detect one or two bits in error in the code. Eg could become... and this will be detected as an error, as the code does not exist.

Error correction For example: {,,, } has a Hamming distance of 3. Link. d(c)2m+ d(c) is 3, thus M must be. So we can correct one bit in error in the code. Eg could become... and as the nearest code will be.

Examples What is the Hamming distance of {,,, } Link? How many errors can be detected? How many errors can be corrected? What is the Hamming distance of {,,,, } Link?

CSN874 Telecommunications 5: Error Coding: Error Correction Data, Audio, Video and Images http://asecuritysite.com/comms Prof Bill Buchanan

Linear and cyclic codes Linear Code: sum of any two codes equals another code - {,,, } and {,,, }. Cyclic Codes: Linear Code + When a cyclic shift also gives a code word - {,,,,,,,, } Is {,,,, } cyclic?

Block parity Odd parity (make number of s odd) or Even parity (make number of s even). Detects single bit errors. Cannot detect when two bits in error in the same position. Example (binary). Link. Example (int). Link. 4 2 6 7

CSN874 Telecommunications Cyclic Redundancy Check Data, Audio, Video and Images

Cyclic redundancy checking (CRC) Example: We have 32, and make it divisible by 9, we add a to make 32, and now divide by 9, to give 35 remainder 4. So lets add 4 to make 324. Now when it is received we divide by 9, and if the answer is zero, there are no errors, and we can ignore the last digit. CRC-CCITT: x 6 +x 2 +x 5 + x 6 +x 2 +x 5 + G(x) The error correction code is 6 bits long and is the remainder of the data message polynomial G(x) divided by the generator polynomial P(x) (x 6 +x 2 +x 5 +, i.e. ). The quotient is discarded and the remainder is truncated to 6 bits. This is then appended to the message as the coded word.

CRC Example Example. Link. For a 7-bit data code determine the encoded bit pattern using a CRC generating polynomial of P(x)=x 3 + x 2 + x. Show that the receiver will not detect an error if there are no bits in error. P(x)=x 3 + x 2 + x () G(x)=x 6 + x 3 + x 2 () Multiply by the number of bits in the CRC polynomial. x 3 (x 6 + x 3 + x 2 ) x 9 + x 6 + x 5 () Figure 5.3 shows the operations at the transmitter. The transmitted message is thus: Figure 5.3

CRC (Receiving) Example. Link. For a 7-bit data code determine the encoded bit pattern using a CRC generating polynomial of P(x)=x 3 + x 2 + x. Show that the receiver will not detect an error if there are no bits in error. P(x)=x 3 + x 2 + x () G(x)=x 6 + x 3 + x 2 () Multiply by the number of bits in the CRC polynomial. x 3 (x 6 + x 3 + x 2 ) x 9 + x 6 + x 5 () Figure 5.3 shows the operations at the transmitter. The transmitted message is thus: No error!

LRC/VRC Link. F r e d d y LRC b b b2 b3 b4 b5 b6 VRC

CSN874 Telecommunications Hamming Code Data, Audio, Video and Images http://asecuritysite.com/comms Prof Bill Buchanan

Hamming Codes Error correction: m is number of bits in the data symbol n is number of Hamming bits n 2 m n Eg if we have 4 bits (m=4). Then to correct we need n=3 (as 8 is greater than or equal to 4+3+). How many error correcting bits would be need for 5 bits?

Hamming Codes The character is The Hamming bits are The message format will be HHHH HHHH Position Code 9 7 3 XOR 9 8 7 6 5 4 3 2

Hamming Codes 9 8 7 6 5 4 3 2 Position Code Hamming 9 7 3 XOR No error Error in bit 5 Position Code Hamming 9 7 5 3 XOR

Hamming Code Sending: P = D D 2 D 4 P 2 = D D 3 D 4 P 3 = D 2 D 3 D 4 D 4 D 3 D 2 P 3 D P 2 P Receiving: S = P D D 2 D 4 S 2 = P 2 D D 3 D 4 S 3 = P 3 D 2 D 3 D 4

Hamming Code H Check of P Check of P 2 Check of P 3

Hamming Code (receiving) At the receiver we calculate the Syndrome matrix S... if all zeros... no error! 3 2 4 3 2 3 2 S S S D D D P D P P T HR S

Hamming Code (Example) Link. H and T T D D 2 D 3 D 4 4 3 2 3 2 D D D P D P P T and D =, D 2 =, D 3 =, D 4 = for even parity: P checks the st, 3rd, 5th and 7th, so P D D 2 D 4 = ; thus P = P 2 checks the 2nd, 3rd, 6th and 7th, so P 2 D D 3 D 4 = ; thus P 2 = P 3 checks the 4th, 5th, 6th and 7th, so P 3 D 2 D 3 D 4 = ; thus P 3 =

Hamming Code Let s check the Syndrome matrix:..................... T HT No error!

Hamming Code Error: R Error in bit 5..................... T HR

CSN874 Telecommunications 5: Error Coding Data, Audio, Video and Images http://asecuritysite.com/comms Prof Bill Buchanan