Question

4. UDP and TCP use 1's complement for their checksums. Suppose you have the following two...

4. UDP and TCP use 1's complement for their checksums. Suppose you have the following two 16-bit words:

0101 0101 0101 0101 and 1010 1010 1010 1011.

4.a. (2 pts.) What is the 1's complement of the sum of these words? Show all work.

4.b. (2 pts.) With the 1's complement scheme, how does the receiver detect errors?

4.c. (2 pts.) Is it possible that a 4-bit error will go undetected? If so, provide an example.

4.d. (2 pts.) Is it possible that a 1-bit error will go undetected? If so, provide an example.4.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer is as follows :

We have two binary numbers say

A = 0101 0101 0101 0101

B = 1010 1010 1010 1011

So answers are as follows :

4.a)

We have to calculate sum of both A and B as follows :

0101 0101 0101 0101 + 1010 1010 1010 1011 = 1 0000 0000 0000 0000 (1 is carry so add it again we get) = 0000 0000 0000 0001

So the 1's complement is inverted bits of calculated sum i.e. 1111 1111 1111 1110

So our 1's complement checksum is 1111 1111 1111 1110

4.b)

At the receiver end, recevier add all the three i.e. A , B and Checksum. If the result comes 0 than there is error in the data. if it don't contains 0 than data is correct

4.c)

No, 4-bit error will not get undetected by this scheme.

4.d)

Yes, 1-bit error is detectable with this scheme.

Let us show,

We have

A = 0101 0101 0101 0101

B = 1010 1010 1010 1011

and calculated checksum is : 0000 0000 0000 0001

Let us suppose sender send this, but to transmission data A get changed 1-bit and data send to receiver is 0101 0101 0101 0100. (last bold bit is changed).

So the data recived by receiver is

A = 0101 0101 0101 0100

B = 1010 1010 1010 1011

and calculated checksum is : 1111 1111 1111 1110

Now we add these all as

0101 0101 0101 0100 + 1010 1010 1010 1011 = 1111 1111 1111 1111

Now checksum is added into this 1111 1111 1111 1111 + 1111 1111 1111 1110 = 11111 1111 1111 1101

We get a 0 in this, so there is error. we can detect it.

if there is any query please ask in comments....

Add a comment
Know the answer?
Add Answer to:
4. UDP and TCP use 1's complement for their checksums. Suppose you have the following two...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • 1. a)UDP and TCP use 1’s complement for their checksums. Suppose you have the following three...

    1. a)UDP and TCP use 1’s complement for their checksums. Suppose you have the following three 8 bit bytes: 0101 0011, 0111 0110, 1001 0011. What is the 1’s complement of the sum of these 3 8-bit bytes? Show all work. Why is it that the 1’s complement is used and not just the sum? What is the sum of the three 8 bit bytes and the checksum you just computed? What is it if you change the first 8...

  • UDP and TCP use 1s complement for their checksum. Suppose you have the following two 8-bit...

    UDP and TCP use 1s complement for their checksum. Suppose you have the following two 8-bit bytes: 0101, 1010. What is the 1s complement of the sum of these 8-bit bytes? Suppose the two bytes are altered during transmission with the checksum as follows: 1001, 0110. Can the checksum be used to detect the alteration?

  • UDP and TCP use 1s compliment for their checksum. Suppose you have the following two 8-bit...

    UDP and TCP use 1s compliment for their checksum. Suppose you have the following two 8-bit bytes: 0101, 1010. What is the 1s compliment of the sum of these 8-bit bytes? Suppose the two bytes are altered during transmission with the checksum as follows: 1001, 0110. Can the checksum be used to detect the alteration?

  • Please answer all Questions Fast and Neatly UDP Checksum (20 pts) Suppose a gender that is...

    Please answer all Questions Fast and Neatly UDP Checksum (20 pts) Suppose a gender that is to send a UDP datagram me given below. It is creating the checku. 1110 1101 1111 0110 0100 1010 Checksum 1111 0110 1. Find the binary sum of the other four fields than checksum (8 pts) 2. Wrap around the overflow and add to the least significant bit(s) if any. (2 pts) 3. Find the l's complement of the result of Problem 2. (2...

  • 4 UDP Checksum (20 pts) Suppose a sender that is to send a UDP datagram as given below. It is creating the checksu...

    4 UDP Checksum (20 pts) Suppose a sender that is to send a UDP datagram as given below. It is creating the checksum 0000 110 0000 0110 0000 1000 Checksum 1. Find the binary sum of the other four fields than checksum. (4 pts) 2. Wrap around the overflow and add to the least significant bit(s) if any. (4 pts) 3. Find the l's complement of the result of Problem 2. (2 pts) Suppose a receiver. Your answer of Problem...

  • Networks Hi guys. I need some assistance with a few questions below. 1. Which of the...

    Networks Hi guys. I need some assistance with a few questions below. 1. Which of the following is TRUE regarding a TCP 3-way handshake. a.   Consists of 3 segments being sent between 2 hosts       b.   Segments only carry data in the SYN, ACK and sequence number bits and bytes with no data       c.   No ACK is needed for the SYNACK received from the receiver       d.   A, B and C       e.   None of the above 2. Which...

  • We have learned a famous shift cipher called Caesar Cipher. Now if we are given a...

    We have learned a famous shift cipher called Caesar Cipher. Now if we are given a plain test: THE ART OF WARAnd key = 3 (a shift by 3 letters), please give the ciphertext Given an 8 bit block P = 10101111 and a key K = 01101011, please give the result of bitwise XOR between P and K Please give the left 2 shift of the 8 bit text 01100101 Use the given a permutation table 23614857 to define...

  • question 1 part 2 and 3 thank you (47) Naruto Notone C Sign In er Sign...

    question 1 part 2 and 3 thank you (47) Naruto Notone C Sign In er Sign Up | Ch ® UFC & MMA × Secure I https://piazza-resourcess3.amazonaws.com/jgopch0cb93d8/j .pdfAWSAccessKeyld-AKAILDNRL/4ALKBWOHA8lexpires-15200435/2&Signature-ol9aXG9 /UAKIHS0QUwMeyBX.. ☆ ミ quations must be properly tyne-set including superscript-s expunents, Always watch the course websile for updates on the assignments. Question 1 (4 points) Show you work I. Convert 2727 into a 32-bit two's complement binary number 2. Convert -5795 into a 16-bit two's complement binary number 3. Add the above...

  • Perform the following base conversion 10011000 is in 2's Complement ?) in 7's complement notation 1....

    Perform the following base conversion 10011000 is in 2's Complement ?) in 7's complement notation 1. 2. 0.335 base 6-() base 10. Given a 2K by 8 bit memory device with three enable pins. The device is enabled when E2 E1 E0-110. Show how to connect the device to the 16 bit Address Bus so that it is located at ŞE000 and takes up exactly 2K of memory space 3. 4 Write -27.5 signed base 10 in 16 bit Floating...

  • Write an Verilog code for a 8-bit subtractor (Bits are in 1's complement) using the following:...

    Write an Verilog code for a 8-bit subtractor (Bits are in 1's complement) using the following: 1. 5-bit parallel adder 2. 3-bit parallel adder The condition are as follows: 1. The Most Significant bits of the subtractor must be given to the 5-bit parallel adder. 2, The Least Significant bits of the subtractor must be given to the 3-bit parallel adder. 3. The input A will be assign to the switches with the least significant bit A[0] linked to SW0....

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT