ENH: Updated steady parcel solver

This commit is contained in:
andy
2010-10-28 18:14:57 +01:00
parent fb332ca5ec
commit 74499d57d9
4 changed files with 21 additions and 12 deletions

View File

@ -1,22 +1,23 @@
if (chemistry.chemistry())
{
Info<< "Solving chemistry" << endl;
chemistry.solve
(
runTime.value() - runTime.deltaTValue(),
runTime.deltaTValue()
);
// update reaction rates
chemistry.calculate();
// turbulent time scale
if (turbulentReaction)
{
DimensionedField<scalar, volMesh> tk =
Cmix*sqrt(turbulence->muEff()/rho/turbulence->epsilon());
DimensionedField<scalar, volMesh> tc =
chemistry.tc()().dimensionedInternalField();
typedef DimensionedField<scalar, volMesh> dsfType;
// Chalmers PaSR model
kappa = (runTime.deltaT() + tc)/(runTime.deltaT() + tc + tk);
const dimensionedScalar e0("e0", sqr(dimLength)/pow3(dimTime), SMALL);
const dsfType tk =
Cmix*sqrt(turbulence->muEff()/rho/(turbulence->epsilon() + e0));
const dsfType tc = chemistry.tc()().dimensionedInternalField();
kappa = tc/(tc + tk);
}
else
{

View File

@ -43,6 +43,11 @@
}
}
// Explicitly relax pressure for momentum corrector
p.relax();
Info<< "p min/max = " << min(p).value() << ", " << max(p).value() << endl;
// Second part of thermodynamic density update
thermo.rho() += psi*p;

View File

@ -1,4 +1,4 @@
Info<< "Reading chemistry properties\n" << endl;
// Info<< "Reading chemistry properties\n" << endl;
IOdictionary chemistryProperties
(

View File

@ -40,6 +40,9 @@ Description
);
rhoEqn.solve();
Info<< "rho min/max = " << min(rho).value() << ", " << max(rho).value()
<< endl;
}
// ************************************************************************* //