The Gateway to Computer Science Excellence
+51 votes

Consider an instance of TCP’s Additive Increase Multiplicative Decrease (AIMD) algorithm where the window size at the start of the slow start phase is $2$ MSS and the threshold at the start of the first transmission is $8$ MSS. Assume that a timeout occurs during the fifth transmission. Find the congestion window size at the end of the tenth transmission.

  1. $8$ MSS
  2. $14$ MSS
  3. $7$ MSS
  4. $12$ MSS
in Computer Networks by Veteran
edited by | 14.9k views
Why in this question marks is given to all? (see the GATE answer key)
Is it the default size of MSS(max segment size) i.e 1 ? And in algo it is mentioned that when timeout/error occurs the congestion window is set to MSS size which is 2 here, i think it mean for AIMD also it should be taken as increment factor instead of 1 MSS. What i mean is :
2, 4, 8, 10, 12, 2, 4, 6, 8, 10   (CW size)

1, 2, 3,  4,  5,  6,  7,8, 9,  10   (transmission count) please see this question. Here MSS is mentioned is 2 MSS, means 2 MSS is taken as a additive factor while doing AIMD.

Correct me if wrong.

In , The size is increase by 1 MSS only. There MSS=2KB


 In congestion avoidance, we increase window size either by 1 or 2.

 Both 1 and 2 are correct , you can take any value like either 1 or 2 , both will give correct answer, why i m saying this , see this qstn here correct answer given by IIT KGP official key is in the range and range value is 1100-1300 . Now, when you take 1 ans coming 1200 . When you take 2, answer coming 1100 .. so both are correct according to IIT KGP .

And in this question, marks given to all due to this ambiguity :)

Can anyone help me regarding what the congestion window size at the end of transmission means? Does it mean the size of last segment sent or the one to be sent in the next transmission?
isn't the answer dependent on TCP tahoe or TCP reno model??

which model to follow during gate.?
Nope. here, answer will be independent of whether it is Tahoe or Reno but in case of three duplicate acknowledgements , TCP reno will give different answer because it avoids the slow-start phase and uses fast recovery after getting 3 duplicate ACKs.
Those days same gate paper has different sets like A,B,C,D... In 2 sets there were typing mistakes so marks were given to all for those 2 sets, rest are fine and this question and options are correct.
Doesn't a transmission mean sending of a segment, whose ACK causes an increment in window size by 1 MSS? Why is everyone counting a whole round/window of segments as one transmission?

6 Answers

+88 votes
Best answer



$t=2, \Rightarrow4MSS$

$t=3, \Rightarrow8MSS$

$t=4, \Rightarrow9MSS$ (after threshold additive increase)

$t=5, \Rightarrow10MSS$ (fails)

Threshold will be reduced to $\dfrac{n}{2}$ i.e. $\dfrac{10}{2} = 5.$

$t=6, \Rightarrow1 MSS $

(There is an ambiguity here if the window size will be 1 MSS or 2 MSS as given in the question and due to this GATE gave marks to all. Assuming window size to be 1 MSS) 

$t=7 \Rightarrow2MSS$

$t=8, \Rightarrow4MSS$

$t=9, \Rightarrow5MSS$

$t=10, \Rightarrow6MSS$.

So, at the end of $10^{th}$ successful transmission ,

The the congestion window size will be $(6+1) = 7\;MSS.$

by Active
edited by
After the fifth transmission failed, how we know there is strong possibility of congestion, weak possibility also may be? And in the problem additive increase is mentioned, so we should go for congestion avoidance instead of slow start. Plz clear my doubt.
Why are you taking




It should be instead,

r=1 => 2MSS ( 2 segments are transmitted)

r=2 => 4MSS ( 3rd and 4th segment is transmitted then at 5th segment TO occurs)

It is supposed to be rounds instead of transmissions. Each round will have number of transmissions equal to the congestion window of that particular round. For each round the transmission has to start from count 1 until all the MSS in that congestion window is filled.
There is an ambiguity present in the nothing is mention about the segment size....if we consider segment size=1mss then ans is 7mss ...if we consider segment size=2mss then the ans is12mss....
Why 6+1?

