FastMath.rint(x) has the following code: double y = floor(x); double d = x - y;
if (d > 0.5) { return y+1.0; // round up } ... For -0.5 < x < 0 the rounding up generates +0.0 - rather than -0.0, as expected by the sign of the input parameter. Is there an easy way to fix this, other than explicitly checking for y == -1.0? --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org For additional commands, e-mail: dev-h...@commons.apache.org