Added the interfacial pressure-work terms according to:
Ishii, M., Hibiki, T.,
Thermo-fluid dynamics of two-phase flow,
ISBN-10: 0-387-28321-8, 2006
While this is the most common approach to handling the interfacial
pressure-work it introduces numerical stability issues in regions of low
phase-fraction and rapid flow deformation. To alleviate this problem an
optional limiter may be applied to the pressure-work term in either of
the energy forms. This may specified in the
"thermophysicalProperties.<phase>" file, e.g.
pressureWorkAlphaLimit 1e-3;
which sets the pressure work term to 0 for phase-fractions below 1e-3.
For particularly unstable cases a limit of 1e-2 may be necessary.
The best of the current options is to use the latest version of
exuberant ctags (which has a new C++ parser) to generate both
declaration and definition tags.
gtags works to some extent and provides additional information about the
function signatures but the C++ parser is not accurate and misses scope
information. gtags can be used with the ctags parser which is effective
but looses the primary advantage of gtags being able to provide function
signatures so support has been switched-off by default.
ebrowse does not appear to be very useful for traversing the OpenFOAM
class tree and the support has been switched-off by default.
Added 'READ_IF_PRESENT' option to support overriding of the default BCs
for complex problems requiring special treatment of Udm at boundaries.
Resolves bug-report http://bugs.openfoam.org/view.php?id=2317
In many publications and Euler-Euler codes the pressure-work term in the
total enthalpy is stated and implemented as -alpha*dp/dt rather than the
conservative form derived from the total internal energy equation
-d(alpha*p)/dt. In order for the enthalpy and internal energy equations
to be consistent this error/simplification propagates to the total
internal energy equation as a spurious additional term p*d(alpha)/dt
which is included in the OpenFOAM Euler-Euler solvers and causes
stability and conservation issues.
I have now re-derived the energy equations for multiphase flow from
first-principles and implemented in the reactingEulerFoam solvers the
correct conservative form of pressure-work in both the internal energy
and enthalpy equations.
Additionally an optional limiter may be applied to the pressure-work
term in either of the energy forms to avoid spurious fluctuations in the
phase temperature in regions where the phase-fraction -> 0. This may
specified in the "thermophysicalProperties.<phase>" file, e.g.
pressureWorkAlphaLimit 1e-3;
which sets the pressure work term to 0 for phase-fractions below 1e-3.
New functionality contributed by Mattijs Janssens:
- new edge projection: projectCurve for use with new geometry
'searchableCurve'
- new tutorial 'pipe'
- naming of vertices and blocks (see pipe tutorial). Including back
substitution for error messages.
Previously the inlet flow of phase 1 (the phase solved for) is corrected
to match the inlet specification for that phase. However, if the second
phase is also constrained at inlets the inlet flux must also be
corrected to match the inlet specification.
Loop over the edges of each block rather than the edgeList of the
topological mesh due to problems with calcEdges for blocks with repeated
point labels
- Write differences with respect to the specified dictionary
(or sub entry if -entry specified)
- Write the differences with respect to a template dictionary:
foamDictionary 0/U -diff $FOAM_ETC/templates/closedVolume/0/U
- Write the differences in boundaryField with respect to a
template dictionary:
foamDictionary 0/U -diff $FOAM_ETC/templates/closedVolume/0/U \
-entry boundaryField
Patch contributed by Mattijs Janssens
Patch contributed by Mattijs Janssens
- Added projected vertices
- Added projected edges
- Change of blockEdges API (operate on list lambdas)
- Change of blockFaces API (pass in blockDescriptor and blockFacei)
- Added sphere7ProjectedEdges tutorial to demonstrate vertex and edge projection
For example, to mesh a sphere with a single block the geometry is defined in the
blockMeshDict as a searchableSurface:
geometry
{
sphere
{
type searchableSphere;
centre (0 0 0);
radius 1;
}
}
The vertices, block topology and curved edges are defined in the usual
way, for example
v 0.5773502;
mv -0.5773502;
a 0.7071067;
ma -0.7071067;
vertices
(
($mv $mv $mv)
( $v $mv $mv)
( $v $v $mv)
($mv $v $mv)
($mv $mv $v)
( $v $mv $v)
( $v $v $v)
($mv $v $v)
);
blocks
(
hex (0 1 2 3 4 5 6 7) (10 10 10) simpleGrading (1 1 1)
);
edges
(
arc 0 1 (0 $ma $ma)
arc 2 3 (0 $a $ma)
arc 6 7 (0 $a $a)
arc 4 5 (0 $ma $a)
arc 0 3 ($ma 0 $ma)
arc 1 2 ($a 0 $ma)
arc 5 6 ($a 0 $a)
arc 4 7 ($ma 0 $a)
arc 0 4 ($ma $ma 0)
arc 1 5 ($a $ma 0)
arc 2 6 ($a $a 0)
arc 3 7 ($ma $a 0)
);
which will produce a mesh in which the block edges conform to the sphere
but the faces of the block lie somewhere between the original cube and
the spherical surface which is a consequence of the edge-based
transfinite interpolation.
Now the projection of the block faces to the geometry specified above
can also be specified:
faces
(
project (0 4 7 3) sphere
project (2 6 5 1) sphere
project (1 5 4 0) sphere
project (3 7 6 2) sphere
project (0 3 2 1) sphere
project (4 5 6 7) sphere
);
which produces a mesh that actually conforms to the sphere.
See OpenFOAM-dev/tutorials/mesh/blockMesh/sphere
This functionality is experimental and will undergo further development
and generalization in the future to support more complex surfaces,
feature edge specification and extraction etc. Please get involved if
you would like to see blockMesh become a more flexible block-structured
mesher.
Henry G. Weller, CFD Direct.