Bounding thermo.rho in rhoPorousSimpleFoam.
Changing initial time step in externalSolarLoad tutorial.
Commenting out momemtun source term in steamInjection which causes problems
- In the corner case with few faces or points, the normal List I/O
results in a compact list representation.
This is less than desirable for external programs with simple
line-based parsers.
- Write exactly the following
*Faces*
// Patch: <word-Region> <word-Patch>
<int-nFaces>
(
<int-faceSize>(<int> .. <int>)
...
)
*Points*
// Patch: <word-Region> <word-Patch>
<int-nPoints>
(
(<float-x> <float-y> <float-z>)
...
)
STYLE: only use serial form of createExternalCoupledPatchGeometry in tutorial
- less confusing for the user, who wonders why it is being done twice.
using a run-time selectable preconditioner
References:
Van der Vorst, H. A. (1992).
Bi-CGSTAB: A fast and smoothly converging variant of Bi-CG
for the solution of nonsymmetric linear systems.
SIAM Journal on scientific and Statistical Computing, 13(2), 631-644.
Barrett, R., Berry, M. W., Chan, T. F., Demmel, J., Donato, J.,
Dongarra, J., Eijkhout, V., Pozo, R., Romine, C. & Van der Vorst, H.
(1994).
Templates for the solution of linear systems:
building blocks for iterative methods
(Vol. 43). Siam.
See also: https://en.wikipedia.org/wiki/Biconjugate_gradient_stabilized_method
Tests have shown that PBiCGStab with the DILU preconditioner is more
robust, reliable and shows faster convergence (~2x) than PBiCG with
DILU, in particular in parallel where PBiCG occasionally diverges.
This remarkable improvement over PBiCG prompted the update of all
tutorial cases currently using PBiCG to use PBiCGStab instead. If any
issues arise with this update please report on Mantis: http://bugs.openfoam.org
Added the option '-subDict' to specify a sub-dictionary if multiple
replacement sets are present in the same file. This also provides
backward compatibility by setting '-subDict dictionaryReplacement'
To re-use existing 'sampleDict' files simply add the following entries:
type sets;
libs ("libsampling.so");
and run
postProcess -func sampleDict
It is probably better to also rename 'sampleDict' -> 'sample' and then run
postProcess -func sampleDict
In most boundary conditions, fvOptions etc. required and optional fields
to be looked-up from the objectRegistry are selected by setting the
keyword corresponding to the standard field name in the BC etc. to the
appropriate name in the objectRegistry. Usually a default is provided
with sets the field name to the keyword name, e.g. in the
totalPressureFvPatchScalarField the velocity is selected by setting the
keyword 'U' to the appropriate name which defaults to 'U':
Property | Description | Required | Default value
U | velocity field name | no | U
phi | flux field name | no | phi
.
.
.
However, in some BCs and functionObjects and many fvOptions another
convention is used in which the field name keyword is appended by 'Name'
e.g.
Property | Description | Required | Default value
pName | pressure field name | no | p
UName | velocity field name | no | U
This difference in convention is unnecessary and confusing, hinders code
and dictionary reuse and complicates code maintenance. In this commit
the appended 'Name' is removed from the field selection keywords
standardizing OpenFOAM on the first convention above.
- Avoids the need for the 'OutputFilterFunctionObject' wrapper
- Time-control for execution and writing is now provided by the
'timeControlFunctionObject' which instantiates the processing
'functionObject' and controls its operation.
- Alternative time-control functionObjects can now be written and
selected at run-time without the need to compile wrapped version of
EVERY existing functionObject which would have been required in the
old structure.
- The separation of 'execute' and 'write' functions is now formalized in the
'functionObject' base-class and all derived classes implement the
two functions.
- Unnecessary implementations of functions with appropriate defaults
in the 'functionObject' base-class have been removed reducing
clutter and simplifying implementation of new functionObjects.
- The 'coded' 'functionObject' has also been updated, simplified and tested.
- Further simplification is now possible by creating some general
intermediate classes derived from 'functionObject'.
See http://www.openfoam.org/mantisbt/view.php?id=2076
- .org is the file extension for emacs org-mode as well
- .orig is more to the point (.org isn't always recognized as "original")
- .original is too long, although more consistent with the convention
of source code file naming
Update script contributed by Bruno Santos
The boundary conditions of HbyA are now constrained by the new "constrainHbyA"
function which applies the velocity boundary values for patches for which the
velocity cannot be modified by assignment and pressure extrapolation is
not specified via the new
"fixedFluxExtrapolatedPressureFvPatchScalarField".
The new function "constrainPressure" sets the pressure gradient
appropriately for "fixedFluxPressureFvPatchScalarField" and
"fixedFluxExtrapolatedPressureFvPatchScalarField" boundary conditions to
ensure the evaluated flux corresponds to the known velocity values at
the boundary.
The "fixedFluxPressureFvPatchScalarField" boundary condition operates
exactly as before, ensuring the correct flux at fixed-flux boundaries by
compensating for the body forces (gravity in particular) with the
pressure gradient.
The new "fixedFluxExtrapolatedPressureFvPatchScalarField" boundary
condition may be used for cases with or without body-forces to set the
pressure gradient to compensate not only for the body-force but also the
extrapolated "HbyA" which provides a second-order boundary condition for
pressure. This is useful for a range a problems including impinging
flow, extrapolated inlet conditions with body-forces or for highly
viscous flows, pressure-induced separation etc. To test this boundary
condition at walls in the motorBike tutorial case set
lowerWall
{
type fixedFluxExtrapolatedPressure;
}
motorBikeGroup
{
type fixedFluxExtrapolatedPressure;
}
Currently the new extrapolated pressure boundary condition is supported
for all incompressible and sub-sonic compressible solvers except those
providing implicit and tensorial porosity support. The approach will be
extended to cover these solvers and options in the future.
Note: the extrapolated pressure boundary condition is experimental and
requires further testing to assess the range of applicability,
stability, accuracy etc.
Henry G. Weller
CFD Direct Ltd.
in decomposeParDict.
This default number of processors may be overridden by the new "-np"
option to runParallel which must be specified before the application
name e.g.:
runParallel -np 4 pisoFoam
transient based solvers to account for incompressible Eq of State laws. It avoids taking into account
the term ddt(rho) as mass contribution due to compressibility effects
- moved control to functionObject (from bc)
- this allows multi-region support
- see heatTransfer/chtMultiRegionFoam/externalCoupledMultiRegionHeater tut
- generalisation of streamed reading/writing of specialised bcs
- shm: have displacementMotionSolver as alternative mesh shrinker
(instead of medialAxis).
- updated iglooWithFridges tutorial to use displacementLaplacian
- selectable interpolation from cells to points in the motion solvers
using the 'interpolation' keyword:
interpolation volPointInterpolation; // default
or
interpolation patchCorrected (lowerWall upperWall);
- wrapped up mesh shrinkers (see above) for use as a displacementMotionSolver
(i.e. the opposite of the displacementMotionSolver mesh shrinker)
This bc was in compressible turbulence library which made it dependent
on liquidProperties. It was moved to a separate library since it is only
used in a single tutorial.
so that the specification of the name and dimensions are optional in property dictionaries.
Update tutorials so that the name of the dimensionedScalar property is
no longer duplicated but optional dimensions are still provided and are
checked on read.
by introducing rational base-classes rather than using the hideous
'switch' statement. Further rationalization of the cell-selection
mechanism will be implemented via an appropriate class hierarchy to
replace the remaining 'switch' statement.
Mesh-motion is currently handled very inefficiently for cellSets and not
at all for inter-region coupling. The former will be improved when the
cell-selection classes are written and the latter by making the
meshToMesh class a MeshObject after it has been corrected for mapFields.
fvOptions does not have the appropriate structure to support MRF as it
is based on option selection by user-specified fields whereas MRF MUST
be applied to all velocity fields in the particular solver. A
consequence of the particular design choices in fvOptions made it
difficult to support MRF for multiphase and it is easier to support
frame-related and field related options separately.
Currently the MRF functionality provided supports only rotations but
the structure will be generalized to support other frame motions
including linear acceleration, SRF rotation and 6DoF which will be
run-time selectable.
Description
Specify an etc file to include when reading dictionaries, expects a
single string to follow.
Searches for files from user/group/shipped directories.
The search scheme allows for version-specific and
version-independent files using the following hierarchy:
- \b user settings:
- ~/.OpenFOAM/\<VERSION\>
- ~/.OpenFOAM/
- \b group (site) settings (when $WM_PROJECT_SITE is set):
- $WM_PROJECT_SITE/\<VERSION\>
- $WM_PROJECT_SITE
- \b group (site) settings (when $WM_PROJECT_SITE is not set):
- $WM_PROJECT_INST_DIR/site/\<VERSION\>
- $WM_PROJECT_INST_DIR/site/
- \b other (shipped) settings:
- $WM_PROJECT_DIR/etc/
An example of the \c \#includeEtc directive:
\verbatim
#includeEtc "etcFile"
\endverbatim
The usual expansion of environment variables and other constructs is
retained.
For multi-region cases the default location of blockMeshDict is now system/<region name>
If the blockMeshDict is not found in system then the constant directory
is also checked providing backward-compatibility
The old separate incompressible and compressible libraries have been removed.
Most of the commonly used RANS and LES models have been upgraded to the
new framework but there are a few missing which will be added over the
next few days, in particular the realizable k-epsilon model. Some of
the less common incompressible RANS models have been introduced into the
new library instantiated for incompressible flow only. If they prove to
be generally useful they can be templated for compressible and
multiphase application.
The Spalart-Allmaras DDES and IDDES models have been thoroughly
debugged, removing serious errors concerning the use of S rather than
Omega.
The compressible instances of the models have been augmented by a simple
backward-compatible eddyDiffusivity model for thermal transport based on
alphat and alphaEff. This will be replaced with a separate run-time
selectable thermal transport model framework in a few weeks.
For simplicity and ease of maintenance and further development the
turbulent transport and wall modeling is based on nut/nuEff rather than
mut/muEff for compressible models so that all forms of turbulence models
can use the same wall-functions and other BCs.
All turbulence model selection made in the constant/turbulenceProperties
dictionary with RAS and LES as sub-dictionaries rather than in separate
files which added huge complexity for multiphase.
All tutorials have been updated so study the changes and update your own
cases by comparison with similar cases provided.
Sorry for the inconvenience in the break in backward-compatibility but
this update to the turbulence modeling is an essential step in the
future of OpenFOAM to allow more models to be added and maintained for a
wider range of cases and physics. Over the next weeks and months more
turbulence models will be added of single and multiphase flow, more
additional sub-models and further development and testing of existing
models. I hope this brings benefits to all OpenFOAM users.
Henry G. Weller
When using models which require the wallDist e.g. kOmegaSST it will
request the method to be used from the wallDist sub-dictionary in
fvSchemes e.g.
wallDist
{
method meshWave;
}
specifies the mesh-wave method as hard-coded in previous OpenFOAM versions.
Changing to Lists the contact resistances of turbulentTemperatureRadCoupledMixed and turbulentTemperatureCoupled BC's
Updating fvOption in heatExchanger tutorial
To support these changes the need for "Sp" corrections on div-terms has been
eliminated by introducing a "bounded" convection scheme which subtracts the Sp
term from the selected scheme. The equivalent will be needed for the ddt term.
A warning message is generated for steady-state solvers in which the "bounded"
scheme is not selected for the convection terms.
New base class for fluid and solid thermo: veryBasicThermo
Base class for fluid thermo: basicThermo (derived from veryBasicThermo)
Base class for solid thermo: solidThermo (derived from veryBasicThermo)
Note in next commit basicThermo -> fluidThermo, veryBasicThermo -> basicThermo
At the specie level:
hs = sensible enthalpy
ha = absolute (what was total) enthalpy
es = sensibly internal energy
ea = absolute (what was total) internal energy
At top-level
Rename total enthalpy h -> ha
Rename sensible enthalpy hs -> h
Combined h, hs, e and es thermo packages into a single structure.
Thermo packages now provide "he" function which may return either enthalpy or
internal energy, sensible or absolute according to the run-time selected form
alphaEff now returns the effective diffusivity for the particular energy which
the thermodynamics package is selected to solve for.