SpECTRE Documentation Coverage Report
Current view: top level - Evolution/Systems/ForceFree - TimeDerivativeTerms.hpp Coverage Total Hit
Commit: 0d1d717af84a81fb1284a20c4013708fe85cc2f0 Lines: 9.1 % 11 1
Test Date: 2026-10-22 17:29:42
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 "DataStructures/DataBox/DataBoxTag.hpp"
       7              : #include "DataStructures/Tensor/TypeAliases.hpp"
       8              : #include "Evolution/DiscontinuousGalerkin/TimeDerivativeDecisions.hpp"
       9              : #include "Evolution/Systems/ForceFree/Tags.hpp"
      10              : #include "NumericalAlgorithms/LinearOperators/PartialDerivatives.hpp"
      11              : #include "PointwiseFunctions/GeneralRelativity/TagsDeclarations.hpp"
      12              : #include "Utilities/TMPL.hpp"
      13              : 
      14              : /// \cond
      15              : namespace gsl {
      16              : template <typename T>
      17              : class not_null;
      18              : }  // namespace gsl
      19              : /// \endcond
      20              : 
      21              : namespace ForceFree {
      22              : 
      23              : /*!
      24              :  * \brief Compute the time derivative of the conserved variables for the GRFFE
      25              :  * equations with divergence cleaning.
      26              :  *
      27              :  */
      28            1 : struct TimeDerivativeTerms {
      29            0 :   struct LapseTimesElectricFieldOneForm : db::SimpleTag {
      30            0 :     using type = tnsr::i<DataVector, 3, Frame::Inertial>;
      31              :   };
      32            0 :   struct LapseTimesMagneticFieldOneForm : db::SimpleTag {
      33            0 :     using type = tnsr::i<DataVector, 3, Frame::Inertial>;
      34              :   };
      35            0 :   struct TildeJDrift : db::SimpleTag {
      36            0 :     using type = tnsr::I<DataVector, 3, Frame::Inertial>;
      37              :   };
      38              : 
      39            0 :   using temporary_tags = tmpl::list<
      40              :       // Flux terms
      41              :       LapseTimesElectricFieldOneForm, LapseTimesMagneticFieldOneForm,
      42              : 
      43              :       // Source terms
      44              :       TildeJDrift, gr::Tags::SpatialChristoffelFirstKind<DataVector, 3>,
      45              :       gr::Tags::SpatialChristoffelSecondKind<DataVector, 3>,
      46              :       gr::Tags::TraceSpatialChristoffelSecondKind<DataVector, 3>,
      47              : 
      48              :       // Need lapse, shift, and inverse spatial metric to be projected to
      49              :       // the boundary for Riemann solvers.
      50              :       gr::Tags::Lapse<DataVector>, gr::Tags::Shift<DataVector, 3>,
      51              :       gr::Tags::InverseSpatialMetric<DataVector, 3>>;
      52              : 
      53            0 :   using argument_tags = tmpl::list<
      54              :       // EM tags
      55              :       Tags::TildeE, Tags::TildeB, Tags::TildePsi, Tags::TildePhi, Tags::TildeQ,
      56              :       Tags::TildeJ, Tags::KappaPsi, Tags::KappaPhi, Tags::ParallelConductivity,
      57              : 
      58              :       // GR-related tags
      59              :       gr::Tags::Lapse<DataVector>, gr::Tags::Shift<DataVector, 3>,
      60              :       gr::Tags::SqrtDetSpatialMetric<DataVector>,
      61              :       gr::Tags::SpatialMetric<DataVector, 3>,
      62              :       gr::Tags::InverseSpatialMetric<DataVector, 3>,
      63              :       gr::Tags::ExtrinsicCurvature<DataVector, 3>,
      64              :       ::Tags::deriv<gr::Tags::Lapse<DataVector>, tmpl::size_t<3>,
      65              :                     Frame::Inertial>,
      66              :       ::Tags::deriv<gr::Tags::Shift<DataVector, 3>, tmpl::size_t<3>,
      67              :                     Frame::Inertial>,
      68              :       ::Tags::deriv<gr::Tags::SpatialMetric<DataVector, 3>, tmpl::size_t<3>,
      69              :                     Frame::Inertial>>;
      70              : 
      71            0 :   static evolution::dg::TimeDerivativeDecisions<3> apply(
      72              :       // Time derivatives returned by reference.
      73              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*>
      74              :           non_flux_terms_dt_tilde_e,
      75              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*>
      76              :           non_flux_terms_dt_tilde_b,
      77              :       gsl::not_null<Scalar<DataVector>*> non_flux_terms_dt_tilde_psi,
      78              :       gsl::not_null<Scalar<DataVector>*> non_flux_terms_dt_tilde_phi,
      79              :       gsl::not_null<Scalar<DataVector>*> /*non_flux_terms_dt_tilde_q*/,
      80              : 
      81              :       // Fluxes returned by reference. Listed in the system struct as
      82              :       // flux_variables.
      83              :       gsl::not_null<tnsr::IJ<DataVector, 3, Frame::Inertial>*> tilde_e_flux,
      84              :       gsl::not_null<tnsr::IJ<DataVector, 3, Frame::Inertial>*> tilde_b_flux,
      85              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*> tilde_psi_flux,
      86              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*> tilde_phi_flux,
      87              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*> tilde_q_flux,
      88              : 
      89              :       // temporary tags
      90              :       gsl::not_null<tnsr::i<DataVector, 3, Frame::Inertial>*>
      91              :           lapse_times_electric_field_one_form,
      92              :       gsl::not_null<tnsr::i<DataVector, 3, Frame::Inertial>*>
      93              :           lapse_times_magnetic_field_one_form,
      94              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*> tilde_j_drift,
      95              :       gsl::not_null<tnsr::ijj<DataVector, 3, Frame::Inertial>*>
      96              :           spatial_christoffel_first_kind,
      97              :       gsl::not_null<tnsr::Ijj<DataVector, 3, Frame::Inertial>*>
      98              :           spatial_christoffel_second_kind,
      99              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*>
     100              :           trace_spatial_christoffel_second,
     101              : 
     102              :       gsl::not_null<Scalar<DataVector>*> temp_lapse,
     103              :       gsl::not_null<tnsr::I<DataVector, 3, Frame::Inertial>*> temp_shift,
     104              :       gsl::not_null<tnsr::II<DataVector, 3, Frame::Inertial>*>
     105              :           temp_inverse_spatial_metric,
     106              : 
     107              :       // argument tags
     108              :       const tnsr::I<DataVector, 3, Frame::Inertial>& tilde_e,
     109              :       const tnsr::I<DataVector, 3, Frame::Inertial>& tilde_b,
     110              :       const Scalar<DataVector>& tilde_psi, const Scalar<DataVector>& tilde_phi,
     111              :       const Scalar<DataVector>& tilde_q,
     112              :       const tnsr::I<DataVector, 3, Frame::Inertial>& tilde_j,
     113              :       const double kappa_psi, const double kappa_phi,
     114              :       const double parallel_conductivity,
     115              : 
     116              :       const Scalar<DataVector>& lapse,
     117              :       const tnsr::I<DataVector, 3, Frame::Inertial>& shift,
     118              :       const Scalar<DataVector>& sqrt_det_spatial_metric,
     119              :       const tnsr::ii<DataVector, 3, Frame::Inertial>& spatial_metric,
     120              :       const tnsr::II<DataVector, 3, Frame::Inertial>& inv_spatial_metric,
     121              :       const tnsr::ii<DataVector, 3, Frame::Inertial>& extrinsic_curvature,
     122              :       const tnsr::i<DataVector, 3, Frame::Inertial>& d_lapse,
     123              :       const tnsr::iJ<DataVector, 3, Frame::Inertial>& d_shift,
     124              :       const tnsr::ijj<DataVector, 3, Frame::Inertial>& d_spatial_metric);
     125              : };
     126              : 
     127              : }  // namespace ForceFree
        

Generated by: LCOV version 2.0-1