From: Aureli S. F. <Aur...@ip...> - 2001-03-14 16:34:45
|
Hi, It seems there is a problem when multiplying complex arrays, but maybe that is already solved for the new NumPy 17.3, is it? The product of complex arrays does not seem to be right. Code lines: >>> a=a_conj[:] >>> a array([[ 1.-0.j, 1.-1.j, 1.-2.j], [ 1.-3.j, 1.-4.j, 1.-5.j], [ 1.-6.j, 1.-7.j, 1.-8.j]]) >>> a.imag=a.imag*-1 >>> a array([[ 1.+0.j, 1.+1.j, 1.+2.j], [ 1.+3.j, 1.+4.j, 1.+5.j], [ 1.+6.j, 1.+7.j, 1.+8.j]]) >>> Numeric.multiply(a,a_conj) array([[ 1. +0.j, 0. +2.j, -3. +4.j], [ -8. +6.j, -15. +8.j, -24.+10.j], [-35.+12.j, -48.+14.j, -63.+16.j]]) where the answer should be [[1+0j,2+0j,5+0j][10+0j,... ################################# Aureli Soria Frisch Fraunhofer IPK Dept. Pattern Recognition post: Pascalstr. 8-9, 10587 Berlin, Germany e-mail:au...@ip... fon: +49 30 39 00 61 50 fax: +49 30 39 17 517 ################################# |