On 04/01/2012 02:06 PM, Nils Bruin wrote:
That's essentially the syntax we already have for FDerivativeOperator.
which can also be like f.D(0) and f.D(0,1) ?
I think that has merit, but it doesn't solve the problem that sage
should probably have some notational convention for the mathematical
entities called differential operators.
If you think you want derivatives right now, you're probably better off
using aptly-named symbolic variables, and performing the differentiation
later on once you're done manipulating the "derivatives."
sage: f = function('f', x)
sage: f_prime = f.diff(x)
sage: f_prime.simplify()
D[0](f)(x)
sage: f_prime(0).simplify()
...
NotImplementedError: arguments must be distinct variables
Most symbolic stuff blows up the same way:
sage: solve([f_prime(0) == 0], f_prime(0))
...
NotImplementedError: arguments must be distinct variables
Substitution doesn't even work pre-evaluation:
sage: g = function('g', x)
sage: f_prime.substitute_function(f,g)
D[0](f)(x)
A symbolic var('D0fx') on the other hand will work just fine.
--
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