[Numpy-discussion] Division by zero doesn't raise exception in the integer case.

Charles R Harris charlesr.harris at gmail.com
Tue Sep 19 18:10:26 CDT 2006


Travis,

Is this intentional?

In [77]: arange(5, dtype=int)/0
Out[77]: array([0, 0, 0, 0, 0])

It looks deliberate because all zeros are returned, but it might be better
if it raised an exception.

Chuck
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.scipy.org/pipermail/numpy-discussion/attachments/20060919/bea57c43/attachment.html 


More information about the Numpy-discussion mailing list