tutorials/multiphase/reactingTwoPhaseEulerFoam/laminar/steamInjection: Improved stability

Main changes in the tutorial:
  - General cleanup of the phaseProperties of unnecessary entries
  - sensibleEnthalpy is used for both phases
  - setTimeStep functionObject is used to set a sharp reduction in time step near the start of the injection
  - Monitoring of pressure minimum and maximum

Patch contributed by Juho Peltola, VTT.
This commit is contained in:
Henry Weller 2017-04-11 20:48:32 +01:00
parent 707abb910e
commit aef09b8daf
8 changed files with 75 additions and 88 deletions

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2015 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2015-2017 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@ -253,6 +253,14 @@ makeReactionMixtureThermo
constRefRhoConstHThermoPhysics
);
makeReactionMixtureThermo
(
rhoThermo,
rhoReactionThermo,
heRhoThermo,
multiComponentMixture,
constRefFluidHThermoPhysics
);
makeReactionMixtureThermo
(

View File

@ -71,7 +71,7 @@ options
volumeMode absolute;
injectionRateSuSp
{
e.steam (3700 0); // kg*m^2/s^3
h.steam (3700 0); // kg*m^2/s^3
}
}
}

View File

@ -15,7 +15,7 @@ FoamFile
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
type thermalPhaseChangeTwoPhaseSystem;
type thermalPhaseChangeTwoPhaseSystem;
phases (steam water);
@ -34,7 +34,7 @@ steam
}
Sc 0.7;
residualAlpha 1e-6;
residualAlpha 1e-3;
}
water
@ -47,7 +47,7 @@ water
}
Sc 0.7;
residualAlpha 1e-6;
residualAlpha 1e-3;
}
blending
@ -56,30 +56,6 @@ blending
{
type none;
continuousPhase water;
minFullyContinuousAlpha.steam 0.7;
minPartlyContinuousAlpha.steam 0.5;
minFullyContinuousAlpha.water 0.7;
minPartlyContinuousAlpha.water 0.5;
}
heatTransfer
{
type none;
continuousPhase water;
minFullyContinuousAlpha.steam 1;
minPartlyContinuousAlpha.steam 0;
minFullyContinuousAlpha.water 1;
minPartlyContinuousAlpha.water 0;
}
massTransfer
{
type none;
continuousPhase water;
minFullyContinuousAlpha.steam 1;
minPartlyContinuousAlpha.steam 0;
minFullyContinuousAlpha.water 1;
minPartlyContinuousAlpha.water 0;
}
}
@ -107,12 +83,6 @@ aspectRatio
type constant;
E0 1.0;
}
(water in steam)
{
type constant;
E0 1.0;
}
);
drag
@ -126,16 +96,6 @@ drag
type none;
}
}
(water in steam)
{
type SchillerNaumann;
residualRe 1e-3;
swarmCorrection
{
type none;
}
}
);
virtualMass
@ -145,27 +105,18 @@ virtualMass
type constantCoefficient;
Cvm 0.5;
}
(water in steam)
{
type constantCoefficient;
Cvm 0.5;
}
);
interfaceComposition
();
heatTransfer
(
(steam in water)
{
type Saturated;
species ( H2O );
Le 1.0;
saturationPressure
{
type ArdenBuck;
}
type spherical;
residualAlpha 1e-4;
}
);
heatTransfer.steam
@ -187,33 +138,19 @@ heatTransfer.water
);
massTransfer.steam
(
);
();
massTransfer.water
(
);
();
lift
(
);
();
wallLubrication
(
);
();
turbulentDispersion
(
(steam in water)
{
type Burns;//
sigma 0.7;
Ctd 1.0;
residualAlpha 1e-3;
}
);
();
// Minimum allowable pressure
pMin 10000;

View File

@ -23,9 +23,13 @@ thermoType
thermo hRefConst;
equationOfState perfectGas;
specie specie;
energy sensibleInternalEnergy;
energy sensibleEnthalpy;
}
dpdt yes;
pressureWorkAlphaLimit 0;
species
(
water

View File

@ -23,9 +23,13 @@ thermoType
thermo hRefConst;
equationOfState perfectFluid;
specie specie;
energy sensibleInternalEnergy;
energy sensibleEnthalpy;
}
dpdt yes;
pressureWorkAlphaLimit 0;
species
(
water

View File

@ -25,11 +25,11 @@ stopAt endTime;
endTime 10;
deltaT 1e-6;
deltaT 1e-3;
writeControl adjustableRunTime;
writeInterval 0.5;
writeInterval 0.1;
purgeWrite 0;
@ -41,7 +41,7 @@ writeCompression compressed;
timeFormat general;
timePrecision 6;
timePrecision 9;
runTimeModifiable yes;
@ -51,5 +51,30 @@ maxCo 0.1;
maxDeltaT 1e-2;
functions
{
timeStepping
{
type setTimeStep;
functionObjectLibs ("libutilityFunctionObjects.so");
enabled yes;
deltaT tableFile;
file "system/deltaTvalues";
}
minMaxp
{
type fieldMinMax;
functionObjectLibs ("libfieldFunctionObjects.so");
fields
(
p
);
location no;
writeControl timeStep;
writeInterval 1;
}
}
// ************************************************************************* //

View File

@ -0,0 +1,9 @@
(
(0 1e-3)
(0.99 1e-3)
(0.999 1e-4)
(0.9999 1e-5)
(1.001 1e-5)
(1.01 1e-4)
(1.1 1e-3)
);

View File

@ -27,8 +27,8 @@ solvers
{
solver PCG;
preconditioner DIC;
tolerance 1e-8;
relTol 0;
tolerance 1e-10;
relTol 0.001;
}
p_rghFinal
@ -78,10 +78,10 @@ solvers
PIMPLE
{
nOuterCorrectors 4;
nOuterCorrectors 3;
nCorrectors 1;
nNonOrthogonalCorrectors 0;
nEnergyCorrectors 1;
nEnergyCorrectors 2;
faceMomentum yes;
}
@ -89,7 +89,7 @@ relaxationFactors
{
fields
{
iDmdt 1;
iDmdt 1;
}
equations