> sage: f=function('f',x) > sage: A=f.diff().subs(x=exp(x)) > sage: A._maxima_() > 'diff('f(x),x,1) > sage: > > perhaps, something has to be improved in trac which implemented > derivatives at a point into Sagehttp://trac.sagemath.org/sage_trac/ticket/385
This is orthogonal to this, though a review of this and #1163 by any interested individuals would be great! They touch on similar issues of making symbolic translation correct between Sage and Maxima. > There could be allready a trac about this and perhaps a patch, not > sure. The problem lies, as so often with such things, in symbolic/ expression_converters.py. It does not look like there is a ticket open for this yet. In lines 462 ff., InterfaceInit.derivative(), we see that it uses ex.args(), which means the following happens: sage: A.operands()[0] e^x sage: _.args() (x,) so when it returns the diff form to send to Maxima (or any other interface which uses this), it has replaced e^x with x. This also explains the original poster's question, since there diff(f,x).subs (e).operands()[0].args() is (t,). However, we can't just naively put ex in for args in the final thing, since it's not a tuple, and it might break something else. I will look into this, but if anyone else has some ideas it'd be great. - kcrisman --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---