31 template<
class EquationOfState>
37 <<
"Tlow(" << Tlow_ <<
") >= Thigh(" << Thigh_ <<
')' 41 if (Tcommon_ <= Tlow_)
44 <<
"Tcommon(" << Tcommon_ <<
") <= Tlow(" << Tlow_ <<
')' 48 if (Tcommon_ > Thigh_)
51 <<
"Tcommon(" << Tcommon_ <<
") > Thigh(" << Thigh_ <<
')' 59 template<
class EquationOfState>
62 EquationOfState(dict),
66 highCpCoeffs_(dict.subDict(
"thermodynamics").
lookup(
"highCpCoeffs")),
67 lowCpCoeffs_(dict.subDict(
"thermodynamics").
lookup(
"lowCpCoeffs"))
72 highCpCoeffs_[coefLabel] *= this->
R();
73 lowCpCoeffs_[coefLabel] *= this->
R();
82 template<
class EquationOfState>
92 highCpCoeffs[coefLabel] = highCpCoeffs_[coefLabel]/this->
R();
93 lowCpCoeffs[coefLabel] = lowCpCoeffs_[coefLabel]/this->
R();
97 dict.
add(
"Tlow", Tlow_);
98 dict.
add(
"Thigh", Thigh_);
99 dict.
add(
"Tcommon", Tcommon_);
100 dict.
add(
"highCpCoeffs", highCpCoeffs);
101 dict.
add(
"lowCpCoeffs", lowCpCoeffs);
108 template<
class EquationOfState>
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
static const int nCoeffs_
Ostream & indent(Ostream &os)
Indent stream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const coeffArray & highCpCoeffs() const
Return const access to the high temperature poly coefficients.
bool add(entry *, bool mergeEntry=false)
Add a new entry.
const word dictName() const
Return the local dictionary name (final part of scoped name)
Useful combination of include files which define Sin, Sout and Serr and the use of IO streams general...
stressControl lookup("compactNormalStress") >> compactNormalStress
void write(Ostream &os) const
Write to Ostream.
janafThermo(const EquationOfState &st, const scalar Tlow, const scalar Thigh, const scalar Tcommon, const coeffArray &highCpCoeffs, const coeffArray &lowCpCoeffs, const bool convertCoeffs=false)
Construct from components.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
#define R(A, B, C, D, E, F, K, M)
const coeffArray & lowCpCoeffs() const
Return const access to the low temperature poly coefficients.
JANAF tables based thermodynamics package templated into the equation of state.
virtual Ostream & write(const token &)=0
Write next token to stream.