SlideShare a Scribd company logo
DATA COMMUNICATIONS &
NETWORKING
LECTURE-
21
Course Instructor : Sehrish Rafiq
Department Of Computer Science
University Of Peshawar
LECTURE OVERVIEW
 CRC
 Performance of CRC
 Checksum
 Performance of Checksum
ERROR DETECTION METHODS
CYCLIC REDUNDANCY CHECK
 The third and the most powerful technique is CRC.
 CRC is based on binary division.
 In CRC a sequence of redundant bits called the CRC
or CRC remainder is appended to the end of a data
unit.
 So that the resulting data unit becomes exactly
divisible by a second, predetermined binary number.
 At the destination, the incoming data unit is divided
by the same number.
CYCLIC REDUNDANCY CHECK
 If at this step there is no remainder the data unit
is assumed to be intact and is accepted.
 A remainder indicates that the data unit has
been damaged in transit and therefore must be
rejected.
REDUNDANCY BITS
 The redundancy bits used by CRC are derived by
dividing the data unit by a predetermined
divisor,the remainder is the CRC.
 To be valid, a CRC must have two qualities.
 It must have exactly one less bit than the divisor.
 Appending it to the end of the data string must
make the resulting bit sequence exactly divisible
by the divisor.
CRC GENERATOR & CHECKER
BINARY DIVISION IN A CRC
GENERATOR
BINARY DIVISION IN CRC
CHECKER
HOW IT WORKS???
 At the Transmitter:
 Step 1: A string of n 0’s is appended to the data
unit.
 The number n is 1 less than the number of bits in the
predetermined divisor which is n+1 bits.
 Step 2: The newly elongated data unit is divided
by the divisor using a process called binary
division.
 The remainder resulting from this division is the CRC.
 Step 3: The CRC derived in step 2 replaces the
appended 0’s at the end of the data unit.
HOW IT WORKS???
 At the receiver:
 The data unit arrives at the receiver data first
followed by the CRC.
 Step 1: The receiver treats the whole string as a
unit and divides it by the same divisor that was
used to find the CRC remainder.
 Result:
 If the string arrives without error ,the CRC checker yields
a remainder of 0 and the data unit passes.
 If the string has been changed in transit ,the division
yields a non zero remainder and the string passes.
THE CRC DIVISOR
 The divisor in the CRC generator is most often
represented not as a string of 1’s and 0’s but as
an algebraic polynomial.
 A polynomial should be selected to have at least
the following properties:
 It should not be divisible by x.
 It should be divisible by x+1.
 E.g.
A POLYNOMIAL
REPRESENTING A DIVISOR
STANDARD POLYNOMIALS
Name Polynomial Application
CRC-8CRC-8 x8
+ x2
+ x + 1 ATM header
CRC-10CRC-10 x10
+ x9
+ x5
+ x4
+ x2
+ 1 ATM AAL
ITU-16ITU-16 x16
+ x12
+ x5
+ 1 HDLC
ITU-32ITU-32
x32
+ x26
+ x23
+ x22
+ x16
+ x12
+ x11
+ x10
+ x8
+ x7
+ x5
+ x4
+ x2
+ x + 1
LANs
PERFORMANCE OF CRC
 CRC can detect all burst errors that effect an
odd number of bits.
 CRC can detect all burst errors of length less
than or equal to the degree of polynomial.
 CRC can detect with a very high probability
,burst errors of length greater than the degree of
polynomial.
CHECKSUM
 The checksum is also based on the concept of
redundancy.
CHECKSUM GENERATOR
 The sender follows these steps:
 Step 1: The unit is divided in to k sections, each
of n bits.
 Step 2: All sections are added using one’s
complement to get the sum in such a way that
the total is also n bits long.
 Step 3: The sum is then complemented and
becomes the checksum.
 Step 4: The checksum is sent with the data.
CHECKSUM CHECKER
 The sender follows these steps:
 Step 1: The unit is divided in to k sections, each
of n bits.
 Step 2: All sections are added using one’s
complement to get the sum in such a way that
the total is also n bits long.

 Step 3: The sum is then complemented.
 Step 4: If the result is zero, the data are
