Fixed floating point rounding problem