Commit Graph

7079 Commits

Author SHA1 Message Date
0433bd3e00 genericFields: Library reorganisation and reduce duplication 2023-08-25 09:46:40 +01:00
ba416ac909 fvMeshStitcher: Standardise mesh change hooks 2023-08-24 12:10:45 +01:00
075c358fb9 snappyHexMeshConfig: layers can be specified for individual surfaces 2023-08-22 16:48:11 +01:00
be88a99ecd Cloud: Delete all particles that fail to map 2023-08-22 11:40:30 +01:00
bf8b8596f8 polyMesh: Use appropriate boundary meshes when swapping patches 2023-08-22 11:40:30 +01:00
af9afec754 snappyHexMeshConfig: allow a cylindrical background mesh without a rotating zone 2023-08-18 16:46:06 +01:00
66d3b49eb5 contactAngleFvPatchScalarField: Added documentation 2023-08-18 10:32:50 +01:00
4e7ee7ed65 primitiveFaceZone: Removed
This definition was incorrect, and the correct form is not needed as it
is the same as indirectPrimitivePatch

Resolves bug report https://bugs.openfoam.org/view.php?id=4008
2023-08-18 08:54:25 +01:00
dd23a7dbe8 Template cases: automatically set relaxationFactors for steady-state and transient simulation 2023-08-17 09:21:39 +01:00
07b434e098 Template cases: remove redundant PISO settings in fvSolution 2023-08-16 18:45:22 +01:00
e3b53f2727 multiphaseEuler: Fix indexing bug in partial elimination 2023-08-16 16:03:32 +01:00
7ab2321a07 multicomponentThermo: Fix for singleComponentMixture
This prevents a segfault when using singleComponentMixture and no mass
fraction fields are stored

Resolves bug report https://bugs.openfoam.org/view.php?id=4006
2023-08-16 09:34:17 +01:00
6d9bc62fa9 foamDictionary: Added -output option
to specify the path name of the output dictionary to which the expanded and/or
changed dictionary is written.

Usage: foamDictionary [OPTIONS] <dictionary file>
options:
  -add <value>      Add a new entry
  -case <dir>       specify alternate case directory, default is the cwd
  -dict             Set, add or merge entry from a dictionary.
  -diff <dict>      Write differences with respect to the specified dictionary
  -entry <name>     report/select the named entry
  -expand           Read the specified dictionary file and expand the macros
                    etc.
  -fileHandler <handler>
                    override the fileHandler
  -hostRoots <((host1 dir1) .. (hostN dirN))>
                    slave root directories (per host) for distributed running
  -includes         List the #include/#includeIfPresent files to standard output
  -keywords         list keywords
  -libs '("lib1.so" ... "libN.so")'
                    pre-load libraries
  -merge <value>    Merge entry
  -noFunctionObjects
                    do not execute functionObjects
  -output <path name>
                    Path name of the output dictionary
  -parallel         run in parallel
  -remove           Remove the entry.
  -roots <(dir1 .. dirN)>
                    slave root directories for distributed running
  -set <value>      Set entry value, add new entry or apply list of
                    substitutions
  -value            Print entry value
  -writePrecision <label>
                    Write with the specified precision
  -srcDoc           display source code in browser
  -doc              display application documentation in browser
  -help             print the usage

manipulates dictionaries
2023-08-10 21:24:44 +01:00
89db32a3a7 foamDictionary: Corrected handling of the -case option
Now if the -case option is specified the dictionary path provided is treated as
relative to the case path, e.g.

foamDictionary -expand -case shockFluid/shockTube system/controlDict
2023-08-10 20:28:54 +01:00
9e296d3040 dimensionedType: Make read flexible as to the presence of a name 2023-08-10 10:37:33 +01:00
cce5bc9e40 HookFunctions: Prevent expansion prior to command evaluation 2023-08-09 16:29:00 +01:00
a2314a5a23 multicomponentThermo: Construct Yslicer on demand
This fixes a crash caused by the pointers to the mass fraction boundary
fields being invalidated by mesh-to-mesh mapping
2023-08-09 15:10:23 +01:00
b790a69507 DimensionedFunction1: Permit setting argument-dimensions of inline functions
Both argument and value dimensions can be set for inline-constructable
function1-s. For example, this inline table function:

    massFlowRate table [CAD] [g/s]
    (
        (0 0.46)
        (0.17 1.9)
        (0.31 4.8)
    );

