[MATRIX-SIG] Weird bug
Konrad Hinsen
hinsen@ibs.ibs.fr
Sat, 30 Aug 1997 15:31:29 +0200
I have hit the following bug which looks really dangerous to me - wrong
results in a perfectly ordinary situation:
>>> from Numeric import *
>>> a = array([[1,2],[3,4]])
>>> a + transpose(a)
array([[2, 5],
[5, 8]])
>>> add(a, transpose(a))
array([[2, 5],
[5, 8]])
>>> add(a, transpose(a), a)
array([[2, 5],
[8, 8]])
>>> a
array([[2, 5],
[8, 8]])
I won't have any time soon to check what's going on, but watch out
for this if you use the three-argument arithmetic functions.
--
-------------------------------------------------------------------------------
Konrad Hinsen | E-Mail: hinsen@ibs.ibs.fr
Laboratoire de Dynamique Moleculaire | Tel.: +33-4.76.88.99.28
Institut de Biologie Structurale | Fax: +33-4.76.88.54.94
41, av. des Martyrs | Deutsch/Esperanto/English/
38027 Grenoble Cedex 1, France | Nederlands/Francais
-------------------------------------------------------------------------------
_______________
MATRIX-SIG - SIG on Matrix Math for Python
send messages to: matrix-sig@python.org
administrivia to: matrix-sig-request@python.org
_______________