Line data Source code
1 : #ifndef MODEL_GAS_EOS_CPG_H_
2 : #define MODEL_GAS_EOS_CPG_H_
3 :
4 : #include "IO/ParmParse.H"
5 : #include "Model/Gas/EOS/EOS.H"
6 : #include <memory>
7 :
8 : namespace Model {
9 : namespace Gas {
10 : class Gas; // Forward declare Gas
11 :
12 : namespace EOS {
13 :
14 : class CPG : public EOS {
15 : public:
16 : static constexpr const char* name = "cpg";
17 8 : virtual const char* model_name() const override { return name; }
18 :
19 : private:
20 : Gas const * const gas;
21 :
22 : public:
23 : CPG() = delete;
24 8 : CPG(Gas *a_gas, IO::ParmParse& pp, std::string name) : gas(a_gas)
25 : {
26 8 : pp.queryclass(name, *this);
27 8 : }
28 :
29 16 : ~CPG() override = default;
30 :
31 8 : static void Parse(CPG & /*value*/, IO::ParmParse & /*pp*/) {}
32 :
33 : public:
34 : double ComputeT(double density, double momentumx, double momentumy, double E, double Tguess,
35 : Set::Patch<const Set::Scalar>& X, int i, int j, int k, double /*rtol=1e-12*/) const override;
36 : double ComputeT(double pressure, double density,
37 : Set::Patch<const Set::Scalar>& X, int i, int j, int k) const override;
38 : double ComputeP(double density, double T,
39 : Set::Patch<const Set::Scalar>& X, int i, int j, int k) const override;
40 : double ComputeE(double density, double momentumx, double momentumy, double T,
41 : Set::Patch<const Set::Scalar>& X, int i, int j, int k) const override;
42 :
43 : }; // class CPG
44 :
45 : } // namespace EOS
46 : } // namespace Gas
47 : } // namespace Model
48 :
49 : #endif
|