[Python-ideas] Fwd: [RFC] draft PEP: Dedicated infix operators for matrix multiplication and matrix power

Ronan Lamy ronan.lamy at gmail.com
Fri Mar 14 23:01:54 CET 2014


Le 14/03/14 20:17, Serhiy Storchaka a écrit :
> Matrix multiplication is only defined on 2d arrays (matrices). But why
> not on arbitrary tensors (except scalars)?

The PEP does include a (complicated) definition of "matrix 
multiplication" for arrays of all ranks. In particular, @-multiplication 
of rank-1 arrays is the dot product.



More information about the Python-ideas mailing list