Line data Source code
1 0 : // Distributed under the MIT License.
2 : // See LICENSE.txt for details.
3 :
4 : #pragma once
5 :
6 : #include <cstddef>
7 :
8 : #include "DataStructures/DataBox/Tag.hpp"
9 : #include "DataStructures/Tensor/Tensor.hpp"
10 : #include "Evolution/Systems/GeneralizedHarmonic/Tags.hpp"
11 : #include "PointwiseFunctions/GeneralRelativity/Tags.hpp"
12 : #include "Utilities/Gsl.hpp"
13 : #include "Utilities/TMPL.hpp"
14 :
15 : /// \cond
16 : namespace gsl {
17 : template <typename>
18 : struct not_null;
19 : } // namespace gsl
20 : class DataVector;
21 : /// \endcond
22 :
23 : namespace gh {
24 : /*!
25 : * \ingroup GeneralRelativityGroup
26 : * \brief Computes the covariant derivative of extrinsic curvature from
27 : * generalized harmonic variables and the spacetime normal vector.
28 : *
29 : * \details If \f$ \Pi_{ab} \f$ and \f$ \Phi_{iab} \f$ are the generalized
30 : * harmonic conjugate momentum and spatial derivative variables, and if
31 : * \f$n^a\f$ is the spacetime normal vector, then the extrinsic curvature
32 : * can be written as
33 : * \f{equation}\label{eq:kij}
34 : * K_{ij} = \frac{1}{2} \Pi_{ij} + \Phi_{(ij)a} n^a,
35 : * \f}
36 : * and its covariant derivative as
37 : * \f{equation}\label{eq:covkij}
38 : * \nabla_k K_{ij} = \partial_k K_{ij} - \Gamma^l{}_{ik} K_{lj}
39 : * - \Gamma^l{}_{jk} K_{li},
40 : * \f}
41 : * where \f$\Gamma^k{}_{ij}\f$ are Christoffel symbols of the second kind.
42 : * The partial derivatives of extrinsic curvature can be computed as
43 : * \f{equation}\label{eq:pdkij}
44 : * \partial_k K_{ij} =
45 : * \frac{1}{2}\left(\partial_k \Pi_{ij} +
46 : * \left(\partial_k \Phi_{ija} +
47 : * \partial_k \Phi_{jia}\right) n^a +
48 : * \left(\Phi_{ija} + \Phi_{jia}\right) \partial_k n^a
49 : * \right),
50 : * \f}
51 : * where we have access to all terms except the spatial derivatives of the
52 : * spacetime unit normal vector \f$\partial_k n^a\f$. Given that
53 : * \f$n^a=(1/\alpha, -\beta^i /\alpha)\f$, the temporal portion of
54 : * \f$\partial_k n^a\f$ can be computed as:
55 : * \f{align}
56 : * \partial_k n^0 =& -\frac{1}{\alpha^2} \partial_k \alpha, \nonumber \\
57 : * =& -\frac{1}{\alpha^2} (-\alpha/2) n^a \Phi_{kab} n^b,
58 : * \nonumber \\
59 : * =& \frac{1}{2\alpha} n^a \Phi_{kab} n^b, \nonumber \\
60 : * =& \frac{1}{2} n^0 n^a \Phi_{kab} n^b, \nonumber \\
61 : * =& -\left(g^{0a} +
62 : * \frac{1}{2}n^0 n^a\right) \Phi_{kab} n^b,
63 : * \f}
64 : * where we use the expression for \f$\partial_k \alpha\f$ from
65 : * \ref spatial_deriv_of_lapse; while the spatial portion of the same can be
66 : * computed as:
67 : * \f{align}
68 : * \partial_k n^i =& -\partial_k (\beta^i/\alpha)
69 : * = -\frac{1}{\alpha}\partial_k \beta^i
70 : * + \frac{\beta^i}{\alpha^2}\partial_k \alpha ,\nonumber \\
71 : * =& -\frac{1}{2}\frac{\beta^i}{\alpha} n^a\Phi_{kab}n^b
72 : * -\left(g^{ia}
73 : * + n^i n^a\right) \Phi_{kab} n^b, \nonumber\\
74 : * =& -\left(g^{ia} + \frac{1}{2}n^i n^a\right) \Phi_{kab}n^b,
75 : * \f}
76 : * where we use the expression for \f$\partial_k \beta^i\f$ from
77 : * \ref spatial_deriv_of_shift. Combining the last two equations, we find that
78 : * \f{equation}
79 : * \partial_k n^a = -\left(g^{ab} + \frac{1}{2}n^a n^b\right)\Phi_{kbc}n^c,
80 : * \f}
81 : * and using Eq.(\f$\ref{eq:covkij}\f$) and Eq.(\f$\ref{eq:pdkij}\f$) with this,
82 : * we can compute the covariant derivative of the extrinsic curvature as:
83 : * \f{equation}
84 : * \nabla_k K_{ij} =
85 : * \frac{1}{2}\left(\partial_k \Pi_{ij} +
86 : * \left(\partial_k \Phi_{ija} +
87 : * \partial_k \Phi_{jia}\right) n^a -
88 : * \left(\Phi_{ija} + \Phi_{jia}\right)
89 : * \left(g^{ab} + \frac{1}{2}n^a n^b\right)
90 : * \Phi_{kbc}n^c
91 : * \right) - \Gamma^l{}_{ik} K_{lj} - \Gamma^l{}_{jk} K_{li} \f}.
92 : */
93 : template <typename DataType, size_t SpatialDim, typename Frame>
94 1 : tnsr::ijj<DataType, SpatialDim, Frame> covariant_deriv_of_extrinsic_curvature(
95 : const tnsr::ii<DataType, SpatialDim, Frame>& extrinsic_curvature,
96 : const tnsr::A<DataType, SpatialDim, Frame>& spacetime_unit_normal_vector,
97 : const tnsr::Ijj<DataType, SpatialDim, Frame>&
98 : spatial_christoffel_second_kind,
99 : const tnsr::AA<DataType, SpatialDim, Frame>& inverse_spacetime_metric,
100 : const tnsr::iaa<DataType, SpatialDim, Frame>& phi,
101 : const tnsr::iaa<DataType, SpatialDim, Frame>& d_pi,
102 : const tnsr::ijaa<DataType, SpatialDim, Frame>& d_phi);
103 :
104 : template <typename DataType, size_t SpatialDim, typename Frame>
105 0 : void covariant_deriv_of_extrinsic_curvature(
106 : gsl::not_null<tnsr::ijj<DataType, SpatialDim, Frame>*>
107 : d_extrinsic_curvature,
108 : const tnsr::ii<DataType, SpatialDim, Frame>& extrinsic_curvature,
109 : const tnsr::A<DataType, SpatialDim, Frame>& spacetime_unit_normal_vector,
110 : const tnsr::Ijj<DataType, SpatialDim, Frame>&
111 : spatial_christoffel_second_kind,
112 : const tnsr::AA<DataType, SpatialDim, Frame>& inverse_spacetime_metric,
113 : const tnsr::iaa<DataType, SpatialDim, Frame>& phi,
114 : const tnsr::iaa<DataType, SpatialDim, Frame>& d_pi,
115 : const tnsr::ijaa<DataType, SpatialDim, Frame>& d_phi);
116 : } // namespace gh
|