Commit Graph

5584 Commits

Author SHA1 Message Date
85e548df23 entrainmentPressureFvPatchScalarField: Added support for mass-flux -> velocity conversion
so that the entrainmentPressure BC can be applied to compressible and multiphase
cases.
2021-12-03 14:47:56 +00:00
f52d8694a3 chtMultiRegionFoam: Added optional thermal system sub-iteration
For some systems the thermal coupling between the solid and fluid regions
dominates overall convergence and it may be beneficial to sub-iterate over the
thermal system as the energy solution is cheaper than the pressure-velocity
system.  To test this the new optional nEcorr entry in system/fvSolution is
provided which defaults to 1, e.g.

PIMPLE
{
    nOuterCorrectors 1;
    nEcorr           2;
}

If this proves useful it could be extended and improved by adding convergence
controls.

Note that the solution of the solid regions is now before the fluid regions as
it make more sense if solid regions are sources or sinks of heat to solve them
before the fluid.
2021-11-29 10:43:03 +00:00
ce000453d7 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2021-11-25 16:11:25 +00:00
26f0e47d4b AndradeTransport: New specie transport model for liquids
Description
    Transport package using the Andrade function for the natural logarithm of
    dynamic viscosity and thermal conductivity of liquids:

    \verbatim
        log(mu) = muCoeffs[0] + muCoeffs[1]*T + muCoeffs[2]*sqr(T)
          + muCoeffs_[3]/(muCoeffs_[4] + T)

        log(kappa) = kappaCoeffs[0] + kappaCoeffs[1]*T + kappaCoeffs[2]*sqr(T)
          + kappaCoeffs_[3]/(kappaCoeffs_[4] + T)
    );
    \endverbatim

    References:
    \verbatim
        Andrade, E. D. C. (1934).
        XLI. A theory of the viscosity of liquids.—Part I.
        The London, Edinburgh, and Dublin Philosophical Magazine
        and Journal of Science, 17(112), 497-511.

        Andrade, E. D. C. (1934).
        LVIII. A theory of the viscosity of liquids.—Part II.
        The London, Edinburgh, and Dublin Philosophical Magazine
        and Journal of Science, 17(113), 698-732.
    \endverbatim

Usage
    \table
        Property        | Description
        muCoeffs        | Dynamic viscosity polynomial coefficients
        kappaCoeffs     | Thermal conductivity polynomial coefficients
    \endtable

    Example of the specification of the transport properties for water@200bar:
    \verbatim
    transport
    {
        muCoeffs    (-25.8542 0.031256 -2.2e-05 3289.918 -11.4784);
        kappaCoeffs (-2.56543 0.008794 -9.8e-06 100.368 0);
    }
    \endverbatim
2021-11-25 16:10:07 +00:00
506d2891b7 transformerIOList: Centralised instantiation 2021-11-25 09:45:04 +00:00
068ed634d2 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2021-11-24 14:54:11 +00:00
e931ccada1 ThermophysicalTransportModels::MaxwellStefan::j(): Added support for the default specie
Resolves bug-report https://bugs.openfoam.org/view.php?id=3755
2021-11-24 14:53:12 +00:00
75cf502d34 streamlinesParticle: Instantiate transformer IO list 2021-11-24 12:37:10 +00:00
701fc2b6a5 streamlines: Corrected handling of cyclic boundaries
By default a streamline now stops at the cyclic and starts again at the
coupled location on the opposite cyclic.

There is also now an "outside" option that can be passed to the
streamlines function. This changes the default behaviour so that the
streamline continues outside of the mesh when it encounters a cyclic
patch. The following postProcess command uses the "outside" option in
this way:

    postProcess -latestTime -func "
        streamlinesPatch
        (
            patch=inlet,
            nPoints=50,
            outside=true,
            fields=(p U)
        )"
2021-11-24 12:26:12 +00:00
dc2bea68cd Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2021-11-24 11:23:27 +00:00
83375c4b5d buoyantPimpleFoam::pEqn: Relax p_rgh and p after the continuity check
Also update p_rgh if p is limited to ensure p_rgh and p are consistent.
2021-11-24 11:07:56 +00:00
175f0fa8f2 tutorials: angledDuct: Prevent memory error in blockMeshDict codeStream 2021-11-23 14:44:39 +00:00
261ce05fac sampledSurfaces: Write multiple fields to the same file
This prevents excessive duplication of surface geometry and makes
post-processing tasks in paraview more convenient.

