36template<
class CloudType>
54 label idSolid =
owner.composition().idSolid();
55 CsLocalId_ =
owner.composition().localId(idSolid,
"C");
58 WO2_ =
owner.thermo().carrier().W(O2GlobalId_);
59 const scalar WCO2 =
owner.thermo().carrier().W(CO2GlobalId_);
62 HcCO2_ =
owner.thermo().carrier().Hc(CO2GlobalId_);
67 <<
"Stoichiometry of reaction, Sb, must be greater than zero" <<
nl
71 const scalar YCloc =
owner.composition().
Y0(idSolid)[CsLocalId_];
72 const scalar YSolidTot =
owner.composition().YMixture0()[idSolid];
73 Info<<
" C(s): particle mass fraction = " << YCloc*YSolidTot <<
endl;
77template<
class CloudType>
86 CsLocalId_(srm.CsLocalId_),
87 O2GlobalId_(srm.O2GlobalId_),
88 CO2GlobalId_(srm.CO2GlobalId_),
97template<
class CloudType>
122 const label idSolid = CloudType::parcelType::SLD;
123 const scalar fComb = YMixture[idSolid]*YSolid[CsLocalId_];
134 const scalar YO2 =
thermo.carrier().Y(O2GlobalId_)[celli];
140 dmC =
min(mass*fComb, dmC);
143 const scalar dmO2 = dmC/WC_*Sb_*WO2_;
146 const scalar dmCO2 = dmC + dmO2;
149 dMassSolid[CsLocalId_] += dmC;
152 dMassSRCarrier[O2GlobalId_] -= dmO2;
153 dMassSRCarrier[CO2GlobalId_] += dmCO2;
155 const scalar HsC =
thermo.solids().properties()[CsLocalId_].Hs(
T);
160 return dmC*HsC - dmCO2*HcCO2_;
Diffusion limited rate surface reaction model for coal parcels. Limited to:
COxidationDiffusionLimitedRate(const dictionary &dict, CloudType &owner)
Construct from dictionary.
virtual scalar calculate(const scalar dt, const scalar Re, const scalar nu, const label celli, const scalar d, const scalar T, const scalar Tc, const scalar pc, const scalar rhoc, const scalar mass, const scalarField &YGas, const scalarField &YLiquid, const scalarField &YSolid, const scalarField &YMixture, const scalar N, scalarField &dMassGas, scalarField &dMassLiquid, scalarField &dMassSolid, scalarField &dMassSRCarrier) const
Update surface reactions.
const CloudType & owner() const
Return const access to the owner cloud.
Thermo package for (S)olids (L)iquids and (G)ases Takes reference to thermo package,...
Templated surface reaction model class.
SurfaceReactionModel(CloudType &owner)
Construct null from owner.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
const dictionary & coeffDict() const
Return const access to the coefficients dictionary.
const dictionary & dict() const
Return const access to the cloud dictionary.
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
basicSpecieMixture & composition
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
constexpr scalar pi(M_PI)
Different types of constants.
DSMCCloud< dsmcParcel > CloudType
messageStream Info
Information stream (stdout output on master, null elsewhere).
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
const word GlobalIOList< Tuple2< scalar, vector > >::typeName("scalarVectorTable")
Ostream & endl(Ostream &os)
Add newline and flush stream.
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
scalarField Re(const UList< complex > &cmplx)
Extract real component.
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
errorManipArg< error, int > exit(error &err, const int errNo=1)
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
constexpr char nl
The newline '\n' character (0x0a).
scalarList Y0(nSpecie, Zero)
const Vector< label > N(dict.get< Vector< label > >("N"))