Techniques for Calculating the Efficient Frontier Weerachart Kilenthong RIPED, UTCC c Kilenthong 2017 Tee (Riped) Introduction 1 / 43
Two Fund Theorem The Two-Fund Theorem states that we can reach any point on the m-v frontier using only two efficient portfolios. Formally, let X a and X b be m-v portfolios with mean return R a and R b R a, respectively. Hence, 1 A combination αx a + (1 α)x b is an m-v portfolio. 2 An m-v portfolio is a combination of (X a, X b ). Proof: Consider a portfolio X z = αx a + (1 α)x b, where X a and X b are m-v portfolios. We need to show that this X z is a solution to m-v problem, i.e., we can write X z = Σ 1 ( 1 R ) A 1 ( 1 R z ) (1) where R z = αr a + (1 α)r b is the mean return of portfolio X z. Tee (Riped) Introduction 2 / 43
Two Fund Theorem: Proof continued We now have X z = αx a + (1 α)x b = ασ 1 ( 1 R ) A 1 ( 1 R a ) In addition, we know that + (1 α)σ 1 ( 1 R ) A 1 ( 1 R b ) = Σ 1 ( 1 R ) A 1 ( 1 αr a + (1 α)r b R z = R T X z = R T (αx a + (1 α)x b ) ). Therefore, we can write = α R T X a + (1 α) R T X b = αr a + (1 α)r b X z = Σ 1 ( 1 R ) A 1 ( 1 R z ). (2) Tee (Riped) Introduction 3 / 43
Two Fund Theorem: Proof continued We just showed that X z is an m-v portfolio. We now can prove the second statement (the opposite direction). In fact, we just reverse the earlier proof. Suppose that X z be an m-v portfolio, i.e., we can write X z = Σ 1 ( 1 R ) A 1 ( 1 R z ). (3) For any pair R a and R b, we can find a real number α such that αr a + (1 α)r b = R z. Inf act, we set α = R z R b R a R b. We can now rewrite the above equation as X z = Σ 1 ( 1 R ) ( ) A 1 1 αr a + (1 α)r b = ασ 1 ( 1 R ) ( ) A 1 1 R a + (1 α)σ 1 ( 1 R ) A 1 ( 1 R b ) Tee (Riped) Introduction 4 / 43
Two Fund Theorem Tee (Riped) Introduction 5 / 43
Tangency Portfolio with Risk-Free Asset With the risk-free asset, the optimal portfolio selection problem becomes subject to min X XT ΣX (4) X T ( R Rf 1 ) = R t R f. (5) where R f is the risk free rate. Note that total weight on risky assets does not need to be equal to 1. If 1 T X > 1, the investor must borrow, and vice versa. The Lagrangian now is L = X T ΣX + µ ( R t R f X T ( R Rf 1 )) (6) Tee (Riped) Introduction 6 / 43
Tangency Portfolio with Risk-Free Asset The optimal condition or FOC with respect to X is 2ΣX µ ( R R f 1 ) = 0 X = µ 2 Σ 1 ( R R f 1 ) (7) Similarly to the above problem we first solve for µ: Thus, R t R f = X T ( R Rf 1 ) = µ 2 ( R Rf 1 ) T Σ 1 ( R Rf 1 ) µ 2 = R t R f ( R R f 1 ) T Σ 1 ( R R f 1 ) (8) Thus, we get X = (R t R f )Σ 1 ( R Rf 1 ) ( R Rf 1 ) T Σ 1 ( R Rf 1 ) Tee (Riped) Introduction 7 / 43
Tangency Portfolio with Risk-Free Asset The tangency portfolio X t is such that 1 T X t = 1 (9) Using this condition with the optimal portfolio, we get ( R Rf 1 ) T Σ 1 ( R Rf 1 ) R t R f = 1 T Σ ( R 1 Rf 1 ) (10) Hence, X t = Σ 1 ( R Rf 1 ) 1 T Σ 1 ( R Rf 1 ) (11) Tee (Riped) Introduction 8 / 43
Efficient Frontier Finding an efficient frontier when short sales are allowed and riskless borrowing and lending is possible, short sales are allowed but riskless borrowing and lending is not possible, short sales are not allowed but riskless borrowing and lending is possible, neither short sales nor riskless borrowing and lending are possible. Roles of a riskless asset (or riskless lending and borrowing). Roles of short sales. Tee (Riped) Introduction 9 / 43
Efficient Frontier with Riskless Lending and Borrowing Let riskless be R F. Let R A be the return of portfolio of risky assets. The average return of the combination between A and riskless asset is R C = (1 X )R F + X R A (12) Variance is σ C = (1 X ) 2 σf 2 + X 2 σa 2 + 2X (1 X )σ Aσ F ρ FA = X σ A (13) Hence, R C = R F + R A R F σ A σ C (14) Tee (Riped) Introduction 10 / 43
Efficient Frontier with Riskless Lending and Borrowing Tee (Riped) Introduction 11 / 43
Efficient Frontier with Riskless Lending and Borrowing Tee (Riped) Introduction 12 / 43
Efficient Frontier with Riskless Lending but not Borrowing Tee (Riped) Introduction 13 / 43
Efficient Frontier with Riskless Lending and Borrowing at Different Rates Tee (Riped) Introduction 14 / 43
An Example with Bonds and Stocks Returns and variances of bonds and stocks are R S = 12.5%, σ S = 14.9%ρ S,B = 0.45, R B = 6%σ B = 4.8% (15) Now assume that the investor and borrow and lend at 5 %. Then we can identify tangent portfolio T. The new efficient frontier is now a straight line. R P = 5 + 0.50σ P (16) Tee (Riped) Introduction 15 / 43
Efficient Frontier with Bonds and Stocks Tee (Riped) Introduction 16 / 43
An Example with Bonds and Stocks (Con t) From the graph, R T = 13.54% and σ T = 16.95% We can find the corresponding portfolio weight X S for the tangent portfolio. 13.54 = X S (2.5) + (1 X S )6 X S = 116%, X B = 16% (17) Tee (Riped) Introduction 17 / 43
Efficient Frontier with Bonds and Stocks Tee (Riped) Introduction 18 / 43
Short Sales and Riskless implies Maximum Slope The existence of riskless asset implies that the efficient frontier in the mean-standard deviation space is the line between the riskless asset and the portfolio of risky assets that gives the maximum slope of the line. The efficient frontier is the line passing through R F and B. Tee (Riped) Introduction 19 / 43
Optimal Portfolio Problem with Short Sales and Riskless Asset Mathematically, we can find the efficient frontier by solving the following problem. The problem is to find a portfolio of risky assets P, whose mean return and standard deviation are R P and σ P respectively, that maximize the slope max X i RP R F σ P (18) subject to N X i = 1 (19) i=1 Tee (Riped) Introduction 20 / 43
Mean and Standard Deviation The mean return of portfolio P is given by R P = N X i Ri (20) i=1 where R i is the mean return of asset i. The standard deviation of portfolio P is given by N σ P = Xi 2 σi 2 + i=1 N i=1 N X i X j σ ij j i 1 2 (21) Tee (Riped) Introduction 21 / 43
Solving for Optimal Portfolio The problem can be written as max X i [ N ( ) ] N X i Ri R F i=1 } {{ } F 1 (X) i=1 X 2 i σ 2 i + N i=1 N X i X j σ ij j i 1 2 } {{ } F 2 (X) (22) Solving this: using first order conditions (FOCs): differentiating the objective function with respect to a choice variable and take it equal to zero. The FOC w.r.t. X k is F 1 F 2 X k = 0 = F 1 F 2 X k + F 2 F 1 X k = 0 (23) Tee (Riped) Introduction 22 / 43
Solving for Optimal Portfolio: More Details Each derivative is and F 2 X k = 1 2 N i=1 X 2 i σ 2 i + F 1 X k = R k R F N i=1 N X i X j σ 32 ij 2X k σk 2 + 2 X j σ jk j k j i Tee (Riped) Introduction 23 / 43
Solving for Optimal Portfolio: More Details Putting these together: 0 = [ R P R F ] ( 1 2) N i=1 2X k σk 2 + 2 X j σ jk j k + [ ] Rk R F N i=1 = [ R P R F ] σ 3 P X 2 i σ 2 i + X 2 i σ 2 i + N i=1 N i=1 N X i X j σ ij j i N X i X j σ ij j i X k σ 2 k + j k X j σ jk 1 2 3 2 + [ R k R F ] σ 1 P Tee (Riped) Introduction 24 / 43
Solving for Optimal Portfolio: More Details Multiplying this equation by σ P and rearranging the terms give 0 = R P R F X σp 2 k σk 2 + X j σ jk + [ ] Rk R F }{{} j k λ P which can be rewritten in a compact form as, for each asset k, R k R F = λ P X }{{ k σ } k 2 + λ P X j σ jk }{{} Z j k k Z j R k R F = Z k σ 2 k + j k Z j σ jk (24) Tee (Riped) Introduction 25 / 43
System of Simultaneous Equations After collecting all FOC for every asset together, we will end up with a system of simultaneous equations: R 1 R F = Z 1 σ 2 1 + Z 2 σ 12 + Z 3 σ 13 +... + Z N σ 1N R 2 R F = Z 1 σ 12 + Z 2 σ 2 2 + Z 3 σ 23 +... + Z N σ 2N. R N R F = Z 1 σ 1N + Z 2 σ 12 + Z 3 σ 1N +... + Z N σn 2 Tee (Riped) Introduction 26 / 43
System of Simultaneous Equations This system of simultaneous equations can be written in a matrix form as R R F 1 = Σ Z where R = Σ = R 1. R N, 1 = 1. 1, Z = σ 2 1 σ 12... σ 1N σ 12 σ2 2... σ 2N...... Z 1. Z N, σ 1N σ 2N... σ 2 N Tee (Riped) Introduction 27 / 43
Recovering the Optimal Portfolio In principle, we will be able to solve for Z i using several methods, e.g., 1 inverse matrix 2 repetitive substitution (see example) Z = Σ 1 ( R R F 1 ) (25) The solution of this mathematical problem is Z i but what we really want is X i. How can we get X i? From Z i = λ P X i, we can show that Z i = λ P X i = λ P (26) i Hence we can recover the optimal portfolio X from Z using i X k = Z k λ P = Z k i Z i (27) Tee (Riped) Introduction 28 / 43
Example Suppose there are three risky assets, say CP (asset 1), Centrals (asset 2), and PTT (asset 3). Using past information, we can calculate mean returns and variance covariance matrix of these assets as R = Σ = 14 8 20, 6 6 0.5 6 3 0.2 6 15 0.5 6 3 3 3 0.4 3 15 0.2 6 15 0.4 3 15 15 15 Suppose that the riskless rate is 5 %. Tee (Riped) Introduction 29 / 43
Example Hence, a system of equations for this problem is 9 = 36Z 1 + 9Z 2 + 18Z 3 3 = 9Z 1 + 9Z 2 + 18Z 3 15 = 18Z 1 + 18Z 2 + 225Z 3 The solution is Z = 14 63 1 63 3 63 Tee (Riped) Introduction 30 / 43
Example We can then find portfolio weight X as X 1 = 14 18, X 2 = 1 18, X 3 = 3 18 The mean return of the optimal portfolio is R P = 14 18 14 + 1 18 8 + 3 20 = 14.67% 18 The variance of the optimal portfolio is σ 2 P = XT ΣX = 33.83% Tee (Riped) Introduction 31 / 43
Example: Solution The slope of the efficient frontier is equal to 1.66. Tee (Riped) Introduction 32 / 43
Short Sales without Riskless We will now consider a case where short sales are allowed but there is no riskless asset. We can use the same technique as before but with an assumed rate R F. Different assumed rates will lead to different efficient portfolios. Tee (Riped) Introduction 33 / 43
Example Continued. Suppose that the riskless rate is now R F = 2. The system of equations now becomes 12 = 36Z 1 + 9Z 2 + 18Z 3 6 = 9Z 1 + 9Z 2 + 18Z 3 18 = 18Z 1 + 18Z 2 + 225Z 3 whose solution is Z 1 = 42 189, Z 2 = 72 189, Z 3 = 6 189 and X 1 = 7 20, X 2 = 12 20, X 3 = 1 20 and R P = 10.7, σ 2 P = 13.70 Tee (Riped) Introduction 34 / 43
Example Continued In principle, we need to find only two of them (Two Fund Theorem). That is, any combination of these two portfolios (which themselves are assets) is on the efficient frontier. For example: put 50 50 weight. We can show that σ 2 P = 21.859. Then we can find the covariance between the two portfolios: using This leads to σ 12 = 19.95. σ 2 P = X 2 1 σ 2 1 + X 2 2 σ 2 2 + 2X 1 X 2 σ 12 With the information of expected returns, variances, and covariance between the two portfolios, we can trace out the whole frontier. Tee (Riped) Introduction 35 / 43
Riskless but No Short Sales We will now consider a case where short sales are not allowed but there is a riskless asset. In principle, an efficient portfolio problem is a constrained maximization problem. In this case, we can write max X i RP R F σ P (28) subject to X i = 1 (29) i X i 0, i (30) where the last one represents the no short-sales constraint. Tee (Riped) Introduction 36 / 43
Riskless but No Short Sales: Example Consider again the example with three assets and risk-free rate R F = 5%. Recall that the efficient portfolio in this case is X 1 = 14 18, X 2 = 1 18, X 3 = 3 18 Remember that this solution is solved under an assumption that short sales are allowed. What if we now impose the no short-sales constraint, should we get a different answer? Tee (Riped) Introduction 37 / 43
Example II Suppose there are three risky assets, say CP (asset 1), Centrals (asset 2), and PTT (asset 3). Using past information, we can calculate mean returns and variance covariance matrix of these assets as R = Σ = 14 8 20, 6 6 0.5 6 10 0.2 6 15 0.5 6 10 10 10 0.4 10 15 0.2 6 15 0.4 10 15 15 15 Suppose that the riskless rate is 5 %. Tee (Riped) Introduction 38 / 43
Example Hence, a system of equations for this problem is 9 = 36Z 1 + 30Z 2 + 18Z 3 3 = 30Z 1 + 100Z 2 + 60Z 3 15 = 18Z 1 + 60Z 2 + 225Z 3 The solution is Z = 0.3000 0.1019 0.0698 Tee (Riped) Introduction 39 / 43
Example We can then find portfolio weight X as X 1 = 1.1197, X 2 = 0.3803, X 3 = 0.2607 But we do not allow for a negative weight! What should we do? Tee (Riped) Introduction 40 / 43
More General Efficient Portfolio Problem This problem started from the seminal work by Markowitz (1959). min Xi 2 σi 2 + X i X j σ ij (31) X i i subject to j i X i = 1 (32) i X i Ri R P (33) i X i 0, i (34) X i d i D (35) i where the last constraint is the so called dividend requirement constraint. The role of a riskless asset is to simplify the objective function as a slope. Tee (Riped) Introduction 41 / 43
CAPM: A first look From the tangency portfolio, we have Hence we can write σ 2 t = X T ΣX = R t R f 1 T Σ 1 ( R Rf 1 ) (36) 1 T Σ 1 ( R Rf 1 ) = R t R f σ 2 t (37) Similarly, covariance between the tangency portfolio and all assets is given by Cov t = ΣX = R R f 1 1 T Σ 1 ( R Rf 1 ) (38) Tee (Riped) Introduction 42 / 43
CAPM: A first look Combining the last two equations lead to CAPM R R f 1 = Cov t σ 2 t (R t R f ) (39) We now set the ratio between covariance and variance as β, e.g., β i = Cov(R 1,R t ), where R σt 2 t is a return process of the tangency portfolio (a random variable). We now have a CAPM with the tangency portfolio as a market portfolio: where β t = (β i ) n i=1. R R f 1 = β t (R t R f ) (40) Tee (Riped) Introduction 43 / 43