Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Simplify derivatives expression

Hi,

I have a really simple problem. Assuming that I have this simple code

sage: rho = function("rho")(x)
sage: J = function("J")(x)
sage: expr = -J**2/rho**2*Derivative(rho, x) + 2*J/rho*Derivative(J, x)

Is there a way in sage to have this expression in a more compact expression. That is to say

Derivative(J**2/rho, x)

Thanks, Loic