diff --git a/src/combustionModels/PaSR/PaSR.C b/src/combustionModels/PaSR/PaSR.C index 7bf26a18cba640ac5f7c3844be67688c167cc8ea..14ae46a1121d9d9b3fb92df5d3da4730777556ec 100644 --- a/src/combustionModels/PaSR/PaSR.C +++ b/src/combustionModels/PaSR/PaSR.C @@ -51,11 +51,18 @@ Foam::combustionModels::PaSR<Type>::PaSR mesh, dimensionedScalar("kappa", dimless, 0.0) ), - useReactionRate_(this->coeffs().lookupOrDefault("useReactionRate", false)) + integrateReactionRate_ + ( + this->coeffs().lookupOrDefault("integrateReactionRate", true) + ) { - if (useReactionRate_) + if (integrateReactionRate_) + { + Info<< " using integrated reaction rate" << endl; + } + else { - Info<< " using reaction rate" << endl; + Info<< " using instantaneous reaction rate" << endl; } } @@ -83,13 +90,13 @@ void Foam::combustionModels::PaSR<Type>::correct() { const scalar dt = this->mesh().time().deltaTValue(); - if (useReactionRate_) + if (integrateReactionRate_) { - this->chemistryPtr_->calculate(); + this->chemistryPtr_->solve(dt); } else { - this->chemistryPtr_->solve(dt); + this->chemistryPtr_->calculate(); } if (turbulentReaction_) @@ -219,7 +226,8 @@ bool Foam::combustionModels::PaSR<Type>::read() { this->coeffs().lookup("Cmix") >> Cmix_; this->coeffs().lookup("turbulentReaction") >> turbulentReaction_; - this->coeffs().lookup("useReactionRate") >> useReactionRate_; + this->coeffs().lookup("integrateReactionRate") + >> integrateReactionRate_; return true; } else diff --git a/src/combustionModels/PaSR/PaSR.H b/src/combustionModels/PaSR/PaSR.H index fa6c73eb955715e68c45f5a7f45762f176e07584..5b4c8d608194fc8a36bfe17c7e4f036d78e3300e 100644 --- a/src/combustionModels/PaSR/PaSR.H +++ b/src/combustionModels/PaSR/PaSR.H @@ -65,8 +65,9 @@ class PaSR //- Mixing parameter volScalarField kappa_; - //- Use reaction rate - bool useReactionRate_; + //- Integrate reaction rate over the time-step + // using the selected ODE solver + bool integrateReactionRate_; // Private Member Functions