ryujin 2.1.1 revision 0348cbb53a3e4b1da2a4c037e81f88f2d21ce219
equation_of_state_pressureless.h
Go to the documentation of this file.
1//
2// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
3// Copyright (C) 2023 by the ryujin authors
4//
5
6#pragma once
7
8#include "equation_of_state.h"
9
10namespace ryujin
11{
12 namespace EquationOfStateLibrary
13 {
20 {
21 public:
26
27 Pressureless(const std::string &subsection)
28 : EquationOfState("pressureless", subsection)
29 {
30 gamma_ = 7. / 5.;
31 this->add_parameter("gamma", gamma_, "The ratio of specific heats");
32 }
33
40 double pressure(double rho [[maybe_unused]],
41 double e [[maybe_unused]]) const final
42 {
43 return 0.0;
44 }
45
52 double specific_internal_energy(double rho [[maybe_unused]],
53 double p [[maybe_unused]]) const final
54 {
55 return 0.0;
56 }
57
64 double temperature(double /*rho*/, double e [[maybe_unused]]) const final
65 {
66 return 0.0;
67 }
68
75 double speed_of_sound(double /*rho*/,
76 double e [[maybe_unused]]) const final
77 {
78 return 0.0;
79 }
80
81 private:
82 double gamma_;
83 };
84 } // namespace EquationOfStateLibrary
85} // namespace ryujin
virtual double specific_internal_energy(double rho, double p) const =0
virtual double pressure(double rho, double e) const =0
virtual double speed_of_sound(double rho, double e) const =0
virtual double temperature(double rho, double e) const =0
double specific_internal_energy(double rho, double p) const final
double pressure(double rho, double e) const final