Bug in math.frexp?

Kirill Simonov kirill at xyz.donetsk.ua
Fri Jun 30 15:17:59 EDT 2000


$ python
Python 1.6a2 (#2, Jun 24 2000, 12:18:54)  [GCC egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)] on linux2
Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam
>>> import math
>>> print math.frexp.__doc__
frexp(x)

Return the matissa and exponent for x. The mantissa is positive.
>>> math.frexp(-1)     
(-0.5, 1)

In this example the mantissa is negative.


--
Kirill




More information about the Python-list mailing list