Can't exponentiate zero in NumPy
Michael George Lerner
mlerner at nospam.is.goodspam.umich.edu
Mon Sep 9 12:01:32 EDT 2002
Rick Muller <rpm at wag.caltech.edu> wrote:
> This crashes on Linux, but not on Mac OS X.
Here's another data point for you:
PythonWin 2.2.1 (#34, Apr 15 2002, 09:51:39) [MSC 32 bit (Intel)] on win32.
Portions Copyright 1994-2001 Mark Hammond
>>> from Numeric import *
>>> a = zeros(3,Float)
>>> a**2
array([ 0., 0., 0.])
>>> a[1] = 1.e-310
>>> a
array([ 0.00000000e+000, 1.00000000e-310, 0.00000000e+000])
>>> a**2
array([ 0., 0., 0.])
>>> import Numeric
>>> Numeric.__version__
'21.0'
More information about the Python-list
mailing list