fixes miles calculation formula