1. 22 Dec, 2020 1 commit
  2. 16 Dec, 2020 2 commits
    • Mark Olesen's avatar
    • Mark Olesen's avatar
      ENH: lazier handling of dynamic libraries · 2811c054
      Mark Olesen authored
      - previously always called dlclose on opened libraries when destroying
        the dlLibraryTable. However, by force closing the libraries the
        situation can arise that the library is missing its own code that it
        needs on unload (#1524). This is also sometimes evident when closing
        VTK libraries for runTimePostProcessing (#354, #1585).
      
      - The new default is to not forcibly dlclose any libraries, unless
        the dlcloseOnTerminate OptimisationSwitch specifies otherwise.
      
        - The dlLibraryTable::close() method can be used to explicitly close
          all libraries and clear the list.
      
        - The dlLibraryTable::clear() method now only clears the entries,
          without a dlclose.
      2811c054
  3. 11 Dec, 2020 2 commits
    • Mark Olesen's avatar
      COMP: remove 64-bit label ambiguity · 4fdeb3be
      Mark Olesen authored
      COMP: fix SP/DP inconsistency in fvGeometryScheme
      
      STYLE: rename polyMesh::updateGeom to polyMesh::updateGeomPoints
      
      - avoids compiler complaints and potential masking of
        primitiveMesh::updateGeom / fvMesh::updateGeom
      
      - mark argument as movable, since that is what is happening inside.
      
      GIT: remove merge cruft
      
      TUT: better clean on MPPICInterFoam
      4fdeb3be
    • Mattijs Janssens's avatar
      ENH: primitiveMesh: make geometry calculation runtime selectable · 46dbfabd
      Mattijs Janssens authored
      This adds a 'geometry' scheme section to the system/fvSchemes:
      
      geometry
      {
          type            highAspectRatio;
      }
      
      These 'fvGeometryMethod's are used to calculate
      - deltaCoeffs
      - nonOrthoCoeffs
      etc and can even modify the basic face/cellCentres calculation.
      46dbfabd
  4. 10 Dec, 2020 1 commit
    • sergio's avatar
      ENH: New vibro-acoustic model suite · bc430ccd
      sergio authored
      
      
        - New solver: `acousticFoam`
        - New base finite-area region class: `regionFaModel`
        - New base shell model classes:
          - `vibrationShellModel`
          - `thermalShellModel`
        - New shell models:
          - A vibration-shell model: `KirchhoffShell`
          - A thermal-shell model: `thermalShell`
        - New finite-area/finite-volume boundary conditions:
          - `clampedPlate`
          - `timeVaryingFixedValue`
          - `acousticWaveTransmissive`
        - New base classes for `fvOption` of finite-area methods: `faOption`
        - New `faOption`s:
          - `contactHeatFluxSource`
          - `externalFileSource`
          - `externalHeatFluxSource`
          - `jouleHeatingSource`
        - New tutorial: `compressible/acousticFoam/obliqueAirJet`
      Signed-off-by: Kutalmis Bercin's avatarKutalmis Bercin <kutalmis.bercin@esi-group.com>
      bc430ccd
  5. 09 Dec, 2020 2 commits
    • mattijs's avatar
      ENH: mpi: use per-application communicator. · 89f2cda3
      mattijs authored
      89f2cda3
    • Mark Olesen's avatar
      ENH: reduce use of readdir on individual processors (#1946) · 627d79db
      Mark Olesen authored
      - implicitly enabled when timeStampMaster (default) is used
        for the fileModificationChecking
      
      - When running with non-distributed roots (eg, NFS-share) read for
        processor directories on master only and send to sub-processes
        instead individual reads.
      
      - If disabled (old default, or when running with distributed roots),
        uses the regular fileHandler readDir, which may perform readDir
        on each processor. Potentially slow startup times on large systems.
      
      Improvements based on analysis from T.Aoyagi(RIST), A.Azami(RIST)
      627d79db
  6. 08 Dec, 2020 1 commit
  7. 30 Nov, 2020 1 commit
  8. 25 Nov, 2020 1 commit
    • Mark Olesen's avatar
      ENH: improve flexiblity for flat output of items (#1929) · 0de32a6e
      Mark Olesen authored
      - change to a templated implementation instead of relying on
        the container's writeList() method.
      
        This inlines the generation while also adding the flexibility to
        define different delimiters (at compile time) without the
        performance penalty of passing run-time parameters.
      0de32a6e
  9. 19 Nov, 2020 3 commits
  10. 17 Nov, 2020 1 commit
  11. 28 Oct, 2020 1 commit
    • Mark Olesen's avatar
      ENH: support true/false, yes/no values for FOAM_ABORT (#1896) · 410d38b9
      Mark Olesen authored
      - consistent with FOAM_SIGFPE etc.
      
      - centralize code as error::useAbort() static function to avoid
        scattering the logic throughout the code.
      
      ENH: also accept "0" and "1" string values for Switch
      
      - not the normal path for Switch input (eg, from a dictionary), but
        consistent with bool definitions and simplifies string parsing.
      
        This means that `FOAM_SIGFPE=1 application` will now also work.
      410d38b9
  12. 19 Oct, 2020 2 commits
    • Mark Olesen's avatar
      ENH: add api/patch information to FatalError (#1880) · f425424e
      Mark Olesen authored
      - can be useful when confronted with partial outputs
      
      - provision for redirecting error/warning
      f425424e
    • Mark Olesen's avatar
      ENH: add ROOTGREAT constants (symmetry with ROOTSMALL) · 1071d413
      Mark Olesen authored
      ENH: add some scalar constants for .org compatibility (#1881)
      
      Although it can very much be a moving target, it can prove partly
      useful to have some compatibility constants/methods.
      
      - The wholesale change of 'GREAT' -> 'great' etc (JAN-2018), makes
        user coding for multiple versions problematic. When
        COMPAT_OPENFOAM_ORG is defined, now define constants (aliases) named
        as per the openfoam.org version. Values, however, remain identical.
      
      - For type-safe dictionary value retrieval, we have the templated
        get<> methods added around NOV-2018 and deprecated the lookupType
        method.
      
        The .org version followed suit in NOV-2019, but opted for renaming
        the templated lookupType method as a templated 'lookup' method.
      
        Using this is discouraged, but allowed when COMPAT_OPENFOAM_ORG is
        defined.
      1071d413
  13. 15 Oct, 2020 1 commit
  14. 12 Oct, 2020 1 commit
    • Mark Olesen's avatar
      ENH: add UPstream::parRun(const bool) · 9c7aa972
      Mark Olesen authored
      - slightly neater code when disabling/restoring parallel state
      
        New
            const bool oldParRun = Pstream::parRun(false);
            ...
            Pstream::parRun(oldParRun);
      
        Old
            const bool oldParRun = Pstream::parRun();
            Pstream::parRun() = false;
            ...
            Pstream::parRun() = oldParRun;
      9c7aa972
  15. 02 Oct, 2020 1 commit
    • Mark Olesen's avatar
      ENH: primitiveEntry construct with empty token list · f9190e2a
      Mark Olesen authored
      - contents to be filled with a later assignment.
      
        This can help avoid deduction issues when populating from a list of
        tokens, and the templated version is selected:
      
        ```
        template<class T>
        primitiveEntry(const keyType&, const T&);
        ```
      
      ENH: support construct empty ITstream with given name
      
      - populate contents later by assigment
      f9190e2a
  16. 01 Oct, 2020 1 commit
    • Mark Olesen's avatar
      ENH: add identity(IntRange) and Istream operator for common types · 56c9134c
      Mark Olesen authored
      - provides consistency with identity(label, label) and looks more
        familiar than using labelRange::labels()
      
      - relocates labelRange IO operators to IntRange
      
      ENH: make sliceRange interators random access
      
      STYLE: scalarRanges::match() instead of predicate operator
      56c9134c
  17. 28 Sep, 2020 2 commits
    • Mark Olesen's avatar
      ENH: add UPstream::subProcs() static method · 5dc5ea92
      Mark Olesen authored
      - returns a range of `int` values that can be iterated across.
        For example,
      
            for (const int proci : Pstream::subProcs()) { ... }
      
        instead of
      
            for
            (
                int proci = Pstream::firstSlave();
                proci <= Pstream::lastSlave();
                ++proci
            )
            {
                ...
            }
      5dc5ea92
    • Mark Olesen's avatar
      ENH: add UPstream::allProcs() method · e18ff114
      Mark Olesen authored
      - returns a range of `int` values that can be iterated across.
        For example,
      
            for (const int proci : Pstream::allProcs()) { ... }
      
        instead of
      
            for (label proci = 0; proci < Pstream::nProcs(); ++proci) { ... }
      e18ff114
  18. 10 Sep, 2020 1 commit
  19. 10 Aug, 2020 1 commit
    • Mark Olesen's avatar
      ENH: direct access to wrapped ifstream/ofstream with compression (#1805) · 6e2b7be9
      Mark Olesen authored
      - previously hidden as Detail::[IO]FstreamAllocator, now exposed
        directly as [io]fstreamPointer, which allows reuse for
        std::ifstream, std::ofstream wrapping, without the additional
        ISstream, OSstream layers.
      
        These stream pointers have some characteristics similar to a
        unique_ptr.
      
      - restrict direct gzstream usage to two files (fstreamPointers.C,
        gzstream.C) which improves localization and makes it simpler to
        enable/disable with the `HAVE_LIBZ` define.
      
        The HAVE_LIBZ define is currently simply hard-coded in the
        Make/options.
      
        If compiled WITHOUT libz support:
          - reading gz files : FatalError
          - writing gz files : emit warning and downgrade to uncompressed
          - warn if compression is specified in the case controlDict
            and downgrade to uncompressed
      
      ENH: minor updates to gzstream interface for C++11
      
      - support construct/open with std::string for the file names.
      
      CONFIG: provisioning for have_libz detect...
      6e2b7be9
  20. 06 Aug, 2020 1 commit
    • Mark Olesen's avatar
      ENH: finer granularity for handling functionObject failure (#1779) · 5424c5e5
      Mark Olesen authored
      - additional "errors" entry with enumerated values
        (default|warn|ignore|strict) for defining warning or error at
        construct or runtime stage
      
      - default : construct = warn, runtime = fatal
      - warn    : construct = warn, runtime = warn
      - ignore  : construct = silent, runtime = silent
      - strict  : construct = fatal, runtime = fatal
      
      The errors control can be added at the top-level and/or for individual
      function objects.
      5424c5e5
  21. 30 Jul, 2020 1 commit
  22. 22 Jul, 2020 2 commits
  23. 16 Jul, 2020 2 commits
    • Mark Olesen's avatar
      STYLE: check autoPtr as plain bool instead of valid() · 12c91b94
      Mark Olesen authored
      - cleaner code, more similarity with unique_ptr
      
        Now
            if (ptr)
            if (!ptr)
      
        instead
            if (ptr.valid())
            if (!ptr.valid())
      12c91b94
    • Mark Olesen's avatar
      STYLE: simplify short-circuit involving autoPtr (#1775) · 9af3f85c
      Mark Olesen authored
      - with '&&' conditions, often better to check for non-null autoPtr
        first (it is cheap)
      
      - check as bool instead of valid() method for cleaner code, especially
        when the wrapped item itself has a valid/empty or good.
        Also when handling multiple checks.
      
        Now
            if (ptr && ptr->valid())
            if (ptr1 || ptr2)
      
        instead
            if (ptr.valid() && ptr->valid())
            if (ptr1.valid() || ptr2.valid())
      9af3f85c
  24. 14 Jul, 2020 2 commits
    • Mark Olesen's avatar
      ENH: mutable libs() access in Time and other classes (#1737) · 1e7c6ea2
      Mark Olesen authored
      - This reflects the pre-existing coding situation where const_cast was
        used throughout to effect the same.
      
      STYLE: fix private/protected access
      
      - CodedField, codedMixedFvPatchField
      1e7c6ea2
    • Mark Olesen's avatar
      ENH: various dlLibraryTable improvements/refinements (#1737) · 41d3e6f1
      Mark Olesen authored
      - libs() singleton method for global library handling
      
      - explicit handling of empty filename for dlLibraryTable open/close.
        Largely worked before, but now be more explicit about its behaviour.
      
      - add (key, dict) constructor and open() methods.
        More similarity to dimensionedType, Enum etc, and there is no
        ambiguity with the templated open().
      
      - construct or open from initializer_list of names
      
      - optional verbosity when opening with auxiliary table,
        avoid duplicate messages or spurious messages for these.
      
      - basename and fullname methods (migrated from dynamicCode).
      
      - centralise low-level load/unload hooks
      
      - adjust close to also dlclose() aliased library names.
      41d3e6f1
  25. 09 Jul, 2020 1 commit
    • Mark Olesen's avatar
      ENH: use unique_ptr for memory management of profiling · a088bda4
      Mark Olesen authored
      - makes it easier to distinguish between pointers referring to pool
        data versus pointers actually holding storage, avoids
        manual demand-driven deletion and autoPtr.
      
      ENH: simplify/improve Pstream profiling
      
      - times now double (not scalar) for consistency with what cpuTime
        delivers
      
      - use bool to track suspend state
      a088bda4
  26. 26 Jun, 2020 1 commit
  27. 23 Jun, 2020 1 commit
  28. 22 Jun, 2020 2 commits
  29. 16 Jun, 2020 1 commit