TimeDerivativeTerms.hpp
1 // Distributed under the MIT License.
2 // See LICENSE.txt for details.
3 
4 #pragma once
5 
8 #include "Evolution/Systems/RelativisticEuler/Valencia/TagsDeclarations.hpp"
10 #include "PointwiseFunctions/GeneralRelativity/TagsDeclarations.hpp"
11 #include "PointwiseFunctions/Hydro/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 
20 class DataVector;
21 /// \endcond
22 
24 /*!
25  * \brief Compute the time derivative of the conserved variables for the
26  * Valencia formulation of the relativistic Euler equations.
27  */
28 template <size_t Dim>
31  using type = Scalar<DataVector>;
32  };
34  using type = Scalar<DataVector>;
35  };
36 
38  using type = tnsr::I<DataVector, Dim, Frame::Inertial>;
39  };
41  using type = tnsr::II<DataVector, Dim, Frame::Inertial>;
42  };
43 
44  using temporary_tags = tmpl::list<
45  // Flux terms
47 
48  // Source terms
50 
51  // Need lapse, shift, and spatial metric to be projected to the boundary
52  // for Riemann solvers.
54 
55  using argument_tags = tmpl::list<
59 
60  // For fluxes (and maybe sources)
64 
65  // For sources
71 
72  // For Riemann solvers
74 
75  static void apply(
76  gsl::not_null<Scalar<DataVector>*> /*non_flux_terms_dt_tilde_d*/,
77  gsl::not_null<Scalar<DataVector>*> non_flux_terms_dt_tilde_tau,
78  gsl::not_null<tnsr::i<DataVector, Dim, Frame::Inertial>*>
79  non_flux_terms_dt_tilde_s,
80 
81  gsl::not_null<tnsr::I<DataVector, Dim, Frame::Inertial>*> tilde_d_flux,
82  gsl::not_null<tnsr::I<DataVector, Dim, Frame::Inertial>*> tilde_tau_flux,
83  gsl::not_null<tnsr::Ij<DataVector, Dim, Frame::Inertial>*> tilde_s_flux,
84 
85  // For fluxes
86  gsl::not_null<Scalar<DataVector>*> pressure_lapse_sqrt_det_spatial_metric,
87  gsl::not_null<Scalar<DataVector>*> transport_velocity,
88 
89  // For sources
90  gsl::not_null<tnsr::I<DataVector, Dim, Frame::Inertial>*> tilde_s_up,
91  gsl::not_null<tnsr::II<DataVector, Dim, Frame::Inertial>*>
92  densitized_stress,
93 
94  // For Riemann solvers
95  gsl::not_null<Scalar<DataVector>*> temp_lapse,
96  gsl::not_null<tnsr::I<DataVector, Dim, Frame::Inertial>*> temp_shift,
97  gsl::not_null<tnsr::ii<DataVector, Dim, Frame::Inertial>*>
98  temp_spatial_metric,
99 
100  // For fluxes and sources
101  const Scalar<DataVector>& tilde_d, const Scalar<DataVector>& tilde_tau,
102  const tnsr::i<DataVector, Dim, Frame::Inertial>& tilde_s,
103  const Scalar<DataVector>& lapse,
104  const tnsr::I<DataVector, Dim, Frame::Inertial>& shift,
105  const Scalar<DataVector>& sqrt_det_spatial_metric,
106  const Scalar<DataVector>& pressure,
107  const tnsr::I<DataVector, Dim, Frame::Inertial>& spatial_velocity,
108 
109  // For sources
110  const tnsr::i<DataVector, Dim, Frame::Inertial>& d_lapse,
111  const tnsr::iJ<DataVector, Dim, Frame::Inertial>& d_shift,
112  const tnsr::ijj<DataVector, Dim, Frame::Inertial>& d_spatial_metric,
113  const tnsr::II<DataVector, Dim, Frame::Inertial>& inv_spatial_metric,
114  const tnsr::ii<DataVector, Dim, Frame::Inertial>& extrinsic_curvature,
115 
116  // For Riemann solvers
117  const tnsr::ii<DataVector, Dim, Frame::Inertial>&
118  spatial_metric) noexcept;
119 };
120 } // namespace RelativisticEuler::Valencia
hydro::Tags::Pressure
The fluid pressure .
Definition: Tags.hpp:119
DataBoxTag.hpp
Frame::Inertial
Definition: IndexType.hpp:44
gr::Tags::SpatialMetric
Definition: Tags.hpp:26
RelativisticEuler::Valencia::TimeDerivativeTerms
Compute the time derivative of the conserved variables for the Valencia formulation of the relativist...
Definition: TimeDerivativeTerms.hpp:29
RelativisticEuler::Valencia::TimeDerivativeTerms::PressureLapseSqrtDetSpatialMetric
Definition: TimeDerivativeTerms.hpp:30
RelativisticEuler::Valencia::TimeDerivativeTerms::DensitizedStress
Definition: TimeDerivativeTerms.hpp:40
RelativisticEuler::Valencia
The Valencia formulation of the relativistic Euler System See Chapter 7 of Relativistic Hydrodynamics...
Definition: BoundaryCondition.hpp:20
db::SimpleTag
Mark a struct as a simple tag by inheriting from this.
Definition: Tag.hpp:36
RelativisticEuler::Valencia::TimeDerivativeTerms::TransportVelocity
Definition: TimeDerivativeTerms.hpp:33
gr::lapse
Scalar< DataType > lapse(const tnsr::I< DataType, SpatialDim, Frame > &shift, const tnsr::aa< DataType, SpatialDim, Frame > &spacetime_metric) noexcept
Compute lapse from shift and spacetime metric.
RelativisticEuler::Valencia::Tags::TildeTau
The densitized energy density .
Definition: Tags.hpp:33
DataVector
Stores a collection of function values.
Definition: DataVector.hpp:46
RelativisticEuler::Valencia::Tags::TildeS
The densitized momentum density .
Definition: Tags.hpp:39
gr::Tags::Shift
Definition: Tags.hpp:48
gr::shift
tnsr::I< DataType, SpatialDim, Frame > shift(const tnsr::aa< DataType, SpatialDim, Frame > &spacetime_metric, const tnsr::II< DataType, SpatialDim, Frame > &inverse_spatial_metric) noexcept
Compute shift from spacetime metric and inverse spatial metric.
Scalar
Tensor< T, Symmetry<>, index_list<> > Scalar
Definition: TypeAliases.hpp:21
TypeAliases.hpp
hydro::Tags::SpatialVelocity
The spatial velocity of the fluid, where . Here is the spatial part of the 4-velocity of the fluid,...
Definition: Tags.hpp:142
RelativisticEuler::Valencia::Tags::TildeD
The densitized rest-mass density .
Definition: Tags.hpp:28
Tags::deriv
Prefix indicating spatial derivatives.
Definition: PartialDerivatives.hpp:52
gr::spatial_metric
tnsr::ii< DataType, SpatialDim, Frame > spatial_metric(const tnsr::aa< DataType, SpatialDim, Frame > &spacetime_metric) noexcept
Compute spatial metric from spacetime metric.
gr::Tags::ExtrinsicCurvature
Definition: Tags.hpp:116
PartialDerivatives.hpp
RelativisticEuler::Valencia::TimeDerivativeTerms::TildeSUp
Definition: TimeDerivativeTerms.hpp:37
gsl
Implementations from the Guideline Support Library.
Definition: ReadSpecThirdOrderPiecewisePolynomial.hpp:11
gr::Tags::Lapse
Definition: Tags.hpp:52
TMPL.hpp
StrahlkorperGr::extrinsic_curvature
void extrinsic_curvature(gsl::not_null< tnsr::ii< DataVector, 3, Frame > * > result, const tnsr::ii< DataVector, 3, Frame > &grad_normal, const tnsr::i< DataVector, 3, Frame > &unit_normal_one_form, const tnsr::I< DataVector, 3, Frame > &unit_normal_vector) noexcept
Extrinsic curvature of a 2D Strahlkorper embedded in a 3D space.
gr::Tags::InverseSpatialMetric
Inverse of the spatial metric.
Definition: Tags.hpp:33
gsl::not_null
Require a pointer to not be a nullptr
Definition: ReadSpecThirdOrderPiecewisePolynomial.hpp:13
gr::Tags::SqrtDetSpatialMetric
Definition: Tags.hpp:44