added rounding (including test)