mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
combustionModels/PaSR/PaSR: Changed useReactionRate to !integrateReactionRate
This commit is contained in:
@ -51,11 +51,18 @@ Foam::combustionModels::PaSR<Type>::PaSR
|
|||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("kappa", dimless, 0.0)
|
dimensionedScalar("kappa", dimless, 0.0)
|
||||||
),
|
),
|
||||||
useReactionRate_(this->coeffs().lookupOrDefault("useReactionRate", false))
|
integrateReactionRate_
|
||||||
|
(
|
||||||
|
this->coeffs().lookupOrDefault("integrateReactionRate", true)
|
||||||
|
)
|
||||||
{
|
{
|
||||||
if (useReactionRate_)
|
if (integrateReactionRate_)
|
||||||
{
|
{
|
||||||
Info<< " using reaction rate" << endl;
|
Info<< " using integrated reaction rate" << endl;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Info<< " using instantaneous reaction rate" << endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -83,13 +90,13 @@ void Foam::combustionModels::PaSR<Type>::correct()
|
|||||||
{
|
{
|
||||||
const scalar dt = this->mesh().time().deltaTValue();
|
const scalar dt = this->mesh().time().deltaTValue();
|
||||||
|
|
||||||
if (useReactionRate_)
|
if (integrateReactionRate_)
|
||||||
{
|
{
|
||||||
this->chemistryPtr_->calculate();
|
this->chemistryPtr_->solve(dt);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this->chemistryPtr_->solve(dt);
|
this->chemistryPtr_->calculate();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (turbulentReaction_)
|
if (turbulentReaction_)
|
||||||
@ -219,7 +226,8 @@ bool Foam::combustionModels::PaSR<Type>::read()
|
|||||||
{
|
{
|
||||||
this->coeffs().lookup("Cmix") >> Cmix_;
|
this->coeffs().lookup("Cmix") >> Cmix_;
|
||||||
this->coeffs().lookup("turbulentReaction") >> turbulentReaction_;
|
this->coeffs().lookup("turbulentReaction") >> turbulentReaction_;
|
||||||
this->coeffs().lookup("useReactionRate") >> useReactionRate_;
|
this->coeffs().lookup("integrateReactionRate")
|
||||||
|
>> integrateReactionRate_;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@ -65,8 +65,9 @@ class PaSR
|
|||||||
//- Mixing parameter
|
//- Mixing parameter
|
||||||
volScalarField kappa_;
|
volScalarField kappa_;
|
||||||
|
|
||||||
//- Use reaction rate
|
//- Integrate reaction rate over the time-step
|
||||||
bool useReactionRate_;
|
// using the selected ODE solver
|
||||||
|
bool integrateReactionRate_;
|
||||||
|
|
||||||
|
|
||||||
// Private Member Functions
|
// Private Member Functions
|
||||||
|
|||||||
Reference in New Issue
Block a user