40 calculatedFvPatchScalarField::typeName
45 for (
label i=1; i<
Y_.size(); i++)
50 if (
mag(
min(Yt).value()) < rootVSmall)
53 <<
"Sum of mass fractions is zero for species " <<
species()
75 species_(specieNames),
79 ?
dict.lookupBackwardsCompatible<
word>
81 {
"defaultSpecie",
"inertSpecie"}
88 && species_.found(defaultSpecieName_)
89 ? species_[defaultSpecieName_]
92 active_(species_.size(),
true),
95 if (species_.size() && defaultSpeciei_ == -1)
98 <<
"default specie " << defaultSpecieName_
99 <<
" not found in available species " << species_
115 if (header.headerOk())
138 if (!tYdefault.
valid())
140 const word YdefaultName
145 typeIOobject<volScalarField> timeIO
154 typeIOobject<volScalarField> constantIO
163 typeIOobject<volScalarField> time0IO
172 if (timeIO.headerOk())
176 else if (constantIO.headerOk())
205 correctMassFractions();
230 return defaultSpeciei_;
298 Y()[i].max(scalar(0));
#define forAll(list, i)
Loop across all elements in list.
Generic GeometricField class.
static tmp< GeometricField< Type, PatchField, GeoMesh > > New(const word &name, const Internal &, const PtrList< PatchField< Type >> &, const HashPtrTable< Source > &=HashPtrTable< Source >())
Return a temporary field constructed from name,.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
static word groupName(Name name, const word &group)
void size(const label)
Override size to be inconsistent with allocated storage.
static void listCombineGather(const List< commsStruct > &comms, List< T > &Value, const CombineOp &cop, const int tag, const label comm)
static void listCombineScatter(const List< commsStruct > &comms, List< T > &Value, const int tag, const label comm)
Scatter data. Reverse of combineGather.
A templated 1D list of pointers to objects of type <T>, where the size of the array is known and used...
static const word & constant()
Return constant name.
static word timeName(const scalar, const int precision=curPrecision_)
Return time name of given scalar time.
static bool & parRun()
Is this a parallel run?
virtual const fvMesh & mesh() const =0
Return const access to the mesh.
virtual const word & phaseName() const =0
Phase name.
A list of keyword definitions, which are a keyword followed by any number of values (e....
const word & name() const
Return const reference to name.
Mesh data needed to do the Finite Volume discretisation.
const Time & time() const
Return the top-level database.
A wordList with hashed indices for faster lookup by name.
void correctMassFractions()
Scale the mass fractions to sum to 1.
virtual const speciesTable & species() const
The table of species.
implementation(const dictionary &, const wordList &, const fvMesh &, const word &)
Construct from dictionary, specie names, mesh and phase name.
virtual ~implementation()
Destructor.
virtual label defaultSpecie() const
The index of the default specie.
virtual const List< bool > & speciesActive() const
Access the specie active flags.
speciesTable species_
Table of specie names.
virtual PtrList< volScalarField > & Y()
Access the mass-fraction fields.
PtrList< volScalarField > Y_
Species mass fractions.
virtual const speciesTable & species() const =0
The table of species.
bool solveSpecie(const label speciei) const
Should the given specie be solved for? I.e., is it active and.
void normaliseY()
Normalise the mass fractions by clipping positive and deriving.
virtual PtrList< volScalarField > & Y()=0
Access the mass-fraction fields.
void syncSpeciesActive() const
Synchronise the specie active flags.
virtual label defaultSpecie() const =0
The index of the default specie.
virtual ~multicomponentThermo()
Destructor.
virtual const List< bool > & speciesActive() const =0
Access the specie active flags.
A class for managing temporary objects.
bool valid() const
Is this temporary object valid,.
T & ref() const
Return non-const reference or generate a fatal error.
Templated form of IOobject providing type information for file reading and header type checking.
A class for handling words, derived from string.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const char *const group
Group name for atomic constants.
errorManipArg< error, int > exit(error &err, const int errNo=1)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const dimensionSet dimless
layerAndWeight min(const layerAndWeight &a, const layerAndWeight &b)
VolField< scalar > volScalarField
dimensioned< scalar > mag(const dimensioned< Type > &)
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.