Lecture 7 LP 对偶性
在对抗者面前求解 LP
假设你想优化下面这个原始 LP:
最大化 $c^\top x$
满足约束:
\[\begin{align*}&Ax \leq b\\ &x_1, \cdots, x_n \geq 0 \end{align*}\]假设一个“对抗者”带着一个 $m$ 维向量 $y\in \mathbb{R}^m, y \geq 0$ 出现,并且满足:$c^\top \leq y^\top A$。
对于原始问题中的任意解 $x$,都有:
\[\begin{align*} c^\top x &\leq (y^\top A) x &\text{ (because } x \geq 0 \text{\ \& \ } c^\top \leq y^\top A) \\ &= y^\top (Ax) \\ &\leq y^\top b &\text{ (because } y^\top \geq 0 \text{\ \&\ } Ax \leq b)\end{align*}\]因此,对抗者的目标是在满足 $c^\top \leq y^\top A$ 的条件下最小化 $y^\top b$,也就是优化对偶 LP。
LP 对偶定理
命题:(弱对偶性)
\[c^\top x^\ast \leq b^\top y^\ast\]定理:(强对偶性,von Neumann’47)下面四种情况之一成立:
-
原始 LP 和对偶 LP 都是可行的,并且对于原始问题的任意最优解 $x^\ast$ 和对偶问题的任意最优解 $y^\ast$,都有:
\[c^\top x^\ast = b^\top y^\ast\] - 原始问题不可行,对偶问题无界。
- 原始问题无界,对偶问题不可行。
- 两个 LP 都不可行。
LP 对偶性的有用推论
原始 LP 和对偶 LP 的解 $x^\ast$ 和 $y^\ast$ 分别同时为最优解,当且仅当下面条件成立:
- 对每个原始约束 $(Ax)_i \leq b_i$,$i = 1, \cdots, m$,要么 $(Ax^\ast)_i = b_i$,要么 $y_i^* = 0$(或者二者都成立)。
- 对每个对偶约束 $(A^\top y)_j \geq c_j$,$j = 1, \cdots, n$,要么 $(A^\top y^\ast)_j = c_j$,要么 $x^\ast_j = 0$(或者二者都成立)。
证明:由弱对偶性,
\[c^\top x^\ast \leq ((y^\ast)^\top A)x^\ast = (y^\ast)^\top (Ax^\ast) \leq (y^\ast)^\top b\]由强对偶性可知,每个不等式恰好在 $x^\ast$ 和 $y^\ast$ 最优时取等号。因此,在最优时,
\[(((y^\ast)^\top A - c^\top )x^\ast = 0\]由于 $(((y^\ast)^\top A - c^\top ) \geq 0$ 且 $x^\ast \geq 0$,所以对每个 $j = 1, \cdots, n$,必有 $(A^\top y^\ast)_j = c_j$ 或 $x^\ast_j = 0$。
同理,在最优时,$(y^\ast)^\top (b - Ax^\ast) = 0$,因此对每个 $i = 1, \cdots, m$,必有 $(Ax^\ast)_i = b_i$ 或 $y_i^* = 0$。
构造 LP 对偶的一般规则
如果原始问题是:
最大化 $c^\top x$
满足约束:
\[\begin{align*} & (Ax)_i \leq b_i, i = 1, \cdots, d,\\& (Ax)_i = b_i, i = d + 1, \cdots, m,\\& x_1, \cdots, x_r \geq 0 \end{align*}\]那么对偶问题是:
最小化 $b^\top y$
满足约束:
\[\begin{align*} & (A^\top y)_i \geq c_i, i = 1, \cdots, r,\\& (A^\top y)_i = c_i, i = r + 1, \cdots, n,\\& y_1, \cdots, y_d \geq 0 \end{align*}\]对偶性与 Minimax 定理
回忆一下,在由矩阵 $A$ 给出的零和博弈中,用来为玩家 1 求解 Minimax 的 LP 是:
最大化 $v$
满足约束:
\[\begin{align*} & v - (x^\top A)_j \leq 0, \text{ for } j = 1, \cdots, m_2,\\& x_1 + \cdots + x_{m_1} = 1 \\& x_1 \geq 0 \text{ for } j = 1, \cdots, m_1.\end{align*}\]这个 LP 的对偶是:
最小化 $u$
满足约束:
\[\begin{align*} & u - (Ay)_i \geq 0, \text{ for } i = 1, \cdots, m_i,\\& y_1 + \cdots + y_{m_2} = 1 \\& y_j \geq 0 \text{ for } j = 1, \cdots, m_2. \end{align*}\]因此,minimax 定理可以由 LP 对偶性推出:这两个 LP 的最优值是相同的。