Hi, I have observed a problem with complex zerodivision and negative powers. With a complex zero the result is either zero or NaN NaNj, the first one is clearly wrong and the other one I don't know what is most reasonable some kind of inf or a Nan.
This problem has been reported in the tracker as #1271. In [1]: import numpy In [2]: numpy.__version__ Out[2]: '1.4.0rc1' In [3]: from numpy import * In [4]: array([-0., 0])**-1 Out[4]: array([-Inf, Inf]) In [5]: array([-0., 0])**-2 Out[5]: array([ Inf, Inf]) In [6]: array([-0.-0j, -0.+0j, 0-0j, 0+0j])**-2 Out[6]: array([ 0.+0.j, 0.+0.j, 0.+0.j, 0.+0.j]) In [7]: array([-0.-0j, -0.+0j, 0-0j, 0+0j])**-1 Out[7]: array([ NaN NaNj, NaN NaNj, NaN NaNj, NaN NaNj]) In [8]: 1/array([-0.-0j, -0.+0j, 0-0j, 0+0j]) Out[8]: array([ NaN NaNj, NaN NaNj, NaN NaNj, NaN NaNj]) _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion