Removed some commented lines. Added new comments. Simplified a formula.