31 template<
class CloudType>
34 template<
class CloudType>
40 template<
class CloudType>
57 O2GlobalId_(owner.composition().carrierId(
"O2")),
58 CO2GlobalId_(owner.composition().carrierId(
"CO2")),
64 label idSolid = owner.composition().idSolid();
65 CsLocalId_ = owner.composition().localId(idSolid,
"C");
68 WO2_ = owner.thermo().carrier().W(O2GlobalId_);
69 const scalar WCO2 = owner.thermo().carrier().W(CO2GlobalId_);
72 HcCO2_ = owner.thermo().carrier().Hc(CO2GlobalId_);
74 const scalar YCloc = owner.composition().Y0(idSolid)[CsLocalId_];
75 const scalar YSolidTot = owner.composition().YMixture0()[idSolid];
76 Info<<
" C(s): particle mass fraction = " << YCloc*YSolidTot <<
endl;
80 template<
class CloudType>
95 CsLocalId_(srm.CsLocalId_),
96 O2GlobalId_(srm.O2GlobalId_),
97 CO2GlobalId_(srm.CO2GlobalId_),
106 template<
class CloudType>
113 template<
class CloudType>
136 const label idSolid = CloudType::parcelType::SLD;
137 const scalar fComb = YMixture[idSolid]*YSolid[CsLocalId_];
148 const scalar rhoO2 = rhoc*thermo.
carrier().
Y(O2GlobalId_)[cellI];
160 const scalar D = D0_*(rho0_/rhoc)*
pow(Tc/T0_, Dn_);
163 const scalar ppO2 = rhoO2/WO2_*
RR*Tc;
166 const scalar
C = pc/(
RR*Tc);
170 Pout<<
"mass = " << mass <<
nl 171 <<
"fComb = " << fComb <<
nl 172 <<
"Ap = " << Ap <<
nl 173 <<
"dt = " << dt <<
nl 182 const scalar qCsLim = mass*fComb/(WC_*Ap*dt);
186 Pout<<
"qCsLim = " << qCsLim <<
endl;
190 while ((
mag(qCs - qCsOld)/qCs > tolerance_) && (iter <= maxIters_))
193 const scalar PO2Surface = ppO2*
exp(-(qCs + N)*d/(2*C*D));
194 qCs = A_*
exp(-E_/(
RR*T))*
pow(PO2Surface, n_);
195 qCs = (100.0*qCs + iter*qCsOld)/(100.0 + iter);
196 qCs =
min(qCs, qCsLim);
200 Pout<<
"iter = " << iter
201 <<
", qCsOld = " << qCsOld
209 if (iter > maxIters_)
213 "scalar Foam::COxidationMurphyShaddix<CloudType>::calculate(...)" 214 ) <<
"iter limit reached (" << maxIters_ <<
")" <<
nl <<
endl;
218 scalar dOmega = qCs*Ap*dt;
221 dMassSRCarrier[O2GlobalId_] += -dOmega*WO2_;
222 dMassSRCarrier[CO2GlobalId_] += dOmega*(WC_ + WO2_);
225 dMassSolid[CsLocalId_] += dOmega*WC_;
232 return dOmega*(WC_*HsC - (WC_ + WO2_)*HcCO2_);
const basicSpecieMixture & carrier() const
Return reference to the gaseous components.
virtual ~COxidationMurphyShaddix()
Destructor.
virtual scalar calculate(const scalar dt, 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.
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
dimensioned< scalar > mag(const dimensioned< Type > &)
Limited to C(s) + O2 -> CO2.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
COxidationMurphyShaddix(const dictionary &dict, CloudType &owner)
Construct from dictionary.
dimensionedScalar exp(const dimensionedScalar &ds)
Graphite solid properties.
const PtrList< solidProperties > & properties() const
Return the solidProperties properties.
A list of keyword definitions, which are a keyword followed by any number of values (e...
Thermo package for (S)olids (L)iquids and (G)ases Takes reference to thermo package, and provides:
Templated surface reaction model class.
Ostream & endl(Ostream &os)
Add newline and flush stream.
stressControl lookup("compactNormalStress") >> compactNormalStress
#define WarningIn(functionName)
Report a warning using Foam::Warning.
const dimensionedScalar e
Elementary charge.
const solidMixtureProperties & solids() const
Return reference to the global (additional) solids.
const scalar RR
Universal gas constant (default in [J/(kmol K)])
PtrList< volScalarField > & Y()
Return the mass-fraction fields.
Templated base class for dsmc cloud.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
prefixOSstream Pout(cout,"Pout")