- Fixed Bug in calcCost