Research Article

An Accurate Analytical Model for 802.11e EDCA under Different Traffic Conditions with Contention-Free Bursting

Algorithm 2

Optimized search for the solution.
𝑖 = 0 . 1 , 𝑝 = 0 . 5 , 𝑏 = 0 . 5 , 𝑐 ( 𝑖 ) = 0 . 5 /* initialize step and interval */
while (estimation erros for 𝑝 𝑏 and 𝑝 𝑐 𝑖 > specified error)  do
while ( 𝑖 > 0 . 0 0 0 0 1 )   do
   for   𝑝 𝑏 = 𝑏 𝑝 𝑖 𝑏 + 𝑝   do /*each time do 10 iterations*/
  calculate 𝑝 𝑐 that leads to the smallest error given 𝑝 𝑐 ( 𝑖 )
  end for
   𝑏 = 𝑝 𝑏 , 𝑝 = 𝑝 / 1 0 , 𝑖 = 𝑖 / 1 0 /* starts from the new value*/
end while
   /* Here the best value of pb is given
for 𝑖 = 1 4   do /* do the same thing for each 𝑝 𝑐 ( 𝑖 ) */
  while ( 𝑖 > 0 . 0 0 0 0 1 ) do
   for   𝑝 𝑐 ( 𝑖 ) = 𝑐 ( 𝑖 ) 𝑝 𝑖 𝑐 ( 𝑖 ) + 𝑝 do
  calculate 𝑝 𝑐 ( 𝑖 ) that leads to the smallest error given 𝑝 𝑏
  end for
   𝑐 ( 𝑖 ) = 𝑝 𝑐 ( 𝑖 ) , 𝑝 = 𝑝 / 1 0 , 𝑖 = 𝑖 / 1 0
  end while
end for
end while
Calculate throughput and delay using 𝑝 𝑏 and 𝑝 𝑐 𝑖