Introduction to Network Utility Maximization (NUM)
Richard T. B. Ma School of Computing
National University of Singapore
CS 4226: Internet Architecture
Outline
Utility maximization and convex optimization Assumptions of utility functions Intuitive solutions of utility maximization Convex set, function and optimization framework
Utility maximization and fairness Max-min, proportional fairness and 𝛼-fairness
Karush–Kuhn–Tucker (KKT) conditions Lagrange multiplier and shadow price
How Does Utility Look Like?
Assumptions on utility function
We assume that each 𝑈𝑖 ⋅ is defined over 0, +∞ continuously differentiable non-decreasing (not critical) concave (most intriguing)
Interpretations and reasons non-negative resource allocation the more you get, the happier you are marginal happiness decreases (diminishing return) guarantee existence of optimal solution
Utility maximization
Multiple flows share a resource:
Maximize 𝑈1 𝑥1 + 𝑈2 𝑥2 subject to: 𝑥1 + 𝑥2 ≤ 𝐶, 𝑥1 ≥ 0 and 𝑥2 ≥ 0
Maximize 𝑈 𝒙 = � 𝑈𝑖 𝑥𝑖𝑛
𝑖=1
subject to: � 𝑥𝑖𝑛
𝑖=1≤ 𝐶 and 𝒙 ≥ 𝟎
𝒙𝟏 𝒙𝟐
𝑪
How does 𝒙∗ look like? 𝒙𝟏 𝒙𝟐
𝑪
𝟏 𝟐
𝟑 𝟒
𝟓 𝟔
𝟕 𝟖
𝟗
𝑼𝟏
𝟏 𝟐
𝟑 𝟒
𝟓 𝟔
𝟕 𝟖
𝟗
𝟎 𝟏 𝟐 𝟑 𝟒 𝟓 𝟔 𝟕 𝟖
𝑼𝟐
𝟏 𝟐
𝟑 𝟒
𝟎 𝟏 𝟐 𝟑 𝟒 𝟓 𝟔 𝟕 𝟖
𝑼𝟏′
𝟏 𝟐
𝟑 𝟒
𝟎 𝟏 𝟐 𝟑 𝟒 𝟓 𝟔 𝟕 𝟖
𝑼𝟐′
Sort marginal utilities by a descending order
Assign resource unit by unit
𝟏 𝟐
𝟑 𝟒
𝟎 𝟏 𝟐 𝟑 𝟒 𝟓 𝟔 𝟕 𝟖 𝟗
𝑼′
Utility maximization
Maximize 𝑈 𝒙 = � 𝑈𝑖 𝑥𝑖𝑛
𝑖=1
subject to: � 𝑥𝑖𝑛
𝑖=1≤ 𝐶 and 𝒙 ≥ 𝟎
A necessary condition: 𝒙∗ = 𝑥1∗,⋯ , 𝑥𝑛∗ is optimal only if for any 𝑖
𝑈𝑖′ 𝑥𝑖∗ ≥ 𝑈𝑗′ 𝑥𝑗∗ ∀𝑗 unless 𝑥𝑖∗ = 0
𝒙𝟏 𝒙𝟐
𝑪
Convex set and convex function
A set 𝑺 is convex iff ∀𝒙,𝒚 ∈ 𝑺 and 𝛼 ∈ 0,1 , 1 − 𝛼 𝒙 + 𝛼𝒚 ∈ 𝑺
A function 𝑓 is convex iff for any 𝛼 ∈ 0,1
𝑓 1 − 𝛼 𝒙 + 𝛼𝒚 ≤ 1 − 𝛼 𝑓 𝒙 + 𝛼𝑓 𝒚
if and only if its epigraph is a convex set
convex set non-convex set convex function
Concave function and property
A function 𝑓 is concave if for any 𝛼 ∈ 0,1
𝑓 1 − 𝛼 𝒙 + 𝛼𝒚 ≥ 1 − 𝛼 𝑓 𝒙 + 𝛼𝑓 𝒚
Properties of concave functions: A function 𝑓 𝒙 is concave over a convex set iff − 𝑓 𝒙 is a convex function over the set.
Sum of concave functions is also concave
A differentiable function 𝑓 𝑥 is concave if 𝑓′ 𝑥 is monotonically decreasing: a concave function has a decreasing slope
Optimality for convex optimization
Minimize 𝑓 𝒙 subject to: 𝒙 ∈ 𝑺 ⊂ 𝑹𝒏
If 𝑺 is convex and 𝑓 𝒙 is convex over 𝑺 any local minimum of 𝑓(·) is a global minimum if 𝑓 ⋅ is strictly convex, then there exists at
most one global minimum
Necessary condition: if 𝒙∗ is optimal, then
𝛻𝑓 𝒙∗ 𝑻 𝒙 − 𝒙∗ ≥ 0, ∀𝒙 ∈ 𝑺. it becomes sufficient under convex optimization
Our utility maximization problem
Maximize 𝑈 𝒙 ⇔ Minimize − 𝑈 𝒙 subject to: 𝒙 ∈ 𝑺 = 𝒙:𝑔𝑖 𝒙 ≤ 0,∀𝑖 = 1,⋯ ,𝑚
Functions 𝑔𝑖 𝒙 are linear, so 𝑺 is convex 𝑈 𝒙 is concave over 𝑺
any local maximum of 𝑈(·) is a global maximum strictly concave 𝑈 ⋅ unique global maximum
Sufficient condition: 𝒙∗ is optimal if
𝛻𝑈 𝒙∗ 𝑻 𝒙 − 𝒙∗ ≤ 0, ∀𝒙 ∈ 𝑺.
Local and global maxima
Outline
Utility maximization and convex optimization Assumptions of utility functions Intuitive solutions of utility maximization Convex set, function and optimization framework
Utility maximization and fairness Max-min, proportional fairness and 𝛼-fairness
Karush–Kuhn–Tucker (KKT) conditions Lagrange multiplier and shadow price
A different point of view
utility: a measure of user satisfaction when getting a data rate from the network need to know users’ applications and utility
functions in practice
A new view: utility function is assigned to user in the network by a service provider with the goal of achieving a certain goal maximize efficiency maximize fairness
Different objectives
Maximize efficiency (aggregate data rate)
𝑈𝑖 𝑥𝑖 = 𝑥𝑖
Minimize potential delay
𝑈𝑖 𝑥𝑖 = −1𝑥𝑖
Proportional fairness
𝑈𝑖 𝑥𝑖 = log 𝑥𝑖
How about max-min fairness?
Proportional fairness
Definition: a feasible allocation solution 𝒙∗ is proportional fair if for any feasible 𝒙,
�𝑥𝑖 − 𝑥𝑖∗
𝑥𝑖∗
𝑛
𝑖=1
≤ 0.
for any allocation, the sum of proportional changes in the utilities will be non-positive.
if some rate increases, there is another user whose rate will decrease and the proportion by which it decreases is larger.
Proportional fairness
The objective function becomes
Maximize 𝑈 𝒙 = �𝑈𝑖 𝑥𝑖
𝑛
𝑖=1
= � log 𝑥𝑖
𝑛
𝑖=1
𝑈 𝒙 is strictly concave sufficient condition: if 𝒙∗ is optimal, then
𝛻𝑈 𝒙∗ 𝑻 𝒙 − 𝒙∗ = �𝑥𝑖 − 𝑥𝑖∗
𝑥𝑖∗
𝑛
𝑖=1
≤ 0, ∀𝒙 ∈ 𝑺.
A unified form of utility
Consider the form of 𝛼-fairness : 𝑈𝑖 𝑥𝑖 =
𝑥𝑖1−𝛼
1 − 𝛼 for some 𝛼 ≥ 0
maximize aggregate rate (efficiency) 𝛼 = 0 minimize potential delay 𝛼 = 2 how about 𝛼 = 1? (not defined, use L’Hospital)
𝑈𝑖 𝑥𝑖 = �𝑥𝑖1−𝛼
1 − 𝛼if 𝛼 ≠ 1
log 𝑥𝑖 if 𝛼 = 1
how about 𝛼 =→ +∞? why does it look so strange? how to remember?
Maximize 𝑈 𝒙 = �𝑈𝑖 𝑥𝑖
𝑛
𝑖=1
= �𝑥𝑖1−𝛼
1 − 𝛼
𝑛
𝑖=1
𝜵𝑼 𝒙∗ =𝒙𝟏−𝜶⋮
𝒙𝒏−𝜶; 𝜵𝑼 𝒙∗ 𝑻 𝒙 − 𝒙∗ = �
𝒙𝒊 − 𝒙𝒊∗
𝒙𝒊∗ 𝜶
𝒏
𝒊=𝟏
≤ 𝟎
Consider a flow 𝑠
�𝑥𝑖 − 𝑥𝑖∗
𝑥𝑖∗𝛼
𝑖:𝑥𝑖∗≤𝑥𝑠∗
+𝑥𝑠 − 𝑥𝑠∗
𝑥𝑠∗ 𝛼 + �𝑥𝑗 − 𝑥𝑗∗
𝑥𝑗∗𝛼
𝑗:𝑥𝑗∗>𝑥𝑠∗
≤ 0
⇒ � 𝒙𝒊 − 𝒙𝒊∗𝒙𝒔∗
𝒙𝒊∗𝜶
𝒊:𝒙𝒊∗≤𝒙𝒔∗
+ 𝒙𝒔 − 𝒙𝒔∗ + � 𝒙𝒋 − 𝒙𝒋∗𝒙𝒔∗
𝒙𝒋∗𝜶
𝒋:𝒙𝒋∗>𝒙𝒔∗
≤ 𝟎
need to decrease users who got less resource
Outline
Utility maximization and convex optimization Assumptions of utility functions Intuitive solutions of utility maximization Convex set, function and optimization framework
Utility maximization and fairness Max-min, proportional fairness and 𝛼-fairness
Karush–Kuhn–Tucker (KKT) conditions Lagrange multiplier and shadow price
Karush–Kuhn–Tucker (KKT) conditions
we know a necessary/sufficient condition:
𝛻𝑈 𝒙∗ 𝑻 𝒙 − 𝒙∗ ≤ 0, ∀𝒙 ∈ 𝑺. if the constraint set can be written as
subject to: 𝑔𝑖 𝒙 ≤ 0,∀𝑖 = 1,⋯ ,𝑚
KKT: if 𝒙∗ is optimal, for each 𝑔𝑖 ⋅ , there is a Lagrange multiplier 𝜇𝑖 ≥ 0 such that
𝛻𝑈 𝒙∗ = � 𝜇𝑖𝛻𝑔𝑖 𝒙∗𝑚
𝑖=1𝑔𝑖 𝒙∗ ≤ 0, ∀𝑖 = 1,⋯ ,𝑚𝜇𝑖𝑔𝑖 𝒙∗ = 0, ∀𝑖 = 1,⋯ ,𝑚
Unconstrained problems
Maximize 𝑈 𝒙 subject to: 𝑔𝑖 𝒙 ≤ 0,∀𝑖 = 1,⋯ ,𝑚
the KKT necessary conditions 𝛻𝑈 𝒙∗ = � 𝜇𝑖𝛻𝑔𝑖 𝒙∗
𝑚
𝑖=1= 𝟎
𝑔𝑖 𝒙∗ ≤ 0, ∀𝑖 = 1,⋯ ,𝑚𝜇𝑖 ≥ 0, ∀𝑖 = 1,⋯ ,𝑚
𝜇𝑖𝑔𝑖 𝒙∗ = 0, ∀𝑖 = 1,⋯ ,𝑚
⇒𝜕𝑓 𝒙∗
𝑥𝑖= 0 ∀𝑖 = 1,⋯ ,𝑛
Utility maximization
Max 𝑈 𝒙 = 𝑈1 𝑥1 + 𝑈2 𝑥2 ; s.t. 𝑥1 + 𝑥2 ≤ 𝐶
𝛻𝑈 𝒙∗ = 𝜇𝛻𝑔 𝒙∗𝑔 𝒙∗ = 𝑥1∗ + 𝑥2∗ − 𝐶 ≤ 0
𝜇 ≥ 0𝜇𝑔 𝒙∗ = 𝜇 𝑥1∗ + 𝑥2∗ − 𝐶 = 0
Either 1) 𝜇 = 0 & 𝛻𝑈 𝒙∗ = 0 or 2) 𝜇 > 0 &
𝛻𝑈 𝒙∗ = 𝜇𝛻𝑔 𝒙∗ ⇔ �𝑈1′ 𝑥1∗ = 𝜇𝑈2′ 𝑥2∗ = 𝜇
𝒙𝟏 𝒙𝟐
𝑪
Lagrange multiplier and shadow price
Max 𝑈 𝒙 = 𝑈1 𝑥1 + 𝑈2 𝑥2 ; s.t. 𝑥1 + 𝑥2 ≤ 𝐶
the Lagrange multiplier 𝜇 corresponds to the marginal utility achieved at the maximum
“shadow price”: if we can add additional resource, how much can we increase utility
Either 1) 𝜇 = 0 & 𝛻𝑈 𝒙∗ = 0 or 2) 𝜇 > 0 &
𝛻𝑈 𝒙∗ = 𝜇𝛻𝑔 𝒙∗ ⇔ �𝑈1′ 𝑥1∗ = 𝜇𝑈2′ 𝑥2∗ = 𝜇
𝒙𝟏 𝒙𝟐
𝑪
Utility maximization
𝛻𝑈 𝒙∗ = 𝜇𝛻𝑔 𝒙∗ + 𝜇1−10 + 𝜇2
0−1
𝑔 𝒙∗ = 𝑥1∗ + 𝑥2∗ − 𝐶 ≤ 0;−𝑥1 ≤ 0;−𝑥2 ≤ 0𝜇 ≥ 0; 𝜇1 ≥ 0; 𝜇2 ≥ 0
𝜇𝑔 𝒙∗ = 𝜇 𝑥1∗ + 𝑥2∗ − 𝐶 = 𝜇1𝑥1∗ = 𝜇2𝑥2∗ = 0
for the non-trivial case of 𝜇 > 0
⇒ �𝑈1′ 𝑥1∗ = 𝜇 − 𝜇1𝑈2′ 𝑥2∗ = 𝜇 − 𝜇2
𝒙𝟏 𝒙𝟐
𝑪 Max 𝑈 𝒙 = 𝑈1 𝑥1 + 𝑈2 𝑥2 ; s.t. 𝑥1 + 𝑥2 ≤ 𝐶, 𝑥1 ≥ 0 and 𝑥2 ≥ 0
Network Utility
Max 𝑈 𝒙 = 𝑈1 𝑥1 + 𝑈2 𝑥2 + 𝑈3 𝑥3 ; s.t. 𝑥1 + 𝑥2 ≤ 𝐶1, 𝑥2 + 𝑥3 ≤ 𝐶2 and 𝒙 ≥ 0
𝛻𝑈 𝒙∗ = 𝜇𝐶1110
+ 𝜇𝐶2101
+ 𝜇1−100
+ 𝜇20−10
+ 𝜇300−1
𝑥1 + 𝑥2 − 𝐶1 ≤ 0, 𝑥2 + 𝑥3 − 𝐶2 ≤ 0 and − 𝑥𝑖 ≤ 0𝜇𝐶1 ≥ 0; 𝜇𝐶2 ≥ 0; 𝜇1 ≥ 0; 𝜇2 ≥ 0; 𝜇3 ≥ 0
𝜇𝐶1 𝑥1∗ + 𝑥2∗ − 𝐶1 = 𝜇𝐶2 𝑥1
∗ + 𝑥3∗ − 𝐶2 = 𝜇𝑖𝑥𝑖∗ = 0
⇒ �𝑈1′ 𝑥1∗ = 𝜇𝐶1 + 𝜇𝐶2 − 𝜇1
𝑈2′ 𝑥2∗ = 𝜇𝐶1 − 𝜇2𝑈3′ 𝑥3∗ = 𝜇𝐶2 − 𝜇3
𝒙𝟏
𝒙𝟑
𝑪𝟐 𝑪𝟏
𝒙𝟐
Further topics
We have characterized the optimization solution. How can we find it? Different optimization algorithms
In practice, global information might not
be available. How can we solve it in a distributed manner? Primal-dual decomposition … another course Convergence of the algorithms
Further Readings F. P. Kelly, “Charging and rate control for
elastic traffic”, Euro. Trans. Telecommun., vol. 8, pp. 33–37, 1997.
F. P. Kelly, A. Maulloo, and D. Tan, “Rate control for communication networks: Shadow prices, proportional fairness and stability”, J. Oper. Res. Soc., 49(3), 1998.
Steven H. Low and David E. Lapsley, “Optimization Flow Control—I: Basic Algorithm and Convergence”, IEEE/ACM Transactions on Networking, 7(6), 1999.