title: Proportional-fair scheduling
text: # Proportional-fair scheduling
  
  Proportional-fair scheduling is a compromise-based scheduling algorithm. It is based upon maintaining a balance between two competing interests: Trying to maximize the total throughput of the network (wired or not) while at the same time allowing all users at least a minimal level of service. This is done by assigning each data flow a data rate or a scheduling priority (depending on the implementation) that is inversely proportional to its anticipated resource consumption.
  
  ## Weighted fair queuing
  
  Proportionally fair scheduling can be achieved by means of weighted fair queuing (WFQ), by setting the scheduling weights for data flow $i$ to $w_{i}=1/c_{i}$, where the cost $c_{i}$ is the amount of consumed resources per data bit. For instance:
  
  * In CDMA spread spectrum cellular networks, the cost may be the required energy per bit in the transmit power control (the increased interference level).
  * In wireless communication with link adaptation, the cost may be the required time to transmit a certain number of bits using the modulation and error coding scheme that this required. An example of this is EVDO networks, where reported SNR is used as the primary costing factor.
  * In wireless networks with fast Dynamic Channel Allocation, the cost may be the number of nearby base station sites that can not use the same frequency channel simultaneously, in view to avoid co-channel interference.
  
  ## User prioritization
  
  Another way to schedule data transfer that leads to similar results is through the use of prioritization coefficients. Here we schedule the channel for the station that has the maximum of the priority function:
  
     $P={\frac {T^{\alpha }}{R^{\beta }}}$
  * $T$ denotes the data rate potentially achievable for the station in the present time slot.
  * $R$ is the historical average data rate of this station.
  * $\alpha$ and $\beta$ tune the "fairness" of the scheduler.
  
  By adjusting $\alpha$ and $\beta$ in the formula above, we are able to adjust the balance between serving the best mobiles (the ones in the best channel conditions) more often and serving the costly mobiles often enough that they have an acceptable level of performance.
  
  In the extreme case ($\alpha =0$ and $\beta =1$) the scheduler acts in a "packet" round-robin fashion and serves all mobiles one after the other (but not equally often in time), with no regard for resource consumption, and such that each user gets the same amount of data. The ($\alpha =0$ and $\beta =1$) scheduler could be called "maximum fairness scheduler" (to be used to provide equal throughout to voice users for example). If $\alpha =1$ and $\beta =0$ then the scheduler will always serve the mobile with the best channel conditions. This will maximize the throughput of the channel while stations with low $T$ are not served at all. The ($\alpha =1$ and $\beta =0$) scheduler could be called "max rate" scheduler. Using $\alpha \approx 1$ and $\beta \approx 1$ will yield the proportional fair scheduling algorithm used in 3G networks. The ($\alpha =1$ and $\beta =1$) scheduler could be implemented by providing the same amount of time & spectrum for each user, irrespective of the desired packet size, channel quality and data rate (MCS) used. The proportional fair ($\alpha =1$ and $\beta =1$) scheduler could be called "equal effort scheduler" or "time/spectrum Round Robin scheduler".
  
  This technique can be further parametrized by using a "memory constant" that determines the period of time over which the station data rate used in calculating the priority function is averaged. A larger constant generally improves throughput at the expense of reduced short-term fairness.
  
  