On 29 May 2012 17:55, smichr <[email protected]> wrote:
>> a) To me it seems strange that f is not Basic (Lambda is an Expr for
>> instance). Moreover if we want the recursively evaluated Expr from
>> another thread here on the mailing list, we need f to be Expr
>>
>
> It actually (in the branch in question, at least) is a BasicType which seems
> wrong.
>
>>>> isinstance(Add, BasicType)
> True
>>>> isinstance(x+y, BasicType)
> False
>>>> isinstance(Function, BasicType)
> True
>>>> isinstance(Function('f'), BasicType)
> True
>
> It seems that are particular instance of Function (or undefinedFunction)
> should not also be considered a BasicType just as a particular Add is not.
>
Actually this is just a bit of dark magic (that will presumably will
be exchanged for a more sane api): Function('f') is NOT an instance of
Function, rather it is a subclass. In this design it does make sense
for it to be BasicType, it is just that I consider the overall idea
needlessly complicated.

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

Reply via email to