accepted, otherwise they are rejected.
CHECKSUM
DATA UNIT AND CHECKSUM
Example 1Example 1
Suppose the following block of 16 bits is to be sent using a
checksum of 8 bits.
10101001 00111001
The numbers are added using one’s complement
10101001
00111001
------------
Sum 11100010
Checksum 00011101
The pattern sent is 10101001 00111001 00011101
EXAMPLE 1 CONTINUED…
Now suppose the receiver receives the pattern sent and there is no
error.
10101001 00111001 00011101
When the receiver adds the three sections, it will get all 1s, which,
after complementing, is all 0s and shows that there is no error.
10101001
00111001
00011101
Sum 11111111
Complement 00000000 means that the pattern is OK.
EXAMPLE 1 CONTINUED…
Now suppose there is a burst error of length 5 that affects 4
bits.
10101111 11111001 00011101
When the receiver adds the three sections, it gets
10101111
11111001
00011101
Partial Sum 1 11000101
Carry 1
Sum 11000110
Complement 00111001 the pattern is corrupted.
PERFORMANCE OF CHECKSUM
 The checksum detects all errors involving an odd
number of bits as well as most errors involving
an even number of bits.
 However if one or more bits of a segment are
damaged and the corresponding bit or bits of
opposite value in a second segment are also
damaged,the sums of those columns will not
change and the receiver will not detect a
problem.
 Checksum retains all carriers, so although two 0s
becoming 1 would not alter the value of their own
column,it would change the value of the next
higher column.
THANKS!!!

More Related Content

What's hot

