CS 455 - Introduction to Computer Networks
Homework 4

Due: See class webpage.

• Question 1 (20 pts)

• Prove that the Stop-and-Wait protocol will operate correctly using only 2 different sequence number

I.e.: you only need to label the frame in Stop-and-Wait using sequence numbers:

 0 and 1

• Question 2 (20 pts)

• A sender and a receiver is using the Sliding Window protocol using a send window size = 4 and receive window size = 4

The ACK scheme used is cumulative ACK where ACK N acknowledges all frames upto (but not including) frame N

The sender transmits 4 frames to the receiver and 2 of the frames are received in error. (Recall that the receiver can use the CRC code in a frame to check if the frame is in error)

The following diagram show the transmitted frames:

Questions: what is the response of the receiver for these frames:

 Frame 3                            Frame 0 Frame 1 Frame 2

• Question 3 (20 pts)

• Suppose you are designing a Sliding Window protocol for a 1 Mbps point-to-point link to the moon.

The a one-way propagation delay between earth and moon is 1 sec.

Assume that the frame size is fixed and is equal to 1 KBytes, you can assume that 1 KBytes = 8000 bits.

You can assume the ACK frame is negligible.

Questions:

• Assuming there is no transmission errors, and Sliding Window uses a send/receive window size of 100, what is the link utilization (= channel utilization) ?

In other words: what fraction of the 1 Mbps link capacity is used to transmit data frames (10 pts)

 You cannot simply apply the Stop-and-Wait utilization formula. Take a look at how the utilization in Stop-and-Wait is calculated Apply the logic to compute the utilization in Sliding Window

• Assuming there are no transmission errors, what is the minimum number of bits you need for the sequence number in the frame that will allow you to use the entire capacity of the link ? (10 pts)

Hint: find the smallest send window size that will allow the sender node to transmit continuously (i.e., without stopping)

• Question 4 (20 pts)

• A sliding window protocol uses the cumulative ACK scheme.

We will use a slightly different Acknowledgement scheme:

 ACK n will acknowledge the reception of all frames upto and including frame n.

(So you must adjust what you have learned to the above scheme !!!

The number of bits in the sequence number field is 3 (8 different sequence numbers).

A receive windows size and send window size is 5.

The initial send and receiver windows are {0,1,2,3,4}.

The following events occurs at the receiver in the given sequence:

1. The receiver first receives the frame numbered with seq. no. 3. What ACK message (give sequence number) will the receiver send back to the sender ? (2 pts)

2. The receiver next receives the frames numbered with seq. no. 0 and 2. What ACK message (give sequence number) will the receiver send back to the sender ? (2 pts)

3. The receiver next receives the frame numbered with seq. no. 1. What ACK message (give sequence number) will the receiver send back to the sender ? (2 pts)

4. The receiver next receives the frame numbered with seq. no. 0. What ACK message (give sequence number) will the receiver send back to the sender ? (2 pts)

 Is this frame always a retransmission or can this frame be a new frame ? Show your reason (with a diagram with frame receive/loss events) to get full credit. (5 pts)

5. The receiver next receives the frame numbered with seq. no. 1. What ACK message (give sequence number) will the receiver send back to the sender ? (2 pts)

 Is this frame always a retransmission or can this frame be a new frame ? Show your reason (with a diagram with frame receive/loss events) to get full credit. (5 pts)

• Question 5 (20 pts)

• Repeat Question 4 using the following changes in the sender and receiver:

 Sender window size = and Receiver window size = 4 The initial sender/receiver window = {0,1,2,3}