Commit Graph

574 Commits

Author SHA1 Message Date
89b4ad6ba7 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2019-08-01 14:27:11 +01:00
b8fcd10cf7 singleStepCombustion: Refactored to include the singleStepReactingMixture functionality
allowing the removal of singleStepReactingMixture which is the first step in
refactoring the instantiation of the reaction scheme.
2019-08-01 14:24:13 +01:00
332b72d561 tutorials: reactingTwoPhaseEulerFoam: Updates to steamInjection
Added limiters for the phase temperatures to prevent divergence, and
monitors to report the minimum and maximum values. Removed the
setTimeStep functionObject as the temperature limiters make this
unnecessary. Dereased the number of energy correctors and set a higher
Courant number limit to reduce the execution-time of the case.

Patch contributed by Juho Peltola, VTT.
2019-07-31 16:01:56 +01:00
b942ba07e0 ractingEulerFoam: populationBalance: Refactored scaling
Refactored the function for scaling the size group volume fractions to
better handle situations in which their sum drifts away from unity.
Scaling is now turned on by default, and can be turned off in the
solution dictionary for the population balance.

Additional revision and renaming of *Polydisperse tutorials

Patch contributed by Institute of Fluid Dynamics,
Helmholtz-Zentrum Dresden - Rossendorf (HZDR)
2019-07-25 12:27:09 +01:00
7af67fbf3f reactingEulerFoam: Corrected LaakkonenAlopaeusAittamaa daughter size distribution model
This fix also required a generalization of the corresponding base class,
which allows the user to specify the number of daughter particles per
breakup event separately.

Patch contributed by Institute of Fluid Dynamics,
Helmholtz-Zentrum Dresden - Rossendorf (HZDR)
2019-07-25 12:12:05 +01:00
4a810cbe9d SpalartAllmaras[I][D]DES: Named temporary fields and added optional caching for LESRegion
The various temporary fields used to create the nuTilda equation sources are now
internal fields to avoid unnecessary evaluation of boundary conditions, lowering
storage and reducing CPU time, particularly when running in parallel.  These
temporary fields are now named with respect to the model so that they can be
cached conveniently and written as required.

The LESRegion field can now be contructed on demand if it is requested as a
cached temporary field and written out for diagnostics if needed, for example in
the tutorials/incompressible/pisoFoam/LES/motorBike tutorial:

cacheTemporaryObjects
(
    SpalartAllmarasDDES:LESRegion
);

functions
{
    writeCachedObjects
    {
        type        writeObjects;
        libs        ("libutilityFunctionObjects.so");

        writeControl writeTime;
        writeOption anyWrite;

        objects
        (
            SpalartAllmarasDDES:LESRegion
        );
    }

    #include "cuttingPlane"
    #include "streamLines"
    #include "forceCoeffs"
}
2019-07-23 11:48:14 +01:00
e947e4d301 tutorials: Updated to use the new dictionary "slash" syntax 2019-07-11 19:44:29 +01:00
b7c0cdefce dictionary: Added support for absolute paths when reading dictionaries referred to within keywords
For example in the combustion/coldEngineFoam/freePiston/0/p field the
internalField entry may be obtained from the include/caseSettings dictionary
using either a relative path:

    internalField   uniform $include/caseSettings!internalField/p;

or an absolute path:

    internalField   uniform ${$FOAM_CASE/0/include/caseSettings!internalField/p};

in which recursive substitution using ${...} is applied to expand the $FOAM_CASE
environment variable.
2019-07-11 09:46:42 +01:00
cba96822f4 tutorials/compressible/rhoSimpleFoam/aerofoilNACA0012/system/blockMeshDict: Updated to demonstrate the new "slash" syntax 2019-07-10 19:41:44 +01:00
73d253c34b blockMesh: Angle-and-axis specification for arc edges
Arc-edges can now be specified with a sector angle (in degrees) and an
axis of the circle of which the arc forms a part. The new syntax is as
follows:

   edges
   (
       arc <vertex-0> <vertex-1> <angle> (<axis-x> <axis-y> <axis-z>)
   );

This is often more convenient than the alternative specification where a
third third point somewhere in the arc is given; it usually does not
require any additional calculation on the part of the user, and multiple
entries are very likely to be identical.

Which specification is used depends on the form of the entry that comes
after the two vertices. If the entry is a vector then it is assumed to
be a point in the arc; if it is scalar then is is taken to be the angle
and the axis is assumed to follow.

For example, to put a 90 degree arc between the vertices 12 and 13, at
(1 0 0) and (0 1 0) respectively, the following specification can now be
used:

   edges
   (
       arc 12 13 90.0 (0 0 1)
   );

This is equivalent to the existing point-in-arc speficiation below:

   edges
   (
       arc 12 13 (0.707107 0.707107 0)
   );

