[Numpy-discussion] Question: why is this different?

meng at are.berkeley.edu meng at are.berkeley.edu
Mon Oct 17 14:12:23 CDT 2005

Hi there-

I have a question on how this difference arises when I run the following 
simple code on windows and Debian:
 >>> from numarray import *
 >>> a=reshape(arange(81.0), (9,9))+identity(9)
 >>> ca = matrixmultiply(transpose(a),a)
 >>> import numarray.linear_algebra as la
 >>> ica = la.inverse(ca)
 >>> ica.min()
 >>> ica.max()

The above is the result in Debian and below is that in Windows:
 >>> ica.min()
 >>> ica.max()

So, what caused this difference (both machines have python2.4 and numarray 
1.3.2)? The difference happens in the 10th/11th decimal point, which should 
be still in the floating point precision, right? This simple difference 
caused big differences in my later calculation.


More information about the Numpy-discussion mailing list