Two different ways of producing variance formula (PDF)