edited by
26,665 views
55 votes
55 votes

Station $A$ uses $32\; \text{byte}$ packets to transmit messages to Station $B$ using a sliding window protocol. The round trip delay between A and $B$ is $80\; \text{milliseconds}$ and the bottleneck bandwidth on the path between $A$ and $B$ is $128\; \text{kbps}$ . What is the optimal window size that $A$ should use?

  1. $20$
  2. $40$
  3. $160$
  4. $320$
edited by

12 Answers

Best answer
65 votes
65 votes
Round trip delay $= 80\ ms$.

Quoting from Wikipedia

the round-trip delay time (RTD) or round-trip time (RTT) is the length of time
it takes for a signal to be sent plus the length of time it takes for an acknowledgment
of that signal to be received.

Now, in many books including standard ones, they have used $\text{RTT}$ to mean just the $2\text{-way}$ propagation delay by considering the signal/packet as of the smallest possible quantity so that its transmission time is negligible. The given question is following the first definition as given by Wikipedia which is clear from the choices.

During this time the first $\text{ACK}$ arrives and so sender can continue sending frames.
So, for maximum utilization sender should have used the full bandwidth during this time.
i.e., it should have sent $128\text{ kbps}\times 80\ ms$ amount of data and a packet being of size $32\text{ bytes},$ we get

no. of packets $=\dfrac{128 \times 80}{32 \times 8} = 40.$
Correct Answer: $B$
edited by
86 votes
86 votes

Answer: B

Round Trip Time $= 80ms$
Frame size $=32\times 8\text{ bits}$
Bandwidth $=128\text{ kbps}$
Transmission Time $=\dfrac{32\times 8}{128}\ ms = 2\ ms$
Let $n$ be the window size.

Utilization $=\dfrac{n}{1+2a}$

where $\large a = \dfrac{\text{Propagation Time}}{\text{Transmission Time}}$

$ =\dfrac{n}{1+\dfrac{2 \times 40}{2}}$

For maximum utilization: $n = 41$ which is close to option (B).

edited by
11 votes
11 votes
RTT is 80 ms , irrespective of what T(p) & T(t) values are .

The acknowledgment is reaching at 80th ms and not 82nd ms (If calcualated T(t) values and added to twice of T(p) = 40 )

Here T(t) + 2 T(p) = 80 ms

 

So 128 kb  == 1 sec
      128 bits == 1 ms
       1ms == 128 bits
        80 ms == 80 * 128 bits

So no of frame required = ( 80 * 128 ) / 256
                                   = 40 frames (Window Size)
10 votes
10 votes

Here, we can use the concept of bandwidth delay product.

What is bandwidth delay product?

"It's the amount of data that left the sender before the first acknowledgement was received by the sender. That is, bandwidth * round trip time = the desired window size under perfect conditions. If the round trip time is measured from the last packet and the sender's outbound bandwidth is perfectly stable and fully used, then the measured window size exactly calculates the number of packets (data and ACKs together) in transit. If you want only one direction, divide the quantity by two."

Further reading: http://www.kehlet.cx/articles/99.htmlhttps://learningnetwork.cisco.com/thread/125627

The bandwidth delay product is given by:  $BW \times RTT$, which in this case is $128 \,\text{kbps} \times 80 \times 10^{-3} \text{s}$, which comes as $10240$ bits.

Therefore, number of packets can be given by $\frac{10240}{32 \times 8} = 40$ packets, which does not have any off by one error.

edited by
Answer:

Related questions

21 votes
21 votes
1 answer
2