This boundary condition now solves for the wall temperature by interval
bisection, which should be significantly more robust than the previous
fixed-point iteration procedure. There is a new non-dimensional
"tolerance" setting that controls how tightly this solution procedure
solves the wall temperature. The "relax" setting is no longer used.
The boundary condition no longer triggers re-evaluation of the
temperature condition in order to re-calculate the heat flux within the
solution iteration. Instead, it extracts physical coefficients from the
form of the boundary condition and uses these to form a linearised
approximation of the heat flux. This is a more general approach, and
will not trigger side-effects associated with re-evaluating the
temperature condition.
The fixedMultiphaseHeatFlux condition has been replaced by a
uniformFixedMultiphaseHeatFlux condition, which constructs a mixed
constraint which portions a specified heat flux between the phases in
such a way as to keep the boundary temperature uniform across all
phases. This can be applied to all phases. It is no longer necessary to
apply a heat flux model to one "master" phase, then map the resulting
temperature to the others. An example specification of this boundary
condition is as follows:
wall
{
type uniformFixedMultiphaseHeatFlux;
q 1000;
relax 0.3;
value $internalField;
}
The wall boiling tutorials have been updated to use these new functions,
and time-varying heat input has been used to replace the
stop-modify-restart pattern present in the single-region cases.
205 lines
5.7 KiB
C++
205 lines
5.7 KiB
C++
/*--------------------------------*- C++ -*----------------------------------*\
|
|
========= |
|
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
|
\\ / O peration | Website: https://openfoam.org
|
|
\\ / A nd | Version: dev
|
|
\\/ M anipulation |
|
|
\*---------------------------------------------------------------------------*/
|
|
FoamFile
|
|
{
|
|
format ascii;
|
|
class dictionary;
|
|
location "system";
|
|
object controlDict;
|
|
}
|
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
|
|
application foamRun;
|
|
|
|
solver multiphaseEuler;
|
|
|
|
startFrom startTime;
|
|
|
|
startTime 0;
|
|
|
|
stopAt endTime;
|
|
|
|
endTime 4;
|
|
|
|
deltaT 0.0001;
|
|
|
|
writeControl adjustableRunTime;
|
|
|
|
writeInterval 0.5;
|
|
|
|
purgeWrite 0;
|
|
|
|
writeFormat ascii;
|
|
|
|
writePrecision 9;
|
|
|
|
writeCompression off;
|
|
|
|
timeFormat general;
|
|
|
|
timePrecision 6;
|
|
|
|
runTimeModifiable yes;
|
|
|
|
adjustTimeStep yes;
|
|
|
|
maxCo 0.5;
|
|
|
|
maxDeltaT 0.001;
|
|
|
|
functions
|
|
{
|
|
writeWallBoilingProperties
|
|
{
|
|
type wallBoilingProperties;
|
|
functionObjectLibs ( "libmultiphaseEulerFoamFunctionObjects.so" );
|
|
writeControl writeTime;
|
|
phase liquid;
|
|
}
|
|
volumeDensity.diameter.bubbles
|
|
{
|
|
type populationBalanceSizeDistribution;
|
|
functionObjectLibs ( "libmultiphaseEulerFoamFunctionObjects.so" );
|
|
writeControl runTime;
|
|
writeInterval 0.5;
|
|
setFormat raw;
|
|
log yes;
|
|
functionType volumeConcentration;
|
|
coordinateType diameter;
|
|
regionType cellZone;
|
|
name x349;
|
|
populationBalance bubbles;
|
|
}
|
|
volumeDensity_bulk.diameter.bubbles
|
|
{
|
|
type populationBalanceSizeDistribution;
|
|
functionObjectLibs ( "libmultiphaseEulerFoamFunctionObjects.so" );
|
|
writeControl runTime;
|
|
writeInterval 0.5;
|
|
setFormat raw;
|
|
log yes;
|
|
functionType volumeConcentration;
|
|
coordinateType diameter;
|
|
regionType cellZone;
|
|
name x349_bulk;
|
|
populationBalance bubbles;
|
|
}
|
|
volumeDensity_wall.diameter.bubbles
|
|
{
|
|
type populationBalanceSizeDistribution;
|
|
functionObjectLibs ( "libmultiphaseEulerFoamFunctionObjects.so" );
|
|
writeControl runTime;
|
|
writeInterval 0.5;
|
|
setFormat raw;
|
|
log yes;
|
|
functionType volumeConcentration;
|
|
coordinateType diameter;
|
|
regionType cellZone;
|
|
name x349_wall;
|
|
populationBalance bubbles;
|
|
}
|
|
outflow
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name outlet;
|
|
operation sum;
|
|
fields ( alphaRhoPhi.gas alphaRhoPhi.gas2 alphaRhoPhi.liquid );
|
|
}
|
|
inflow
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name inlet;
|
|
operation sum;
|
|
fields ( alphaRhoPhi.gas alphaRhoPhi.gas2 alphaRhoPhi.liquid );
|
|
}
|
|
outletGas
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name outlet;
|
|
operation sum;
|
|
weightField alphaRhoPhi.gas;
|
|
fields ( h.gas );
|
|
}
|
|
outletGas2
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name outlet;
|
|
operation sum;
|
|
weightField alphaRhoPhi.gas2;
|
|
fields ( h.gas2 );
|
|
}
|
|
outletLiquid
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name outlet;
|
|
operation sum;
|
|
weightField alphaRhoPhi.liquid;
|
|
fields ( h.liquid );
|
|
}
|
|
inletGas
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name inlet;
|
|
operation sum;
|
|
weightField alphaRhoPhi.gas;
|
|
fields ( h.gas );
|
|
}
|
|
inletGas2
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name inlet;
|
|
operation sum;
|
|
weightField alphaRhoPhi.gas2;
|
|
fields ( h.gas2 );
|
|
}
|
|
inletLiquid
|
|
{
|
|
type surfaceFieldValue;
|
|
functionObjectLibs ( "libfieldFunctionObjects.so" );
|
|
log yes;
|
|
writeFields false;
|
|
regionType patch;
|
|
name inlet;
|
|
operation sum;
|
|
weightField alphaRhoPhi.liquid;
|
|
fields ( h.liquid );
|
|
}
|
|
#includeFunc writeObjects(d.gas, d.gas2)
|
|
}
|
|
|
|
|
|
// ************************************************************************* //
|