Question:
Consider a three-asset portfolio consisting of three stocks called A, B, and C. The stocks are weighted, respectively, 20%, 30% and 50% (i.e., weight A = 20%, weight B = 30%, and weight C = 50%). The volatility (standard deviation) of returns for all three assets is 20%. The covariances are as follows: COVAR(A,B) = 0.09 = 9%, COVAR(A,C) = 0.16 = 16%, COVAR(B,C) = 0.01 = 1%. Using matrix math, calculate the three-asset portfolio variance.
Answer:
This is likely a harder question than you would encounter on the exam (not for conceptual difficulty but rather time required to perform the calculation). It is basic matrix application.
Recall that if w is the vector of portfolio weights and Sigma is the covariance matrix, we have a very COMPACT FORMULA for PORTFOLIO VARIANCE:

portfolio variance = (w’)(Sigma)(w)
where w’ is row vector of weights, having been transposed.
In this case, w’ is given by:
[20% 30% 50%]
And the COVARIANCE MATRIX is 3 x 3 and given by:
| 0.04 0.09 0.16 |
| 0.09 0.04 0.01 |
| 0.16 0.01 0.04 |
Note the diagonal of the covariance matrix contains the variances (0.04) which are squared volatilities (0.04 = 20%^2).
The portfolio variance is the product of:
(w’)(Sigma)(w)
Note that matrix multiplication happens to be ‘associative’ so that the order of multiplication does not matter: (AB)C = A(BC).
The worked out answer can viewed in this editgrid spreadsheet.
For reflection:
* The diagonal of the covariance matrix consists of variances. Why? The covariance of a thing with itself is its variance.
* Where is the correlation matrix? It is implicit in the covariance matrix. By the way, what elements are in the diagonal of a correlation matrix? Ones (1). Why? Because the correlation of a thing with itself is 1.0.
