Reference 0005

Stationarity for an Upper Bound

A quick recipe for turning objective slope into a dual variable at a binding max-weight cap.

Problem shape

Maximize a score over one portfolio weight, with an upper bound w <= c.

Binding case

If the unconstrained target is above c, then w* = c and the cap is active.

Dual value

For this maximization convention, lambda = score'(w*) when the upper cap binds and the slope is positive.

Inactive case

If the unconstrained target is below the cap, the cap has slack and lambda = 0.

Worked Pattern

score(w) = -(w - target)^2
score'(w) = -2(w - target)

constraint: w <= cap
solution:   w* = min(target, cap)

if target > cap:
  lambda = score'(cap) = 2(target - cap)
else:
  lambda = 0

Example

target = 0.80
cap    = 0.70
w*     = 0.70

score'(0.70) = -2(0.70 - 0.80) = 0.20
lambda       = 0.20

Sign Warning

Books and solvers may use minimization form, maximization form, or write inequalities in different directions. Do not memorize a naked sign. First identify the convention, then interpret the dual as the pressure that balances the blocked objective push.

Use this page with Lesson 0005 and Reference 0004.