Discussion: Introducing new operators for matrix computation

Moshe Zadka moshez at math.huji.ac.il
Sat Jul 15 03:15:38 EDT 2000


On Sat, 15 Jul 2000, Huaiyu Zhu wrote:

> How would you write this in list compresension (in less than 10 lines)?
> 
> B*(sin(A*x+b).*(A*y)/3)/C

B*[sin(a)*b/3; for a,b in transpose([A*x+b, A*y])]/C

--
Moshe Zadka <moshez at math.huji.ac.il>
There is no GOD but Python, and HTTP is its prophet.
http://advogato.org/person/moshez





More information about the Python-list mailing list