D Hardy added the comment:
Oh; OK, thanks for the response.
Sorry, I've used +/- inf and NaN values in other languages and was under the
impression inf != inf under IEEE 754. I think this requires explicitly testing
for
infinity then.
For anyone interested, I've written a test whic
New submission from D Hardy :
Currently python evaluates infinity as equal to itself in my tests (2.6.2 and
3.0.1+
from ubuntu). I'm not entirely sure whether the behaviour of 'inf == inf' is
specified
by IEEE 754, but it leads to results like:
>>> 1e400
inf
>>&g