Skip to content

Constraint

A constraint is a rule a candidate solution must satisfy. See how budget, long-only and position limits combine, and what active or binding means.

A constraint is a rule that a candidate solution must satisfy. In portfolio construction, a model can prefer a position but still be forbidden to hold it: the position may exceed a mandate limit or require a short sale that the mandate excludes.
Constraints restrict the permitted values of the decision variables. The candidates satisfying all the rules form the feasible set. An objective function then ranks those candidates. Passing the rules establishes feasibility, not that a portfolio is best.

One portfolio, three kinds of rule

Suppose a hypothetical portfolio invests only in Assets A and B, with no separate cash position. Let wAw_A and wBw_B be fractions of total portfolio value. Its mandate requires:

wA+wB=1⏟fully invested budget,wA≥0,wB≥0⏟long-only,wA≤0.6⏟Asset A cap.\underbrace{w_A+w_B=1}_{\text{fully invested budget}}, \qquad \underbrace{w_A\ge0,\quad w_B\ge0}_{\text{long-only}}, \qquad \underbrace{w_A\le0.6}_{\text{Asset A cap}}.
The budget is an equality constraint: it demands an exact total. The remaining rules are inequality constraints: zero weights and exactly 60% in A are permitted. These are invented modelling rules for this example, not a statement of actual regulation.
Candidate (wA,wB)(w_A,w_B)CheckResult
(0.5,0.5)(0.5,0.5)Total is 1; both weights nonnegative; A is below 0.6Feasible
(0.7,0.3)(0.7,0.3)Total is 1, but A exceeds its cap by 0.1Infeasible
(0.5,0.4)(0.5,0.4)Both weights meet their bounds, but total is only 0.9Infeasible

The last portfolio leaves 10% unallocated. It would need an explicitly modelled cash weight to describe that allocation; it does not satisfy the stated two-asset budget.

Substitute wB=1−wAw_B=1-w_A into the inequalities. Long-only gives 0≤wA≤10\le w_A\le1, and the cap tightens the upper end to 0.6. Thus the entire feasible set is

{(wA,1−wA):0≤wA≤0.6}.\{(w_A,1-w_A):0\le w_A\le0.6\}.
Hypothetical nonnegative portfolio weights: the blue feasible segment joins (0, 1) and (0.6, 0.4). (0.5, 0.5) is feasible, (0.7, 0.3) violates the cap, and (0.5, 0.4) violates the budget.
Hypothetical nonnegative portfolio weights: the blue feasible segment joins (0, 1) and (0.6, 0.4). (0.5, 0.5) is feasible, (0.7, 0.3) violates the cap, and (0.5, 0.4) violates the budget.
Original hypothetical allocation diagram. Weights are fractions of portfolio value. The equality budget leaves a line segment, not an area of feasible portfolios.

When a constraint is active

At a feasible point, an inequality is active, also called binding, when it holds with equality. At (0.6,0.4)(0.6,0.4), the cap is active because wA=0.6w_A=0.6. At (0.5,0.5)(0.5,0.5) it is slack, with slack 0.6−0.5=0.10.6-0.5=0.1: ten percentage points of portfolio weight remain before reaching the cap. The budget equality holds at every feasible point.
Active describes tightness at a point. It does not by itself establish that relaxing the constraint would improve the best objective value. That economic effect also depends on the objective and the other rules; an active inequality can have a zero Lagrange multiplier.

Rules can change the problem itself

A hard constraint must be satisfied; a penalty in the objective merely makes a violation costly unless another rule prohibits it. Conflicting constraints can leave no feasible solution at all. Adding wA≥0.7w_A\ge0.7 to this example would conflict directly with wA≤0.6w_A\le0.6.

These particular constraints are linear, as used in linear programming. Other constraints can be nonlinear, such as a portfolio variance limit, or discrete, such as requiring whole numbers of contracts. Their form affects which methods can solve the resulting constrained optimisation problem.
For the next mathematical step, Constrained and Convex Optimisation develops equality constraints and active inequalities. The public page is a preview; the full lesson requires membership.

Sources

Last updated
  • optimisation
  • portfolio weights
  • constraints
  • feasibility
← Back to the glossaryBack to top ↑