[Python-Dev] Matrix product

Sebastien Loisel loisel at temple.edu
Wed Jul 30 03:53:49 CEST 2008


Dear Greg,

Thank you for your email.

> In MATLAB, the elementwise operations are probably
> used fairly infrequently. But numpy arrays are often
> used to vectorise what are otherwise scalar operations,
> in which case elementwise operations are used almost
> exclusively.

Your assessment of pointwise operators in MATLAB is incorrect. The
pointwise operators in MATLAB are used heavily to vectorise the scalar
operations, exactly the same as what you describe in numpy. Recently,
the MATLAB JIT has become good enough that looping is fast, however,
the pointwise operators remain "the MATLAB way" of programming.

-- 
Sébastien Loisel


More information about the Python-Dev mailing list