30 template<
class ThermoType>
50 template<
class ThermoType>
57 template<
class ThermoType>
93 forAll(this->chemistry_.reactions(), i)
98 scalar omegaf, omegar;
99 const scalar omegai =
R.omega(
p,
T,
c1, li, omegaf, omegar);
110 scalar sl = -
R.lhs()[
s].stoichCoeff;
130 scalar sl =
R.rhs()[
s].stoichCoeff;
154 label curID = wAID[id];
157 scalar curwA = ((wA[id]>=0) ? wA[
id] : -wA[
id]);
163 label sj =
R.lhs()[j].index;
169 label sj =
R.rhs()[j].index;
175 deltaBi[curID] =
false;
176 while(!usedIndex.empty())
180 if (deltaBi[curIndex])
183 deltaBi[curIndex] =
false;
186 if (rABPos(curID, curIndex)==-1)
188 rABPos(curID, curIndex) = NbrABInit[curID];
190 rABNum(curID, rABPos(curID, curIndex)) = curwA;
191 rABOtherSpec(curID, rABPos(curID, curIndex)) = curIndex;
195 rABNum(curID, rABPos(curID, curIndex)) += curwA;
199 if (rABDen[curID] == 0.0)
201 rABDen[curID] = curwA;
205 rABDen[curID] +=curwA;
215 this->activeSpecies_[i] =
false;
222 for (
label i=0; i<searchInitSet_.size(); i++)
224 label q = searchInitSet_[i];
225 this->activeSpecies_[q] =
true;
233 scalar Den = rABDen[u];
237 for (
label v=0; v<NbrABInit[u]; v++)
239 label otherSpec = rABOtherSpec(u, v);
240 scalar rAB = rABNum(u, v)/Den;
251 rAB >= this->tolerance()
252 && !this->activeSpecies_[otherSpec]
256 this->activeSpecies_[otherSpec] =
true;
#define forAll(list, i)
Loop across all elements in list.
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
DynamicList< T, SizeInc, SizeMult, SizeDiv > & append(const T &)
Append an element at the end of the list.
DynamicList< T, SizeInc, SizeMult, SizeDiv > & shrink()
Shrink the allocated space to the number of elements used.
A FIFO stack based on a singly-linked list.
void push(const T &a)
Push an element onto the stack.
T pop()
Pop the bottom element off the stack.
A HashTable with keys but without contents.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
void append(const T &)
Append an element at the end of the list.
Simple extension of ThermoType to handle reaction kinetics in addition to the equilibrium thermodynam...
Extends base chemistry model by adding a thermo package, and ODE functions. Introduces chemistry equa...
An abstract class for methods of chemical mechanism reduction.
void initReduceMechanism()
Protected Member Functions.
const dictionary coeffsDict_
Dictionary that store the algorithm data.
void endReduceMechanism(List< label > &ctos, DynamicList< label > &stoc)
End reduction of the mechanism.
DRG(const IOdictionary &dict, chemistryModel< ThermoType > &chemistry)
Construct from components.
virtual void reduceMechanism(const scalar p, const scalar T, const scalarField &c, List< label > &ctos, DynamicList< label > &stoc, const label li)
Reduce the mechanism.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.name(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
const dimensionedScalar c1
First radiation constant: default SI units: [W/m^2].
const dimensionedScalar c
Speed of light in a vacuum.
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 scalar R(const scalar a, const scalar x)
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
basicChemistryModel & chemistry