tensor(deprecated)/Lie_diff - Maple Help

tensor

 Lie_diff
 compute the Lie derivative of a tensor with respect to a contravariant vector field

 Calling Sequence Lie_diff( T, V, coord)

Parameters

 T - tensor whose Lie derivative is to be computed V - contravariant vector field with respect to which the derivative is being taken coord - list of coordinate names

Description

Important: The tensor package has been deprecated. Use the superseding commands DifferentialGeometry[LieDerivative] and Physics[LieDerivative] instead.

 • Given the coordinate variables, coord, a contravariant vector field V, and any tensor T, Lie_diff(T, V, coord) computes the Lie derivative of T with respect to the vector field V using the usual partial derivatives of T and V according to the standard formula:

$\mathrm{Lv}\left({T}_{a,b,c,\mathrm{...},l,m,n,\mathrm{...}}\right)≔{T}_{a,b,c,\mathrm{...},l,m,n,\mathrm{...}},q{V}_{q}-{T}_{q,b,c,\mathrm{...},l,m,n,\mathrm{...}}{V}_{a},-{T}_{a,q,c,\mathrm{...},l,m,n,\mathrm{...}}{V}_{b}+q,-{T}_{a,b,q,\mathrm{...},l,m,n,\mathrm{...}}{V}_{c}+q,{T}_{a,b,c,\mathrm{...},q,m,n,\mathrm{...}}{V}_{q}-\mathrm{....}+q,{T}_{a,b,c,\mathrm{...},l,q,n,\mathrm{...}}{V}_{q}+l,{T}_{a,b,c,\mathrm{...},l,m,q,\mathrm{...}}{V}_{q}+m,n+\mathrm{...}$

 where the comma denotes a partial derivative, a, b, c, ... are contravariant indices of T and l, m, n, ... are covariant indices of T, and * indicates an inner product on the repeated indices.
 • It is required that V be a tensor_type with character: [1] (that is, V is a contravariant vector field)
 • Note that the rank and index character of the result is identical to that of the input tensor, T.
 • Simplification:  This routine uses the routine tensor/Lie_diff/simp routine for simplification purposes.  The simplification routine is applied twice to each component: first, to the first term involving the inner product of the partial of T and the vector V, and second to the entire component once all of the subsequent terms have been added on. By default, this routine is initialized to the tensor/simp routine.  It is recommended that the tensor/Lie_diff/simp routine be customized to suit the needs of the particular problem.
 • This function is part of the tensor package, and so can be used in the form Lie_diff(..) only after performing the command with(tensor) or with(tensor, Lie_diff).  The function can always be accessed in the long form tensor[Lie_diff](..).

Examples

Important: The tensor package has been deprecated. Use the superseding commands DifferentialGeometry[LieDerivative] and Physics[LieDerivative] instead.

 > $\mathrm{with}\left(\mathrm{tensor}\right):$

Define a mixed rank 2 tensor type, T:

 > $\mathrm{T_compts}≔\mathrm{array}\left(\mathrm{symmetric},1..3,1..3,\left[\left[r\mathrm{sin}\left(\mathrm{\theta }\right),{\mathrm{\phi }}^{3},0\right],\left[{\mathrm{\phi }}^{3},r-{\mathrm{cos}\left(\mathrm{\theta }\right)}^{2},{r}^{3}\right],\left[0,{r}^{3},9\right]\right]\right):$
 > $T≔\mathrm{create}\left(\left[1,-1\right],\mathrm{eval}\left(\mathrm{T_compts}\right)\right)$
 ${T}{≔}{table}{}\left(\left[{\mathrm{index_char}}{=}\left[{1}{,}{-1}\right]{,}{\mathrm{compts}}{=}\left[\begin{array}{ccc}{r}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right)& {{\mathrm{\phi }}}^{{3}}& {0}\\ {{\mathrm{\phi }}}^{{3}}& {r}{-}{{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)}^{{2}}& {{r}}^{{3}}\\ {0}& {{r}}^{{3}}& {9}\end{array}\right]\right]\right)$ (1)

Define a contravariant vector field, V:

 > $V≔\mathrm{create}\left(\left[1\right],\mathrm{array}\left(\left[r,r\mathrm{cos}\left(\mathrm{\theta }\right),r\mathrm{cos}\left(\mathrm{\phi }\right)\right]\right)\right)$
 ${V}{≔}{table}{}\left(\left[{\mathrm{index_char}}{=}\left[{1}\right]{,}{\mathrm{compts}}{=}\left[\begin{array}{ccc}{r}& {r}{}{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)& {r}{}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right)\end{array}\right]\right]\right)$ (2)

Define the coordinates:

 > $\mathrm{coord}≔\left[r,\mathrm{\theta },\mathrm{\phi }\right]$
 ${\mathrm{coord}}{≔}\left[{r}{,}{\mathrm{\theta }}{,}{\mathrm{\phi }}\right]$ (3)

Because the components of T and V involve trigonometric functions, customize the tensor/Lie_diff/simp routine so that it uses the trig option of the Maple simplify:

 > tensor/Lie_diff/simp:=proc(x) simplify(x,trig) end proc:

Now compute the Lie derivative of T with respect to the field V:

 > $\mathrm{LvT}≔\mathrm{tensor}\left[\mathrm{Lie_diff}\right]\left(T,V,\mathrm{coord}\right)$
 ${\mathrm{LvT}}{≔}{table}{}\left(\left[{\mathrm{index_char}}{=}\left[{1}{,}{-1}\right]{,}{\mathrm{compts}}{=}\left[\begin{array}{ccc}{{r}}^{{2}}{}{{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)}^{{2}}{+}{{\mathrm{\phi }}}^{{3}}{}{\mathrm{cos}}{}\left({\mathrm{\theta }}\right){+}{r}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right)& {3}{}{{\mathrm{\phi }}}^{{2}}{}{r}{}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right){-}{{\mathrm{\phi }}}^{{3}}{}\left({r}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){+}{1}\right)& {0}\\ {-}{{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)}^{{3}}{-}{r}{}\left({\mathrm{sin}}{}\left({\mathrm{\theta }}\right){-}{1}\right){}{\mathrm{cos}}{}\left({\mathrm{\theta }}\right){+}{{\mathrm{\phi }}}^{{3}}{}{r}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){+}\left({3}{}{{\mathrm{\phi }}}^{{2}}{}{r}{+}{{r}}^{{3}}\right){}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right){+}{{\mathrm{\phi }}}^{{3}}& {r}{+}{2}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){}{{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)}^{{2}}{}{r}{-}{{\mathrm{\phi }}}^{{3}}{}{\mathrm{cos}}{}\left({\mathrm{\theta }}\right)& {-}{{r}}^{{3}}{}\left({r}{}{\mathrm{sin}}{}\left({\mathrm{\phi }}\right){-}{r}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){-}{3}\right)\\ {-}{r}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right){}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right){+}{{r}}^{{3}}{}{\mathrm{cos}}{}\left({\mathrm{\theta }}\right){+}{9}{}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right)& {3}{}{{r}}^{{3}}{-}{{\mathrm{\phi }}}^{{3}}{}{\mathrm{cos}}{}\left({\mathrm{\phi }}\right){+}{{r}}^{{4}}{}{\mathrm{sin}}{}\left({\mathrm{\phi }}\right){-}{{r}}^{{4}}{}{\mathrm{sin}}{}\left({\mathrm{\theta }}\right)& {0}\end{array}\right]\right]\right)$ (4)