Ricci.hpp
Go to the documentation of this file.
1 // Distributed under the MIT License.
2 // See LICENSE.txt for details.
3 
4 ///\file
5 /// Declares function templates to calculate the Ricci tensor
6 
7 #pragma once
8 
9 #include <cstddef>
10 
12 
13 namespace gr {
14 
15 /*!
16  * \ingroup GeneralRelativityGroup
17  * \brief Computes Ricci tensor from the (spatial or spacetime)
18  * Christoffel symbol of the second kind and its derivative.
19  *
20  * \details Computes Ricci tensor \f$R_{ab}\f$ as:
21  * \f$ R_{ab} = \frac{1}{2} ( \partial_c \Gamma^{c}_{ab} - \partial_{(b}
22  * \Gamma^{c}_{a)c}
23  * + \Gamma^{d}_{ab}\Gamma^{c}_{cd} - \Gamma^{d}_{ac} \Gamma^{c}_{bd} ) \f$
24  * where \f$\Gamma^{a}_{bc}\f$ is the Christoffel symbol of the second kind.
25  */
26 template <size_t SpatialDim, typename Frame, IndexType Index, typename DataType>
27 tnsr::aa<DataType, SpatialDim, Frame, Index> ricci_tensor(
28  const tnsr::Abb<DataType, SpatialDim, Frame, Index>& christoffel_2nd_kind,
29  const tnsr::aBcc<DataType, SpatialDim, Frame, Index>&
30  d_christoffel_2nd_kind) noexcept;
31 
32 } // namespace gr
Holds functions related to general relativity.
Definition: KerrHorizon.cpp:14
Defines a list of useful type aliases for tensors.
tnsr::aa< DataType, SpatialDim, Frame, Index > ricci_tensor(const tnsr::Abb< DataType, SpatialDim, Frame, Index > &christoffel_2nd_kind, const tnsr::aBcc< DataType, SpatialDim, Frame, Index > &d_christoffel_2nd_kind) noexcept
Computes Ricci tensor from the (spatial or spacetime) Christoffel symbol of the second kind and its d...
Definition: Ricci.cpp:12