[SciPy-dev] matrix bug

Robert Kern rkern at ucsd.edu
Tue Oct 11 21:47:42 CDT 2005


Even better:

In [1]: A = array([[1., 2.],
   ...:                    [3., 4.]])

In [2]: mA = matrix(A)



In [20]: dot(3, mA)
Out[20]:
matrix([[  3.,   6.],
       [  9.,  12.]])

In [21]: dot(3, mA)
Out[21]:
matrix([[  3.,   6.],
       [  9.,  12.]])

In [22]: dot(3, mA)
Out[22]:
matrix([[  3.00000000e+00,   6.00000000e+00],
       [  7.30927399e+92,   1.20000000e+01]])

In [23]: dot(3, A)
Out[23]:
array([[  3.00000000e+00,   6.00000000e+00],
       [  6.60362578e+91,   1.20000000e+01]])

In [24]: dot(3, A)
Out[24]:
array([[  3.,   6.],
       [  9.,  12.]])

-- 
Robert Kern
rkern at ucsd.edu

"In the fields of hell where the grass grows high
 Are the graves of dreams allowed to die."
  -- Richard Harter




More information about the Scipy-dev mailing list