Matlab vs Python (was RE: Discussion: Introducing new operators for matrix computation)

Huaiyu Zhu hzhu at localhost.localdomain
Mon Jul 17 16:02:31 EDT 2000


On Mon, 17 Jul 2000 14:12:02 -0500, Paul Prescod <paul at prescod.net> wrote:

>Maybe you should consider how to scale back your syntactic request.
>Perhaps a single keyword or symbol at the beginning of an expression
>could make it element-wise or matrix-wise.

Well, that would be fine if it is workable, ie, when they don't appear in
the same expression.  

Consider the proposal of having two classes, Matrixwise and Elementwise,
with methods to cast to each other.  I don't know why

(a.E()*b.E()).M()*(c.E()*d.E()).M()

would be more preferable to 

(a.*b)*(c.*d)

I chose python because most expressions I write I can visually parse at a
glance.  

Please show an example of special xml syntax proposed that was rejected
because it was too special, and we'll see what kind of simplicity the
proposal represents.

Huaiyu



More information about the Python-list mailing list