Skip to content
Snippets Groups Projects
  1. Jun 15, 2020
  2. Jun 09, 2020
    • Henning Scheufler's avatar
      CONT: Addition of compressibleIsoInterFOam and PLIC · 44a84d47
      Henning Scheufler authored and Andrew Heather's avatar Andrew Heather committed
         1) Implementation of the compressibleIsoInterFOam solver
         2) Implementation of a new PLIC interpolation scheme.
         3) New tutorials associated with the solvers
      
      This implementation was carried out by Henning Scheufler (DLR) and Johan
      Roenby (DHI), following :
      
      \verbatim
      
      Henning Scheufler, Johan Roenby,
      Accurate and efficient surface reconstruction from volume fraction data
      on general meshes, Journal of Computational Physics, 2019, doi
      10.1016/j.jcp.2019.01.009
      
      \endverbatim
      
      The integration of the code was carried out by Andy Heather and Sergio
      Ferraris from OpenCFD Ltd.
      44a84d47
  3. Jun 03, 2020
    • sergio's avatar
      COM: Separate htc FO from general FO and reactingEuler solvers (#1714) · 95f7ed03
      sergio authored and Mark OLESEN's avatar Mark OLESEN committed
      The phase systems tables for multiphase solvers create conflict
      between each other as they are defined in the same namespace and using
      similar class names.
      
      Therefore a special htc function object for reactingEulerSolver was
      added (reactingEulerHtcModel), located under
      src/phaseSystemModels/reactingEulerFoam/functionObjects/
      
      This commit includes the following:
      
      - Relocate solvers/reactingEulerFoam functionObjects to
        src/phaseSystemModels
      - Remove links for fieldFunctionObject to multiphase libs to avoid
        conflicts
      - New FO for htc for reactingEulerFoam called reactingEulerHtcModel
      95f7ed03
  4. May 12, 2020
    • Mark OLESEN's avatar
      ENH: add 'subcommand' handling to wmake (#1693) · 9e3d0685
      Mark OLESEN authored
      - initial split of wmake-related commands into "plumbing" and
        "porcelain" akin to how git handles things.
      
      - wmakeBuildInfo (very low-level), now relocated to the wmake/scripts
        and accessible for the user as "wmake -build-info".
      
        This satisfies a long-standing desire to access build information
        in a fashion similar to the api/patch information.
      
      CONFIG: avoid git information when building with a debian/ directory
      
      - when a 'debian/' directory exists, there is a high probability that
        the '.git/' directory is from debian and not from OpenFOAM (ie,
        useless here). This corresponds to an implicit '-no-git', which has
        no effect when building from pristine sources.
      
      ENH: wmakeCheckPwd becomes scripts/wmake-check-dir
      
      - accessible for the user as "wmake -check-dir" and with 1 or 2
        directory names. A wmakeCheckPwd symlink left for compatibility.
      9e3d0685
  5. Feb 12, 2020
  6. Dec 19, 2019
  7. Dec 14, 2019
  8. Sep 30, 2019
  9. Jul 30, 2019
    • Mark OLESEN's avatar
      ENH: improvements for handling update of build information · 59b867b7
      Mark OLESEN authored
      - When building OpenFOAM for different platform combinations
        (single/double, int32/int64) the build information that is compiled
        into the OpenFOAM lib can become out of sync.
      
        This is because the update trigger (wmakeBuildInfo -check) is
        independent of the targetted platform. The added file
        'src/OpenFOAM/Alltouch' provides a direct means of forcing a rebuild
        of the version information. Eg,
      
            src/OpenFOAM/Alltouch
            wmake src/OpenFOAM
      
        Also provide an additional 'wmakeBuildInfo -remove' to forcibly
        remove META-INFO/build-info, if that is desired.
      59b867b7
  10. Jun 17, 2019
    • Vaggelis Papoutsis's avatar
      CONTRIB: New adjoint optimisation and tools · ecc1fb5e
      Vaggelis Papoutsis authored
      A set of libraries and executables creating a workflow for performing
      gradient-based optimisation loops. The main executable (adjointOptimisationFoam)
      solves the flow (primal) equations, followed by the adjoint equations and,
      eventually, the computation of sensitivity derivatives.
      
      Current functionality supports the solution of the adjoint equations for
      incompressible turbulent flows, including the adjoint to the Spalart-Allmaras
      turbulence model and the adjoint to the nutUSpaldingWallFunction, [1], [2].
      
      Sensitivity derivatives are computed with respect to the normal displacement of
      boundary wall nodes/faces (the so-called sensitivity maps) following the
      Enhanced Surface Integrals (E-SI) formulation, [3].
      
      The software was developed by PCOpt/NTUA and FOSS GP, with contributions from
      
      Dr. Evangelos Papoutsis-Kiachagias,
      Konstantinos Gkaragounis,
      Professor Kyriakos Giannakoglou,
      Andy Heather
      
      and contributions in earlier version from
      
      Dr. Ioannis Kavvadias,
      Dr. Alexandros Zymaris,
      Dr. Dimitrios Papadimitriou
      
      [1] A.S. Zymaris, D.I. Papadimitriou, K.C. Giannakoglou, and C. Othmer.
      Continuous adjoint approach to the Spalart-Allmaras turbulence model for
      incompressible flows. Computers & Fluids, 38(8):1528–1538, 2009.
      
      [2] E.M. Papoutsis-Kiachagias and K.C. Giannakoglou. Continuous adjoint methods
      for turbulent flows, applied to shape and topology optimization: Industrial
      applications. 23(2):255–299, 2016.
      
      [3] I.S. Kavvadias, E.M. Papoutsis-Kiachagias, and K.C. Giannakoglou. On the
      proper treatment of grid sensitivities in continuous adjoint methods for shape
      optimization. Journal of Computational Physics, 301:1–18, 2015.
      
      Integration into the official OpenFOAM release by OpenCFD
      ecc1fb5e
  11. Jun 12, 2019
  12. Jun 07, 2019
    • Sergio Ferraris's avatar
      INT: Org integration of VOF, Euler phase solvers and models. · 8170f2ad
      Sergio Ferraris authored
      Integration of VOF MULES new interfaces. Update of VOF solvers and all instances
      of MULES in the code.
      Integration of reactingTwoPhaseEuler and reactingMultiphaseEuler solvers and sub-models
      Updating reactingEuler tutorials accordingly (most of them tested)
      
      New eRefConst thermo used in tutorials. Some modifications at thermo specie level
      affecting mostly eThermo. hThermo mostly unaffected
      
      New chtMultiRegionTwoPhaseEulerFoam solver for quenching and tutorial.
      
      Phases sub-models for reactingTwoPhaseEuler and reactingMultiphaseEuler were moved
      to src/phaseSystemModels/reactingEulerFoam in order to be used by BC for
      chtMultiRegionTwoPhaseEulerFoam.
      
      Update of interCondensatingEvaporatingFoam solver.
      8170f2ad
  13. Apr 28, 2019
  14. Apr 11, 2019
  15. Feb 04, 2019
  16. Jan 31, 2019
  17. Jan 30, 2019
  18. Jan 17, 2019
  19. Dec 03, 2018
    • Mark OLESEN's avatar
      CONFIG: adjustments to environment · b8c257d6
      Mark OLESEN authored
      - provide default WM_DIR if not already set, to improve robustness if a
        reduced environment is used
      
      - add etc/ to WM_PROJECT_SITE search. This makes the site directory
        structure consistent with the OpenFOAM structure.
        Eg,
      
            WM_PROJECT_SITE/etc/..
            WM_PROJECT_SITE/bin/..
            WM_PROJECT_SITE/platforms/..
      
      - Don't set/export WM_OSTYPE.  The default is POSIX and is properly
        defaulted throughout, including in CMakeLists-OpenFOAM.txt (also for
        Catalyst)
      b8c257d6
  20. Dec 02, 2018
    • Mark OLESEN's avatar
      ENH: update handling of versioning and make control (issue #1010) · 6c68c34e
      Mark OLESEN authored
      - Use the OPENFOAM define (eg, 1806, 1812), which normally corresponds
        to a major release, to define an API level. This remains consistent
        within a release cycle and means that it is possible to manage
        several sub-versions and continue to have a consistent lookup.
      
        The current API value is updated automatically during the build
        and cached as meta data for later use, even when the wmake/ directory
        is missing or OpenFOAM has not yet be initialized.
      
        The version information reported on program start or with -help
        usage adjusted to reflect this. The build tag from git now also
        carries the date as being more meaningful to trace than a hash
        value.
      
      - Update etc/bashrc and etc/cshrc to obtain the project directory
        directly instead of via its prefix directory. The value obtained
        corresponds to an absolute path, from which the prefix directory
        can be obtained.
      
        The combination of these changes removes the reliance on any
        particular directory naming convention.
        For example,
      
           With an 1812 version (API level):
      
           WM_PROJECT_VERSION=myVersion
      
           installed as /some/path/somewhere/openfoam-mySandbox
      
        This makes the -prefix, -foamInstall, -projectVersion, -version
        values of foamEtcFiles, and similar entries for foamConfigurePaths
        superfluous.
      
        WM_PROJECT_INST_DIR is no longer required or used
      
      ENH: improve handling and discovery of ThirdParty
      
      - improve the flexibility and reusability of ThirdParty packs to cover
        various standard use cases:
      
          1. Unpacking initial release tar files with two parallel directories
             - OpenFOAM-v1812/
             - ThirdParty-v1812/
      
          2. With an adjusted OpenFOAM directory name, for whatever reason
             - OpenFOAM-v1812-myCustom/
             - openfoam-1812-other-info/
      
          3. Operating with/without ThirdParty directory
      
        To handle these use cases, the following discovery is used.
      
        Note PROJECT = the OpenFOAM directory `$WM_PROJECT_DIR`
             PREFIX = the parent directory
             VERSION = `$WM_PROJECT_VERSION`
             API = `$WM_PROJECT_API`, as per `foamEtcFiles -show-api`
      
         0. PROJECT/ThirdParty
            - for single-directory installations
      
         1. PREFIX/ThirdParty-VERSION
            - this corresponds to the traditional approach
      
         2. PREFIX/ThirdParty-vAPI
            - allows for an updated value of VERSION (eg, v1812-myCustom)
              without requiring a renamed ThirdParty. The API value
              would still be '1812' and the original ThirdParty-v1812/
              would be found.
      
         3. PREFIX/ThirdParty-API
            - this is the same as the previous example, but using an unadorned
              API value. This also makes sense if the chosen version name also
              uses the unadorned API value in its naming
              (eg, 1812-patch190131, 1812.19W03)
      
         4. PREFIX/ThirdParty-common
            - permits maximum reuse for various versions, but only for
              experienced user who are aware of potential version
              incompatibilities
      
         Directory existence is checked as is the presence of an Allwmake file
         or a platforms/ directory. This reduces the potential of false positive
         matches and limits the selection to directories that are either
         with sources (has the Allwmake file), or pre-compiled binaries (has
         the platforms/ directory).
      
         If none of the explored directories are found to be suitable,
         it reverts to using a PROJECT/ThirdParty dummy location since
         this is within the project source tree and can be trusted to
         have no negative side-effects.
      
      ENH: add csh support to foamConfigurePaths
      
      - this removes the previously experienced inconsistence in config file
        contents.
      
      REMOVED: foamExec
      
      - was previously used when switching versions and before the
        bashrc/cshrc discovery logic was added. It is now obsolete.
      6c68c34e
  21. Jan 18, 2018
  22. Dec 19, 2017
  23. Apr 24, 2018
    • Mark OLESEN's avatar
      ENH: improve handling of ThirdParty packages · b4d38ab4
      Mark OLESEN authored
      - generalize some of the library extensions (.so vs .dylib).
        Provide as wmake 'sysFunctions'
      
      - added note about unsupported/incomplete system support
      
      - centralize detection of ThirdParty packages into wmake/ subdirectory
        by providing a series of scripts in the spirit of GNU autoconfig.
        For example,
      
            have_boost, have_readline, have_scotch, ...
      
        Each of the `have_<package>` scripts will generally provide the
        following type of functions:
      
            have_<package>          # detection
            no_<package>            # reset
            echo_<package>          # echoing
      
        and the following type of variables:
      
            HAVE_<package>          # unset or 'true'
            <package>_ARCH_PATH     # root for <package>
            <package>_INC_DIR       # include directory for <package>
            <package>_LIB_DIR       # library directory for <package>
      
        This simplifies the calling scripts:
      
            if have_metis
            then
                wmake metisDecomp
            fi
      
        As well as reducing clutter in the corresponding Make/options:
      
            EXE_INC = \
                -I$(METIS_INC_DIR) \
                -I../decompositionMethods/lnInclude
      
            LIB_LIBS = \
                -L$(METIS_LIB_DIR) -lmetis
      
        Any additional modifications (platform-specific or for an external build
        system) can now be made centrally.
      b4d38ab4
  24. Apr 12, 2018
  25. Mar 15, 2018
  26. Sep 15, 2017
  27. Mar 20, 2018
    • Henry Weller's avatar
      ENH: atmosphericModels: Added Lopes da Costa porosity and turbulence models · c812b4c6
      Henry Weller authored and Andrew Heather's avatar Andrew Heather committed
      Specialized variants of the power law porosity and k epsilon turbulence models
      developed to simulate atmospheric flow over forested and non-forested complex
      terrain.
      
      Class
          Foam::powerLawLopesdaCosta
      
      Description
          Variant of the power law porosity model with spatially varying
          drag coefficient
      
          given by:
      
              \f[
                  S = -\rho C_d \Sigma |U|^{(C_1 - 1)} U
              \f]
      
          where
          \vartable
              \Sigma | Porosity surface area per unit volume
              C_d    | Model linear coefficient
              C_1    | Model exponent coefficient
          \endvartable
      
          Reference:
          \verbatim
              Costa, J. C. P. L. D. (2007).
              Atmospheric flow over forested and non-forested complex terrain.
          \endverbatim
      
      Class
          Foam::RASModels::kEpsilonLopesdaCosta
      
      Description
          Variant of the standard k-epsilon turbulence model with additional source
          terms to handle the changes in turbulence in porous regions represented by
          the powerLawLopesdaCosta porosity model.
      
          Reference:
          \verbatim
              Costa, J. C. P. L. D. (2007).
              Atmospheric flow over forested and non-forested complex terrain.
          \endverbatim
      
          The default model coefficients are
          \verbatim
              kEpsilonLopesdaCostaCoeffs
              {
                  Cmu         0.09;
                  C1          1.44;
                  C2          1.92;
                  sigmak      1.0;
                  sigmaEps    1.3;
              }
          \endverbatim
      
      Tutorial case to follow.
      c812b4c6
  28. Oct 19, 2017
    • Will Bainbridge's avatar
      ENH: semiPermeableBaffle: Added two new boundary conditions and a tutorial · 79ad0f06
      Will Bainbridge authored and Andrew Heather's avatar Andrew Heather committed
      Two boundary conditions for the modelling of semi-permeable baffles have
      been added. These baffles are permeable to a number of species within
      the flow, and are impermeable to others. The flux of a given species is
      calculated as a constant multipled by the drop in mass fraction across
      the baffle.
      
      The species mass-fraction condition requires the transfer constant and
      the name of the patch on the other side of the baffle:
      
      boundaryField
      {
          // ...
      
          membraneA
          {
              type            semiPermeableBaffleMassFraction;
              samplePatch     membranePipe;
              c               0.1;
              value           uniform 0;
          }
          membraneB
          {
              type            semiPermeableBaffleMassFraction;
              samplePatch     membraneSleeve;
              c               0.1;
              value           uniform 1;
          }
      }
      
      If the value of c is omitted, or set to zero, then the patch is
      considered impermeable to the species in question. The samplePatch entry
      can also be omitted in this case.
      
      The velocity condition does not require any special input:
      
      boundaryField
      {
          // ...
      
          membraneA
          {
              type            semiPermeableBaffleVelocity;
              value           uniform (0 0 0);
          }
          membraneB
          {
              type            semiPermeableBaffleVelocity;
              value           uniform (0 0 0);
          }
      }
      
      These two boundary conditions must be used in conjunction, and the
      mass-fraction condition must be applied to all species in the
      simulation. The calculation will fail with an error message if either is
      used in isolation.
      
      A tutorial, combustion/reactingFoam/RAS/membrane, has been added which
      demonstrates this transfer process.
      
      This work was done with support from Stefan Lipp, at BASF.
      79ad0f06
  29. Jun 23, 2017
    • Mark OLESEN's avatar
      ENH: integration of lumpedPointMotion · c0b38033
      Mark OLESEN authored
      - This provides a mechanism for moving mesh patches based on external
        input (eg, from an external structures solver). The patch points are
        influenced by the position and rotation of the lumped points.
      
        BC:  lumpedPointDisplacementPointPatchVectorField
      
        Controlling mechanisms:
        - externalCoupler
          for coordinating the master/slave
      
        - lumpedPointMovement
          manages the patch-points motion, but also for extracting forces/moments
      
        - lumpedPointState
          represents the positions/rotations of the controlling points
      
        Utils:
        - lumpedPointZones
          diagnostic for visualizing the correspondence between controlling
          points and patch faces
      
        - lumpedPointMovement
          Test that the patch motion is as desired without invoking moveMesh.
          With the -slave option, return items from a precalculated table
          for the lumpedPointDisplacementPointPatchVectorField BC.
      c0b38033
  30. Jun 14, 2017
    • mattijs's avatar
      ENH: overset: Initial release of overset capability. · fd665b4a
      mattijs authored
      Adds overset discretisation to selected physics:
      - diffusion : overLaplacianDyMFoam
      - incompressible steady : overSimpleFoam
      - incompressible transient : overPimpleDyMFoam
      - compressible transient: overRhoPimpleDyMFoam
      - two-phase VOF: overInterDyMFoam
      
      The overset method chosen is a parallel, fully implicit implementation
      whereby the interpolation (from donor to acceptor) is inserted as an
      adapted discretisation on the donor cells, such that the resulting matrix
      can be solved using the standard linear solvers.
      
      Above solvers come with a set of tutorials, showing how to create and set-up
      simple simulations from scratch.
      fd665b4a
  31. May 18, 2017
  32. Apr 21, 2017
  33. Apr 04, 2017
    • Mark Olesen's avatar
      ENH: reduce reliance on FOAM_EXT_LIBBIN during builds · dd78e042
      Mark Olesen authored
      - just check WM_PROJECT_DIR instead.
      
      - provide a fallback value when FOAM_EXT_LIBBIN might actually be needed.
      
      Only strictly need FOAM_EXT_LIBBIN for scotch/metis decomposition, and
      when these are actually supplied by ThirdParty.
      All other ThirdParty dependencies are referenced by BOOST_ARCH_PATH etc.
      
      Can therefore drop the FOAM_EXT_LIBBIN dependency for VTK-related
      things, which do not use scotch/metis anyhow.
      dd78e042
  34. Mar 27, 2017
  35. Mar 20, 2017
    • Mark Olesen's avatar
      ENH: minor improvements to environment · b970ba09
      Mark Olesen authored
      - handle sourcing bashrc with a relative path (issue #383)
      - handle sourcing from bash and zsh.
        Still need manual intervention when sourcing dash, sh, or ksh.
      - replace grep in etc/cshrc with sed only
      - logical instead of physical path for WM_PROJECT_DIR (issue #431).
        Doesn't seem to be possible for csh/tcsh.
      
        * Continue using physical locations when comparing directories,
          but not for the top-level FOAM_INST_DIR, WM_PROJECT_DIR.
      
      - relocate WM_CC, WM_CXX overrides from etc/config.*/compiler
        to etc/config.*/settings to ensure that they are left untouched
        when etc/config.sh/compiler is sourced while making third-party
        packages (eg, gcc, llvm, CGAL).
      
      - provide fallback FOAM_TUTORIALS setting in RunFunctions
      
      STYLE: remove "~OpenFOAM" fallback as being too rare, non-obvious
      b970ba09
  36. Feb 06, 2017
  37. Jan 28, 2017
  38. Dec 22, 2016
    • Mark Olesen's avatar
      COMP: update lnInclude directories when building (issue #364) · 608bb5d8
      Mark Olesen authored
      - Could be related to interrupted builds.
        So if there are any parts of the build that rely on an explicit
        'wmakeLnInclude', make sure that the contents are properly updated.
      
      --
      
      ENH: improved feedback from top-level Allwmake
      
      - Report which section (libraries, applications) is being built.
      
      - Provide final summary of date, version, etc, which can be helpful
        for later diagnosis or record keeping.
      
      - The -log=XXX option for Allwmake now accepts a directory name
        and automatically appends an appropriate log name.
        Eg,
            ./Allwmake -log=logs/  ->> logs/log.linux64GccDPInt32Opt
      
        The default name is built from the value of WM_OPTIONS.
      
      --
      
      BUG: shell not exiting properly in combination with -log option
      
      - the use of 'tee' causes the shell to hang around.
        Added an explicit exit to catch this.
      
      --
      
      - Detecting the '-k' (-non-stop) option at the top-level Allwmake, which
        may improve robustness.
      
      - Explicit continue-on-error for foamyMesh (as optional component)
      
      - unify format of script messages for better readability
      
      COMP: reduce warnings when building Pstream (old-style casts in openmpi)
      608bb5d8