[PYTHON MATRIX-SIG] default axes

Konrad HINSEN hinsenk@ere.umontreal.ca
Fri, 16 Aug 1996 05:36:00 -0400


> I really think dot(a,b) should behave _exactly_ like
> 
> add.reduce(a*b,axis=-1)

Why?

> Full rank multiplication of two arrays could be written:
> 
> dot(a[...,(n-1)*(NewAxis,)],b,axes=-n)

That is a lot too complicated for a frequent operation, especially
considering that n might not be available as a variable or constant,
i.e. it would have to be written as shape(b)[0].

Konrad.
-------------------------------------------------------------------------------
Konrad Hinsen                     | E-Mail: hinsenk@ere.umontreal.ca
Departement de chimie             | Tel.: +1-514-343-6111 ext. 3953
Universite de Montreal            | Fax:  +1-514-343-7586
C.P. 6128, succ. Centre-Ville     | Deutsch/Esperanto/English/Nederlands/
Montreal (QC) H3C 3J7             | Francais (phase experimentale)
-------------------------------------------------------------------------------

=================
MATRIX-SIG  - SIG on Matrix Math for Python

send messages to: matrix-sig@python.org
administrivia to: matrix-sig-request@python.org
=================