I apologize if similar question has been already asked.
I have to compute optimal allocation of investment I between market asset and risk free asset. The investor's utility function is $U(w)=E(r_P)- γσ^2(r_P))/2$, $γ = 3$.
Then I use two formulas:
$E(r_P) = r_F + ((E(r_M) - r_F)σ_P)/σ_M$
$σ^2_P = w^2_1σ^2_1 + w^2_2σ^2_2 + 2w_1 w_2 σ_1 σ_2 ρ$
Which I plug in the utility function, before taking the derivatives wrt $w_1$ & $w_2$ . The result I obtained after equating both FOC seems wrong, because I can't use $γ = 3$ information anywhere to solve the problem:
$w_1 = ρ^2$
So where's the mistake?
Also I don't know the code for fraction line, so sorry about the messy notation.