Heat transfer model to describe inter-grain conduction in terms of volume fraction instead of explicit contacts.

This commit is contained in:
tlichtenegger
2019-01-07 09:44:36 +01:00
parent 87a730fbe1
commit 0b57c2400c
10 changed files with 588 additions and 136 deletions

View File

@ -26,6 +26,7 @@ else
}
//U.relax();
#include "limitU.H"
fvOptions.correct(U);

View File

@ -189,6 +189,39 @@ Info<< "Reading thermophysical properties\n" << endl;
)
);
dimensionedScalar pMax
(
dimensionedScalar::lookupOrDefault
(
"pMax",
pimple.dict(),
dimPressure,
GREAT
)
);
dimensionedScalar pMin
(
dimensionedScalar::lookupOrDefault
(
"pMin",
pimple.dict(),
dimPressure,
-GREAT
)
);
dimensionedScalar UMax
(
dimensionedScalar::lookupOrDefault
(
"UMax",
pimple.dict(),
dimVelocity,
-1.0
)
);
Info<< "Creating turbulence model\n" << endl;
autoPtr<compressible::turbulenceModel> turbulence
(
@ -265,4 +298,6 @@ Info<< "Reading thermophysical properties\n" << endl;
),
Us
);
//===============================

View File

@ -60,6 +60,8 @@ else
// Explicitly relax pressure for momentum corrector
p.relax();
#include "limitP.H"
// Recalculate density from the relaxed pressure
rho = thermo.rho();
rho = max(rho, rhoMin);
@ -77,6 +79,8 @@ else
U = HbyA - rAU*(fvc::grad(p)-Ksl*UsRec);
}
#include "limitU.H"
U.correctBoundaryConditions();
fvOptions.correct(U);
K = 0.5*magSqr(U);

View File

@ -85,6 +85,11 @@ int main(int argc, char *argv[])
scalar recTimeStep = recurrenceBase.recM().recTimeStep();
scalar startTime = runTime.startTime().value();
const IOdictionary& couplingProps = particleCloud.couplingProperties();
label nEveryFlow(couplingProps.lookupOrDefault<label>("nEveryFlow",1));
Info << "Solving flow equations every " << nEveryFlow << " steps.\n" << endl;
label stepcounter = 0;
Info<< "\nStarting time loop\n" << endl;
while (runTime.run())
@ -127,33 +132,36 @@ int main(int argc, char *argv[])
particleCloud.clockM().start(26,"Flow");
volScalarField rhoeps("rhoeps",rho*voidfractionRec);
while (pimple.loop())
if (stepcounter%nEveryFlow==0)
{
// if needed, perform drag update here
if (pimple.nCorrPIMPLE() <= 1)
while (pimple.loop())
{
#include "rhoEqn.H"
}
// if needed, perform drag update here
if (pimple.nCorrPIMPLE() <= 1)
{
#include "rhoEqn.H"
}
// --- Pressure-velocity PIMPLE corrector loop
// --- Pressure-velocity PIMPLE corrector loop
#include "UEqn.H"
#include "EEqn.H"
#include "UEqn.H"
#include "EEqn.H"
// --- Pressure corrector loop
while (pimple.correct())
{
// besides this pEqn, OF offers a "pimple consistent"-option
#include "pEqn.H"
rhoeps=rho*voidfractionRec;
}
// --- Pressure corrector loop
while (pimple.correct())
{
// besides this pEqn, OF offers a "pimple consistent"-option
#include "pEqn.H"
rhoeps=rho*voidfractionRec;
}
if (pimple.turbCorr())
{
turbulence->correct();
if (pimple.turbCorr())
{
turbulence->correct();
}
}
}
stepcounter++;
particleCloud.clockM().stop("Flow");
particleCloud.clockM().start(31,"postFlow");