An edge's points are ordered on the perimeter of the circle according to
a right-hand screw rule on the given axis. Changing the the side of the
edge on which the arc is defined can therefore be achieved by reversing
either the edge or the direction of the axis.

If the given axis is not perpendicular to the line between the vertices,
then the arc gains some axial length and becomes a helix.
2019-07-10 11:05:10 +01:00
9cc193398f tutorials/multiphase/reactingMultiphaseEulerFoam/laminar/bed: Increased water flow rate 2019-07-08 15:57:28 +01:00
802f3c1c22 tutorials/mesh/snappyHexMesh: Corrected links 2019-07-05 15:33:59 +01:00
fb6eff2c87 Moved tutorials/multiphase/compressibleInterFoam/RAS/sloshingTank2D to tutorials/multiphase/compressibleInterFoam/laminar/sloshingTank2D
Resolves bug-report https://bugs.openfoam.org/view.php?id=3296
2019-06-24 14:40:36 +01:00
96b69f6f88 Standardised and rationalised the way in which units are written in function documentation 2019-06-20 10:54:14 +01:00
251f91cfa5 fvOptions::isotropicDamping: New wave damping fvOption
This implicit isotropic damping function relaxes the velocity field towards a
specified uniform value which can be set to (0 0 0) if no flow is required.
This is particularly appropriate to damp the waves in a closed wave tank with no
mean flow.

Testing on the interFoam wave has shown that for this simple case with uniform
mean flow the new isotropicDamping fvOption provides more rapid and complete
damping than the original verticalDamping.
2019-06-18 22:06:17 +01:00
d0bf565783 tutorials/incompressible/boundaryFoam/boundaryWallFunctionsProfile/Allrun: Updated for latest gnuplot 2019-06-08 14:38:23 +01:00
1e2550b6cd Rationalised wall function implementation to avoid complex and inconsistent coefficients
All wall functions now operate collaboratively, obtaining the Cmu, kappa and E
coefficients and yPlusLam from the nutWallFunction base class.  Now these
optional inputs need only be specified in the nut boundary condition with the k,
epsilon, omega, v2 and f wall functions obtaining these values from there.  This
is much simpler to specify and avoids inconsistencies in the operation of the
wall functions for the different turbulence fields.

The code has also been rationalised and simplified avoiding unnecessary code
and duplication.
2019-05-31 19:40:32 +01:00
0889ff91c7 graphField: Moved graphs directory into postProcessing 2019-05-20 10:43:36 +01:00
8803a89407 fvOptions: Added volumeFractionSource and solidEquilibriumEnergySource
The volumeFractionSource represents the effect of a reduction in the
volume of the domain due to the presence of a stationary phase, most
likely a solid porous media. It only represents the dynamic effects
associated with the reduction in volume; it does not does not model
loss, drag or heat transfer. Separate models (e.g., the existing
porosity models) will be necessary to represent these effects. An
example usage, in system/fvOptions, is as follows:

    volumeFraction
    {
        type            volumeFractionSource;
        phase           solid;
        phi             phi;
        rho             rho;
        U               U;
        fields          (rho U e);
    }

The volume fraction will be read from constant/alpha.<phase>, and must
be generated in advance using setFields or a function object. Note that
the names of the flux, density (if compressible) and velocity must all
be specified. Every field for which a transport equation is solved
should also be specified in the "fields" entry.

The solidEquilibriumEnergySource adds the thermal inertia and diffusive
characteristics of a stationary solid phase to the energy equation of
the fluid, assuming that the two phases are in thermal equilibrium. An
example usage is as follows:

    solidEqulibriumEnergy
    {
        type            solidEqulibriumEnergySource;
        phase           solid;
        field           e;
    }

This will read the volume fraction in the same way as the
volumeFractionSource option. In addition, thermal properties of the
solid will be constructed from settings in
system/thermophysicalProperties.<phase>.

Two tutorials have been added, demonstrating use of these options in
both incompressible and compressible simulations. These are
incompressible/pimpleFoam/laminar/blockedChannel and
compressible/rhoPimpleFoam/laminar/blockedChannel.
2019-05-07 08:52:57 +01:00
784244790f DTCHull tutorials: rename fields to .orig
to avoid them being overwritten during renumbering
2019-04-29 19:26:50 +01:00
cd656fbf9b postChannel: Moved postChannelDict from constant to system
Resolves https://bugs.openfoam.org/view.php?id=3224
2019-04-18 11:03:56 +01:00
cb6eb31d42 tutorials/multiphase/interFoam/RAS/DTCHullMoving/Allrun: Corrected call to renumberMesh 2019-04-08 20:37:58 +01:00
1909f9cf85 DTCHull tutorials: renumberMesh after meshing, before decomposition
Avoids the need to renumber the decompositon/reconstruction maps
2019-04-05 17:01:13 +01:00
2f3d47ad7e Residuals: New MeshObject class to store solver performance residuals
This is more efficient and modular than the previous approach of storing the
residuals in the mesh data dictionary.
2019-04-04 19:08:08 +01:00
2dd53c898a turbulenceModels/laminar/Giesekus: Giesekus model for visco-elasticity
Implementation of the Giesekus model for visco-elasticity, derived from the new
generalised form of the Maxwell model which now support additional sources.

    Giesekus, H., 1982.
    A simple constitutive equation for polymer fluids based on the
    concept of deformation-dependent tensional mobility.
    J. Non-Newton. Fluid. 11, 69–109.

