60int main(
int argc,
char *argv[])
64 "Calculate the equilibrium level of carbon monoxide."
67 argList::noParallel();
68 argList::noFunctionObjects();
73 Info<<
nl <<
"Reading thermodynamic data IOdictionary" <<
endl;
82 IOobject::MUST_READ_IF_MODIFIED,
91 const scalar
T = 3000.0;
94 thermo O2(thermoData.subDict(
"O2")); O2 *= O2.W();
98 thermo H2(thermoData.subDict(
"H2")); H2 *= H2.W();
99 thermo OH(thermoData.subDict(
"OH")); OH *= OH.W();
100 thermo H(thermoData.subDict(
"H"));
H *=
H.W();
101 thermo O(thermoData.subDict(
"O")); O *= O.W();
104 thermo CO2(thermoData.subDict(
"CO2")); CO2 *= CO2.W();
106 thermo CO(thermoData.subDict(
"CO")); CO *= CO.W();
112 new thermo(CO2 == CO + 0.5*O2)
131 for (
const thermo& react : EQreactions)
133 Info<<
"Kc(EQreactions) = " << react.Kc(P,
T) <<
endl;
Istream and Ostream manipulators taking arguments.
Functions used by OpenFOAM that are specific to POSIX compliant operating systems and need to be repl...
Non-intrusive singly-linked pointer list.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Defines the attributes of an object for which implicit objectRegistry management is supported,...
void append(const T &elem)
Add copy at back of list.
Template class for non-intrusive linked PtrLists.
Thermodynamics mapping class to expose the absolute enthalpy functions.
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
scalar W() const
Molecular weight [kg/kmol].
volScalarField H(IOobject("H", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE), mesh, dimensionedScalar(dimLength, Zero))
messageStream Info
Information stream (stdout output on master, null elsewhere)
Ostream & endl(Ostream &os)
Add newline and flush stream.
constexpr char nl
The newline '\n' character (0x0a)