 tensor(deprecated)/Christoffel2 - Maple Help

tensor

 Christoffel2
 compute the Christoffel symbols of the second kind Calling Sequence Christoffel2(ginv, Cf1) Parameters

 ginv - rank two tensor_type of character [1,1] representing the contravariant metric tensor; specifically, ${\left({\mathrm{ginv}}_{\mathrm{compts}}\right)}_{i,j}≔{g}^{\left\{\mathrm{ij}\right\}}$ The components of ginv should be indexed using Maple's symmetric indexing function. Cf1 - rank three tensor_type of character [-1,-1,-1] representing the Christoffel symbols of the first kind; specifically, ${\mathrm{Cf1}}_{\mathrm{compts}}[i,j,k]:=\left\{ij,k\right\}$ The components of Cf1 should be indexed using the index/cf1 indexing function. Description

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

 • The resultant tensor_type, Cf2 say, of this routine is the Christoffel symbols of the second kind, indexed as shown below:

${\mathrm{Cf2}}_{{\mathrm{compts}}_{i,j,k}}≔\left\{\begin{array}{c}i\\ jk\end{array}\right\}\left(in conventional notation\right)$

 • The ginv parameter can be obtained by using the tensor package function tensor[invert] and the Cf1 parameter can be obtained by using the tensor package function tensor[Christoffel1]. Otherwise, be sure to use the appropriate indexing functions for the components of these quantities (as mentioned above).
 • Indexing Function:  Because the Christoffel symbols of the second kind are symmetric in the last two (that is, lower) indices, the array of computed symbols uses the index/cf2 indexing function. This function indexes an array of rank 3 so that it is symmetric in the second and third indices.  Use of this indexing function decreases the number of symbols that must be assigned and stored to the number of independent symbols.
 • Simplification:  This routine uses the tensor/Christoffel2/simp routine to carry out the simplification of each independent Christoffel symbol of the second kind. By default, it is initialized to the tensor/simp function.  It is recommended that the tensor/Christoffel2/simp routine be customized to suit the particular needs of the problem at hand.
 • This function is part of the tensor package, and so can be used in the form Christoffel2(..) only after performing the command with(tensor) or with(tensor, Christoffel2).  The function can always be accessed in the long form tensor[Christoffel2](..). Examples

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

Define the coordinate variables and the covariant metric tensor components for the Schwarzchild metric:

 > $\mathrm{with}\left(\mathrm{tensor}\right):$
 > $\mathrm{coord}≔\left[t,r,\mathrm{\theta },\mathrm{\phi }\right]:$
 > $\mathrm{g_compts}≔\mathrm{array}\left(\mathrm{symmetric},\mathrm{sparse},1..4,1..4\right):$
 > $\mathrm{g_compts}\left[1,1\right]≔1-\frac{2m}{r}:$$\mathrm{g_compts}\left[2,2\right]≔-\frac{1}{\mathrm{g_compts}\left[1,1\right]}:$
 > $\mathrm{g_compts}\left[3,3\right]≔-{r}^{2}:$$\mathrm{g_compts}\left[4,4\right]≔-{r}^{2}{\mathrm{sin}\left(\mathrm{th}\right)}^{2}:$
 > $g≔\mathrm{create}\left(\left[-1,-1\right],\mathrm{eval}\left(\mathrm{g_compts}\right)\right)$
 ${g}{≔}{table}{}\left(\left[{\mathrm{compts}}{=}\left[\begin{array}{cccc}{1}{-}\frac{{2}{}{m}}{{r}}& {0}& {0}& {0}\\ {0}& {-}\frac{{1}}{{1}{-}\frac{{2}{}{m}}{{r}}}& {0}& {0}\\ {0}& {0}& {-}{{r}}^{{2}}& {0}\\ {0}& {0}& {0}& {-}{{r}}^{{2}}{}{{\mathrm{sin}}{}\left({\mathrm{th}}\right)}^{{2}}\end{array}\right]{,}{\mathrm{index_char}}{=}\left[{-1}{,}{-1}\right]\right]\right)$ (1)

Now determine the contravariant components of the metric tensor, the first partials of the covariant metric tensor components, and the Christoffel symbols of the first kind:

 > $\mathrm{ginv}≔\mathrm{invert}\left(g,'\mathrm{detg}'\right):$
 > $\mathrm{D1g}≔\mathrm{d1metric}\left(g,\mathrm{coord}\right):$
 > $\mathrm{Cf1}≔\mathrm{Christoffel1}\left(\mathrm{D1g}\right):$

Because this metric involves trigonometric functions, alter the tensor/Christoffel2/simp routine to apply Maple's simplify function using the "trig" option to the quantities it computes:

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

