mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: combustionModels: Changed the construction order
The combustion and chemistry models no longer select and own the
thermodynamic model; they hold a reference instead. The construction of
the combustion and chemistry models has been changed to require a
reference to the thermodyanmics, rather than the mesh and a phase name.
At the solver-level the thermo, turbulence and combustion models are now
selected in sequence. The cyclic dependency between the three models has
been resolved, and the raw-pointer based post-construction step for the
combustion model has been removed.
The old solver-level construction sequence (typically in createFields.H)
was as follows:
autoPtr<combustionModels::psiCombustionModel> combustion
(
combustionModels::psiCombustionModel::New(mesh)
);
psiReactionThermo& thermo = combustion->thermo();
// Create rho, U, phi, etc...
autoPtr<compressible::turbulenceModel> turbulence
(
compressible::turbulenceModel::New(rho, U, phi, thermo)
);
combustion->setTurbulence(*turbulence);
The new sequence is:
autoPtr<psiReactionThermo> thermo(psiReactionThermo::New(mesh));
// Create rho, U, phi, etc...
autoPtr<compressible::turbulenceModel> turbulence
(
compressible::turbulenceModel::New(rho, U, phi, *thermo)
);
autoPtr<combustionModels::psiCombustionModel> combustion
(
combustionModels::psiCombustionModel::New(*thermo, *turbulence)
);
ENH: combustionModel, chemistryModel: Simplified model selection
The combustion and chemistry model selection has been simplified so
that the user does not have to specify the form of the thermodynamics.
Examples of new combustion and chemistry entries are as follows:
In constant/combustionProperties:
combustionModel PaSR;
combustionModel FSD;
In constant/chemistryProperties:
chemistryType
{
solver ode;
method TDAC;
}
All the angle bracket parts of the model names (e.g.,
<psiThermoCombustion,gasHThermoPhysics>) have been removed as well as
the chemistryThermo entry.
The changes are mostly backward compatible. Only support for the
angle bracket form of chemistry solver names has been removed. Warnings
will print if some of the old entries are used, as the parts relating to
thermodynamics are now ignored.
ENH: combustionModel, chemistryModel: Simplified model selection
Updated all tutorials to the new format
STYLE: combustionModel: Namespace changes
Wrapped combustion model make macros in the Foam namespace and removed
combustion model namespace from the base classes. This fixes a namespace
specialisation bug in gcc 4.8. It is also somewhat less verbose in the
solvers.
This resolves bug report https://bugs.openfoam.org/view.php?id=2787
ENH: combustionModels: Default to the "none" model
When the constant/combustionProperties dictionary is missing, the solver
will now default to the "none" model. This is consistent with how
radiation models are selected.
This commit is contained in:
committed by
Andrew Heather
parent
255ec7366b
commit
22aae2816d
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -17,9 +17,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel infinitelyFastChemistry<psiThermoCombustion,gasHThermoPhysics>;
|
||||
combustionModel infinitelyFastChemistry;
|
||||
|
||||
active true;
|
||||
|
||||
@ -24,3 +24,5 @@ infinitelyFastChemistryCoeffs
|
||||
semiImplicit no;
|
||||
C 10;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel infinitelyFastChemistry<psiThermoCombustion,gasHThermoPhysics>;
|
||||
combustionModel infinitelyFastChemistry;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -15,10 +15,10 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel infinitelyFastChemistry<psiThermoCombustion,gasHThermoPhysics>;
|
||||
combustionModel infinitelyFastChemistry;
|
||||
|
||||
//combustionModel FSD<psiThermoCombustion,gasHThermoPhysics>;
|
||||
//combustionModel diffusionMulticomponent<psiChemistryCombustion,gasHThermoPhysics>;
|
||||
//combustionModel FSD;
|
||||
//combustionModel diffusionMulticomponent;
|
||||
//NOTE: To use diffusionMulticomponent combustion model you need to rename files:
|
||||
// reactions.twoSteps -> reactions
|
||||
// thermophysicalProperties.twoSteps -> thermophysicalProperties
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo psi;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -16,7 +16,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel infinitelyFastChemistry<psiThermoCombustion,gasHThermoPhysics>;
|
||||
combustionModel infinitelyFastChemistry;
|
||||
|
||||
active on;
|
||||
|
||||
|
||||
@ -17,9 +17,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
importantSpecies
|
||||
|
||||
@ -17,9 +17,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel EDC<psiChemistryCombustion>;
|
||||
combustionModel EDC;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -16,9 +16,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel EDC<psiChemistryCombustion>;
|
||||
combustionModel EDC;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo psi;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel noCombustion<psiThermoCombustion>;
|
||||
combustionModel none;
|
||||
|
||||
|
||||
// ************************************************************************* //
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo psi;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<psiChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo psi;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<psiChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,9 +17,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<psiChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<psiChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,9 +17,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -17,9 +17,8 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
TDAC on;
|
||||
solver ode;
|
||||
method TDAC;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<psiChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel PaSR<psiChemistryCombustion>;
|
||||
combustionModel PaSR;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo rho;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel PaSR<rhoChemistryCombustion>;
|
||||
combustionModel PaSR;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver noChemistrySolver;
|
||||
chemistryThermo rho;
|
||||
solver noChemistrySolver;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel laminar<rhoChemistryCombustion>;
|
||||
combustionModel laminar;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver ode;
|
||||
chemistryThermo psi;
|
||||
solver ode;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel PaSR<psiChemistryCombustion>;
|
||||
combustionModel PaSR;
|
||||
|
||||
active yes;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo rho;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry on;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel PaSR<rhoChemistryCombustion>;
|
||||
combustionModel PaSR;
|
||||
|
||||
active true;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo rho;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel PaSR<rhoChemistryCombustion>;
|
||||
combustionModel PaSR;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
@ -17,8 +17,7 @@ FoamFile
|
||||
|
||||
chemistryType
|
||||
{
|
||||
chemistrySolver EulerImplicit;
|
||||
chemistryThermo rho;
|
||||
solver EulerImplicit;
|
||||
}
|
||||
|
||||
chemistry off;
|
||||
|
||||
@ -15,7 +15,7 @@ FoamFile
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
combustionModel PaSR<rhoChemistryCombustion>;
|
||||
combustionModel PaSR;
|
||||
|
||||
active false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user