














Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!















AMSC 607 / CMSC 764 Advanced Numerical Optimization Fall 2006 UNIT 3: Constrained Optimization PART 1: Characterizing a solution Dianne P. O’Leary ©^ c2001,2003,
Fundamentals for constrained optimization
Our approach: Always try to reduce the problem to one with a known solution.
Reference: N&S, Chapter 14
Our problem
min x f (x)
ci(x) = 0 , i ∈ E ci(x) ≥ 0 , i ∈ I
where f and ci are C^2 functions from Rn^ into R^1.
Definition of a solution
We say that x∗^ is a solution to our problem if
In other words, x∗^ is feasible and locally optimal.
The plan
We will develop necessary and sufficient optimality conditions so that we can recognize solutions and develop algorithms to find solutions.
We do this in several stages.
Then we will discuss duality.
Case 1: Optimality Conditions for Linear equality constraints only
Our problem
Reference: Some of this material can be found in N&S Chapter 3.
Our problem: min x f (x)
Ax = b
where A is a matrix of dimension m × n.
We also assume a constraint qualification or regularity condition: assume that A has rank m.
Unquiz:
An example
We obtain this formulation for feasible x by taking a particular solution [ 0 1
and adding on a linear combination of vectors that span the null space of the matrix (^) [ 1 1
The null space defines the set of feasible directions, the directions in which we can step without immediately stepping outside the feasible space.
End example []
What we have accomplished
In general, if our constraints are Ax = b, to get feasible directions, we express x as x = ¯x + Zv
where
Then we have succeeded in reformulating our constrained problem as an unconstrained one: min v f (¯x + Zv)
Where does Z come from?
N&S, Section 3.3.
Suppose we have a QR factorization of the matrix AT^ :
where
Then Ax = (RT^ QT 1 + 0QT 2 )x = RT^ QT 1 x
and the columns of Q 2 form a basis for the nullspace of A.
Therefore, to determine Z, we do a QR factorization of AT^ and set Z = Q 2.
Algorithms for QR factorization: Gram-Schmidt, Givens, Householder, ...
What are the optimality conditions for our reformulated problem?
min v f (¯x + Zv)
Let F (v) = f (¯x + Zv).
Then
(^5) v F (v) = ZT^5 x f (¯x + Zv) = ZT^ g(x) (^52) v F (v) = ZT^52 x f (¯x + Zv)Z = ZT^ H(x)Z
since ¯x + Zv = x.
Our theory for unconstrained optimization now gives us necessary conditions for optimality:
We also have sufficient conditions for optimality:
So we have an alternate formulation of our first order necessary conditions for optimality:
ZT^ g(x) = 0 , Ax = b.
Three digressions
Digression 1: There are cheaper but less stable alternatives to QR.
The QR factorization gives a very nice basis for the nullspace: its columns are mutually orthogonal and therefore computing with them is stable.
There are alternative approaches.
Option 1: Partitioning
Let A =
where B ∈ Rm×m^ and N ∈ Rm×(n−m).
Partition x similarly, with x 1 ∈ Rm^ and x 2 ∈ Rn−m.
Assume that B is nonsingular. (If not, rearrange the columns of A until it is.)
Then Ax = 0 if and only if Bx 1 + N x 2 = 0 ,
and this means x 1 + B−^1 N x 2 = 0 ,
so x 1 = −B−^1 N x 2
and
x =
v.
Therefore, the columns of (^) [ −B−^1 N I
must be a basis for the nullspace of A!
Caution: This basis is sometimes very ill-conditioned, and working with it can lead to unnecessary round-off error.
Option 2: Orthogonal projection
Let x = p + q
where p is in the nullspace of A and q is in the range of AT^.
Then Ap = 0
and q can be expressed as q = AT^ λ
for some vector λ.
Now Ax = A(AT^ λ)
so λ = (AAT^ )−^1 Ax.
Let’s look at
p = x − q = x − AT^ (AAT^ )−^1 Ax = (I − AT^ (AAT^ )−^1 A)x ≡ P x.
The matrix P is an orthogonal projection that takes x into the null space of A.
Thus we have reduced our problem to an unconstrained one, where x = xb + (I − AT^ (AAT^ )−^1 A)y where xb is a particular solution to Ax = b and y is any n-vector.
Unquiz: Prove that
but note that in general P T^ P 6 = I, so P itself is not an orthogonal matrix. []
The projector P is usually applied using a Cholesky factorization.
Case 2: Optimality conditions for linear inequality constraints
A big “if”
IF we knew W = {i ∈ I : ci(x∗) = 0} ,
where c(x∗) = Ax∗^ − b, then we could set up the Lagrange multiplier problem and have optimality conditions for our problem.
Let W¯ denote the subscripts not in W.
But we don’t know the set W of constraints that are active at the solution.
Let’s guess!
Suppose we take a guess at the active set. This gives us a set of equations to solve:
g(x) − ATwλw = 0 , Awx = bw.
Assume that Aw has full row rank. This implies that W has at most n elements.
Suppose this system has a solution xˆ, ˆλ. Also suppose that A (^) w¯ x > bˆ (^) w¯, so that ˆx is feasible. Do we have a solution to our minimization problem?
Suppose we find that λˆj < 0.
Let p solve Awp = ej.
(This has a solution since Aw is full rank.)
Then Aw(ˆx + αp) = bw + αej ≥ bw,
so xˆ + αp satisfies the W inequality constraints as long as α > 0 , and it satisfies the other inequalities as long as α is small enough. Thus, p is a feasible direction.
Also, by Digression 2, we know that
f (ˆx + αp) ≈ f (ˆx) + αeTj ˆλ = f (ˆx) + αˆλj < f (ˆx)
(for small enough α) so we have found a better point!
We’ll come back to the algorithmic use of this idea later. For now, we seek insight on recognizing an optimal point.
We have just shown that if x is a minimizer, then the multipliers λw that satisfy ATwλw = g(x) must be nonnegative.
(The multipliers for the w¯ indices must be zero, since these constraints do not appear in the Lagrangian.)
A fancy way of writing this
Current formulation of (first order) necessary conditions for optimality:
ATwλw = g(x) λw ≥ 0 , λ (^) w¯= Awx = bw A (^) w¯x > b (^) w¯
where w¯ denotes the subscripts not in W.
Equivalently,
AT^ λ = g(x) λ ≥ 0 Ax ≥ b λT^ (Ax − b) = 0
This last condition is called complementarity.
The second order necessary condition: (from the reduced variable derivation above) The reduced variable Hessian matrix
ZwT H(x)Zw
must be positive semidefinite.
Sufficient conditions for optimality: All of this, plus ZwT H(x)Zw positive definite.
Goal:
To prove: If all constraints are equalities, then
AT^ (x∗)λ = g(x∗).
Note: We are proving the correctness of the Lagrange multiplier formulation for solving equality constrained problems as promised earlier in this set of notes.
Proof ingredient 1: a pitfall
With nonlinear constraints, there may be no feasible directions!
picture
So we need to work with feasible curves x(t), 0 ≤ t ≤ t 1 , with x(0) being our current point. A curve is feasible if it stays tangent to our (active) constraints.
Example 1: The curve
x(t) =
cos t sin t
stays tangent to the unit circle x^21 + x^22 = 1.
This is true since
x(0) =
and
x′(t) =
− sin t cos t
which is tangent to the circle. []
Example 2: The curve
x(t) =
t 2 t
stays tangent to the line x 2 − 2 x 1 = 4.
[]
Proof ingredient 2: Some unstated machinery that N&S use:
Proof ingredient 3: the tangent cone
Define the tangent cone
T (x∗) = {p : p = x′(0)for some feasible curve at x∗}.
This is a cone because
picture
Now the constraints are equalities, so
ci(x(t)) = 0, t ∈ [t 0 , t 1 ] ,
so d ci(x(t)) dt
= x′(t)T^5 ci(x(t)) = 0. t ∈ [t 0 , t 1 ].
Therefore, at t = 0, for all feasible curves,
x′(0)T^5 ci(x∗) = 0.
Thus, for all p in the tangent cone T of x∗,
pT^5 ci(x∗) = 0, i = 1,... , m,
so A(x∗)p = 0.
Therefore, if p is in the tangent cone, then p is in the null space of the matrix of constraint gradients!
If the rows of A are linearly independent, then we can reverse the argument and show that if p is in the null space of A, then p is in the tangent cone.
Therefore, when A(x∗) is full rank, the tangent cone T (x∗) equals the nullspace of A(x∗).
Duality
Duality
Idea: Problems come in pairs, linked through the Lagrangian.
We need two theorems about this linkage, or duality:
and then two theorems about dual problems:
and finally an alternate dual problem, the Wolfe dual, that depends on differentiability.
Weak duality
Theorem: (Weak Duality) (N&S p466) Let F (x, λ) be a function from Rn+m^ → R^1 with x ∈ Rn^ and λ ∈ Rm. Then
max λ min x F (x, λ) ≤ min x max λ F (x, λ).
Notes:
Proof: Given any ˆx and ˆλ,
min x F (x, λˆ) ≤ F (ˆx, ˆλ) ≤ max λ F (ˆx, λ).
Now let’s make a specific choice:
Then max λ min x F ≤ min x max λ
Strong duality
Theorem: (Strong Duality) (N&S p.468) Let F (x, λ) be a function from Rn+m^ → R^1. Then the condition
max λ min x F (x, λ)= min x max λ F (x, λ)
holds if and only if there exists a point (x∗, λ∗) such that
F (x∗, λ) ≤ F (x∗, λ∗) ≤ F (x, λ∗)
for all points x and λ in the domain of F.
In words: We can reverse the order of the max and the min if and only if there exists a saddle point for F.
Proof: (←) Suppose (x∗, λ∗) is a saddle point. Then
min x max λ
F (x, λ) ≤ max λ
F (x∗, λ)
≤ F (x∗, λ∗) ≤ min x F (x, λ∗)
≤ max λ min x F (x, λ)
Now, considering the result of the weak duality theorem, we can conclude that the first term must equal the last.
(→) Suppose max λ
min x F (x, λ)= min x max λ
F (x, λ)
and that this is equal to the value F (x∗, λ∗). Then, for any ˆx and ˆλ,
F (x∗, ˆλ) ≤ max λ F (x∗, λ)
= max λ min x F (x, λ)
= F (x∗, λ∗) = min x max λ
F (x, λ)
= min x F (x, λ∗)
≤ F (ˆx, λ∗)
Theorem: (Weak Lagrange duality) (N&S p. 471) Let ˜x be primal feasible, so that c(˜x) ≥ 0. Let ¯x, ¯λ be dual feasible, so that ¯λ ≥ 0 , and ¯x minimizes L(x, λ¯).
Then f (¯x) − ¯λT^ c(¯x) ≤ f (˜x).
Note:
Proof: Let’s recall what we know. The Lagrangian is
L(x, λ) = f (x) − λT^ c(x).
The Weak Duality Theorem, and the fact that ˜x is feasible, tells us
f (¯x) − ¯λT^ c(¯x) = L(¯x, ¯λ) ≤ max λ≥ 0 min x L(x, λ)
≤ min x max λ≥ 0 L(x, λ)
≤ max λ≥ 0
L(˜x, λ)
= f (˜x)
Corollary: If the primal is unbounded, then the dual is infeasible. If the dual is unbounded, then the primal is infeasible.
Example: Consider the primal problem
min x −x
(with x ∈ R^1 ) subject to x ≥ 0. The Lagrangian is
L(x, λ) = −x − λx.
Then ¯x, λ is dual feasible if ¯x satisfies
min x −(λ + 1)x
where λ is a fixed nonnegative number. There are no dual feasible points, and the primal has no minimum. []
An important example: Linear programming duality
Example: Duality for linear programming
Consider the linear programming problem
min x cT^ x
Ax − b ≥ 0
The Lagrangian is L(x, λ) = cT^ x−λT^ (Ax − b).
The primal problem is min x max λ≥ 0 cT^ x−λT^ (Ax − b)
which is equivalent to our original problem.
The dual problem is max λ≥ 0 min x cT^ x−λT^ (Ax − b).
Fix λ ≥ 0. Then we need to minimize
(c−AT^ λ)T^ x+λT^ b
and this value is L∗(λ).
But
L∗(λ) =
−∞ if c−AT^ λ 6 = 0 , λT^ b if c−AT^ λ = 0.
Therefore, if λ∗^ ≥ 0 and c−AT^ λ∗^ = 0, then the dual problem solution value is λ∗T^ b.
Thus, the dual problem is equivalent to
max λ≥ 0 λT^ b
AT^ λ−c = 0
Check strong duality: