Extract the formulas in math latex markdown format to calculate the portfolio return and variance in Modern Portfolio Theory https://en.wikipedia.org/wiki/Modern_portfolio_theory