Bug fix for early retirement reduction change
Cost side computation code
Refactored to work with the webapp