How to explicitly write derivatives of a symbolic function?

I have

u = function('u',x)

      

and I am wondering what happens when the degrees of some scalar a

are eigenvalues ​​of the differentiation operator (i.e. D^n u = a^n*u

). For n=1,2

there are rudimentary functional examples ( De^(a*x) = a*e^(a*x)

, sin

and cos

for a=i

and n=2

), but for higher degrees I need to go in abstract.

My question is how to symbolically assign derivatives u

? One option is to write a function that distinguishes everything ok but dispatches u

to a*u

, but what if I just want to D^3u = a^3*u

?

In other words, if I want every derivative of u

just to be "derived from u

" ( D[...](u)(x)

), except for the third, which I want to be a^3*u

for some scalar a

. How could I implement this?
+3


source to share


1 answer


What's wrong with the solution you propose in your second paragraph? e. in Maxima,

D[n](u, x) := if n=3 then a^3*u(x) else diff(u(x),x,n)$

      



gives you what you want, right?

Maxima allows first derivatives to be assigned symbolically with gradef

, but I don't know how to assign higher derivatives.

+1


source







All Articles