Status: Accepted
Owner: asmeurer
Labels: Type-Defect Priority-Medium Printing

New issue 2442 by asmeurer: Why does Lambda use Dummys?
http://code.google.com/p/sympy/issues/detail?id=2442

We have

In [19]: Lambda(x, x)
Out[19]: Lambda(_x, _x)

In [20]: Lambda(y, y)
Out[20]: Lambda(_x, _x)

The _x is a Dummy, which automatically replaces the given variable. Why is this done? I know that we need to be able to compare essentially equal Lambdas as equal with ==, but that can be done equally as well with the original symbol as with a Dummy. On the other hand, if we use the original symbol, we get nicer printing.

Also, there is an inconsistency with multiple symbols, and a printing bug:

In [22]: Lambda((x, y), y)
Out[22]: Lambda((_x, _y), _y

In [23]: Lambda((x, z), y)
Out[23]: Lambda((_x, _z), y


--
You received this message because you are subscribed to the Google Groups 
"sympy-issues" group.
To post to this group, send email to sympy-issues@googlegroups.com.
To unsubscribe from this group, send email to 
sympy-issues+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sympy-issues?hl=en.

Reply via email to