Thu, 07 Oct 2010 18:02:43 -0400, Andrew P. Mullhaupt wrote:
> On 10/7/2010 3:45 PM, josef.p...@gmail.com wrote:
>> what's your namespace?from scipy import log
>>>>> log(int(-2))
>> (0.69314718055994529+3.1415926535897931j)
> 
> This should explain:
> >>> R = ones(2)
> >>> R[0] = R[0] * 1j
> >>> R
> array([ 0.,  1.])
[clip]

As Charles and Anne said:

> Newer versions of numpy will warn you that the imaginary part is 
> going to be discarded in your first example.

This will possibly be strengthened to an error or NaN in the future.

_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to