Professional Documents
Culture Documents
Assignment No. 03
Scenario 1
Consider the figure below in which a TCP sender and receiver communicate over a connection in which
the segments can be lost. The TCP sender wants to send a total of 10 segments to the receiver and
sends an initial window of 5 segments at t = 1, 2, 3, 4, and 5, respectively. Suppose the initial value of
the sequence number is 166 and every segment sent to the receiver each contains 309 bytes. The delay
between the sender and receiver is 7 time units, and so the first segment arrives at the receiver at t = 8,
and an ACK for this segment arrives at t = 15. As shown in the figure, 1 of the 5 segments is lost between
the sender and the receiver, but none of the ACKs are lost. Assume there are no timeouts and any out of
order segments received are thrown out.
Page 1 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
Page 2 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
The result of sending that flight of packets is that either (i) all packets are ACKed at the end of the time
unit, (ii) there is a timeout for the first packet, or (iii) there is a triple duplicate ACK for the first packet. In
this problem, you are asked to reconstruct the sequence of events (ACKs, losses) that resulted in the
evolution of TCP's cwnd shown below.
1. Give the times at which TCP is in slow start. Format your answer like: 1,3,5,9 (If none submit
blank)
The times where TCP is in slow start are: 1,2,3,7,8,11,12,13,30,31,32.
2. Give the times at which TCP is in congestion avoidance. Format your answer like: 1,3,5,9 (If none
submit blank)
The times where TCP is in slow start are:
4,5,6,9,10,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,33,34,35,36,37,38,39
,40.
3. Give the times at which TCP is in fast recovery. Format your answer like: 1,3,5,9 (If none submit
blank)
The times where TCP is in fast recovery are:
4. Give the times at which packets are lost via timeout. Format your answer like: 1,3,5,9 (If none
submit blank)
The times where TCP has a loss by timeout are: 1,7,13,20,30.
5. Give the times at which packets are lost via triple ACK. Format your answer like: 1,3,5,9 (If none
submit blank)
The times where TCP has a loss by triple duplicate ACK are:
Page 3 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
6. Give the times at which the value of ssthresh changes (if it changes between t=3 and t=4, use
t=4 in your answer)
The times where the ssthresh changes are: 2,6,11,17,26,34,35
Scenario 3
Suppose that TCP's current estimated values for the round trip time (estimatedRTT) and deviation in the
RTT (DevRTT) are 340 msec and 39 msec, respectively (see Section 3.5.3 for a discussion of these
variables). Suppose that the next three measured values of the RTT are 260 msec, 200 msec, and 290
msec respectively.
Page 4 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
=(1−α)⋅RTT2+α⋅MeasuredRTT3
=(1−0.125)⋅252.5+0.125⋅290
=0.875⋅252.5+0.125⋅290
=220.9375+36.25
=257.1875msec
6. What is the TCP timeout for the second RTT?
=RTT1+4⋅Dev1
=260+4⋅49.25
=260+197
=457msec
7. What is the estimatedRTT after the third RTT?
=(1−α)⋅RTT2+α⋅MeasuredRTT3
=(1−0.125)⋅252.5+0.125⋅290
=0.875⋅252.5+0.125⋅290
=220.9375+36.25
=257.1875msec
8. What is the RTT Deviation for the the third RTT?
=(1−β)⋅Dev2+β⋅∣RTT3−RTT2∣
=(1−0.25)⋅38.8125+0.25⋅∣257.1875−252.5∣
=0.75⋅38.8125+0.25⋅4.6875
=29.109375+1.171875
=30.28125msec
9. What is the TCP timeout for the third RTT?
=RTT2+4⋅Dev2
=252.5+4⋅38.8125
=252.5+155.25
=407.75msec
Scenario 4
Consider the RDT 3.0 protocol, for reliably communicating data from a sender to receiver over a channel
that can lose or corrupt packets in either direction, and when the maximum delay from sender to
Page 5 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
receiver and back is not known. The FSMs for the sender and receiver are shown below, with their
transitions labeled as SX and RY, respectively.
Now let’s consider the sequence of sender and receiver transitions that would happen when one or
more of the following complications occur: a packet (data or ACK) is lost, a timer times out (prematurely
or not), or a message is corrupted. One or more of these events has occurred to produce the sequence
of transitions below. In the sequence below, one transition has been omitted and replaced with a "*".
Transition Sequence: S0, R0, S3, S4, S5, R2, S7, *, S6, S7, R3, S8
Question.
Page 6 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
1. What is the missing transition? To indicate the missing transition, enter S or R, followed by an
index.
The missing transition is: S6
Scenario 5
Consider the rdt2.2 protocol from the text (pages 209-212). The FSMs for the sender and receiver are
shown below:
Page 7 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
Suppose that the channel connecting the sender and receiver can corrupt but not lose or reorder
packets. Now consider the figure below, which shows four data packets and three corresponding ACKs
being exchanged between an rdt 2.2 sender and receiver. The actual corruption or successful
transmission/reception of a packet is indicated by the corrupt and OK labels, respectively, shown above
the packets in the figure below.
Page 8 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
13. How many times is the payload of the received packet passed up to the higher layer?
1 packets were passed up to the higher layer by the receiver.
Scenario 6
You are assigned the IP address 10.0.0.0/8. Design a subnetting scheme to accommodate at least 1000
subnets, with each subnet supporting a minimum of 100 hosts. Provide the subnet mask for the scheme.
Present your answers in a table with columns for the subnet address, 1st host address, last host address,
broadcast address, and subnet mask.
Subnet # Subnet Address 1st Host Last Host Broadcast Address Subnet Mask
Page 9 of 10
Computer Networks (theory) Registration No: _________________
Fall 2023 Date submitted: _________________
Scenario 7
Given the IP address 172.16.0.0/16, design a subnetting plan that allows for 50 subnets, each capable of
supporting up to 500 hosts. Specify the subnet mask for the designed scheme. Present your answers in a
table with columns for the subnet address, 1st host address, last host address, broadcast address, and
subnet mask.
Subnet # Subnet Address 1st Host Last Host Broadcast Address Subnet Mask
Page 10 of 10