fixed rounding for negative values