Question 1:

In Modern Portfolio Theory, the case where we minimize variance given a set return and that the weights sum to 1, why is the return set as an equality constraint, not an inequality?

Question 2:

If we were to add an constraint, let us say an ESG constraint (we assign each asset an ESG score and force the weights multiplied with the ESG scores to be a certain scalar), should this be an equality constraint or an inequality constraint?

I understand that equality constraints are easier in both cases, but I fail to understand why they would also be correct.

  • $\begingroup$ Welcome to the forum. Not too sure what you mean by return is set as an equality constraint. In an MVP, the only constraints applied is all weights sum to 1. $\endgroup$
    – KaiSqDist
    Feb 13 at 20:59
  • $\begingroup$ (Gonna make an assumption that you are taking about weight, not return for the constraint) If we let $w_i$ represent the weight of asset $i$ in some portfolio, then setting $\sum_{\forall i}w_i=1$ indicates that we have to allocate all the available capital, if we say $\sum_{\forall i}w_i \le 1$, then we do not have to allocate all capital. For the ESG question, same thing applies. If you use a equality constraints, then the solution has to meet that exact requirement. If you use an inequality constraint, it is more flexible. $\endgroup$
    – Valter
    Feb 16 at 22:24

1 Answer 1


I'm not sure if I understand your question correctly. I'll try to answer, but you ay want to clarify what you're asking.

I'll review portfolio optimization and constraints.

Typically, you have a universe of assets to possibly invest in, and a matrix of pairwise covariances between the assets (variances on the diagonal), and an optimizer such as HiGHS or cvxopt.

When Markowitz got an economics Nobel Prize in 1990, lots of quant shops reacted to the media buzz by offering pretty much the same thing:

1 pick a universe of a few hundred stocks using some criteria, hoping that this universe would outperform the market

2 use a quadratic optimizer to find a minimum-covariance portfolio. For the vast majority, the objective function being minimized was just the portfolio covariance. Some people included some kind on "alpha" in the objective function, such as a "buy" or "sell" from their favorite research, signifying that some assets are more or less desirable; included some kind of transaction cost of moving from the current portfolio weights to the new optimal weights; and tweaked the covariance matrix in some ways supposed to produce a better optimal portfolio.

Without constraints, the optimization would invest all the money in a small number of low-variance assets. To avoid this, and to force more diversification, you need linear constraints. For example, for each asset, you'll probably need a constraint forcing the weight of this asset to be no more than 1% (or 5%, or whatever you think is OK in one asset). For a long-only portfolio, you need the weight of each asset to be >=0. You might also have an upper bound on some industrial sectors, or on some screens used to construct the universe.

As KaiSqDist mentioned, having all the weights add up to 100% is one obvious equality constraint. I can think of a few more practical use cases for equality constraints. For example, suppose that two corporations in your portfolio have merged, resulting in a combined weight exceeding your single-name upper bound. Or suppose that a corporation got taken private, requiring you to tender the stock and to receive cash that you need to put to work. In order to reduce transaction costs, you may want to run an optimization where the assets that you won't want to change for now would have an equality constraint forcing the weight to remain the same, and letting the optimizer find substitutions for the deleted assets that would minimize the objective function.

If you have some ESG score for each asset, I see several ways to use it, for example:

1 you can identify all the assets with the ESG score below a certain thresholds, or are into fossil fuels, or otherwise undesirable, and have an equality constraint forcing them all to 0. But the same result be accomplished more efficiently by not having the excluded assets in the universe and the covariance matrix.

2 you can include the ESG score in your objective function, like the alpha mentioned above.

3 you can have an inequality constraint requiring the weighted ESG score of your portfolio to be above some minimal threshold.

However I can't think of a realistic use case with ESG scores in an equality constraint. Suppose you have ESG scores between 0 and $n$, and you force the optimized portfolio ESG score to be exactly $k<n$, rather than $\gt k$. In other words, you instruct your optimizer to reject a portfolio that might have both better objective function (lower covariance) and better ESG score. Why would anyone want that?

  • 1
    $\begingroup$ I think you are completely right and I agree that ESG as an equality constraint would be incorrect (since an inequality constraint would obviously be a better model). However, one can find som papers where ESG is modeled as an equality, such as "Portfolio optimization for sustainable investments" (Varmaz, Fieberg & Poddig 2022) or as three E, S, and G constraints in "On Imposing ESG Constraints of Portfolio Selection for Sustainable Investment and Comparing the Efficient Frontiers in the Weight Space" (Qi & Li 2020). Varmaz, Fieberg & Poddig (2022) uses a utility function as justification. $\endgroup$ Feb 23 at 12:28
  • $\begingroup$ Would you happen to have doi's for these papers? I'm curious to take a look. Thanks! $\endgroup$ Feb 23 at 13:45
  • 1
    $\begingroup$ Yes, both are open access. Varmaz, Fieberg & Poddig: dx.doi.org/10.2139/ssrn.3859616 Qi & Li: doi.org/10.1177/2158244020975070 $\endgroup$ Feb 28 at 15:19
  • $\begingroup$ Thanks @MrEntscheidung! $\endgroup$ Feb 28 at 16:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.