Add working version of CostCalculator