31 template<
class ChemistryModel>
42 IOobject::groupName(
"chemistryProperties", phaseName),
51 word chemistryTypeName;
53 if (chemistryDict.
isDict(
"chemistryType"))
57 chemistryDict.
subDict(
"chemistryType")
60 Info<<
"Selecting chemistry type " << chemistryTypeDict <<
endl;
63 const char* cmptNames[nCmpt] =
81 IOobject::MUST_READ_IF_MODIFIED,
89 if (thermoDict.
isDict(
"thermoType"))
93 word(thermoTypeDict.lookup(
"transport")) +
'<' 94 +
word(thermoTypeDict.lookup(
"thermo")) +
'<' 95 +
word(thermoTypeDict.lookup(
"equationOfState")) +
'<' 96 +
word(thermoTypeDict.lookup(
"specie")) +
">>," 97 +
word(thermoTypeDict.lookup(
"energy")) +
">";
102 <<
"thermoType is in the old format and must be upgraded" 108 word(chemistryTypeDict.lookup(
"chemistrySolver")) +
'<' 109 +
word(chemistryTypeDict.lookup(
"chemistryThermo")) +
',' 110 + thermoTypeName +
">";
112 typename ChemistryModel::fvMeshConstructorTable::iterator cstrIter =
113 ChemistryModel::fvMeshConstructorTablePtr_->find(chemistryTypeName);
115 if (cstrIter == ChemistryModel::fvMeshConstructorTablePtr_->end())
118 <<
"Unknown " << ChemistryModel::typeName <<
" type " <<
nl 119 <<
"chemistryType" << chemistryTypeDict <<
nl <<
nl 120 <<
"Valid " << ChemistryModel ::typeName <<
" types are:" 126 ChemistryModel::fvMeshConstructorTablePtr_->sortedToc()
133 validChemistryTypeNames.
size() + 1
136 validChemistryTypeNameCmpts[0].
setSize(nCmpt);
137 forAll(validChemistryTypeNameCmpts[0], j)
139 validChemistryTypeNameCmpts[0][j] = cmptNames[j];
143 forAll(validChemistryTypeNames, i)
145 validChemistryTypeNameCmpts[i+1] = basicThermo::splitThermoName
147 validChemistryTypeNames[i],
166 Info<<
"Selecting chemistry type " << chemistryTypeName <<
endl;
168 typename ChemistryModel::fvMeshConstructorTable::iterator cstrIter =
169 ChemistryModel::fvMeshConstructorTablePtr_->find(chemistryTypeName);
171 if (cstrIter == ChemistryModel::fvMeshConstructorTablePtr_->end())
174 <<
"Unknown " << ChemistryModel::typeName <<
" type " 175 << chemistryTypeName <<
nl <<
nl 176 <<
"Valid ChemistryModel types are:" <<
nl 177 << ChemistryModel::fvMeshConstructorTablePtr_->sortedToc() <<
nl #define forAll(list, i)
Loop across all elements in list.
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.
void size(const label)
Override size to be inconsistent with allocated storage.
const dictionary & subDict(const word &) const
Find and return a sub-dictionary.
bool isDict(const word &) const
Check if entry is a sub-dictionary.
Ostream & endl(Ostream &os)
Add newline and flush stream.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
A class for handling words, derived from string.
static autoPtr< Thermo > New(const fvMesh &mesh, const word &phaseName)
Generic New for each of the related chemistry model.
const word & constant() const
Return constant name.
void printTable(const List< wordList > &, List< string::size_type > &, Ostream &)
void setSize(const label)
Reset size of List.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
word dictName("noiseDict")
Mesh data needed to do the Finite Volume discretisation.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
const Time & time() const
Return the top-level database.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.