In the past when I wanted to add functionality to a python expression I would wrap it in a class as below -

class ga(object):

    def __init__(self,sympy_expression):

        self.obj = sympy_expression


    more functions to add functionality, etc.

Would it be better to derive my class from Expr as in -

class ga(Expr):

    def __init__(self,sympy_expression):

        what next?

I can find no __init__ for Expr so how do I initialize it, how do I refer to it in my class so I can manipulate it, how do I use the original __mul__ if I override __mul__ ?




--
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?hl=en-US.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to