Christian Heimes added the comment:

Mark Dickinson wrote:
> So e.g. cos(infinity) should give a ValueError, while log(infinity) and 
> exp(infinity) 
> should not raise any Python exception, but should return an infinity instead. 
>  And most 
> single variable operations should return an input NaN unaltered, without 
> raising an 
> exception.

The matter should be discussed in a proper PEP and targeted for Python
3.0. Python 3.0 is the right place for subtle changes which may break
code. For Python 2.6 we must not change the exception or outcome of a
function and new functions should be as consistent with existing ones as
possible.

I still don't like the idea of math.atanh(1) == inf. Why? See for yourself:

18.714973875118524
>>> math.atanh(.99999999999999999)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: math domain error

(Linux)

Christian

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

Reply via email to