Hi, I think that the distinction between
def f(x): return x^2 and f(x) = x^2 is a common source of confusion, and everyone will run into it when trying to define piecewise functions. It would be possible to introduce a decorator, say @symbolic_function, that makes sure that @symbolic_function(x) def f(x): return x^2 makes f a symbolic function. I've done just that in this published worksheet: http://www.sagenb.org/home/pub/4919 As you can see, it works with piecewise functions, too. Of course, it should probably do something sane with multiple variables, class methods, etc, but it seems possible. I can probably produce a patch for this, but I would like some feedback first. Best regards, Timo Kluck -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org