Commit 81e77b61 authored by Andrew Heather's avatar Andrew Heather
Browse files

not registering cached density field

parent a549c0c8
......@@ -454,7 +454,20 @@ Foam::ODEChemistryModel<CompType, ThermoType>::tc() const
scalar pf,cf,pr,cr;
label lRef, rRef;
const volScalarField rho = this->thermo().rho();
const volScalarField rho
(
IOobject
(
"rho",
this->time().timeName(),
this->mesh(),
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->thermo().rho()
);
label nCells = rho.size();
label nReaction = reactions_.size();
......@@ -582,7 +595,19 @@ Foam::label Foam::ODEChemistryModel<CompType, ThermoType>::nEqns() const
template<class CompType, class ThermoType>
void Foam::ODEChemistryModel<CompType, ThermoType>::calculate()
{
const volScalarField rho = this->thermo().rho();
const volScalarField rho
(
IOobject
(
"rho",
this->time().timeName(),
this->mesh(),
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->thermo().rho()
);
for (label i=0; i<nSpecie_; i++)
{
......@@ -629,7 +654,19 @@ Foam::scalar Foam::ODEChemistryModel<CompType, ThermoType>::solve
const scalar deltaT
)
{
const volScalarField rho = this->thermo().rho();
const volScalarField rho
(
IOobject
(
"rho",
this->time().timeName(),
this->mesh(),
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
this->thermo().rho()
);
for (label i=0; i<nSpecie_; i++)
{
......
......@@ -90,12 +90,12 @@ Foam::ODEChemistryModel<CompType, ThermoType>::RR
IOobject
(
"RR(" + this->Y_[i].name() + ')',
this->thermo().rho()().mesh().time().timeName(),
this->thermo().rho()().mesh(),
this->time().timeName(),
this->mesh(),
IOobject::NO_READ,
IOobject::NO_WRITE
),
this->thermo().rho()().mesh(),
this->mesh(),
dimensionedScalar("zero", dimensionSet(1, -3, -1, 0, 0), 0.0),
zeroGradientFvPatchScalarField::typeName
)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment