J
John C. Bollinger
Basic question: if d is a finite positive double value, is
d - Math.ulp(d)
guaranteed to be the next representable double value smaller than d? Is
there any finite value of d for which the result would be d, or for
which there is another double value between the result and d?
The docs for Math.ulp(double) describe it in terms of the opposite
direction -- the distance to the next value _larger_ than the argument.
I'm out of my league when it comes to this level of minutiae of
floating point representation and arithmetic.
Thanks,
d - Math.ulp(d)
guaranteed to be the next representable double value smaller than d? Is
there any finite value of d for which the result would be d, or for
which there is another double value between the result and d?
The docs for Math.ulp(double) describe it in terms of the opposite
direction -- the distance to the next value _larger_ than the argument.
I'm out of my league when it comes to this level of minutiae of
floating point representation and arithmetic.
Thanks,