Is equivalent to this dictionary specification:

    massFlowRate
    {
        type    table;
        xDimensions [CAD];
        dimensions [g/s];
        values
        (
             (0 0.46)
             (0.17 1.9)
             (0.31 4.8)
        );
    }

In the inline form, the argument/x-dimensions come first, and the value
dimensions second. If there only one dimension set provided, then this
is assumed to be the value dimensions.
2023-08-09 12:30:44 +01:00
9a7b9e9229 ConeInjection: Permit unit specification for dInner/dOuter 2023-08-08 16:29:51 +01:00
a693bf009d IrreversibleReaction: Formatting 2023-08-08 16:18:01 +01:00
95589f6973 dimensionSets: Removed writeSets
The functionality necessary to write in a different unit set has been
removed. This was excessivelty complex, never used in practice, and of
little practical usage. Output numeric data, in general, is not designed
to be conveniently user-readable, so it is not important what unit
system it is written in.
2023-08-08 16:17:57 +01:00
fd2f932bfe DimensionSets: Added milliseconds [ms] and microseconds [us] 2023-08-08 13:12:03 +01:00
bf044f5c47 DimensionedFunction1: Function1 with dimensions
This can be used identically to a standard Function1. In addition, it
also permits specification of the dimensions. This allows the dimensions
to be checked. It also permits unit conversions. For example:

    <name>
    {
        type        table;

        // Dimensions
        xDimensions [CAD];  // Optional. Argument dimensions/units.
                            // Here, this specifies coordinates are in
                            // crank angle degrees (available if using
                            // engine time).
        dimensions  [mm];   // Optional. Value dimensions/units.
                            // Here, values are in mm.

        // Tablulated data
        values
        (
            (0 0)
            (60 12)         // <-- i.e., 12 mm at 60 degrees
            (180 20)
            (240 8)
            (360 0)
        );
        outOfBounds repeat;
    }

This replaces TimeFunction1, as it allows per-function control over
whether the function is considered to be one of real-time or user-time.
2023-08-08 13:11:59 +01:00
3a52ee2ac5 src/OpenFOAM/Make/files: added stepInterpolationWeights.C 2023-08-07 14:28:44 +01:00
a05d7f15e5 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2023-08-07 12:11:08 +01:00
50c0530276 stepInterpolationWeights: New interpolation weight for Function1s::Table
Description
    Generates the weight for step-wise interpolation and integration

    The step transitions are at the end of each interval.

The value returned by the Table::value function returns the value set for the
start of each interval within that interval and transitions abruptly to the next
interval value at the start of the next interval.
2023-08-07 12:08:05 +01:00
71ccf51ba5 decomposePar, reconstructPar: Do all regions simultaneously
DecomposePar and reconstructPar now interleave the processing of
multiple regions. This means that with the -allRegions option, the
earlier times are completed in their entirety before later times are
considered. It also lets regions to access each other during
decomposition and reconstruction, which will be important for
non-conformal region interfaces.

To aid interpretation of the log, region prefixing is now used by both
utilities in the same way as is done by foamMultiRun.

