33template<
class ThermoType>
44 new ThermoType(
thermoDict.subDict(species_[i]))
48 return speciesData_[0];
52template<
class ThermoType>
58 for (label
n=1;
n<Y_.size();
n++)
63 if (
mag(
min(
Yt).value()) < ROOTVSMALL)
66 <<
"Sum of mass fractions is zero for species " << this->species()
70 if (
mag(
max(
Yt).value()) != scalar(1))
73 <<
"Sum of mass fractions is different from one for species "
87template<
class ThermoType>
98 speciesData_(species_.size()),
99 mixture_(
"mixture", *thermoData[specieNames[0]]),
100 mixtureVol_(
"volMixture", *thermoData[specieNames[0]])
107 new ThermoType(*thermoData[
species_[i]])
111 correctMassFractions();
115template<
class ThermoType>
120 const word& phaseName
130 speciesData_(species_.size()),
131 mixture_(
"mixture", constructSpeciesData(
thermoDict)),
132 mixtureVol_(
"volMixture", speciesData_[0])
134 correctMassFractions();
140template<
class ThermoType>
146 mixture_ = Y_[0][celli]*speciesData_[0];
148 for (label
n=1;
n<Y_.size();
n++)
150 mixture_ += Y_[
n][celli]*speciesData_[
n];
157template<
class ThermoType>
164 mixture_ = Y_[0].boundaryField()[patchi][facei]*speciesData_[0];
166 for (label
n=1;
n<Y_.size();
n++)
168 mixture_ += Y_[
n].boundaryField()[patchi][facei]*speciesData_[
n];
175template<
class ThermoType>
186 rhoInv += Y_[i][celli]/speciesData_[i].rho(
p,
T);
190 Y_[0][celli]/speciesData_[0].rho(
p,
T)/rhoInv*speciesData_[0];
192 for (label
n=1;
n<Y_.size();
n++)
195 Y_[
n][celli]/speciesData_[
n].rho(
p,
T)/rhoInv*speciesData_[
n];
202template<
class ThermoType>
216 Y_[i].boundaryField()[patchi][facei]/speciesData_[i].rho(
p,
T);
220 Y_[0].boundaryField()[patchi][facei]/speciesData_[0].rho(
p,
T)/rhoInv
223 for (label
n=1;
n<Y_.size();
n++)
226 Y_[
n].boundaryField()[patchi][facei]/speciesData_[
n].rho(
p,
T)
227 / rhoInv*speciesData_[
n];
234template<
class ThermoType>
volScalarField Yt(0.0 *Y[0])
const T * set(const label i) const
virtual bool read()
Re-read model coefficients if they have changed.
speciesTable species_
Table of specie names.
Specialization of basicMultiComponentMixture for a mixture consisting of a number for molecular speci...
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
const dictionary & subDict(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a sub-dictionary.
Mesh data needed to do the Finite Volume discretisation.
Foam::multiComponentMixture.
const ThermoType & cellMixture(const label celli) const
const ThermoType & cellVolMixture(const scalar p, const scalar T, const label celli) const
const ThermoType & patchFaceMixture(const label patchi, const label facei) const
const ThermoType & patchFaceVolMixture(const scalar p, const scalar T, const label patchi, const label facei) const
Lookup type of boundary radiation properties.
A class for handling words, derived from Foam::string.
const dictionary & thermoDict
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
#define WarningInFunction
Report a warning using Foam::Warning.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
errorManipArg< error, int > exit(error &err, const int errNo=1)
constexpr char nl
The newline '\n' character (0x0a)
#define forAll(list, i)
Loop across all elements in list.