variance of a portfolio with n assets

prisoners harbor to painted cave