This implementation is instantiated for incompressible, compressible and VoF
two-phase flow.
2019-03-28 22:10:59 +00:00
e1e3e2a333 pimpleFoam: Added LTS capability for demonstration and testing
For most steady cases simpleFoam is likely to converge faster than pimpleFoam
with LTS but this capability may be useful for testing meshes, BCs etc. for more
complex solver for which SIMPLE is not stable and LTS is provided instead.
2019-03-28 11:54:55 +00:00
9bf34679bd buoyantBoussinesq[SP]impleFoam: replaced by the more general buoyant[SP]impleFoam solvers
With the selection of the Boussinesq equation of state the general buoyancy
solvers buoyantSimpleFoam and buoyantPimpleFoam can be used instead of the
specialised Boussinesq solvers avoiding the need for special implementation of
thermal and pressure boundary conditions and providing support for radiation and
fvOptions which would not have been feasible or practical in the Boussinesq
solvers.

Other incompressible equations of state are also supported; for most gaseous
problems the incompressiblePerfectGas equation of state is likely to be more
accurate than the Boussinesq equation of state.

The buoyantBoussinesq[SP]impleFoam tutorials have been updated and moved to the
corresponding buoyant[SP]impleFoam directories.
2019-03-26 21:42:14 +00:00
118f7c88f8 tutorials::membrane/Allrun: Fixed scipting typo 2019-03-18 12:23:32 +00:00
51edeaaa1f tutorials/multiphase/interFoam/RAS/mixerVesselAMI: Rationalised phase names and properties 2019-03-16 18:10:33 +00:00
2dd8b51d2a Removed redundant file 2019-03-15 11:52:15 +00:00
18bd64314c Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2019-03-15 11:17:57 +00:00
c97e133c04 tutorials/incompressible/simpleFoam/motorBike/system/controlDict: Reverted change 2019-03-15 11:17:07 +00:00
081db9a350 lagrangian: drag: Various improvements
The dense drag models (WenYu, ErgunWenYu and PlessisMasliyah) have been
extended so that they can create their own void-fraction field when one
is not otherwise available.

The duplicated functionality in the drag models has been generalised and
is now utilised by multiple models.

References have been added for all models for which they could be found.
In addition, an additional drag model, SchillerNaumann, has been added.
This is of the same form as sphereDrag, and is designed for the same
scenario; sparsely distributed spherical particles. The SchillerNaumann
form is more widely referenced and should now be considered standard.

The thermo-parcel-specific force instantiation macro has been removed,
as all the force models are now possible to use with all parcel types.

Resolves bug report https://bugs.openfoam.org/view.php?id=3191
2019-03-15 08:49:39 +00:00
d41166187a writeEntry: Rationalised for consistency, ease of use and maintainability
The writeEntry form is now defined and used consistently throughout OpenFOAM
making it easier to use and extend, particularly to support binary IO of complex
dictionary entries.
2019-03-14 20:54:10 +00:00
8f0772d7d2 tutorials::floatingObject: Added rigidBodyState functionObject 2019-03-01 13:51:59 +00:00
a3fd68eed0 tutorials: shellAndTubeHeatExchanger: Update due to change in snappyHexMesh writeFlags 2019-02-12 11:35:31 +00:00
682caa71b1 Revert "snappyHexMesh: Changed the default for the writing of pointLevels and cellLevels files in the polyMesh directory"
This reverts commit 799db4d958.
2019-02-12 09:41:00 +00:00
c59c82ac0e radiationModels: Relocation, namespace changes, and fixed Qdot access
The radiation modelling library has been moved out of
thermophysicalProperties into the top-level source directory. Radiation
is a process, not a property, and belongs alongside turbulence,
combustion, etc...

The namespaces used within the radiation library have been made
consistent with the rest of the code. Selectable sub-models are in
namespaces named after their base classes. Some models have been
renamed remove the base type from the suffix, as this is unnecessary.
These renames are:

    Old name:                       New name:

    binaryAbsorptionEmission        binary
    cloudAbsorptionEmission         cloud
    constantAbsorptionEmission      constant
    greyMeanAbsorptionEmission      greyMean/greyMeanCombustion
    greyMeanSolidAbsorptionEmission greyMeanSolid
    wideBandAbsorptionEmission      wideBand/wideBandCombustion

    cloudScatter                    cloud
    constantScatter                 constant

    mixtureFractionSoot             mixtureFraction