The Nastran and Star-CD surface formats were found not to work, so
support for these output types has been removed. Raw, VTK, Foam and
Ensight formats are all still available.
2021-11-23 14:44:34 +00:00
c9b4fc75d4 blockMesh: Replaced b.cells().size() with blockCells.size()
Resolves bug-report https://bugs.openfoam.org/view.php?id=3754
20211121
2021-11-20 21:03:02 +00:00
687996724a fvMeshDistributors: New framework within fvMesh to handle run-time mesh redistribution
for e.g. load-balancing.  The fvMeshDistributor is selected via the new optional
distributor entry in dynamicMeshDict, e.g.

distributor
{
    type            decomposer;

    libs            ("libfvMeshDistributors.so");
}

Note that currently only the framework is included in this commit, the
fvMeshDistributors library is not yet fully functional and hence not released
yet.
2021-11-18 15:10:15 +00:00
daf9d6e2f6 buoyantPimpleFoam::pEqn: Moved p_rgh relaxation so that the relaxed p_rgh is used when updating p
This improves convergence of some steady-state chtMultiRegionFoam (which uses
the pEqn.H from buoyantPimpleFoam) cases but does not affect transient
simulations unless aggressive pressure relaxation is applied, i.e. transient
SIMPLE.
2021-11-18 14:52:19 +00:00
a1622077e2 fvConstraints::limitPressure: Added support for maxFactor and minFactor when p has calculated BCs
When limiting the pressure in p_rgh based solvers p typically has calculated BCs
which are now supported when calculating the max and min pressure from maxFactor
and minFactor.
2021-11-18 14:49:41 +00:00
4b5491300f sampledSurfaces: Fixed failure to write surfaces 2021-11-18 09:49:51 +00:00
487879de66 sampledSurface: Fixed documentation for iso-surface based surfaces 2021-11-18 09:49:02 +00:00
b478751c35 meshWavePatchDistMethod: Corrections on coupled and transform patches 2021-11-16 15:09:20 +00:00
494e440ad4 fvMeshTopoChangers::refiner: Added mapping of Uf for new faces
The surfaceVectorField Uf is used instead of the flux field phi for ddtPhiCorr
in moving mesh cases to handle linear and rotating motion and must mapped from
the volVectorField U to new faces created by cell splitting or merging in mesh
refinement/unrefinement.
2021-11-11 15:11:52 +00:00
f39d78bd53 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2021-11-10 20:32:15 +00:00
ae44671ea6 fvMeshTopoChangers::refiner: Updated documentation 2021-11-10 20:31:40 +00:00
0ad695b3c6 movingWallSlipVelocity: Better initialisation on null construct 2021-11-10 14:38:09 +00:00
facc363a21 engineFoam: superseded by reactingFoam with fvMeshMover::engine
With the general run-time selectable fvMeshMovers engine compression simulations
can be performed with reactingFoam so there is no longer any need for engine
specific solvers or engineMesh.

An engineFoam script is provided to redirect users to reactingFoam with
instructions.
2021-11-07 23:50:43 +00:00
7a6d08e897 PDRFoam: Moved to sub-directory of XiFoam
PDRFoam is a Xi combustion model solver including porosity distributed
resistance and shares code with XiFoam so it is more logical that it should be
in a sub-directory of XiFoam to simplify compilation dependency.
2021-11-07 21:51:11 +00:00
640cd66a65 coldEngineFoam: superseded by rhoPimpleFoam with fvMeshMover::engine
With the general run-time selectable fvMeshMovers engine compression simulations
can be performed with rhoPimpleFoam so there is no longer any need for engine
specific solvers.

