# A Software-Defined Networking Framework to Provide Dynamic QoS Management in IEEE 802.11 Networks
## 4 Evaluation
### Evaluation of the Mathematical Model  
#### 4.1.1 Impact of DEDCA mechanism in the _normal terminals_  
Equations (5) and (6) describe the multiplicative increment and decrement in the probability of winning the channel, when the \(CW_{min}\) value of the _requesting_ and _giving terminals_ are modified. However, it would be interesting to know how the _normal_ stations are affected. In a backoff-based network, the bandwidth is shared among all the stations. Therefore, assuming that the network has a capacity of C bps, the bandwidth assigned to each station is:  
\[C\times P(win)\]  
For a _normal_ station, the probability of winning the channel has been obtained in Equation (2). However, considering an ideal arbitration of the multiple access control, all the stations tend to obtain the same access probability, and thus this probability can be approximated to:  
\[P(win)_{normal}\approx\frac{1}{s}\]  
where \(s\) is the number of stations. On the other hand, the probabilities that a _requesting station_ and a _giving station_ win the channel are respectively:  
\[P(win)_{requesting}=P(win)_{normal}\cdot G^{+}=\frac{1}{s}\cdot\frac{default\_ CW_{min}+1}{default\_CW_{min}+1-k}\]  
\[P(win)_{giving}=P(win)_{normal}\cdot G^{-}=\frac{1}{S}\cdot\frac{default\_ CW_{min}+1}{default\_CW_{min}+1+k}\]  
Adding all the bandwidth assigned to each station:  
\[C=\sum_{z=1}^{n}C\cdot\frac{1}{S}+\sum_{i=1}^{r}C\cdot\frac{1}{S}\cdot\frac{ default\_CW_{min}+1}{default\_CW_{min}+1-k_{i}}+\sum_{j=1}^{g}C\cdot\frac{ 1}{S}\cdot\frac{default\_CW_{min}+1}{default\_CW_{min}+1+k_{j}}\]  
\[C=n\cdot\frac{C}{S}+\frac{C}{S}\sum_{i=1}^{r}\frac{default\_CW_{min}+1}{default \_CW_{min}+1-k_{i}}+\frac{C}{S}\sum_{j=1}^{g}\frac{default\_CW_{min}+1}{default \_CW_{min}+1+k_{j}}\]  
and finally, dividing by C:  
\[1=\frac{n}{S}+\frac{1}{S}\sum_{i=1}^{r}\frac{default\_CW_{min}+1}{default\_CW_{ min}+1-k_{i}}+\frac{1}{S}\sum_{j=1}^{g}\frac{default\_CW_{min}+1}{default\_CW_{min}+1+k_{j}} \tag{7}\]  
where \(s\) is the number of stations, \(r\) is the number of _requesting stations_, \(g\) is the number of _giving stations_, and \(n=s-r-g\) is the number of _normal stations_. In the proposed system, Equation (7) can be used to obtain the number of _giving terminals_ and their parameters, given a certain number of _requesting terminals_ and the corresponding requested bandwidth increase. Now, we are going to evaluate the impact of DEDCA mechanism in the normal terminals by simulation. We consider a set of \(s=15\) terminals whose default \(CW_{min}\) is set to 31. To test DEDCA impact, we have performed multiple simulations as described. For each simulation, a random number of _requesting terminals_ are chosen, whose \(CW_{min}\) value is decremented in \(k\) units. Taking into account that the bandwidth increase of _requesting terminals_ is going to be compensated by the _giving_ terminals, the number of _giving terminals_ and their parameters are obtained from Equation (7). The channel access rate of each terminal is obtained considering saturated conditions. All the terminals always have a packet to be transmitted, and they contend for the channel accordingly to their congestion window size. To simplify the drawing of the obtained results, but without loss of generality, Figure 6 shows the simulation results in a particular case, where station 2 and 3 are chosen as _requesting stations_. The default \(CW_{min}\) value of these _requesting stations_ is decremented in 10 and 7 units (that is, the new \(CW_{min}\) value is set to 21 and 24), respectively. The figure plots the access rate obtained by each one of the 15 terminals when the gain of the _requesting stations_ is compensated in three different ways, selecting five, six and eight _giving terminals_ respectively. From Equation (7), the default \(CW_{min}\) values of the _giving stations_ have to be incremented in 8,7,7,7 units in the first case; in 5,5,5,4,4 in the second case, and in 4,4,3,3,3,3,3 in the last case.