SpECTRE Documentation Coverage Report
Current view: top level - Evolution/Systems/ScalarTensor - System.hpp Hit Total Coverage
Commit: 965048f86d23c819715b3af1ca3f880c8145d4bb Lines: 1 16 6.2 %
Date: 2024-05-16 17:00:40
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 <cstddef>
       7             : 
       8             : #include "DataStructures/VariablesTag.hpp"
       9             : #include "Evolution/Systems/CurvedScalarWave/System.hpp"
      10             : #include "Evolution/Systems/GeneralizedHarmonic/System.hpp"
      11             : #include "Evolution/Systems/ScalarTensor/BoundaryConditions/BoundaryCondition.hpp"
      12             : #include "Evolution/Systems/ScalarTensor/BoundaryCorrections/BoundaryCorrection.hpp"
      13             : #include "Evolution/Systems/ScalarTensor/Characteristics.hpp"
      14             : #include "Evolution/Systems/ScalarTensor/Tags.hpp"
      15             : #include "Evolution/Systems/ScalarTensor/TimeDerivative.hpp"
      16             : #include "PointwiseFunctions/GeneralRelativity/Tags.hpp"
      17             : #include "Utilities/TMPL.hpp"
      18             : 
      19             : /*!
      20             :  * \ingroup EvolutionSystemsGroup
      21             :  * \brief Items related to evolving the first-order scalar tensor system.
      22             :  */
      23             : namespace ScalarTensor {
      24             : /*!
      25             :  * \brief Scalar Tensor system obtained from combining the CurvedScalarWave and
      26             :  * gh systems.
      27             :  *
      28             :  * \details The evolution equations follow from
      29             :  * \f{align*}{
      30             :  *  R_{ab} &= 8 \pi \, T^{(\Psi, \text{TR})}_{ab} ~, \\
      31             :  *  \Box \Psi &= 0~,
      32             :  * \f}
      33             :  *
      34             :  * where \f$\Psi\f$ is the scalar field and the trace-reversed stress-energy
      35             :  * tensor of the scalar field is given by
      36             :  * \f{align*}{
      37             :     T^{(\Psi, \text{TR})}_{ab}
      38             :  *      &\equiv T^{(\Psi)}_{ab} - \frac{1}{2} g_{ab} g^{cd} T^{(\Psi)}_{cd} \\
      39             :  *      &= \partial_a \Psi \partial_b \Psi ~.
      40             :  * \f}
      41             :  *
      42             :  * Both systems are recast as first-order systems in terms of the variables
      43             :  * \f{align*}{
      44             :  * & g_{ab}~,                                                           \\
      45             :  * & \Pi_{ab} = - \dfrac{1}{\alpha} \left( \partial_t g_{ab} - \beta^k
      46             :  * \partial_k g_{ab} \right)~,                                          \\
      47             :  * & \Phi_{iab} = \partial_i g_{ab}~,                                   \\
      48             :  * & \Psi~,                                                             \\
      49             :  * & \Pi = - \dfrac{1}{\alpha} \left(\partial_t \Psi - \beta^k
      50             :  * \partial_k \Psi \right)~,                                            \\
      51             :  * & \Phi_i = \partial_i \Psi~,
      52             :  * \f}
      53             :  *
      54             :  * where \f$ \alpha \f$ and \f$ \beta^k \f$ are the lapse and shift.
      55             :  *
      56             :  * The computation of the evolution equations is implemented in each system in
      57             :  * gh::TimeDerivative and CurvedScalarWave::TimeDerivative, respectively. We
      58             :  * take the additional step of adding the contribution of the trace-reversed
      59             :  * stress-energy tensor to the evolution equations of the metric.
      60             :  *
      61             :  * \note Although both systems are templated in the spatial dimension, we
      62             :  * only implement this system in three spatial dimensions.
      63             :  */
      64           1 : struct System {
      65           0 :   using boundary_conditions_base = BoundaryConditions::BoundaryCondition;
      66           0 :   using boundary_correction_base = BoundaryCorrections::BoundaryCorrection;
      67           0 :   static constexpr bool has_primitive_and_conservative_vars = false;
      68           0 :   static constexpr size_t volume_dim = 3;
      69             : 
      70           0 :   using gh_system = gh::System<3_st>;
      71           0 :   using scalar_system = CurvedScalarWave::System<3_st>;
      72             : 
      73           0 :   using variables_tag = ::Tags::Variables<
      74             :       tmpl::append<typename gh_system::variables_tag::tags_list,
      75             :                    typename scalar_system::variables_tag::tags_list>>;
      76             : 
      77           0 :   using flux_variables = tmpl::append<typename gh_system::flux_variables,
      78             :                                       typename scalar_system::flux_variables>;
      79             : 
      80           0 :   using gradient_variables =
      81             :       tmpl::append<typename gh_system::gradient_variables,
      82             :                    typename scalar_system::gradient_variables>;
      83           0 :   using gradients_tags = gradient_variables;
      84             : 
      85           0 :   static constexpr bool is_in_flux_conservative_form = false;
      86             : 
      87           0 :   using compute_largest_characteristic_speed =
      88             :       Tags::ComputeLargestCharacteristicSpeed<>;
      89             : 
      90           0 :   using compute_volume_time_derivative_terms = ScalarTensor::TimeDerivative;
      91           0 :   using inverse_spatial_metric_tag =
      92             :       typename gh_system::inverse_spatial_metric_tag;
      93             : };
      94             : 
      95             : }  // namespace ScalarTensor

Generated by: LCOV version 1.14