Some absorption-emission models have been split into versions which do
and don't use the heat release rate. The version that does has been
given the post-fix "Combustion" and has been moved into the
combustionModels library. This removes the dependence on a registered
Qdot field, and makes the models compatible with the recent removal of
that field from the combustion solvers.
2019-02-11 08:38:56 +00:00
6d4960e36c chtMultiRegionFoam: Added shell-and-tube heat exchanger tutorial
This tutorial serves as a reference of how to create a multi-region
mesh with layer addition.

The multiRegionHeater tutorial and it's variants have been removed as
the geometry is not meaningful and the functionality is now all
represented elsewhere.
2019-02-04 12:27:11 +00:00
7203f20283 chtMultiRegionFoam: Added radiation to reverseBurner tutorial 2019-02-04 09:18:37 +00:00
b292fc6d8d radiation: Changed to dictionary constructors for dimensioned types
This allows coefficients of the constantAbsorptionEmission and
constantScatter to be entered as pure numbers, with the name and
dimensions set automatically, rather than having to specify them
manually.
2019-02-04 09:18:37 +00:00
756d10c37c reactingEulerFoam: sizeDistribution: Naming conventions
The keyword which selects how the subset over which the function
operates is generated has been renamed to "selectionMode", to make it
more consistent with other parts of the OpenFOAM (e.g., fvOptions). It
can still take the value "all" or "cellZone". A cell zone is now
specified with a "cellZone", again for consistency.

Error messaging has also been overhauled.

Patch contributed by Institute of Fluid Dynamics,
Helmholtz-Zentrum Dresden - Rossendorf (HZDR)
2019-02-04 09:18:36 +00:00
82356c7d08 tutorials: windAroundBuildings: Updated snappyHexMesh write flags 2019-01-31 08:55:05 +00:00
799db4d958 snappyHexMesh: Changed the default for the writing of pointLevels and cellLevels files in the polyMesh directory
These files are now only written if the "refinement" write flag is set:

writeFlags
(
    .
    .
    .
    refinement
);
2019-01-30 17:50:23 +00:00
da77e6a77f tutorial simplifiedSiwek: Updated chemistry stability settings for the new Jacobian
Resolves bug-report https://bugs.openfoam.org/view.php?id=3155
2019-01-29 22:38:47 +00:00
5e2f17a9af populationBalanceModel: phaseChange: Improvements
A number of improvements have been made to the population balance phase
change drift model.

- The model now checks the ordering of the phase pairs and changes the
sign of the drift rate accordingly.

- The phase change mass flux and weights are calculated for each
velocity group, so the drift rate and phase change mass flux should be
consistent for each velocity group.

- By default the phase change mass flux is distributed between the size
groups based on the interfacial area of each group. For backward
compatibility number weighting can be enabled with a new
"numberWeighted" option.

The model now requires the user to provide a list of phase pairs in the
usual parenthesised form, rather than using the name. For example:

    phaseChange
    {
        pairs ((gas and liquid));
    }

Patch contributed by Juho Peltola, VTT.
2019-01-28 16:47:34 +00:00
4221e43dfc combustion: Removed Qdot field from solvers
The Qdot field has been removed from all reacting solvers, in favour of
computing on the fly whenever it is needed. It can still be generated
for post-processing purposes by means of the Qdot function object. This
change reduces code duplication and storage for all modified solvers.

The Qdot function object has been applied to a number of tutorials in
order to retain the existing output.

A fix to Qdot has also been applied for multi-phase cases.
2019-01-24 14:29:17 +00:00
dc25f10202 combustionModels: Added Qdot function object
This function object writes out the heat release rate field for a
combustion model. This is useful for solvers where combustion is
optional, and which do not therefore write out the heat release rate by
default; e.g., chtMultiRegionFoam and reactingTwoPhaseEulerFoam.
2019-01-24 10:10:05 +00:00
a0850290b3 chtMultiRegionFoam: Improvements to reverseBurner tutorial
The tutorial has been converted from two-dimensions to a wedge and the
flow has been swirl stabilised. The turbulence parameters have been made
physical. The transport schemes have been increased to second order. The
reaction mechanism has been changed to one from a publically accessible
reference. The gas thermodynamics have been made incompressible, and the
pressure offset around zero, which improves the behaviour of the
pressure solution.
2019-01-24 09:01:52 +00:00
c5db440298 dynamicMeshDict: standardised indentation 2019-01-23 11:45:23 +00:00