Why Derive the Minimum-Variance Weights?
A portfolio’s risk depends not only on the individual assets’ variances but also on how their returns move together. Once those inputs are known, the two-asset portfolio variance formula can be used to find the allocation with the smallest possible variance. The derivation matters because it shows which inputs drive the answer and when the resulting allocation is not allowed by a long-only investment policy.
The analysis below minimizes variance only. It does not use expected returns to choose an allocation, and it does not discount cash flows. No interest rate or mortality assumption is involved. Returns are measured over the same period, and the variances and covariance are treated as known inputs. A particular parametric distribution is not required for the derivation; each worked example states its assumed return distribution and parameters.
Deriving the Unconstrained Minimum
“Unconstrained” means that the only restriction is full investment: \(w_1+w_2=1\). In particular, short selling is permitted. Substitute \(w_2=1-w_1\) into the variance formula, so the problem becomes minimizing a function of one variable.
Differentiate with respect to \(w_1\). At an interior minimum, the first derivative is zero. The second derivative then tells us whether the stationary point is a minimum.
\(V'(w_1)=2(\sigma_1^2+\sigma_2^2-2c)w_1+2(c-\sigma_2^2)=0\).
Provided \(\sigma_1^2+\sigma_2^2-2c\ne 0\), this gives \(w_1^*=(\sigma_2^2-c)/(\sigma_1^2+\sigma_2^2-2c)\).
\(w_2^*=1-w_1^*=(\sigma_1^2-c)/(\sigma_1^2+\sigma_2^2-2c)\).
\(V''(w_1)=2(\sigma_1^2+\sigma_2^2-2c)\), which is positive when the denominator is positive.
The denominator has a useful interpretation:
It is nonnegative because it is a variance. If it is positive, the quadratic is strictly convex, so the stationary point is the unique unconstrained minimum. If it is zero, \(R_1-R_2\) has zero variance and is constant with probability one. In that special case, every fully invested allocation has the same portfolio variance, and the weight formulas with this denominator do not apply.
The minimum variance can also be found by completing the square in the quadratic. Writing \(D=\sigma_1^2+\sigma_2^2-2c>0\), the quadratic’s minimum is \(\sigma_2^2-(\sigma_2^2-c)^2/D\), which simplifies to:
This expression is a check on a calculated portfolio variance. For valid variance and covariance inputs, the covariance matrix is positive semidefinite, so \(\sigma_1^2\sigma_2^2-c^2\ge 0\).
Worked Applications
Worked Example: An Interior Minimum-Variance Allocation
Suppose the one-period returns are jointly normally distributed with mean vector \((0.06,0.08)\), variances \(\sigma_1^2=0.04\) and \(\sigma_2^2=0.09\), and covariance \(c=0.01\). Find the unconstrained minimum-variance weights and minimum variance. Assume short selling is allowed.
Method. Use the derivative formulas. The covariance inputs are valid: \(0.04(0.09)-0.01^2=0.0035>0\). The means are distribution parameters but do not enter this variance-only minimization.
First calculate the denominator:
Then calculate both weights:
They sum to one. Rounding weights to four decimal places gives \(w_1^*=0.7273\) and \(w_2^*=0.2727\). Both are between zero and one, so this unconstrained solution is also feasible for a long-only portfolio.
Calculate the minimum variance using the derived expression:
The minimum variance is \(0.031818\), rounded to six decimal places. The result is consistent with the weights: substituting them into the portfolio variance formula gives the same value. Common mistake avoided: omitting covariance would give weights based only on the two variances, which is not the problem being minimized.
Worked Example: A Short Position and the Long-Only Optimum
Suppose the one-period returns are jointly normally distributed with mean vector \((0.05,0.07)\), variances \(\sigma_1^2=0.04\) and \(\sigma_2^2=0.01\), and covariance \(c=0.015\). Find the unconstrained weights, then find the minimum-variance allocation if both weights must be nonnegative.
Method. First apply the unconstrained derivative result; then check the signs of the weights. The covariance inputs are valid because \(0.04(0.01)-0.015^2=0.000175>0\).
The denominator is \(D=0.04+0.01-2(0.015)=0.02\). Therefore:
The weights sum to one, but asset 1 has a negative weight. The unconstrained solution therefore requires short selling and is not long-only. Its variance is \(V_{\min}=(0.04(0.01)-0.015^2)/0.02=0.00875\).
To find the long-only optimum, write the variance as a function of \(w_1\), with \(w_2=1-w_1\). The feasible interval is \(0\le w_1\le1\), and the derivative is \(V'(w_1)=2(0.02)w_1+2(0.015-0.01)=0.04w_1+0.01\). This derivative is positive throughout the feasible interval, so variance increases as \(w_1\) increases from zero. The constrained minimum is at \(w_1=0,w_2=1\), investing entirely in asset 2; its variance is \(0.01\). Common mistake avoided: treating the negative unconstrained weight as acceptable when the portfolio rules prohibit short selling.
Worked Example: Negative Covariance and Diversification
Suppose the one-period returns are jointly normally distributed with mean vector \((0.04,0.06)\), variances \(\sigma_1^2=0.16\) and \(\sigma_2^2=0.04\), and covariance \(c=-0.02\). Find the unconstrained minimum-variance weights, verify whether they are long-only, and calculate the minimum variance.
Method. Use covariance directly in the weight formulas; do not substitute a correlation for covariance. The covariance inputs are valid because \(0.16(0.04)-(-0.02)^2=0.006>0\). The correlation is \(-0.02/(\sqrt{0.16}\sqrt{0.04})=-0.25\), but the formulas require \(c=-0.02\).
The denominator and weights are:
The weights sum to one and are both nonnegative, so the unconstrained optimum is long-only. Direct substitution gives:
The determinant check gives the same result: \((0.16(0.04)-(-0.02)^2)/0.24=0.006/0.24=0.025\). The negative covariance reduces portfolio variance through the negative cross term. Common mistake avoided: dropping the cross term or using the correlation \(-0.25\) in place of the covariance \(-0.02\).
When the Unconstrained Weights Are Not Long-Only
For \(D>0\), the denominator in both weights is positive. Thus both unconstrained weights are nonnegative exactly when \(c\le\sigma_2^2\) and \(c\le\sigma_1^2\), or equivalently \(c\le\min(\sigma_1^2,\sigma_2^2)\). Since the weights sum to one, nonnegative weights are also no greater than one. If this condition fails, one of the unconstrained weights is negative and the solution uses a short position.
If long-only weights are required, minimize the same convex variance function over \(0\le w_1\le1\), rather than accepting an infeasible stationary point. When the unconstrained minimum lies outside that interval, the constrained minimum is at an endpoint. Compare the two endpoint portfolios: investing entirely in asset 1 has variance \(\sigma_1^2\), and investing entirely in asset 2 has variance \(\sigma_2^2\). In the usual case of a valid covariance matrix and \(D>0\), the endpoint with the smaller standalone variance is the constrained minimum when the unconstrained solution is outside the interval.
A frequent exam trap is to use the formula \(w_1=\sigma_2^2/(\sigma_1^2+\sigma_2^2)\), which assumes \(c=0\). For example, in the first worked example that shortcut gives \(0.09/(0.04+0.09)=0.6923\), not the correct weight \(0.7273\). The correction is to retain covariance in both the numerator and denominator: \(w_1^*=(\sigma_2^2-c)/(\sigma_1^2+\sigma_2^2-2c)\).
Check Your Understanding
For each problem, treat returns as one-period returns with the stated means, variances, and covariance. State whether the unconstrained solution is long-only where requested.
- Returns are jointly normally distributed with means \(0.06\) and \(0.07\), variances \(0.09\) and \(0.04\), and covariance \(0.012\). Find the unconstrained weights and determine whether they are long-only. (Answer: \(w_1=0.2642,\ w_2=0.7358\); yes.)
- Returns are jointly normally distributed with means \(0.03\) and \(0.05\), variances \(0.0225\) and \(0.0625\), and covariance \(0.03\). Find the unconstrained weights and the long-only minimum-variance allocation. (Answer: unconstrained \(w_1=1.3000,\ w_2=-0.3000\); long-only optimum \(w_1=1,\ w_2=0\), with variance \(0.0225\).)
- Returns are jointly normally distributed with means \(0.04\) and \(0.06\), variances \(0.05\) and \(0.08\), and covariance \(0.045\). Find the unconstrained weights and minimum variance, and check whether the solution is long-only. (Answer: \(w_1=0.8750,\ w_2=0.1250\); minimum variance \(0.049375\); yes.)
- Suppose \(\operatorname{Var}(R_1)=\operatorname{Var}(R_2)=\operatorname{Cov}(R_1,R_2)=0.04\). Evaluate the denominator of the weight formulas and state the variance of any fully invested allocation. (Answer: the denominator is \(0\); every fully invested allocation has variance \(0.04\), so the formulas with that denominator do not apply.)
- Returns are jointly normally distributed with means \(0.05\) and \(0.08\), variances \(0.01\) and \(0.04\), and covariance \(0.005\). Find the unconstrained weights, verify their sum, and calculate the minimum variance. (Answer: \(w_1=0.8750,\ w_2=0.1250\); they sum to \(1\); minimum variance \(0.009375\).)