Question asks : Find the congestion window size at the end of the tenth transmission.
Its given in the question that a timeout occurs during the fifth transmission, so timeout will occur on the 10th transmission , so why now window size became 6/2 =3 at the end of 10th transmission?


TO  occurs at the end of fifth transmission not every 5th transmission


Thanks, can you have a looks over a similar yet different question


Look at the wordings - 

 at the start of the slow start phase is $22$ MSS

so it should be like this according to me -  (the value of $t$ represents the cwnd at the end of $t_{th}$ $RTT$.)

At $t=0$ : $2$

At $t=1$ : $4$

At $t=2$ : $8$ ($cwnd$ at threshold)

At $t=3$ : $9$

At $t=4$ : $10$

At $t=5$ : $11$, here at the end of $RTT$ timeout has been realized. so $CWND_{threshold}=\lfloor{11/2}\rfloor = 5$ and $CWND=1$

At $t=6$ : $2$ (Assuming it restarts with $2$ as it started with that)

At $t=7$ : $4$ (Receiver will advertize $CWND = 5$ for next RTT)

At $t=8$ : $5$

At $t=9$ : $6$

At $t=10$ : $7$ 


But I am not sure about this solution. Can anyone point out mistakes in this?


@ your solution seems more accurate.

At t=0 they (TCP/IP 4th Edition forouzan ) started from 1MSS, here in question they have give to start from 2MSS

So, in the above answer by @ it should have been started from t=0 and no need for 6+1 (bcz its clearly mention at the end of transmission).

Why cwnd size is 1 more than the last segment transmitted?

Yes @2019_Aspirant

answer makes more sense. The transmission starts from 0th.

In the above answer at T=6, its written as 1MSS. I think its not possible, because it should be 2MSS.


@Shamim Ahmed 'During' means when $10MSS$ was being transmitted. I was wrong there, I took 'after transmission'. These are possible solutions -

  • 2 -> 4-> 8 -> 9 -> 10 (time out. make threshold 5) -> 1-> 2 -> 4 -> 5 -> 6 -> 7
  • 2 -> 4-> 8 -> 9 -> 10 (time out. make threshold 5) -> 2-> 4 -> 5 -> 6 -> 7 -> 8

@Ashish Patel 

So in that case 8 would be the answer right as its mentioning "During", i.e.., at T=4.

But how can it be 7 then? It clearly mentioned that MSS = 2.
I think there should be no confusion..bcz it mentioned in textbooks when time out happens set thrrshold to half and congestion window size to one....


2 questions : <please answer>

1) selected answer has time t1 to t10 ,but at start (t1) cwnd was 2 but this is before any transmission last time should be t11 isn't it? cause at t2 1st transmission happened and ackn received so cwnd is 4 now .


t2...4(1st transmission)

t3...8(2nd transmission) on and so forth



2) when cwnd turned to 8 we went in congestion avoidance phase incrementing cwnd by 1 MSS,but when ssthresh brcame 10/2=5  and cwnd became 4 at t8 it hasn't yet reached 5 so..cwnd should be 8 in next step ... isn't it...???

wht start congestion avoidance at cwnd=4 when ssthresh is 5????




please reply with your own words..please do

if my picture is wrong then why?

if it's correct then mention it too in your reply.

+42 votes


$t=2, \Rightarrow4MSS$

$t=3, \Rightarrow8MSS$

$t=4, \Rightarrow9MSS$ (after threshold additive increase)

$t=5, \Rightarrow10MSS$ (fails)

Threshold will be reduced by $\dfrac{n}{2}$ i.e. $\dfrac{10}{2}=5$.

$t=6, \Rightarrow2MSS$

$t=7 \Rightarrow4MSS$

$t=8, \Rightarrow5MSS$

$t=9, \Rightarrow6MSS$

$t=10, \Rightarrow7MSS$.

So at the end of $10^{th}$ transmission congestion window size will be $8 MSS$.
by Boss
edited by
For the linear increase you should consider the additive factor of 2 MSS and not 1 MSS (As it is the smallest window possible in given system). Thus, at t=4 , you will get => 10 MSS. And calculating it upto 10th iteration the answer one should get is 12 MSS (after 10th iteration).  So, option (d).

