414Assignment2

414Assignment2 - ECSE 414 Intro. to Telecom. Networks...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
ECSE 414 – Intro. to Telecom. Networks Assignment #2 - Fall 2010 27/09/10 M. Rabbat ECSE 414 - Homework Assignment #2 – Transport Layer Due Thursday, October 7, 2010 Note: Unless otherwise noted, all assignments are due at the beginning of the lecture period on the due date. For “paper and pencil” problems (such as Problems 1, 2, 3 and 4 below), you may submit a hard copy of your assignment in class or to the instructor’s mailbox, or you can submit your assignment electronically via WebCT. For programming problems (such as Problem 5), you must upload an archive file (e.g., zip, rar, or tgz) on WebCT containing the source code, executable (or .class file for Java applications), and a Readme file containing any special instructions for compiling and running your application. Problem 1 (K&R Ch3, P4) (3 marks, one per part) a) Suppose you have the following 2 bytes: 01011100 and 01010110. What is the 1’s complement of the sum of these two bytes? b) Suppose you have the following 2 bytes: 11011010 and 00110110. What is the 1’s complement of the sum of these two bytes? c) For the bytes in part (a), give an example where one bit is flipped in each of the two bytes and yet the 1’s complement doesn’t change. Problem 2 (K&R Ch3, P12) (3 marks) Consider the Stop-and-wait ARQ protocol discussed in class (also called rdt 3.0 in the textbook). Draw a diagram showing that if the network connection between the sender and receiver can reorder messages (that is, two messages propagating in the medium between the sender and receiver can be reordered), then the alternating-bit protocol (alternating between sequence numbers 0 and 1) will not work correctly. Make sure you clearly identify the sense in which it will not work correctly (i.e., how will the received message differ from what was sent). Your diagram should have the sender on the left and the receiver on the right, with the time axis running down the page. Indicate data packets as D x , and acknowledgement messages as A x , where x is replaced by the sequence number (0 or 1). Problem 3 (K&R Ch3, P21) (4 marks) Consider the Go-Back-N and Selective Repeat protocols. Suppose the sequence number space is of size k (i.e., sequence numbers range from 0 to k-1). What is the largest allowable sender window that will avoid the occurrence of problems such as that in Figure 3.27 (reproduced below) for each of these protocols?
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
ECSE 414 – Intro. to Telecom. Networks Assignment #2 - Fall 2010 27/09/10 M. Rabbat
Background image of page 2
ECSE 414 – Intro. to Telecom. Networks Assignment #2 - Fall 2010 27/09/10 M. Rabbat Problem 4 (K&R Ch3, P25) (6 marks, 1 each for parts a,b,c, and 3 for part c) Hosts A and B are communicating over a TCP connection, and Host B has already received from A all bytes up to and including byte 126. Suppose Host A then sends two segments to Host B back-to- back. The first and second segments contain 70 and 50 bytes of data, respectively. In the first segment, the sequence number is 127, the source port number is 302, and the destination port
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 5

414Assignment2 - ECSE 414 Intro. to Telecom. Networks...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online