Updates and extensions to the MRF and SRF handling.

This commit is contained in:
henry
2009-03-11 16:49:46 +00:00
parent 23a579774a
commit 73b153f302
10 changed files with 264 additions and 230 deletions

View File

@ -26,7 +26,7 @@ Application
MRFSimpleFoam
Description
Steady-state solver for incompressible, turbulent flow of non-Newtonian
Steady-state solver for incompressible, turbulent flow of non-Newtonian
fluids with MRF regions.
\*---------------------------------------------------------------------------*/
@ -63,10 +63,10 @@ int main(int argc, char *argv[])
// Pressure-velocity SIMPLE corrector
{
// Momentum predictor
tmp<fvVectorMatrix> UEqn
(
fvm::div(phi, U)
- fvm::Sp(fvc::div(phi), U)
+ turbulence->divDevReff(U)
);
mrfZones.addCoriolis(UEqn());

View File

@ -1,9 +1,9 @@
// Momentum predictor
// Relative momentum predictor
tmp<fvVectorMatrix> UrelEqn
(
fvm::div(phi, Urel)
+ turbulence->divDevReff(Urel)
+ SRF->Su()
+ turbulence->divDevReff(Urel)
+ SRF->Su()
);
UrelEqn().relax();

View File

@ -27,7 +27,7 @@ Application
Description
Steady-state solver for incompressible, turbulent flow of non-Newtonian
fluids with single rotating frame.
fluids in a single rotating frame.
\*---------------------------------------------------------------------------*/
@ -40,16 +40,13 @@ Description
int main(int argc, char *argv[])
{
#include "setRootCase.H"
#include "createTime.H"
#include "createMesh.H"
#include "createFields.H"
#include "initContinuityErrs.H"
# include "setRootCase.H"
# include "createTime.H"
# include "createMesh.H"
# include "createFields.H"
# include "initContinuityErrs.H"
//mesh.clearPrimitives();
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Info<< "\nStarting time loop\n" << endl;
@ -57,20 +54,19 @@ int main(int argc, char *argv[])
{
Info<< "Time = " << runTime.timeName() << nl << endl;
# include "readSIMPLEControls.H"
# include "initConvergenceCheck.H"
#include "readSIMPLEControls.H"
#include "initConvergenceCheck.H"
p.storePrevIter();
// Pressure-velocity SIMPLE corrector
{
# include "UEqn.H"
# include "pEqn.H"
#include "UrelEqn.H"
#include "pEqn.H"
}
turbulence->correct();
if (runTime.outputTime())
{
volVectorField Uabs
@ -93,7 +89,7 @@ int main(int argc, char *argv[])
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
<< nl << endl;
# include "convergenceCheck.H"
#include "convergenceCheck.H"
}
Info<< "End\n" << endl;