## Problem Statement for the definition of the Efficient Frontier

Let $\mu$ be the vector of expected returns and $\Omega$ the returns covariance matrix of $n$ assets. The Markowitz optimization problem is to find the minimum variance portfolio that achieves an expected return $\mu_p$.

$$w^* = {\arg\,\min} \frac{1}{2} w^t \Omega w$$

subject to the sum of weights constraints $u^t w = 1$, and returns constraints $\mu^t w = \mu_p $ where $u$ is the unit vector composed of ones: $u^t=(1, \ldots 1)$.

Note that for simplicity, we show a version of the problem that does not have non-negative weight constraint.

### Solution by Lagrange Multipliers

We write the Lagrangian: $$L = \frac{1}{2} w^t \Omega w - \lambda_1 (w^t u - 1) - \lambda_2 (w^t \mu - \mu_p) $$

The solution is obtaining by writing that its derivatives at the optimum are 0:

$$\frac{\partial L}{\partial w_i} = \sum_j \Omega_{ij} w^*_j - \lambda_1 u_i - \lambda_2 \mu_i = 0$$

$$\frac{\partial L}{\partial \lambda_1} = u^t w^* -1 = 0$$

$$\frac{\partial L}{\partial \lambda_2} = \mu^t w^* - \mu_p = 0$$

Cancelling the $n$ gradient w.r. to $w_i$ gives us:

$$w^* = \Omega^{-1} ( \lambda_1 u + \lambda_2 \mu)$$

The cancellation of the gradient w.r. to $\lambda_1$ and $\lambda_2$ give:

$$1 = u^t w^* = \lambda_1 u^t \Omega^{-1} u + \lambda_2 u^t \Omega^{-1} \mu$$

$$\mu_p = \mu^t w^* = \lambda_1 \mu^t \Omega^{-1} u + \lambda_2 \mu^t \Omega^{-1} \mu$$

Introducing the simplifying notations $a,b,c$:

$$a = u^t \Omega^{-1} u$$

$$b = \mu^t \Omega^{-1} u$$

$$c = \mu^t \Omega^{-1} \mu$$

with the determinant $\Delta = ac-b^2$, we have :

$$ \lambda_1 = \frac{c - b \mu_p}{\Delta}$$

$$ \lambda_2 = \frac{a \mu_p - b}{\Delta}$$

## Shape of the Efficient Frontier

The portfolio variance $\sigma_p$ verifies:

$$\sigma_p^2 = w^t \Omega w = w^t \Omega (\lambda_1 \Omega^{-1} u + \lambda_2 \Omega^{-1} \mu$$

$$\sigma_p^2 = \lambda_1 w^t u + \lambda_2 w^t \mu = \lambda_1 + \lambda_2 \mu$$

$$\sigma_p^2 = \frac{a \mu_p^2 -2 b \mu_p +c}{\Delta}$$

Therefore, the efficient frontier is a parabola in return/variance space.

### Two funds theorem

The minimum variance is obtained for

$$\lambda_1 = 1/a, \lambda_2 =0, \mu=b/a, w_g = \frac{1}{a} \Omega^{-1} u = \frac{\Omega^{-1} u}{u^t \Omega^{-1} u}$$

The other portfolio that cancels the constraint $\lambda_1$ is given by:

$$\lambda_1 = 0, \lambda_2 =1/b, \mu=c/b, w_d = \frac{1}{b} \Omega^{-1} \mu = \frac{\Omega^{-1} \mu}{u^t \Omega^{-1} \mu}$$

Any optimal portfolio with weights $w$ is a linear combination of these 2 portfolio since:

$$ w = (\lambda_1 a) w_g + (\lambda_2 b) w_d $$

The multipliers are picked by the optimizer to achieve the required return $\mu_p$ at minimal variance.

The minimum variance portfolio $w_g$ depends only on the covariance input and not on expected return. The second portfolio $w_d$ depends on expected returns and is required to achieve some expected return.

## Tangency Portfolio, unconstrained problem and Kelly ratio

Amongst all the optimal portfolios, one portfolio has a higher Sharpe ratio than the others. This is the tangency portfolio obtained by drawing a tangent to the efficient frontier that goes through from the risk-free rate return point.

There is an intuitive demonstration showing that $w_d$ is the efficient frontier portfolio provided $\mu$ is the vector of return above the risk-free asset.

We define the simple return $R_i = \mu_i \Delta t, \sigma_i \Delta W_t$.

The return over a period of a portfolio is the weighted average return $w^t R$, with $E(w^t R) = w^t \mu \Delta t$ and $Var(w^t R) = \frac{1}{2} w^t \Omega w \Delta t$. The quantity of interest when compounding this return is the geometric return, we need to maximize the expected log return: $$ E(\ln (1+w^t R)) = w^t \mu \Delta t - \frac{1}{2} w^t \Omega w \Delta t + o(\Delta t) $$ Writing that the Lagrangian $L_u$ corresponding to this quantity being maximized is even simpler than the previous problem as there is no constraint on $w$. $$L_u := w^t \mu - \frac{1}{2} w^t \Omega w$$ This leads to the solution: $$ w_u = {\arg\, \min} L = \Omega^{-1} \mu $$ Note that this solution $w_u$ is just the solution $w_d$ (where weights summed to 1) rescaled by the optimal leverage $K$ that ensures that the tangency portfolio compounds at the highest possible rate.

This optimal leverage $K$ is actually the multi-asset Kelly ratio.

Note that this is only an intuitive demonstration, as this relies on $\Delta t$ being small. An actual demonstration based on the geometric properties of the efficient frontier and would be more involved as $w_d$ is more complicated term than $w_u$ can be found in section 5.2 of this optimization in finance advanced lecture course (can also be found here).

Therefore, the 2 fund theorem shows that any optimal portfolio (positioned on the efficient frontier) is a linear combination of the minimum variance portfolio and the optimal return portfolio, and the Kelly ratio is the leverage of the unconstrained optimal weights.

### Next Steps

All the above results are classic. Next, we are going to look at a spectral analysis of the problem.