Block coding, error detection (Parity checking, Cyclic redundancy checking (C...
Block coding, error detection (Parity checking, Cyclic redundancy checking (C...Block coding, error detection (Parity checking, Cyclic redundancy checking (C...
Block coding, error detection (Parity checking, Cyclic redundancy checking (C...
Paulo_Vangui
 
Media Access Control (MAC Layer)
Media Access Control (MAC Layer)Media Access Control (MAC Layer)
Media Access Control (MAC Layer)
Meenakshi Paul
 
Congestion control 1
Congestion control 1Congestion control 1
Congestion control 1
Aman Jaiswal
 
Error Detection And Correction
Error Detection And CorrectionError Detection And Correction
Error Detection And Correction
Renu Kewalramani
 
Chapter 4 data link layer
Chapter 4 data link layerChapter 4 data link layer
Chapter 4 data link layer
Naiyan Noor
 
Lecture 5
Lecture 5Lecture 5
Error correction error detection in digital communication
Error correction error detection in digital communicationError correction error detection in digital communication
Error correction error detection in digital communication
swatihalunde
 
Error Detection and Correction presentation
Error Detection and Correction presentation Error Detection and Correction presentation
Error Detection and Correction presentation
Badrul Alam
 
Data Communication And Networking - DATA RATE LIMITS
Data Communication And Networking - DATA RATE LIMITSData Communication And Networking - DATA RATE LIMITS
Data Communication And Networking - DATA RATE LIMITS
Avijeet Negel
 
Error Detection N Correction
Error Detection N CorrectionError Detection N Correction
Error Detection N Correction
Ankan Adhikari
 
Error Detection and Correction
Error Detection and CorrectionError Detection and Correction
Error Detection and Correction
TechiNerd
 
x.509-Directory Authentication Service
x.509-Directory Authentication Servicex.509-Directory Authentication Service
x.509-Directory Authentication Service
Swathy T
 
MAC-Message Authentication Codes
MAC-Message Authentication CodesMAC-Message Authentication Codes
MAC-Message Authentication Codes
DarshanPatil82
 
BCH Codes
BCH CodesBCH Codes
BCH Codes
AakankshaR
 
The mac layer
The mac layerThe mac layer
The mac layer
aazamk
 
Hamming codes
Hamming codesHamming codes
Hamming codes
GIGI JOSEPH
 
Error Detection and correction concepts in Data communication and networks
Error Detection and correction concepts in Data communication and networksError Detection and correction concepts in Data communication and networks
Error Detection and correction concepts in Data communication and networks
Nt Arvind
 
Lecture 20
Lecture 20Lecture 20
Lecture 20
Sehrish Rafiq
 
Introduction to the Data Link Layer
Introduction to the Data Link LayerIntroduction to the Data Link Layer
Introduction to the Data Link Layer
Meenakshi Paul
 
Error detection and correction
Error detection and correctionError detection and correction
Error detection and correction
Maria Akther
 

What's hot (20)

Block coding, error detection (Parity checking, Cyclic redundancy checking (C...
Block coding, error detection (Parity checking, Cyclic redundancy checking (C...Block coding, error detection (Parity checking, Cyclic redundancy checking (C...
Block coding, error detection (Parity checking, Cyclic redundancy checking (C...
 
Media Access Control (MAC Layer)
Media Access Control (MAC Layer)Media Access Control (MAC Layer)
Media Access Control (MAC Layer)
 
Congestion control 1
Congestion control 1Congestion control 1
Congestion control 1
 
Error Detection And Correction
Error Detection And CorrectionError Detection And Correction
Error Detection And Correction
 
Chapter 4 data link layer
Chapter 4 data link layerChapter 4 data link layer
Chapter 4 data link layer
 
Lecture 5
Lecture 5Lecture 5
Lecture 5
 
Error correction error detection in digital communication
Error correction error detection in digital communicationError correction error detection in digital communication
Error correction error detection in digital communication
 
Error Detection and Correction presentation
Error Detection and Correction presentation Error Detection and Correction presentation
Error Detection and Correction presentation
 
Data Communication And Networking - DATA RATE LIMITS
Data Communication And Networking - DATA RATE LIMITSData Communication And Networking - DATA RATE LIMITS
Data Communication And Networking - DATA RATE LIMITS
 
Error Detection N Correction
Error Detection N CorrectionError Detection N Correction
Error Detection N Correction
 
Error Detection and Correction
Error Detection and CorrectionError Detection and Correction
Error Detection and Correction
 
x.509-Directory Authentication Service
x.509-Directory Authentication Servicex.509-Directory Authentication Service
x.509-Directory Authentication Service
 
MAC-Message Authentication Codes
MAC-Message Authentication CodesMAC-Message Authentication Codes
MAC-Message Authentication Codes
 
BCH Codes
BCH CodesBCH Codes
BCH Codes
 
The mac layer
The mac layerThe mac layer
The mac layer
 
Hamming codes
Hamming codesHamming codes
Hamming codes
 
Error Detection and correction concepts in Data communication and networks
Error Detection and correction concepts in Data communication and networksError Detection and correction concepts in Data communication and networks
Error Detection and correction concepts in Data communication and networks
 
Lecture 20
Lecture 20Lecture 20
Lecture 20
 
Introduction to the Data Link Layer
Introduction to the Data Link LayerIntroduction to the Data Link Layer
Introduction to the Data Link Layer
 
Error detection and correction
Error detection and correctionError detection and correction
Error detection and correction
 

Viewers also liked

Lecture 06
Lecture 06Lecture 06
Lecture 06
Sehrish Rafiq
 
Lecture 19
Lecture 19Lecture 19
Lecture 19
Sehrish Rafiq
 
Checksum 101
Checksum 101Checksum 101
Checksum 101
Ross Spencer
 
Lecture 24
Lecture 24Lecture 24
Lecture 24
Sehrish Rafiq
 
Lecture 03
Lecture 03Lecture 03
Lecture 03
Sehrish Rafiq
 
Lecture 18
Lecture 18Lecture 18
Lecture 18
Sehrish Rafiq
 
Lecture 12
Lecture 12Lecture 12
Lecture 12
Sehrish Rafiq
 
Lecture 13
Lecture 13Lecture 13
Lecture 13
Sehrish Rafiq
 
Lecture 07
Lecture 07Lecture 07
Lecture 07
Sehrish Rafiq
 
Data Communications and Networking Lecture 16
Data Communications and Networking Lecture 16Data Communications and Networking Lecture 16
Data Communications and Networking Lecture 16
Sehrish Rafiq
 
Lecture 17
Lecture 17Lecture 17
Lecture 17
Sehrish Rafiq
 
Lecture 11
Lecture 11Lecture 11
Lecture 11
Sehrish Rafiq
 
Data communication - Lecture-01
Data communication - Lecture-01 Data communication - Lecture-01
Data communication - Lecture-01
Sehrish Rafiq
 
Powerpoint for data communication
Powerpoint for data communication Powerpoint for data communication
Powerpoint for data communication
samanthaanderson21
 
Data communication (simple explanation)
Data communication (simple explanation)Data communication (simple explanation)
Data communication (simple explanation)
Twist Akid Sultan
 
Chapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and NetworksChapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and Networks
Shafaan Khaliq Bhatti
 
OperacióN Binaria
OperacióN BinariaOperacióN Binaria
OperacióN Binaria
guest3c75fbe
 
05 directnets errors
05 directnets errors05 directnets errors
05 directnets errors
jyang1983
 
Checksum explaination
Checksum explainationChecksum explaination
Checksum explaination
Mohammed Fuzail
 
Cyclic redundancy check
Cyclic redundancy checkCyclic redundancy check
Cyclic redundancy check
Saleh Alrkiyan
 

Viewers also liked (20)

Lecture 06
Lecture 06Lecture 06
Lecture 06
 
Lecture 19
Lecture 19Lecture 19
Lecture 19
 
Checksum 101
Checksum 101Checksum 101
Checksum 101
 
Lecture 24
Lecture 24Lecture 24
Lecture 24
 
Lecture 03
Lecture 03Lecture 03
Lecture 03
 
Lecture 18
Lecture 18Lecture 18
Lecture 18
 
Lecture 12
Lecture 12Lecture 12
Lecture 12
 
Lecture 13
Lecture 13Lecture 13
Lecture 13
 
Lecture 07
Lecture 07Lecture 07
Lecture 07
 
Data Communications and Networking Lecture 16
Data Communications and Networking Lecture 16Data Communications and Networking Lecture 16
Data Communications and Networking Lecture 16
 
Lecture 17
Lecture 17Lecture 17
Lecture 17
 
Lecture 11
Lecture 11Lecture 11
Lecture 11
 
Data communication - Lecture-01
Data communication - Lecture-01 Data communication - Lecture-01
Data communication - Lecture-01
 
Powerpoint for data communication
Powerpoint for data communication Powerpoint for data communication
Powerpoint for data communication
 
Data communication (simple explanation)
Data communication (simple explanation)Data communication (simple explanation)
Data communication (simple explanation)
 
Chapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and NetworksChapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and Networks
 
OperacióN Binaria
OperacióN BinariaOperacióN Binaria
OperacióN Binaria
 
05 directnets errors
05 directnets errors05 directnets errors
05 directnets errors
 
Checksum explaination
Checksum explainationChecksum explaination
Checksum explaination
 
Cyclic redundancy check
Cyclic redundancy checkCyclic redundancy check
Cyclic redundancy check
 

Similar to Lecture 21

Skr+3200+chapter+3+(kweh)
Skr+3200+chapter+3+(kweh)Skr+3200+chapter+3+(kweh)
Skr+3200+chapter+3+(kweh)
Ammar Shafiq
 
III_UNIT_ErrorCorrecting.pptx
III_UNIT_ErrorCorrecting.pptxIII_UNIT_ErrorCorrecting.pptx
III_UNIT_ErrorCorrecting.pptx
ShantanuDharekar
 
Computer Networks Module II
Computer Networks Module IIComputer Networks Module II
Computer Networks Module II
Ajit Nayak
 
Data link layar
Data link layarData link layar
Data link layar
jaysanshrestha
 
Data link layar
Data link layarData link layar
Data link layar
jaysanshrestha
 
B0210714
B0210714B0210714
B0210714
IOSR Journals
 
computer networks Error Detection Methods.pdf
computer networks Error Detection Methods.pdfcomputer networks Error Detection Methods.pdf
computer networks Error Detection Methods.pdf
Balasubramanian699229
 
Error Control In Network Layer
Error Control In Network LayerError Control In Network Layer
Error Control In Network Layer
Ahtesham Ullah khan
 
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
ZahouAmel1
 
Error detection.
Error detection.Error detection.
Error detection.
Wasim Akbar
 
07 Data Link LayerError Control.pdf
07 Data Link LayerError Control.pdf07 Data Link LayerError Control.pdf
07 Data Link LayerError Control.pdf
baysahcmjames2kblax
 
Ch3 datalink
Ch3 datalinkCh3 datalink
Ch3 datalink
Ramesh Kumar
 
Ch 10
Ch 10Ch 10
Error detection and correction
Error detection and correctionError detection and correction
Error detection and correction
Sisir Ghosh
 
Error control 20
Error control 20Error control 20
Error control 20
zulhelman hanafi
 
Error detection techniques
Error detection techniquesError detection techniques
Error detection techniques
kunjan shah
 
Cyclic Redundancy Check in Computers Network
Cyclic Redundancy Check in Computers Network Cyclic Redundancy Check in Computers Network
Cyclic Redundancy Check in Computers Network
ShivangiTak1
 
Error.pdf
Error.pdfError.pdf
Error.pdf
IvyRamosCaones
 
COMPUTER NETWORKS UNIT 2
COMPUTER NETWORKS UNIT 2COMPUTER NETWORKS UNIT 2
COMPUTER NETWORKS UNIT 2
BON SECOURS COLLEGE FOR WOMEN
 
computer Networks Error Detection and Correction.ppt
computer Networks Error Detection and Correction.pptcomputer Networks Error Detection and Correction.ppt
computer Networks Error Detection and Correction.ppt
Jayaprasanna4
 

Similar to Lecture 21 (20)

Skr+3200+chapter+3+(kweh)
Skr+3200+chapter+3+(kweh)Skr+3200+chapter+3+(kweh)
Skr+3200+chapter+3+(kweh)
 
III_UNIT_ErrorCorrecting.pptx
III_UNIT_ErrorCorrecting.pptxIII_UNIT_ErrorCorrecting.pptx
III_UNIT_ErrorCorrecting.pptx
 
Computer Networks Module II
Computer Networks Module IIComputer Networks Module II
Computer Networks Module II
 
Data link layar
Data link layarData link layar
Data link layar
 
Data link layar
Data link layarData link layar
Data link layar
 
B0210714
B0210714B0210714
B0210714
 
computer networks Error Detection Methods.pdf
computer networks Error Detection Methods.pdfcomputer networks Error Detection Methods.pdf
computer networks Error Detection Methods.pdf
 
Error Control In Network Layer
Error Control In Network LayerError Control In Network Layer
Error Control In Network Layer
 
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols5-LEC- 5.pptxTransport Layer.  Transport Layer Protocols
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
 
Error detection.
Error detection.Error detection.
Error detection.
 
07 Data Link LayerError Control.pdf
07 Data Link LayerError Control.pdf07 Data Link LayerError Control.pdf
07 Data Link LayerError Control.pdf
 
Ch3 datalink
Ch3 datalinkCh3 datalink
Ch3 datalink
 
Ch 10
Ch 10Ch 10
Ch 10
 
Error detection and correction
Error detection and correctionError detection and correction
Error detection and correction
 
Error control 20
Error control 20Error control 20
Error control 20
 
Error detection techniques
Error detection techniquesError detection techniques
Error detection techniques
 
Cyclic Redundancy Check in Computers Network
Cyclic Redundancy Check in Computers Network Cyclic Redundancy Check in Computers Network
Cyclic Redundancy Check in Computers Network
 
Error.pdf
Error.pdfError.pdf
Error.pdf
 
COMPUTER NETWORKS UNIT 2
COMPUTER NETWORKS UNIT 2COMPUTER NETWORKS UNIT 2
COMPUTER NETWORKS UNIT 2
 
computer Networks Error Detection and Correction.ppt
computer Networks Error Detection and Correction.pptcomputer Networks Error Detection and Correction.ppt
computer Networks Error Detection and Correction.ppt
 

More from Sehrish Rafiq

Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14
Sehrish Rafiq
 
Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13
Sehrish Rafiq
 
Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12
Sehrish Rafiq
 
Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11
Sehrish Rafiq
 
Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10
Sehrish Rafiq
 
Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9
Sehrish Rafiq
 
Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8
Sehrish Rafiq
 
Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7
Sehrish Rafiq
 
Introduction to computers Lecture # 4
Introduction to computers Lecture # 4Introduction to computers Lecture # 4
Introduction to computers Lecture # 4
Sehrish Rafiq
 
Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5
Sehrish Rafiq
 
Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3
Sehrish Rafiq
 
Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2
Sehrish Rafiq
 
Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1
Sehrish Rafiq
 
Lecture 22
Lecture 22Lecture 22
Lecture 22
Sehrish Rafiq
 
Lecture 23
Lecture 23Lecture 23
Lecture 23
Sehrish Rafiq
 
Lecture 15
Lecture 15Lecture 15
Lecture 15
Sehrish Rafiq
 
Lecture 14
Lecture 14Lecture 14
Lecture 14
Sehrish Rafiq
 
Lecture 10
Lecture 10Lecture 10
Lecture 10
Sehrish Rafiq
 

More from Sehrish Rafiq (18)

Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14Introduction to Computers Lecture # 14
Introduction to Computers Lecture # 14
 
Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13Introduction to Computers Lecture # 13
Introduction to Computers Lecture # 13
 
Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12Introduction to Computers Lecture # 12
Introduction to Computers Lecture # 12
 
Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11Introduction to Computers Lecture # 11
Introduction to Computers Lecture # 11
 
Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10Introduction to Computers Lecture # 10
Introduction to Computers Lecture # 10
 
Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9Introduction to Computers Lecture # 9
Introduction to Computers Lecture # 9
 
Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8Introduction to Computers Lecture # 8
Introduction to Computers Lecture # 8
 
Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7Introduction to Computers Lecture # 7
Introduction to Computers Lecture # 7
 
Introduction to computers Lecture # 4
Introduction to computers Lecture # 4Introduction to computers Lecture # 4
Introduction to computers Lecture # 4
 
Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5Introduction to Computers Lecture # 5
Introduction to Computers Lecture # 5
 
Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3Introduction to Computers Lecture # 3
Introduction to Computers Lecture # 3
 
Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2Introduction to Computers Lecture # 2
Introduction to Computers Lecture # 2
 
Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1Introduction to Computers Lecture # 1
Introduction to Computers Lecture # 1
 
Lecture 22
Lecture 22Lecture 22
Lecture 22
 
Lecture 23
Lecture 23Lecture 23
Lecture 23
 
Lecture 15
Lecture 15Lecture 15
Lecture 15
 
Lecture 14
Lecture 14Lecture 14
Lecture 14
 
Lecture 10
Lecture 10Lecture 10
Lecture 10
 

Recently uploaded

Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Alpen-Adria-Universität
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Safe Software
 
A Comprehensive Guide to DeFi Development Services in 2024
A Comprehensive Guide to DeFi Development Services in 2024A Comprehensive Guide to DeFi Development Services in 2024
A Comprehensive Guide to DeFi Development Services in 2024
Intelisync
 
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxOcean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
SitimaJohn
 
June Patch Tuesday
June Patch TuesdayJune Patch Tuesday
June Patch Tuesday
Ivanti
 
Letter and Document Automation for Bonterra Impact Management (fka Social Sol...
Letter and Document Automation for Bonterra Impact Management (fka Social Sol...Letter and Document Automation for Bonterra Impact Management (fka Social Sol...
Letter and Document Automation for Bonterra Impact Management (fka Social Sol...
Jeffrey Haguewood
 
Operating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptxOperating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptx
Pravash Chandra Das
 
AWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptxAWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptx
HarisZaheer8
 
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying AheadDigital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Wask
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
alexjohnson7307
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
Zilliz
 
Recommendation System using RAG Architecture
Recommendation System using RAG ArchitectureRecommendation System using RAG Architecture
Recommendation System using RAG Architecture
fredae14
 
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
saastr
 
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStrDeep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
saastr
 
Nunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdf
Nunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdfNunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdf
Nunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdf
flufftailshop
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
Jakub Marek
 
WeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation TechniquesWeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation Techniques
Postman
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 

Recently uploaded (20)

Energy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing InstancesEnergy Efficient Video Encoding for Cloud and Edge Computing Instances
Energy Efficient Video Encoding for Cloud and Edge Computing Instances
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
 
A Comprehensive Guide to DeFi Development Services in 2024
A Comprehensive Guide to DeFi Development Services in 2024A Comprehensive Guide to DeFi Development Services in 2024
A Comprehensive Guide to DeFi Development Services in 2024
 
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptxOcean lotus Threat actors project by John Sitima 2024 (1).pptx
Ocean lotus Threat actors project by John Sitima 2024 (1).pptx
 
June Patch Tuesday
June Patch TuesdayJune Patch Tuesday
June Patch Tuesday
 
Letter and Document Automation for Bonterra Impact Management (fka Social Sol...
Letter and Document Automation for Bonterra Impact Management (fka Social Sol...Letter and Document Automation for Bonterra Impact Management (fka Social Sol...
Letter and Document Automation for Bonterra Impact Management (fka Social Sol...
 
Operating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptxOperating System Used by Users in day-to-day life.pptx
Operating System Used by Users in day-to-day life.pptx
 
AWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptxAWS Cloud Cost Optimization Presentation.pptx
AWS Cloud Cost Optimization Presentation.pptx
 
Digital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying AheadDigital Marketing Trends in 2024 | Guide for Staying Ahead
Digital Marketing Trends in 2024 | Guide for Staying Ahead
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
leewayhertz.com-AI in predictive maintenance Use cases technologies benefits ...
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
Generating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and MilvusGenerating privacy-protected synthetic data using Secludy and Milvus
Generating privacy-protected synthetic data using Secludy and Milvus
 
Recommendation System using RAG Architecture
Recommendation System using RAG ArchitectureRecommendation System using RAG Architecture
Recommendation System using RAG Architecture
 
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
Overcoming the PLG Trap: Lessons from Canva's Head of Sales & Head of EMEA Da...
 
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStrDeep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
Deep Dive: Getting Funded with Jason Jason Lemkin Founder & CEO @ SaaStr
 
Nunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdf
Nunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdfNunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdf
Nunit vs XUnit vs MSTest Differences Between These Unit Testing Frameworks.pdf
 
Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)Main news related to the CCS TSI 2023 (2023/1695)
Main news related to the CCS TSI 2023 (2023/1695)
 
WeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation TechniquesWeTestAthens: Postman's AI & Automation Techniques
WeTestAthens: Postman's AI & Automation Techniques
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 

Lecture 21

  • 1. DATA COMMUNICATIONS & NETWORKING LECTURE- 21 Course Instructor : Sehrish Rafiq Department Of Computer Science University Of Peshawar
  • 2. LECTURE OVERVIEW  CRC  Performance of CRC  Checksum  Performance of Checksum
  • 4. CYCLIC REDUNDANCY CHECK  The third and the most powerful technique is CRC.  CRC is based on binary division.  In CRC a sequence of redundant bits called the CRC or CRC remainder is appended to the end of a data unit.  So that the resulting data unit becomes exactly divisible by a second, predetermined binary number.  At the destination, the incoming data unit is divided by the same number.
  • 5. CYCLIC REDUNDANCY CHECK  If at this step there is no remainder the data unit is assumed to be intact and is accepted.  A remainder indicates that the data unit has been damaged in transit and therefore must be rejected.
  • 6. REDUNDANCY BITS  The redundancy bits used by CRC are derived by dividing the data unit by a predetermined divisor,the remainder is the CRC.  To be valid, a CRC must have two qualities.  It must have exactly one less bit than the divisor.  Appending it to the end of the data string must make the resulting bit sequence exactly divisible by the divisor.
  • 7. CRC GENERATOR & CHECKER
  • 8. BINARY DIVISION IN A CRC GENERATOR
  • 9. BINARY DIVISION IN CRC CHECKER
  • 10. HOW IT WORKS???  At the Transmitter:  Step 1: A string of n 0’s is appended to the data unit.  The number n is 1 less than the number of bits in the predetermined divisor which is n+1 bits.  Step 2: The newly elongated data unit is divided by the divisor using a process called binary division.  The remainder resulting from this division is the CRC.  Step 3: The CRC derived in step 2 replaces the appended 0’s at the end of the data unit.
  • 11. HOW IT WORKS???  At the receiver:  The data unit arrives at the receiver data first followed by the CRC.  Step 1: The receiver treats the whole string as a unit and divides it by the same divisor that was used to find the CRC remainder.  Result:  If the string arrives without error ,the CRC checker yields a remainder of 0 and the data unit passes.  If the string has been changed in transit ,the division yields a non zero remainder and the string passes.
  • 12. THE CRC DIVISOR  The divisor in the CRC generator is most often represented not as a string of 1’s and 0’s but as an algebraic polynomial.  A polynomial should be selected to have at least the following properties:  It should not be divisible by x.  It should be divisible by x+1.  E.g.
  • 14. STANDARD POLYNOMIALS Name Polynomial Application CRC-8CRC-8 x8 + x2 + x + 1 ATM header CRC-10CRC-10 x10 + x9 + x5 + x4 + x2 + 1 ATM AAL ITU-16ITU-16 x16 + x12 + x5 + 1 HDLC ITU-32ITU-32 x32 + x26 + x23 + x22 + x16 + x12 + x11 + x10 + x8 + x7 + x5 + x4 + x2 + x + 1 LANs
  • 15. PERFORMANCE OF CRC  CRC can detect all burst errors that effect an odd number of bits.  CRC can detect all burst errors of length less than or equal to the degree of polynomial.  CRC can detect with a very high probability ,burst errors of length greater than the degree of polynomial.
  • 16. CHECKSUM  The checksum is also based on the concept of redundancy.
  • 17. CHECKSUM GENERATOR  The sender follows these steps:  Step 1: The unit is divided in to k sections, each of n bits.  Step 2: All sections are added using one’s complement to get the sum in such a way that the total is also n bits long.  Step 3: The sum is then complemented and becomes the checksum.  Step 4: The checksum is sent with the data.
  • 18. CHECKSUM CHECKER  The sender follows these steps:  Step 1: The unit is divided in to k sections, each of n bits.  Step 2: All sections are added using one’s complement to get the sum in such a way that the total is also n bits long.   Step 3: The sum is then complemented.  Step 4: If the result is zero, the data are accepted, otherwise they are rejected.
  • 20. DATA UNIT AND CHECKSUM
  • 21. Example 1Example 1 Suppose the following block of 16 bits is to be sent using a checksum of 8 bits. 10101001 00111001 The numbers are added using one’s complement 10101001 00111001 ------------ Sum 11100010 Checksum 00011101 The pattern sent is 10101001 00111001 00011101
  • 22. EXAMPLE 1 CONTINUED… Now suppose the receiver receives the pattern sent and there is no error. 10101001 00111001 00011101 When the receiver adds the three sections, it will get all 1s, which, after complementing, is all 0s and shows that there is no error. 10101001 00111001 00011101 Sum 11111111 Complement 00000000 means that the pattern is OK.
  • 23. EXAMPLE 1 CONTINUED… Now suppose there is a burst error of length 5 that affects 4 bits. 10101111 11111001 00011101 When the receiver adds the three sections, it gets 10101111 11111001 00011101 Partial Sum 1 11000101 Carry 1 Sum 11000110 Complement 00111001 the pattern is corrupted.
  • 24. PERFORMANCE OF CHECKSUM  The checksum detects all errors involving an odd number of bits as well as most errors involving an even number of bits.  However if one or more bits of a segment are damaged and the corresponding bit or bits of opposite value in a second segment are also damaged,the sums of those columns will not change and the receiver will not detect a problem.  Checksum retains all carriers, so although two 0s becoming 1 would not alter the value of their own column,it would change the value of the next higher column.