fixing precision issues with rate computations