6.7. Directional derivatives
From the mathematical point of view, the simplest concept of a derivative is that of a "derivation", a mapping from scalar fields to scalar fields. In fact, the concept of tanget space at a point is constructed as the space of derivations at that point. We can work with operators acting as derivations (or "directional derivatives") using the Dir head.
The object PD[Dir[v[a]]] can be interpreted as the directional derivative along the vector v[a]:
In[503]:=
Out[503]=
and it has all the expected properties:
In[504]:=
Out[504]=
Actually, it is possible to work directly with the derivations acting on scalars, saving 6 brackets (!) in the notation. For example we define the derivation wder associated to the vector w[a]:
In[505]:=
In[506]:=
Out[506]=
Or even better, in prefix notation:
In[507]:=
Out[507]=
In[508]:=
Out[508]=
Created by Mathematica (May 16, 2008) | ![]() |