Explain the mathematical framework of a Sharpe ratio optimization problem and how you would solve it.