Jean Brouwers <[EMAIL PROTECTED]> added the comment:

This is pretty bizarre, take a look at the following, 64-bit Pyhon 2.6b1 
-xO5.

Python 2.6b1 (r26b1:64398, Jun 28 2008, 12:50:06) [C] on sunos5
Type "help", "copyright", "credits" or "license" for more information.
>>> import math
>>> math.log(100.0, 2.0)
6.6438561897747253
>>> math.log(100.0) / math.log(2.0)
6.6438561897747253

>>> import cmath
>>> cmath.log(100.0, 2.0)
(0.71244151439608006-2.0556716794852954j)
>>> cmath.log(complex(100.0, 0), complex(2.0, 0)) 
(0.71244151439608006-2.0556716794852954j)

>>> cmath.log(2.0)
(0.69314718055994529+0j)
>>> cmath.log(100.0)
(4.6051701859880918+0j)
>>> cmath.log(100.0) / cmath.log(2.0)
(6.6438561897747253+0j)

There is only an issue with cmath.log(100.0, 2.0) but not with 
cmath.log(100.0) / cmath.log(2.0).  That seems to indicate that the 
c_quot function may be the root cause of the problem.

_______________________________________
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3168>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to