Finally, we use the Christoffel2 routine to obtain the Christoffel symbols of the second kind:

 > $\mathrm{Cf2}≔\mathrm{Christoffel2}\left(\mathrm{ginv},\mathrm{Cf1}\right)$
 ${\mathrm{Cf2}}{≔}{table}{}\left(\left[{\mathrm{compts}}{=}{array}{}\left({\mathrm{cf2}}{,}{1}{..}{4}{,}{1}{..}{4}{,}{1}{..}{4}{,}\left[\left({1}{,}{1}{,}{1}\right){=}{0}{,}\left({1}{,}{1}{,}{2}\right){=}{-}\frac{{m}}{{r}{}\left({-}{r}{+}{2}{}{m}\right)}{,}\left({1}{,}{1}{,}{3}\right){=}{0}{,}\left({1}{,}{1}{,}{4}\right){=}{0}{,}\left({1}{,}{2}{,}{1}\right){=}{-}\frac{{m}}{{r}{}\left({-}{r}{+}{2}{}{m}\right)}{,}\left({1}{,}{2}{,}{2}\right){=}{0}{,}\left({1}{,}{2}{,}{3}\right){=}{0}{,}\left({1}{,}{2}{,}{4}\right){=}{0}{,}\left({1}{,}{3}{,}{1}\right){=}{0}{,}\left({1}{,}{3}{,}{2}\right){=}{0}{,}\left({1}{,}{3}{,}{3}\right){=}{0}{,}\left({1}{,}{3}{,}{4}\right){=}{0}{,}\left({1}{,}{4}{,}{1}\right){=}{0}{,}\left({1}{,}{4}{,}{2}\right){=}{0}{,}\left({1}{,}{4}{,}{3}\right){=}{0}{,}\left({1}{,}{4}{,}{4}\right){=}{0}{,}\left({2}{,}{1}{,}{1}\right){=}\frac{{-}{2}{}{{m}}^{{2}}{+}{m}{}{r}}{{{r}}^{{3}}}{,}\left({2}{,}{1}{,}{2}\right){=}{0}{,}\left({2}{,}{1}{,}{3}\right){=}{0}{,}\left({2}{,}{1}{,}{4}\right){=}{0}{,}\left({2}{,}{2}{,}{1}\right){=}{0}{,}\left({2}{,}{2}{,}{2}\right){=}\frac{{m}}{{r}{}\left({-}{r}{+}{2}{}{m}\right)}{,}\left({2}{,}{2}{,}{3}\right){=}{0}{,}\left({2}{,}{2}{,}{4}\right){=}{0}{,}\left({2}{,}{3}{,}{1}\right){=}{0}{,}\left({2}{,}{3}{,}{2}\right){=}{0}{,}\left({2}{,}{3}{,}{3}\right){=}{-}{r}{+}{2}{}{m}{,}\left({2}{,}{3}{,}{4}\right){=}{0}{,}\left({2}{,}{4}{,}{1}\right){=}{0}{,}\left({2}{,}{4}{,}{2}\right){=}{0}{,}\left({2}{,}{4}{,}{3}\right){=}{0}{,}\left({2}{,}{4}{,}{4}\right){=}\left({-}{r}{+}{2}{}{m}\right){}{{\mathrm{sin}}{}\left({\mathrm{th}}\right)}^{{2}}{,}\left({3}{,}{1}{,}{1}\right){=}{0}{,}\left({3}{,}{1}{,}{2}\right){=}{0}{,}\left({3}{,}{1}{,}{3}\right){=}{0}{,}\left({3}{,}{1}{,}{4}\right){=}{0}{,}\left({3}{,}{2}{,}{1}\right){=}{0}{,}\left({3}{,}{2}{,}{2}\right){=}{0}{,}\left({3}{,}{2}{,}{3}\right){=}\frac{{1}}{{r}}{,}\left({3}{,}{2}{,}{4}\right){=}{0}{,}\left({3}{,}{3}{,}{1}\right){=}{0}{,}\left({3}{,}{3}{,}{2}\right){=}\frac{{1}}{{r}}{,}\left({3}{,}{3}{,}{3}\right){=}{0}{,}\left({3}{,}{3}{,}{4}\right){=}{0}{,}\left({3}{,}{4}{,}{1}\right){=}{0}{,}\left({3}{,}{4}{,}{2}\right){=}{0}{,}\left({3}{,}{4}{,}{3}\right){=}{0}{,}\left({3}{,}{4}{,}{4}\right){=}{0}{,}\left({4}{,}{1}{,}{1}\right){=}{0}{,}\left({4}{,}{1}{,}{2}\right){=}{0}{,}\left({4}{,}{1}{,}{3}\right){=}{0}{,}\left({4}{,}{1}{,}{4}\right){=}{0}{,}\left({4}{,}{2}{,}{1}\right){=}{0}{,}\left({4}{,}{2}{,}{2}\right){=}{0}{,}\left({4}{,}{2}{,}{3}\right){=}{0}{,}\left({4}{,}{2}{,}{4}\right){=}\frac{{1}}{{r}}{,}\left({4}{,}{3}{,}{1}\right){=}{0}{,}\left({4}{,}{3}{,}{2}\right){=}{0}{,}\left({4}{,}{3}{,}{3}\right){=}{0}{,}\left({4}{,}{3}{,}{4}\right){=}{0}{,}\left({4}{,}{4}{,}{1}\right){=}{0}{,}\left({4}{,}{4}{,}{2}\right){=}\frac{{1}}{{r}}{,}\left({4}{,}{4}{,}{3}\right){=}{0}{,}\left({4}{,}{4}{,}{4}\right){=}{0}\right]\right){,}{\mathrm{index_char}}{=}\left[{1}{,}{-1}{,}{-1}\right]\right]\right)$ (2)

The user may also view the result with the tensor package function displayGR.