DecomposePar has been overhauled so that it matches reconstructPar much
more closely, both in terms of output and of iteration sequence. All
meshes and addressing are loaded simultaneously and each field is
considered in turn. Previously, all the fields were loaded, and each
process and addressing set was considered in turn. This new strategy
optimises memory usage for cases with lots of fields.
2023-08-01 14:25:28 +01:00
58e15f296c Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2023-07-29 16:33:06 +01:00
77f0e7fbdc compressibleVoF/fvModels::VoFTurbulenceDamping: corrected documentation
Resolves bug-report https://bugs.openfoam.org/view.php?id=4000
2023-07-29 16:32:08 +01:00
32a877d236 polyMesh: Prevent "no points/cells" warnings on processor cases 2023-07-28 14:52:04 +01:00
2f579ca041 fluidSolvers: Stabilise rDeltaT calculation
When the flow is stationary (e.g., at the beginning of a run) the
rDeltaT calculation now requires a maxDeltaT setting in the PIMPLE
sub-section of the fvSolution dictionary. This prevents floating point
errors associated with rDeltaT approaching zero.
2023-07-27 12:16:05 +01:00
9cba18a073 Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2023-07-27 10:58:46 +01:00
1e79d0245c MomentumTransferPhaseSystem::partialElimination: Removed the phase velocity mean adjustment
The phase velocity mean adjustment was introduced for consistency with phase
flux mean adjustment which is necessary to ensure the mean flux divergence is
preserved.  However for systems with very high drag it has proved preferable to
not adjust the velocity of the phases to conserve momentum rather than ensure
consistency with the fluxes.
2023-07-27 10:54:52 +01:00
4acddc6ab0 solidThermo: Add rhoThermo interface
The old fluid-specific rhoThermo has been split into a non-fluid
specific part which is still called rhoThermo, and a fluid-specific part
called rhoFluidThermo. The rhoThermo interface has been added to the
solidThermo model. This permits models and solvers that access the
density to operate on both solid and fluid thermophysical models.
2023-07-27 09:20:43 +01:00
65f3050b35 thermophysicalModels: Renamed he*Thermo classes
The he*Thermo classes have been renamed to match their corresponding
basic thermo classes. E.g., rhoThermo now corresponds to RhoThermo,
rather than heRhoThermo.
2023-07-27 08:39:58 +01:00
3c542d664b thermophysicalModels: Primitive mixture classes
Mixture classes (e.g., pureMixtrure, coefficientMulticomponentMixture),
now have no fvMesh or volScalarField dependence. They operate on
primitive values only. All the fvMesh-dependent functionality has been
moved into the base thermodynamic classes. The 'composition()' access
function has been removed from multi-component thermo models. Functions
that were once provided by composition base classes such as
basicSpecieMixture and basicCombustionMixture are now implemented
directly in the relevant multi-component thermo base class.
2023-07-27 08:39:58 +01:00
966457788c IOerror: Split location into separate class
This simplifies the IOerror constructors and allows for the location to
be conveniently cached for errors that can't be triggered until after
the IO operation.
2023-07-27 08:39:58 +01:00
87ff44aeb8 tutorials: Simplified dimensionless specification from [0 0 0 0 0 0 0] -> [] 2023-07-26 18:37:57 +01:00
66188fac7a XiFluid, PDRFoam: Updated so that coefficients can be specified without dimensions
All associated combustion tutorials have been simplified using this functionality.
2023-07-26 14:44:10 +01:00
a9a75605cb Test-Function1: Minor clean-up 2023-07-26 12:35:59 +01:00
6655627b0d Merge branch 'master' of github.com-OpenFOAM:OpenFOAM/OpenFOAM-dev 2023-07-26 12:35:42 +01:00
ab5b45c3be InjectionModel: Corrected normalisation of flowRateProfile for user time 2023-07-25 15:51:21 +01:00
d98d2c371a MPLIC: Add an explicit error detailing incompatibility with NCC
Resolves bug report https://bugs.openfoam.org/view.php?id=3999
2023-07-25 09:02:35 +01:00
dd53598fa2 functionObjects::wallHeatFlux: Improved the diagnostic message 2023-07-24 10:09:14 +01:00
c772291a9c engineCompRatio: Added support for specifying the combustion chamber cellSet/Zone
Application
    engineCompRatio

Description
    Calculate the compression ratio of the engine combustion chamber

    If the combustion chamber is not the entire mesh a \c cellSet or
    \c cellZone name of the cells in the combustion chamber can be provided.

Usage
    \b engineCompRatio [OPTION]

      - \par -cellSet \<name\>
        Specify the cellSet name of the combustion chamber

      - \par -cellZone zoneName
        Specify the cellZone name of the combustion chamber
2023-07-24 10:08:07 +01:00
764a7e570b updated etc/config.sh/bash_completion 2023-07-21 18:59:24 +01:00
6d36c53788 snappyHexMeshConfig: added '-firstLayerThickness' and '-layerExpansionRatio' options 2023-07-21 17:55:22 +01:00
2d39211826 foamExec: Improve correctness of splitting and check for envsubst 2023-07-21 09:11:07 +01:00
55e5b17d92 snappyHexMeshConfig: clean surfaces to improve closedness test 2023-07-20 18:08:47 +01:00
1608401ee6 tutorials/multiphaseEuler/wallBoilingIATE/0/T.gas: Corrected q 2023-07-20 17:39:18 +01:00