Ask Your Question

# How do i display a derivative using view()

I can currently display the form of an integral in latex using:

f(x) = x + x^2
view( integral(f(x),x, hold=True) ) #displays the form of the derivative


But i can't figure out how to do it for a derivative:

f(x) = x + x^2
view( derivative(f(x),x, hold=True) ) #fails
view( derivative(f(x),x) ) # takes derivative then displays answer instead of the problem


Is their any easy way to do this? If not, whats the recommended way to fake it (inline latex etc)?

edit retag close merge delete

## 1 Answer

Sort by » oldest newest most voted

As you can see, the problem is not about viewing the formula in LaTeX/pdf, but about telling Sage not to compute the derivative. Indeed , it seems that the derivative method does not support a hold argument (yet).

sage: f(x) = x + x^2
sage: derivative(f(x),x)
2*x + 1
sage: derivative(f(x),x, hold=True)
TypeError: derivative() got an unexpected keyword argument 'hold'

more

## Comments

1

Apparently the long-delayed http://trac.sagemath.org/ticket/6756 would implement this, or at least should implement it but maybe hasn't yet...

## Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

## Stats

Asked: 2015-10-02 10:17:12 +0200

Seen: 185 times

Last updated: Oct 02 '15