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/Tensor/EagerMath/Magnitude.hpp"
9 : #include "DataStructures/VariablesTag.hpp"
10 : #include "Evolution/Systems/GeneralizedHarmonic/System.hpp"
11 : #include "Evolution/Systems/GrMhd/GhValenciaDivClean/BoundaryConditions/BoundaryCondition.hpp"
12 : #include "Evolution/Systems/GrMhd/GhValenciaDivClean/Characteristics.hpp"
13 : #include "Evolution/Systems/GrMhd/GhValenciaDivClean/Tags.hpp"
14 : #include "Evolution/Systems/GrMhd/ValenciaDivClean/ConservativeFromPrimitive.hpp"
15 : #include "Evolution/Systems/GrMhd/ValenciaDivClean/NewmanHamlin.hpp"
16 : #include "Evolution/Systems/GrMhd/ValenciaDivClean/PrimitiveFromConservative.hpp"
17 : #include "Evolution/Systems/GrMhd/ValenciaDivClean/System.hpp"
18 : #include "Evolution/Systems/GrMhd/ValenciaDivClean/Tags.hpp"
19 : #include "Evolution/Systems/GrMhd/ValenciaDivClean/TimeDerivativeTerms.hpp"
20 : #include "PointwiseFunctions/GeneralRelativity/Tags.hpp"
21 : #include "PointwiseFunctions/Hydro/Tags.hpp"
22 : #include "Utilities/TMPL.hpp"
23 :
24 : namespace grmhd {
25 :
26 : /// Namespace associated with utilities for the combined Generalized Harmonic
27 : /// and Valencia formulation of ideal GRMHD with divergence cleaning systems.
28 : namespace GhValenciaDivClean {
29 : /// \cond
30 : struct TimeDerivativeTerms;
31 : /// \endcond
32 :
33 : template <typename NeutrinoTransportSystem>
34 : struct System;
35 :
36 : template <typename NeutrinoTransportSystem>
37 0 : struct System {
38 0 : static std::string name() { return "GhValenciaDivClean"; }
39 :
40 0 : using boundary_conditions_base = BoundaryConditions::BoundaryCondition;
41 0 : static constexpr bool has_primitive_and_conservative_vars = true;
42 0 : static constexpr size_t volume_dim = 3;
43 0 : using grmhd_system = grmhd::ValenciaDivClean::System;
44 0 : using gh_system = gh::System<3_st>;
45 0 : using neutrino_transport_system = NeutrinoTransportSystem;
46 :
47 : static_assert(std::is_same_v<Tags::spacetime_reconstruction_tags,
48 : typename gh_system::variables_tag::tags_list>);
49 :
50 0 : using variables_tag = ::Tags::Variables<
51 : tmpl::append<typename gh_system::variables_tag::tags_list,
52 : typename grmhd_system::variables_tag::tags_list>>;
53 0 : using non_conservative_variables =
54 : typename gh_system::variables_tag::tags_list;
55 0 : using flux_variables = tmpl::append<typename gh_system::flux_variables,
56 : typename grmhd_system::flux_variables>;
57 0 : using gradient_variables =
58 : tmpl::append<typename gh_system::gradient_variables,
59 : typename grmhd_system::gradient_variables>;
60 0 : using gradients_tags = gradient_variables;
61 0 : static constexpr bool is_in_flux_conservative_form = false;
62 :
63 0 : using primitive_variables_tag =
64 : typename grmhd_system::primitive_variables_tag;
65 0 : using spacetime_variables_tag = ::Tags::Variables<
66 : tmpl::list<::Tags::deriv<gr::Tags::Lapse<DataVector>, tmpl::size_t<3>,
67 : Frame::Inertial>,
68 : ::Tags::deriv<gr::Tags::Shift<DataVector, 3>, tmpl::size_t<3>,
69 : Frame::Inertial>,
70 : ::Tags::deriv<gr::Tags::SpatialMetric<DataVector, 3>,
71 : tmpl::size_t<3>, Frame::Inertial>,
72 : gr::Tags::ExtrinsicCurvature<DataVector, 3>>>;
73 :
74 0 : using compute_volume_time_derivative_terms = TimeDerivativeTerms;
75 :
76 0 : using conservative_from_primitive =
77 : typename grmhd_system::conservative_from_primitive;
78 : template <typename OrderedListOfPrimitiveRecoverySchemes>
79 0 : using primitive_from_conservative =
80 : typename grmhd_system::template primitive_from_conservative<
81 : OrderedListOfPrimitiveRecoverySchemes>;
82 :
83 0 : using compute_largest_characteristic_speed =
84 : Tags::ComputeLargestCharacteristicSpeed<>;
85 :
86 0 : using inverse_spatial_metric_tag =
87 : typename gh_system::inverse_spatial_metric_tag;
88 : };
89 : } // namespace GhValenciaDivClean
90 : } // namespace grmhd
|