BUT, as the algo suggest, in slow start mechanism, system should start sending with 1 packet only in entire window. That equates to 1 MSS. But, as they mentioned 2 MSS here, many students must have got  answer as either 7 MSS (by consider +1) or 12 MSS (like approach above). And that is why, they had gone for grace marks for this particular qstn.

At the beginning of first transmission congestion window size: 2 MSS
After end of first transmission congestion window size: 4 MSS

At beginning of 10th transmission congestion window size: 7 MSS
After end of 10th transmission congestion window size: 8 MSS

Then answer should be 8 MSS? 
Please check

Shouldn't it be 8 MSS? since it is asked AFTER 10th transmission, so after 10th transmission will be done window size would become 8 MSS.

since 10 packet is sent and why u wait for ack , and will be 8 if question says 10 packet successfully received by receiver . question ask time when u send 10th packet. 

it i asked as "at the end of 10th transmission" -which i guess mean after 10th transmission

-=- must be 8 then

Here is the rfc reference and there is a thing called smss which is 2 mss in this problem

+11 votes
In Case of AIMD , Remember following points to solve the questions : -

1 - Start with Given MSS (Min Seq Size)
2 - Increase the Window size in multiples of MSS till the threshold occurs
3 - Once the threshold reached , increase the window size by 1 MSS till the timeout occurs
4 - Once the timeout occurs , reduce threshold to half and again start from Given Start MSS.

Here , 2-4-8(Threshold reached , increase by 1 MSS till timeout)-9-10(Timeout reached)--(Reduce Threshold and again start from 2)--2-4-5-6-7(Window size at 10th Transaction).

Hence Ans : - 7
+2 votes


t=1, =>2mss

t=2, =>4mss

t=3, =>8mss

t=4, => 10mss (after threshold additive increase  and as the mss is 2 KB we add +2(linear increase) in each step till timeout)

t=5, =>12mss (fails)

Threshold will be reduced by n/2 i.e. 12/2 = 6.

t=6, =>1mss

t=7 =>2mss

t=8, =>4mss

t=9, =>5mss

t=10, =>6mss.

So at the end of 10th successful transmission ,the the congestion window size will be (6+1) = 7 mss.


At t=1, 2MSS

At t=2,4MSS

At t=3,8MSS

At t=4,9MSS

At t=5,10MSS(Here time out occurs and it enters slow start phase, so new threshold is 5MSS)

At t=6,2MSS (Given in the question, Window size at the start of the slow start phase is 2MSS)

At t=7,4MSS

At t=8,5MSS

At t=9,6MSS

At t=10,7MSS

Now it is asked at the end of the 10th transmission and we are not sure whether it is successful or not untill and unless we get acknowledgment and hence we are not sure about the sender window sizenow.

In the question if it is given as at the end of 10th successful transmission then answer would be 8MSS.

Please refer problem 4 (10) second point in the  below link: (reference link from standard book)

Hope it clears..!!

I am not getting why after 4 mss at t=7, we increased linearly since threshold was 5 not 4. Please tell.
0 votes






(after threshold additive increase)



Threshold will be reduced by n2

i.e. 10/2=5.

(The window size is NOT always =1MSS. Here it is mentioned  2MSS)






the the congestion window size will be =7MSS.

0 votes

Since Slow Start is used, window size is increased by the number of segments successfully sent. This happens until either threshold value is reached or time out occurs.
In both of the above situations AIMD is used to avoid congestion. If threshold is reached, window size will be increased linearly. If there is timeout, window size will be reduced to half.

Window size for 1st transmission = 2 MSS
Window size for 2nd transmission = 4 MSS
Window size for 3rd transmission = 8 MSS
threshold reached, increase linearly (according to AIMD)
Window size for 4th transmission = 9 MSS
Window size for 5th transmission = 10 MSS
time out occurs, resend 5th with window size starts with as slow start.
Window size for 6th transmission = 2 MSS
Window size for 7th transmission = 4 MSS
threshold reached, now increase linearly (according to AIMD)
Additive Increase: 5 MSS (since 8 MSS isn’t permissible anymore)
Window size for 8th transmission = 5 MSS
Window size for 9th transmission = 6 MSS
Window size for 10th transmission = 7 MSS

by Active

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
52,215 questions
60,009 answers
94,695 users