Minimum variance portfolio problem given risk free rate,covariance matrix and mean vector Consider 3 assets $r_1,r_2,r_3$ respectively. Covariance matrix and expected return is given by 
$C=$
        \begin{bmatrix}
    2 & 1 & 0 \\
    1 & 2 & 1 \\
    0 & 1 & 2 \\
    \end{bmatrix} 
and $\mu=$
       \begin{bmatrix}
    0.4\\
    0.4  \\
    0.8 \\
    \end{bmatrix}
(i) Find the minimum variance portfolio. 
Just by using $w^*  = \frac{1 C^{-1}}{1 C^{-1} 1^T} = [0.5\text{ } 0.5\text{ } 0.5]$
(ii) Find a 2nd efficient portfolio. 
$w^*  = \frac{ C^{-1} \mu}{1^T C^{-1} \mu} = [\frac{1}{2}\text{ } \frac{-1}{3}\text{ } \frac{5}{6}]$
(iii) If the risk free rate is 0.2, find the market portfolio comprising of 1 risk free rate and 3 risky assets, thus find an efficient portfolio of risky assets. 
I don't know how to proceed here. I tried 
$w = \frac{C^{-1}(\mu - r_f.1)}{b-cr_f}$ where $b= 1^T C^{-1} \mu$ and $c=\mu ^T C^{-1} \mu$
but I need 4 weights.
Part (i) and (ii) are correctly done. I just need the optimal weights. My problem is in (iv) where I need to find an optimal weight for the risky and risk free asset. Short selling is allowed.
Note that 
$C^{-1}=$
      \begin{bmatrix}
    3/4 & -2/4 & 1/4 \\
    -2/4 & 4/4 & -2/4\\
    1/4 & -2/4 & 3/4 \\
    \end{bmatrix} 
The answer to (iii) is (0.6 0.2 -0.2 0.4) and (0 $\frac{1}{3}$ $\frac{-1}{3}$ $\frac{2}{3})$
 A: I have quite a few questions regarding your question.  Based on your covariance matrix, all of your assets have the same variance of 2, or a volatility of 1.414214. and the following correlations:
corr(a,b) = 0.5; corr(a,c) = 0; corr(b,c) = 0.5
i)  I am a little unclear on what you mean here?  Are you assuming that the portfolio would be leveraged?  The sum of your weights totals 1.5, which would imply a leveraged portfolio.  Most of these exercises assume the efficient frontier portfolios are not leveraged (ie that the weights sum to 1) and no short selling.  If I make these the constraints, the min variance portfolio would basically be a portfolio that comprises the following weights [0.5 0 0.5].  Could you please verify that this is what you asking?
ii)  Here your weights do sum to 1 (3/6 -2/6 +5/6 = 1).  However, you do not have the no short selling constraint.  The expected return of this portfolio is 0.73, with a std. deviation of 1.1055416, or a variance of 1.222222229.
iii)  I am not sure what you mean here as well.  Assuming you are looking for the capital market portfolio, the highest Sharpe ratio portfolio would be where the Sharpe ratio is 0.63, implying weights of [1/3 0 2/3] (again assuming no leverage and no short selling constraints).  The capital market line would be the line connecting 0.2 (risk free rate) on the Y-axis (return axis) and the portfolio specified above, where the expected return would be 0.67 and a standard deviation of 1.054.  The weight of the risk free asset would depend on the expected return and standard deviation you desire on this capital market line.  The weight of your risk free asset would depend on how much leverage you desire and the weight of the capital market portfolio would be decreased or increased by that amount, proportionately to the weights of [1/3 0 2/3] for each of the assets.
If you clarify your question, perhaps I can provide the answer you are looking for.
