move calculation to TripCalculator class