8#include <compile_time_options.h>
12#include <deal.II/base/array_view.h>
13#include <deal.II/base/exceptions.h>
14#include <deal.II/base/parameter_acceptor.h>
15#include <deal.II/base/tensor.h>
21 namespace EquationOfStateLibrary
38 : ParameterAcceptor(subsection +
"/" + name)
71 virtual double pressure(
double rho,
double e)
const = 0;
83 virtual void pressure(
const dealii::ArrayView<double> &p,
84 const dealii::ArrayView<double> &rho,
85 const dealii::ArrayView<double> &e)
const
87 Assert(p.size() == rho.size() && rho.size() == e.size(),
88 dealii::ExcMessage(
"vectors have different size"));
90 std::transform(std::begin(rho),
94 [&](
double rho,
double e) {
return pressure(rho, e); });
115 const dealii::ArrayView<double> &rho,
116 const dealii::ArrayView<double> &p)
const
118 Assert(p.size() == rho.size() && rho.size() == e.size(),
119 dealii::ExcMessage(
"vectors have different size"));
121 std::transform(std::begin(rho),
125 [&](
double rho,
double p) {
147 const dealii::ArrayView<double> &rho,
148 const dealii::ArrayView<double> &e)
const
150 Assert(T.size() == rho.size() && rho.size() == e.size(),
151 dealii::ExcMessage(
"vectors have different size"));
158 [&](
double rho,
double e) {
return temperature(rho, e); });
178 const dealii::ArrayView<double> &rho,
179 const dealii::ArrayView<double> &e)
const
181 Assert(c.size() == rho.size() && rho.size() == e.size(),
182 dealii::ExcMessage(
"vectors have different size"));
232 const std::string name_;
virtual double specific_internal_energy(double rho, double p) const =0
virtual void pressure(const dealii::ArrayView< double > &p, const dealii::ArrayView< double > &rho, const dealii::ArrayView< double > &e) const
virtual double pressure(double rho, double e) const =0
virtual void specific_internal_energy(const dealii::ArrayView< double > &e, const dealii::ArrayView< double > &rho, const dealii::ArrayView< double > &p) const
virtual void speed_of_sound(const dealii::ArrayView< double > &c, const dealii::ArrayView< double > &rho, const dealii::ArrayView< double > &e) const
virtual double speed_of_sound(double rho, double e) const =0
virtual double temperature(double rho, double e) const =0
EquationOfState(const std::string &name, const std::string &subsection)
bool prefer_vector_interface_
virtual void temperature(const dealii::ArrayView< double > &T, const dealii::ArrayView< double > &rho, const dealii::ArrayView< double > &e) const
double interpolation_pinfty_
#define ACCESSOR_READ_ONLY(member)