0% found this document useful (0 votes)
13 views

Checksum

The document is an assignment on the concept of checksum in computer networking, detailing its procedure for error detection during data transmission. It outlines the steps for both sender and receiver sides, providing an example using the message 'Network' to illustrate the checksum calculation. Additionally, it discusses a potential drawback of the checksum method where certain errors may go undetected.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

Checksum

The document is an assignment on the concept of checksum in computer networking, detailing its procedure for error detection during data transmission. It outlines the steps for both sender and receiver sides, providing an example using the message 'Network' to illustrate the checksum calculation. Additionally, it discusses a potential drawback of the checksum method where certain errors may go undetected.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

Green University of Bangladesh

Department of Computer Science and Engineering (CSE)


Faculty of Sciences and Engineering
Semester: (Spring, Year:2024), B.Sc. in CSE (Day)
Assignment: Short Note On Checksum with Example
Course Title: Computer Networking
Course Code: CSE_ 311 Section: 221_D1

Name ID
MD. Monirul Islam 221002154

Submission Date: 21/10/2024


Instructor Name: Prof. Dr. Md. Zahidul Islam

Assignment Status
Marks: Signature:
Comments: Date:
221002154, CSE_311,221_D1

Assignment On Checksum with Example


Goal: detect errors (i.e., flipped bits) in transmitted segment.
Procedure Of Checksum
Receiver & Transmitter side should be agreed upon same method.
Sender Side
• Break the original message into k number of blocks with n number of bits in each block.
• Sum all the k data block.
• If carry generate then add carry of the sum
• Then find out 1𝑠𝑡 Complement. i.e., Checksum=1𝑠𝑡 Complement.
• Send data with checksum.
Receiver Side
• Collect all the data block including checksum.
• Sum all the data block & checksum.
• After 1𝑠𝑡 Complement Result all 0’s then accept it otherwise reject it.

Example:
Alice wants to send a message to Bob and ensure that it arrives without any errors. To achieve this, she plans to use
a checksum algorithm. Your task is to identify the appropriate checksum algorithm that will help Alice send the
message and also assist Bob in verifying that he receives the correct message.
The message is “Network.”
221002154, CSE_311,221_D1

Answer To The Example


The Message=: “Network”

ASCII and Binary Representation of "Network"

Character ASCII Value Binary Representation


N 78 0100 1110
e 101 0110 0101
t 116 0111 0100
w 119 0111 0111
o 111 0110 1111
r 114 0111 0010
k 107 0110 1011

Binary Representation-> 0110 1011 0111 0010 0110 1111 0111 0111 0111 0100 0110 0101 0100 1110

0 1 1 0 0 1 0 1 0 1 0 0 1 1 1 0
0 1 1 1 0 1 1 1 0 1 1 1 0 1 0 0
0 1 1 1 0 0 1 0 0 1 1 0 1 1 1 1
0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 1
0 1 0 0 1 1 1 1 1 0 0 1 1 1 0 0
Add Carry 1
0 1 0 0 1 1 1 1 1 0 0 1 1 1 0 1
𝒔𝒕
𝟏 𝑪𝒐𝒎𝒑𝒍𝒆𝒎𝒆𝒏𝒕 1 0 1 1 0 0 0 0 0 1 1 0 0 0 1 0
221002154, CSE_311,221_D1

Receiver Side:
Receiver Receive the message with Checksum= 1011 0000 0110 0010
Total Bits Receive:
1011 0000 0110 0010 0110 1011 0111 0010 0110 1111 0111 0111 0111 0100 0110 0101 0100 1110
0 1 1 0 0 1 0 1 0 1 0 0 1 1 1 0
0 1 1 1 0 1 1 1 0 1 1 1 0 1 0 0
0 1 1 1 0 0 1 0 0 1 1 0 1 1 1 1
0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 1
Checksum 1 0 1 1 0 0 0 0 0 1 1 0 0 0 1 0
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0
Add Carry 1
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
𝒔𝒕
𝟏 𝑪𝒐𝒎𝒑𝒍𝒆𝒎𝒆𝒏𝒕 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

Here, after apply 𝟏𝒔𝒕 Complement Result all bits are 0’s therefore no Error Detected. The Message
should send correct order.
221002154, CSE_311,221_D1

Drawbacks:
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.

On Same Example:
Sender Side

0 1 1 0 0 1 0 1 0 1 0 0 1 1 1 0
0 1 1 1 0 1 1 1 0 1 1 1 if this bit changes to 0 0 1 0 0
0 1 1 1 0 0 1 0 0 1 1 0 this bit changes to 1 1 1 1 1
0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 1
0 1 0 0 1 1 1 1 1 0 0 1 sum not change of columns 1 1 0 0
Add Carry 1
0 1 0 0 1 1 1 1 1 0 0 1 1 1 0 1
𝒔𝒕
𝟏 𝑪𝒐𝒎𝒑𝒍𝒆𝒎𝒆𝒏𝒕 1 0 1 1 0 0 0 0 0 1 1 0 0 0 1 0
221002154, CSE_311,221_D1

Receiver Side
0 1 1 0 0 1 0 1 0 1 0 0 1 1 1 0
0 1 1 1 0 1 1 1 0 1 1 0 0 1 0 0
0 1 1 1 0 0 1 0 0 1 1 1 1 1 1 1
0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 1
Checksum 1 0 1 1 0 0 0 0 0 1 1 0 0 0 1 0
1 1 1 1 1 1 1 1 1 1 1 1 sum not change of columns 1 1 1 0
Add Carry 1
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
𝒔𝒕
𝟏 𝑪𝒐𝒎𝒑𝒍𝒆𝒎𝒆𝒏𝒕 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

That means, here sums of this columns will not change therefore receiver will not detect problem We
successfully converted the message "Network" into binary and organized it into a table for easy understanding. This
helps in applying a checksum to check for any errors during data transmission.

You might also like