mixture enthalpy logic reuse and no read dummy 0 time directory

This commit is contained in:
Yeongdo Park 2018-11-01 12:37:10 -04:00
parent de43afdee1
commit 1dc3746afd
2 changed files with 9 additions and 5 deletions

View file

@ -96,8 +96,12 @@ int main(int argc, char *argv[])
forAll(T, i)
{
// OpenFOAM diffusivity model
thermo.T()[0] = T[i];
thermo.he() = thermo.he(p, thermo.T());
scalar h0 = 0.0;
forAll(Y, k)
{
h0 += XY[k]*specieData[k].Hs(p[0], T[i]);
}
thermo.he() = dimensionedScalar("h", dimEnergy/dimMass, h0);
thermo.correct();
diff.correct();

View file

@ -10,7 +10,7 @@ Info<< "Creating base fields for time " << runTime.timeName() << endl;
"Ydefault",
runTime.timeName(),
mesh,
IOobject::READ_IF_PRESENT,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
@ -27,7 +27,7 @@ Info<< "Creating base fields for time " << runTime.timeName() << endl;
"p",
runTime.timeName(),
mesh,
IOobject::READ_IF_PRESENT,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),
@ -44,7 +44,7 @@ Info<< "Creating base fields for time " << runTime.timeName() << endl;
"T",
runTime.timeName(),
mesh,
IOobject::READ_IF_PRESENT,
IOobject::NO_READ,
IOobject::NO_WRITE,
false
),