fvModels: Added new clouds and surfaceFilm fvModels to replace specialised solvers
With the new fvModels framework it is now possible to implement complex models
and wrappers around existing complex models which can then be optionally
selected in any general solver which provides compatible fields and
thermophysical properties. This simplifies code development and maintenance by
significantly reducing complex code duplication and also provide the opportunity
of running these models in other solvers without the need for code duplication
and alteration.
The immediate advantage of this development is the replacement of the
specialised Lagrangian solvers with their general counterparts:
reactingParticleFoam -> reactingFoam
reactingParcelFoam -> reactingFoam
sprayFoam -> reactingFoam
simpleReactingParticleFoam -> reactingFoam
buoyantReactingParticleFoam -> buoyantReactingFoam
For example to run a reactingParticleFoam case in reactingFoam add the following
entries in constant/fvModels:
buoyancyForce
{
type buoyancyForce;
}
clouds
{
type clouds;
libs ("liblagrangianParcel.so");
}
which add the acceleration due to gravity needed by Lagrangian clouds and the
clouds themselves.
See the following cases for examples converted from reactingParticleFoam:
$FOAM_TUTORIALS/combustion/reactingFoam/Lagrangian
and to run a buoyantReactingParticleFoam case in buoyantReactingFoam add the
following entry constant/fvModels:
clouds
{
type clouds;
libs ("liblagrangianParcel.so");
}
to add support for Lagrangian clouds and/or
surfaceFilm
{
type surfaceFilm;
libs ("libsurfaceFilmModels.so");
}
to add support for surface film. The buoyancyForce fvModel is not required in
this case as the buoyantReactingFoam solver has built-in support for buoyancy
utilising the p_rgh formulation to provide better numerical handling for this
force for strongly buoyancy-driven flows.
See the following cases for examples converted from buoyantReactingParticleFoam:
$FOAM_TUTORIALS/combustion/buoyantReactingFoam/Lagrangian
All the tutorial cases for the redundant solvers have been updated and converted
into their new equivalents and redirection scripts replace these solvers to
provide users with prompts on which solvers have been replaced by which and
information on how to upgrade their cases.
To support this change and allow all previous Lagrangian tutorials to run as
before the special Lagrangian solver fvSolution/PIMPLE control
solvePrimaryRegion has been replaced by the more general and useful controls:
models : Enable the fvModels
thermophysics : Enable thermophysics (energy and optional composition)
flow : Enable flow (pressure/velocity system)
which also replace the fvSolution/PIMPLE control frozenFlow present in some
solvers. These three controls can be used in various combinations to allow for
example only the fvModels to be evaluated, e.g. in
$FOAM_TUTORIALS/combustion/buoyantReactingFoam/Lagrangian/rivuletPanel
PIMPLE
{
models yes;
thermophysics no;
flow no;
.
.
.
so that only the film is solved. Or during the start-up of a case it might be
beneficial to run the pressure-velocity system for a while without updating
temperature which can be achieved by switching-off thermophysics. Also the
behaviour of the previous frozenFlow switch can be reproduced by switching flow
off with the other two switches on, allowing for example reactions, temperature
and composition update without flow.
This commit is contained in:
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Version: dev
|
||||
\\/ M anipulation |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object fvModels;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
clouds
|
||||
{
|
||||
type clouds;
|
||||
libs ("liblagrangianParcel.so");
|
||||
}
|
||||
|
||||
surfaceFilm
|
||||
{
|
||||
type surfaceFilm;
|
||||
libs ("libsurfaceFilmModels.so");
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application buoyantReactingParticleFoam;
|
||||
application buoyantReactingFoam;
|
||||
|
||||
startFrom latestTime;
|
||||
|
||||
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration | Website: https://openfoam.org
|
||||
\\ / A nd | Version: dev
|
||||
\\/ M anipulation |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object fvModels;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
clouds
|
||||
{
|
||||
type clouds;
|
||||
libs ("liblagrangianParcel.so");
|
||||
}
|
||||
|
||||
surfaceFilm
|
||||
{
|
||||
type surfaceFilm;
|
||||
libs ("libsurfaceFilmModels.so");
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application buoyantReactingParticleFoam;
|
||||
application buoyantReactingFoam;
|
||||
|
||||
startFrom startTime;
|
||||
|
||||
@ -33,7 +33,7 @@ writeInterval 0.1;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii; // binary;
|
||||
writeFormat binary;
|
||||
|
||||
writePrecision 10;
|
||||
|
||||
@ -51,5 +51,6 @@ maxCo 0.2;
|
||||
|
||||
maxDeltaT 0.002;
|
||||
|
||||
libs ("libsurfaceFilmModels.so");
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -11,10 +11,14 @@ FoamFile
|
||||
format ascii;
|
||||
class dictionary;
|
||||
location "constant";
|
||||
object additionalControls;
|
||||
object fvModels;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvePrimaryRegion true;
|
||||
surfaceFilm
|
||||
{
|
||||
type surfaceFilm;
|
||||
libs ("libsurfaceFilmModels.so");
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application buoyantReactingParticleFoam;
|
||||
application buoyantReactingFoam;
|
||||
|
||||
startFrom startTime;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user