On Sunday, February 2, 2014 8:30:45 PM UTC+4, David Kremer wrote: > > What I would simply ask, is if it wouldn't be possible to overload an > operator such as "%" or ".*" to > implement matrix elementwise multiplication in sympy. It would greatly > improve the readability of my > code. >
First, there is no ".*" operator at all: http://docs.python.org/dev/reference/lexical_analysis.html#operators % - stands for integer division (yields the remainder). While it's possible to overload it, I doubt if that's natural and pythonic (to include in sympy). In your words, it's too hackish. > About the second question, it is about the point if defining a single > operator such as ".*" in matlab > could be done in sympy > Probably, this can be done only with some syntax extension. BTW, see also PEP 225. -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/sympy. For more options, visit https://groups.google.com/groups/opt_out.