A coldEngineFoam script is provided to redirect users to rhoPimpleFoam with
instructions.
2021-11-07 19:09:44 +00:00
49faf0be14 fvMeshMovers::engine: Moved and updated enginePiston and engineValve from src/engine 2021-11-07 19:08:43 +00:00
43f8daf1a7 XiFoam: Relocated the ignition library from engine to XiFoam
as this ignition method is specific to the Xi combustion model.
2021-11-07 19:07:01 +00:00
a576f213e4 Added XiEngineFoam script to redirect users to XiFoam with instructions 2021-11-07 19:04:49 +00:00
251c628c77 moveEngineMesh: Removed as no longer required
moveDynamicMesh can be used to move engine meshes which use fvMeshMovers
2021-11-06 00:51:28 +00:00
730b8163b5 engineCompRatio: Updated to use the engine fvMeshMover 2021-11-06 00:39:04 +00:00
451fbb40d4 Moved kivaTest to tutorials/combustion/XiFoam/RAS/kivaTest 2021-11-06 00:23:27 +00:00
8f14b69fba XiFoam: Added mesh-motion to replace XiEngineFoam
With the addition of mesh-motion to XiFoam and the new engine fvMeshMover the
XiEngineFoam kivaTest simple IC engine example now runs in XiFoam and
XiEngineFoam has been removed.  This simplifies maintenance provides greater
extensibility.
2021-11-05 22:32:42 +00:00
941ea19930 fvMeshMovers::engine, layeredEngine: New fvMesh movers for engine simulations
derived from engineMesh and layeredEngineMesh.
2021-11-05 17:50:22 +00:00
dc6f4ab34c tutorials/combustion/coldEngineFoam/freePiston: Removed pending the completion of the rewrite of engineMesh 2021-11-05 09:57:09 +00:00
55467aaa7f momentumTransportModel, twoPhaseMixture: Updated for clang
The use of move semantics differs between gcc and clang requiring a different
approach when returning a registered IOdictionary
2021-11-05 08:02:44 +00:00
e10830632e engineTime: Completely replaced engineTime derived from Time
with the run-time selectable engine userTime embedded in Time.

All parts of the original engineTime relating to the engine geometry have been
moved to engineMesh.  This is part of the process of integrating engine
simulations within the standard moving-mesh solvers.
2021-11-03 19:33:41 +00:00
7f56646aba multiphaseEulerFoam::MovingPhaseModel: Register phase divU for refinement/unrefinement mapping 2021-11-03 11:40:15 +00:00
30a16cc88c tutorials/multiphase/interFoam/RAS/floatingObject: Improved surface initialisation 2021-11-02 17:40:09 +00:00
d3022ae1d7 reconstruct::processorMeshes: Disable reading of dynamicMeshDict during reconstruction 2021-11-02 17:33:16 +00:00
a075e1a774 rigidBodyMeshMotion: Added support for mesh refinement/unrefinement with multiple bodies 2021-11-02 16:54:51 +00:00
a817efc9c6 Updates to avoid warning messages from Clang 2021-11-02 16:54:25 +00:00
37c7d6b9ac rigidBodyMeshMotion: Added support for dynamic mesh refinement/unrefinement
The floatingObject tutorial has been update to demonstrate this functionality by
adding the following topoChanger entry to dynamicMeshDict:

topoChanger
{
    type    refiner;

    libs    ("libfvMeshTopoChangers.so");

    // How often to refine
    refineInterval  1;

    // Field to be refinement on
    field           alpha.water;

    // Refine field in between lower..upper
    lowerRefineLevel 0.001;
    upperRefineLevel 0.999;

    // Have slower than 2:1 refinement
    nBufferLayers   1;

    // Refine cells only up to maxRefinement levels
    maxRefinement   1;

    // Stop refinement if maxCells reached
    maxCells        200000;

    // Flux field and corresponding velocity field. Fluxes on changed
    // faces get recalculated by interpolating the velocity. Use 'none'
    // on surfaceScalarFields that do not need to be reinterpolated.
    correctFluxes
    (
        (phi none)
        (nHatf none)
        (rhoPhi none)
        (alphaPhi.water none)
        (meshPhi none)
        (ghf none)
    );

    // Write the refinement level as a volScalarField
    dumpLevel       true;
}

Note that currently only single rigid body motion is supported (but multi-body
support will be added shortly) and the Crank-Nicolson scheme is not supported.
2021-11-02 14:11:52 +00:00
465b9382c0 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2021-11-02 11:28:43 +00:00
2d1c97f4fa Function2::UniformTable2: Corrected and updated documentation
Resolves bug-report https://bugs.openfoam.org/view.php?id=3750
2021-11-02 11:27:54 +00:00
80c1a65bc8 movingWallSlipVelocity: Added boundary condition
This boundary condition specifies a slip velocity on moving walls. It
works similarly to movingWallVelocity, except that the tangential
velocity is not constrained. It can be specified as follows:

    <patchName>
    {
        type            movingWallSlipVelocity;
        value           uniform (0 0 0); // Initial value
    }
2021-11-02 10:32:33 +00:00
a13826f1d6 Test-liquid: Separate data blocks for gnuplot 2021-10-29 13:09:29 +01:00
81f6cf91d0 liquidProperties: Added properties for NH3 (ammonia) 2021-10-29 12:51:46 +01:00
f376c1b087 TDACChemistryModel: Added test for reduction before updating active composition
to remove parallel overhead when integrating chemistry without reduction.

Resolves bug-report https://bugs.openfoam.org/view.php?id=3748
2021-10-29 10:48:07 +01:00