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/Prefixes.hpp" // IWYU pragma: keep 7 : #include "DataStructures/Tensor/TypeAliases.hpp" 8 : #include "Utilities/TMPL.hpp" 9 : 10 : /// \cond 11 : class DataVector; 12 : // IWYU pragma: no_forward_declare Tensor 13 : namespace Burgers { 14 : namespace Tags { 15 : struct U; 16 : } // namespace Tags 17 : } // namespace Burgers 18 : namespace gsl { 19 : template <typename T> 20 : class not_null; 21 : } // namespace gsl 22 : 23 : class DataVector; 24 : /// \endcond 25 : 26 : namespace Burgers { 27 : /// Computes the time derivative terms needed for the Burgers system, which are 28 : /// just the fluxes. 29 1 : struct TimeDerivativeTerms { 30 0 : using temporary_tags = tmpl::list<>; 31 0 : using argument_tags = tmpl::list<Tags::U>; 32 : 33 0 : static void apply( 34 : // Time derivatives returned by reference. No source terms or 35 : // nonconservative products, so not used. All the tags in the 36 : // variables_tag in the system struct. 37 : gsl::not_null<Scalar<DataVector>*> /*non_flux_terms_dt_vars*/, 38 : 39 : // Fluxes returned by reference. Listed in the system struct as 40 : // flux_variables. 41 : gsl::not_null<tnsr::I<DataVector, 1, Frame::Inertial>*> flux_u, 42 : 43 : // Arguments listed in argument_tags above 44 : const Scalar<DataVector>& u); 45 : }; 46 : } // namespace Burgers