Skip to content

Objective function

An objective function scores a decision. Compare return maximisation, variance minimisation and a risk-adjusted score on the same two-asset portfolio choices.

An objective function assigns a numerical score to a choice so an optimisation problem can seek the highest or lowest score. In portfolio construction, the score might be expected return, return variance, or expected return after a risk penalty. Calling a portfolio “optimal” makes sense only after specifying that criterion and the allowed choices.

The distinction is compactly written as

min⁡x∈Ff(x).\min_{x\in\mathcal{F}} f(x).
The decision variable xx describes the choice; the objective function ff maps that choice to one real number; the feasible set F\mathcal{F} contains choices permitted by the constraints. For a minimisation, lower is better. For a maximisation, higher is better. The optimal solution x∗x^* is a choice, while f(x∗)f(x^*) is its objective value. They can have entirely different units.

An objective describes what the model rewards. It does not establish that the reward is the investor's true goal or that an optimum exists. A problem can have several optimal choices, no feasible choices, or a score that improves without attaining a best value.

One portfolio menu, two answers

Suppose a manager allocates between two hypothetical assets over one common holding period. Their simple-return moments are stipulated, rather than estimated from market data:

InputAsset AAsset B
Expected return8%4%
Return variance, decimal-return squared0.040.01
Return standard deviation20%10%
The assets have zero covariance. Invest fraction ww in A and 1−w1-w in B, with 0≤w≤10\le w\le1: fully invested, no shorts, no cash asset. Ignore trading costs. The portfolio's expected return and variance are
μ(w)=0.08w+0.04(1−w)=0.04+0.04w,v(w)=0.04w2+0.01(1−w)2.\begin{aligned} \mu(w)&=0.08w+0.04(1-w)=0.04+0.04w,\\ v(w)&=0.04w^2+0.01(1-w)^2. \end{aligned}
Maximise expected return. Since μ(w)\mu(w) increases throughout the allowed interval, choose w=1w=1. The expected return is 8%, and the variance is 0.04. Risk has no penalty in this particular objective; the model has no reason to diversify.
Minimise variance. Rewrite the other criterion as
v(w)=0.008+0.05(w−0.2)2.v(w)=0.008+0.05(w-0.2)^2.

The squared term cannot be negative and vanishes at w=0.2w=0.2. That feasible weight therefore gives the global minimum variance, 0.008. It invests 20% in A and 80% in B, earning an expected 4.8% with return standard deviation about 8.94%. Despite A's higher standalone variance, a modest allocation to A reduces portfolio variance because of the specified covariance.

Same synthetic long-only allocations: expected return rises from 4% to 8% and is maximised at 100% in A; variance is minimised at 20% in A, where it is 0.008.
Same synthetic long-only allocations: expected return rises from 4% to 8% and is maximised at 100% in A; variance is minimised at 20% in A, where it is 0.008.
Original one-period model comparison. The horizontal axes show the same allocation choices; the vertical axes have different units and scales. Zero covariance is an assumption, not an empirical finding.

Both answers are correct for their stated objectives. Neither changes the feasible set. In contrast, adding a cap w≤0.6w\le0.6 changes which allocations are allowed; under that cap, maximum expected return becomes 6.4% at w=0.6w=0.6.

A trade-off needs an explicit exchange rate

Mean–variance optimisation combines return and risk into one score. A common convention is

max⁡0≤w≤1Jλ(w),Jλ(w)=μ(w)−λ2v(w),λ>0.\max_{0\le w\le1} J_\lambda(w), \qquad J_\lambda(w)=\mu(w)-\frac{\lambda}{2}v(w), \qquad \lambda>0.

The parameter λ\lambda sets the risk penalty. Its numerical meaning depends on the return units and the factor-of-two convention. A higher penalty expresses a stronger preference against variance within this model; it is not an additional portfolio constraint.

For λ=5\lambda=5 with decimal returns,

J5′(w)=0.09−0.25w,J5′′(w)=−0.25.J_5'(w)=0.09-0.25w, \qquad J_5''(w)=-0.25.
The score is strictly concave, so its feasible stationary point w=0.36w=0.36 is its unique maximum. The resulting expected return is 5.44%, variance is 0.00928, and score is 0.0312. The score is not a forecast return: 0.0312 includes a preference penalty; the forecast mean remains 0.0544. The risk penalty does not remove uncertainty or charge an actual fee.

Unit changes require care. Expressing returns in percentage points multiplies means by 100 and variances by 10,000. To retain the same ranking under the displayed formula, replace λ=5\lambda=5 by λ=0.05\lambda=0.05. Keeping the numerical penalty unchanged would describe a different trade-off. More generally, multiplying a whole objective by a positive constant or adding a constant leaves its optimisers unchanged; changing just one term's coefficient can change the answer. Maximising ff is also equivalent to minimising −f-f.

More than one criterion does not automatically give one winner

“Maximise return and minimise risk” states two criteria. It does not specify how much return to exchange for less risk. One approach is the weighted score above. Another is to minimise variance subject to a required expected return. A third is to examine the efficient frontier: portfolios for which no feasible alternative has at least as much expected return and at most as much variance, with one strict improvement.

Choosing a frontier point still requires a preference or mandate. Two moments also omit features such as asymmetric losses, liquidity and estimation uncertainty. In a trading model, transaction costs and holding costs may belong in the objective too, with compatible units. A precisely solved objective can faithfully optimise an incomplete description of the investment problem.

For the portfolio derivations, see Mean–Variance Optimisation (public preview; full lesson requires membership).

Sources

  • Gérard Cornuéjols, Javier Peña and Reha Tütüncü, Optimization Methods in Finance, second edition, Cambridge University Press, 2018, Chapter 1, especially the opening model and §1.3, and Chapter 6, §§6.1–6.2. Definitions of objectives, feasible choices and optimal values; portfolio mean–variance formulations.
  • Stephen Boyd, Enzo Busseti, Steven Diamond, Ronald Kahn, Kwangmoo Koh, Peter Nystrup and Jan Speth, Multi-Period Trading via Convex Optimization, Foundations and Trends in Optimization 3(1), 2017. Portfolio objectives combining expected return, risk, transaction costs and holding costs.
Last updated
  • optimisation
  • decision making
  • portfolio construction
  • mean variance
  • risk penalty
← Back to the glossaryBack to top ↑