SpECTRE Documentation Coverage Report
Current view: top level - Evolution/Systems/GeneralizedHarmonic - Tags.hpp Hit Total Coverage
Commit: 9a905b0737f373631c1b8e8389b8f26e67fa5313 Lines: 15 44 34.1 %
Date: 2024-03-28 09:03:18
Legend: Lines: hit not hit

          Line data    Source code
       1           0 : // Distributed under the MIT License.
       2             : // See LICENSE.txt for details.
       3             : 
       4             : #pragma once
       5             : 
       6             : #include <string>
       7             : 
       8             : #include "DataStructures/DataBox/Prefixes.hpp"
       9             : #include "DataStructures/DataBox/Tag.hpp"
      10             : #include "DataStructures/Tensor/TypeAliases.hpp"
      11             : #include "Evolution/Systems/GeneralizedHarmonic/TagsDeclarations.hpp"
      12             : #include "Evolution/Tags.hpp"
      13             : #include "Options/String.hpp"
      14             : #include "PointwiseFunctions/GeneralRelativity/TagsDeclarations.hpp"
      15             : 
      16             : namespace gh {
      17             : namespace Tags {
      18             : /*!
      19             :  * \brief Conjugate momentum to the spacetime metric.
      20             :  *
      21             :  * \details If \f$ \psi_{ab} \f$ is the spacetime metric, and \f$ N \f$ and
      22             :  * \f$ N^i \f$ are the lapse and shift respectively, then we define
      23             :  * \f$ \Pi_{ab} = -\frac{1}{N} ( \partial_t \psi_{ab} + N^{i} \Phi_{iab} ) \f$
      24             :  * where \f$\Phi_{iab}\f$ is the variable defined by the tag Phi.
      25             :  */
      26             : template <typename DataType, size_t Dim, typename Frame>
      27           1 : struct Pi : db::SimpleTag {
      28           0 :   using type = tnsr::aa<DataType, Dim, Frame>;
      29             : };
      30             : 
      31             : /*!
      32             :  * \brief Auxiliary variable which is analytically the spatial derivative of the
      33             :  * spacetime metric
      34             :  * \details If \f$\psi_{ab}\f$ is the spacetime metric then we define
      35             :  * \f$\Phi_{iab} = \partial_i \psi_{ab}\f$
      36             :  */
      37             : template <typename DataType, size_t Dim, typename Frame>
      38           1 : struct Phi : db::SimpleTag {
      39           0 :   using type = tnsr::iaa<DataType, Dim, Frame>;
      40             : };
      41             : 
      42             : /*!
      43             :  * \brief Gauge source function for the generalized harmonic system.
      44             :  *
      45             :  * \details In the generalized / damped harmonic gauge, unlike the simple
      46             :  * harmonic gauge, the right hand side of the gauge equation
      47             :  * \f$ \square x_a = H_a\f$ is sourced by non-vanishing functions. This variable
      48             :  * stores those functions \f$ H_a\f$.
      49             :  */
      50             : template <typename DataType, size_t Dim, typename Frame>
      51           1 : struct GaugeH : db::SimpleTag {
      52           0 :   using type = tnsr::a<DataType, Dim, Frame>;
      53             : };
      54             : 
      55             : /*!
      56             :  * \brief Spacetime derivatives of the gauge source function for the
      57             :  * generalized harmonic system.
      58             :  *
      59             :  * \details In the generalized / damped harmonic gauge, the right hand side of
      60             :  * the gauge equation \f$ \square x_a = H_a\f$ is sourced by non-vanishing
      61             :  * functions \f$ H_a\f$. This variable stores their spacetime derivatives
      62             :  * \f$ \partial_b H_a\f$.
      63             :  */
      64             : template <typename DataType, size_t Dim, typename Frame>
      65           1 : struct SpacetimeDerivGaugeH : db::SimpleTag {
      66           0 :   using type = tnsr::ab<DataType, Dim, Frame>;
      67             : };
      68             : 
      69             : /*!
      70             :  * \brief Initial value of the gauge source function for the generalized
      71             :  * harmonic system.
      72             :  *
      73             :  * \details In the generalized / damped harmonic gauge, unlike the simple
      74             :  * harmonic gauge, the right hand side of the gauge equation
      75             :  * \f$ \square x_a = H_a\f$ is sourced by non-vanishing functions. This variable
      76             :  * stores the initial or starting value of those functions \f$ H_a\f$, which
      77             :  * are set by the user (based on the choice of initial data) to begin evolution.
      78             :  */
      79             : template <typename DataType, size_t Dim, typename Frame>
      80           1 : struct InitialGaugeH : db::SimpleTag {
      81           0 :   using type = tnsr::a<DataType, Dim, Frame>;
      82             : };
      83             : 
      84             : /*!
      85             :  * \brief Initial spacetime derivatives of the gauge source function
      86             :  * for the generalized harmonic system.
      87             :  *
      88             :  * \details In the generalized / damped harmonic gauge, the right hand side of
      89             :  * the gauge equation \f$ \square x_a = H_a\f$ is sourced by non-vanishing
      90             :  * functions \f$ H_a\f$. This variable stores the initial or starting value of
      91             :  * the spacetime derivatives of those functions \f$ \partial_b H_a\f$, which
      92             :  * are set by the user (based on the choice of initial data) to begin evolution.
      93             :  */
      94             : template <typename DataType, size_t Dim, typename Frame>
      95           1 : struct SpacetimeDerivInitialGaugeH : db::SimpleTag {
      96           0 :   using type = tnsr::ab<DataType, Dim, Frame>;
      97             : };
      98             : 
      99             : /// @{
     100             : /// \brief Tags corresponding to the characteristic fields of the generalized
     101             : /// harmonic system.
     102             : ///
     103             : /// \details For details on how these are defined and computed, see
     104             : /// CharacteristicSpeedsCompute
     105             : template <typename DataType, size_t Dim, typename Frame>
     106           1 : struct VSpacetimeMetric : db::SimpleTag {
     107           0 :   using type = tnsr::aa<DataType, Dim, Frame>;
     108             : };
     109             : template <typename DataType, size_t Dim, typename Frame>
     110           0 : struct VZero : db::SimpleTag {
     111           0 :   using type = tnsr::iaa<DataType, Dim, Frame>;
     112             : };
     113             : template <typename DataType, size_t Dim, typename Frame>
     114           0 : struct VPlus : db::SimpleTag {
     115           0 :   using type = tnsr::aa<DataType, Dim, Frame>;
     116             : };
     117             : template <typename DataType, size_t Dim, typename Frame>
     118           0 : struct VMinus : db::SimpleTag {
     119           0 :   using type = tnsr::aa<DataType, Dim, Frame>;
     120             : };
     121             : /// @}
     122             : 
     123             : template <typename DataType, size_t Dim, typename Frame>
     124           0 : struct CharacteristicSpeeds : db::SimpleTag {
     125           0 :   using type = std::array<DataType, 4>;
     126             : };
     127             : 
     128             : template <typename DataType, size_t Dim, typename Frame>
     129           0 : struct CharacteristicFields : db::SimpleTag {
     130           0 :   using type = Variables<tmpl::list<
     131             :       VSpacetimeMetric<DataType, Dim, Frame>, VZero<DataType, Dim, Frame>,
     132             :       VPlus<DataType, Dim, Frame>, VMinus<DataType, Dim, Frame>>>;
     133             : };
     134             : 
     135             : template <typename DataType, size_t Dim, typename Frame>
     136           0 : struct EvolvedFieldsFromCharacteristicFields : db::SimpleTag {
     137           0 :   using type = Variables<
     138             :       tmpl::list<gr::Tags::SpacetimeMetric<DataType, Dim, Frame>,
     139             :                  Pi<DataType, Dim, Frame>, Phi<DataType, Dim, Frame>>>;
     140             : };
     141             : 
     142             : /*!
     143             :  * \brief Tags corresponding to various constraints of the generalized
     144             :  * harmonic system, and their diagnostically useful combinations.
     145             :  * \details For details on how these are defined and computed, see
     146             :  * `GaugeConstraintCompute`, `FConstraintCompute`, `TwoIndexConstraintCompute`,
     147             :  * `ThreeIndexConstraintCompute`, `FourIndexConstraintCompute`, and
     148             :  * `ConstraintEnergyCompute` respectively
     149             :  */
     150             : template <typename DataType, size_t SpatialDim, typename Frame>
     151           1 : struct GaugeConstraint : db::SimpleTag {
     152           0 :   using type = tnsr::a<DataType, SpatialDim, Frame>;
     153             : };
     154             : /// \copydoc GaugeConstraint
     155             : template <typename DataType, size_t SpatialDim, typename Frame>
     156           1 : struct FConstraint : db::SimpleTag {
     157           0 :   using type = tnsr::a<DataType, SpatialDim, Frame>;
     158             : };
     159             : /// \copydoc GaugeConstraint
     160             : template <typename DataType, size_t SpatialDim, typename Frame>
     161           1 : struct TwoIndexConstraint : db::SimpleTag {
     162           0 :   using type = tnsr::ia<DataType, SpatialDim, Frame>;
     163             : };
     164             : /// \copydoc GaugeConstraint
     165             : template <typename DataType, size_t SpatialDim, typename Frame>
     166           1 : struct ThreeIndexConstraint : db::SimpleTag {
     167           0 :   using type = tnsr::iaa<DataType, SpatialDim, Frame>;
     168             : };
     169             : /// \copydoc GaugeConstraint
     170             : template <typename DataType, size_t SpatialDim, typename Frame>
     171           1 : struct FourIndexConstraint : db::SimpleTag {
     172           0 :   using type = tnsr::iaa<DataType, SpatialDim, Frame>;
     173             : };
     174             : /// \copydoc GaugeConstraint
     175             : template <typename DataType, size_t SpatialDim, typename Frame>
     176           1 : struct ConstraintEnergy : db::SimpleTag {
     177           0 :   using type = Scalar<DataType>;
     178             : };
     179             : }  // namespace Tags
     180             : 
     181           1 : namespace OptionTags {
     182             : /*!
     183             :  * \ingroup OptionGroupsGroup
     184             :  * Groups option tags related to the GeneralizedHarmonic evolution system.
     185             :  */
     186           1 : struct Group {
     187           0 :   static std::string name() { return "GeneralizedHarmonic"; }
     188           0 :   static constexpr Options::String help{"Options for the GH evolution system"};
     189           0 :   using group = evolution::OptionTags::SystemGroup;
     190             : };
     191             : }  // namespace OptionTags
     192             : }  // namespace gh

Generated by: LCOV version 1.14