Close

20th July 2021

OpenFOAM 9 Released

The OpenFOAM Foundation is pleased to announce the release of version 9 of the OpenFOAM open source CFD toolbox. Version 9 is a snapshot of the OpenFOAM development version which, through sustainable development, is always-releasable.  It provides new functionality and major improvements to existing code, with strict demands on usability, robustness and extensibility.

OpenFOAM 9 includes the following key developments.

  • Multiphase: improved the performance, numerics and robustness of multiphase solvers.
  • Transport: muticomponent diffusion and the redesign of ThermophysicalTransportModels.
  • Thermophysical: automatic compilation of model packages, mixing rules, tabulated input.
  • Heat transfer: made calculations consistent between solvers, BCs and post-processing.
  • Particle tracking: cloud types selected by user, not hard-coded into solvers.
  • Reactions: improved robustness of numerics and chemistry and added general controls.
  • Mesh: refactored parts of snappyHexMesh, decomposition and manipulation tools.
  • Surface Film: introduced standard thermophysical modelling.
  • Function Objects: overhaul of packaged function objects for improved usability.
  • Models and Constraints: fvOptions replaced by more flexible fvModels and fvConstraints.
  • Case Configuration: enhanced scripts and added new Function2 functions of 2 variables.
  • Computation: improved robustness and performance of I/O, compilation, numerics.
  • Approximately 750 code commits, 200+ resolved issues.
  • ISO/IEC 14882:2011 (C++14): tested for GCC v5.4+, Clang v10+ (v4+ should also work).

OpenFOAM 9 is packaged for the following platforms, with ParaView 5.6 including Mesa with LLVM/Gallium acceleration for systems without a (supported) graphics card:

The OpenFOAM 9 Source Pack can be compiled on suitable Linux platforms.

Multiphase

  • Modelling: Corrected energy changes due to mass transfer at the interface in multiphaseEulerFoam [ commit 0efc49 ]. In compressibleInterFoam, mixture models are based on mass fraction for thermodynamic properties and volume fraction for transport properties [ commit 1988e3 ]. Centralised the compilation of multiphase momentum and thermophysical transport models [ commit 8a5ee8 ]. compressibleInterFoam supports particle clouds which can impinge on walls, forming a film, which in turn can transfer to the VoF when the film is thick enough to resolve [ commit 707fb6 ]. For surface tension at walls the contact angle can now be specified in any phase in multiphase solvers [ commit de7642 ].
  • Reacting Multiphase (with VTT Finland and HZDR Dresden-Rossendorf): New phaseSurfaceArrhenius reaction calculates a reaction rate at a surface of a phase in a multiphase simulation [ commit 3f64e2 ]. Added fvOption source terms, modified sizeGroup equation and corrected density change drift model [ commits 1cbb70 ]. New bubblePipe tutorial with population balance modelling in multiphaseEulerFoam [ commit 01205c ].
  • Performance/Numerics: Improved the limiting of multiple phases in multiphaseEulerFoam [ commits 058562 ], switchable back to the old method for testing [ commit d92665 ]. multiphaseEulerFoam and reactingFoam include a frozenFlow switch to disable the flow in a simulation [ commit 0e8391 ]. Corrected the kinetic energy term to ensure conservation across a shock in multiphaseEulerFoam [ commit a060c6 ]. Pressure controls added to multiphaseEulerFoam consistent with compressible solvers [ commit 762fb4 ]. Improved conservation and boundedness of multiphaseEulerFoam for moving mesh cases [ commit bdf45f ].
  • Tutorials: New isothermalGrowth example case for multiphaseEulerFoam [ commit b92955 ]. New containerDischarge2D example case with liquid discharge from the container [ commit 6b469e ]. The mixerVessel2D case for multiphaseEulerFoam is now fully incompressible to demonstrate pressure referencing [ commit 4865cd ].

Transport Modelling

  • MomentumTransportModels: New thixotropic momentum transport model [ commit 9105b8 ].
  • ThermophysicalTransportModels: Added heat flux models based on temperature gradient (rather than energy) that are stable and efficient [ commit 747cea ]. Improved unityLewis number diffusivity models when solving for internal energy [ commit 8106c1 ]. Improved the heat flux calculation due to differential diffusion of fluid species [ commit 0ea1b2 ].
  • Multicomponent Diffusion: New MaxwellStefanFourier for laminar flow combines the Maxwell Stefan model for multicomponent diffusion with a Fourier heat flux model including optional Soret thermal diffusion of species [ commit 8182a0 ]. New FickianEddyDiffusivity multicomponent transport model calculates heat and mass fluxes using Fick’s Law and eddy viscosity turbulence modelling [ commit e001cd ] with optional temperature-dependent coefficients [ commit c5fc21 ]. New multicomponent FickianFourier mass/energy transport model [ commit 16e975 ].
  • Turbulence: Added the Lopez & Walters (2016) correction to the kkLOmega turbulence model [ commit fdfe5f ]. New kOmega2006 turbulence model, the 2006 version of Wilcox’s k-omega RAS turbulence model [ commit 10a6e7 ].

For more information on transport modelling, see “Redesigning OpenFOAM for the Future”.

Thermophysical Modelling

  • Model Packages: If a package of models (thermodynamics, transport, equation of state) is specified which is not available as standard, the package of is constructed and compiled automatically [ commit 04cab8 ]. Dynamic compilation of packages of thermophysicalProperties to a range of solver applications [ commits f60252 ] and similarly for packages of basic chemistry modelling [ commit 78ef8e ].
  • Thermodynamics: Solid thermophysical modelling no longer requires a pressure field so solid regions in conjugate heat transfer cases no longer need a p file [ commit 51d763 ]. New fluidReactionThermo model allows users to choose a thermophysical model based on density (rho) or compressibility (psi) — rhoReacting(Buoyant)Foam are deprecated in favour of the more general reactingFoam & buoyantReactingFoam solvers [ commit a8e809 ].
  • Mixing Rules: Core maintenance of thermophysical modelling supports the implementation of separate mixing rules for thermodynamics and transport properties [ commit a63b30 ]. New valueMulticomponentMixture model enables general calculations of thermophysical properties for mixtures of species [ commit 995cda ], e.g. the Wilke mixing rule for gaseous transport properties [ commit e638d7 ].
  • Data Input: New rhoTabulated, hTabulatedThermo, tabulatedTransport provide density, enthalpy, viscosity and thermal conductivity from a uniform table in pressure and temperature with fast lookup and interpolation [ commit 13589c ]. Added tabulated thermophysical properties of R12 refrigerant [ commit 6b4b81 ].
  • Refactoring: Improved efficiency of multi-specie thermophysical modelling by caching the calculation of Cp and Cv [ commit 5e146c ].

Heat Transfer

  • Case Setup: Thermal radiation is now included in simulations using the radiation fvOption [ commit 984830 ].
  • Numerics: Updated the wallHeatFlux function object to use the q() function in thermophysicalTransportModel [ commit 16da54 ]. In conjugate heat transfer, the solid heat flux model is now both energy conservative and temperature consistent [ commit f15d15 ].
  • Boundary Conditions: The temperature-coupled boundary conditions use a symmetric tensor for anisotropic thermal conductivity at the boundary patch [ commit 77b31c ]. Corrected and generalised radiative heat transfer in the externalWallHeatFuxTemperature boundary condition [ commit bdbb2a ].
  • Data Processing: Added integrated and average calculations to the wallHeatFlux function object [ commit 9b2f93 ]. Redesigned the wall heat transfer function object with options to calculate it as an effective diffusivity or using the Reynolds analogy [ commit c0978a ].

Particles and Tracking

  • Solvers: The composition of particles is now independent of the continuous phase [ commit 40d3db ].
  • Tracking: Core maintenance work removed the unnecessary inclusion of particle Cloud at lower levels of the Lagrangian code [ commits 2df733 ].
  • Modelling: Rewritten particle functionality to enable to users to configure the cloud type(s) in case input files; Lagrangian solvers are renamed accordingly [ commit 43d66b ].

Reactions

  • Control: Added a check for mass balance in chemical reactions [ commit 52a10b ]. New reaction base class provides reaction specie coefficients without the need for a thermodynamics model [ commit e8fba9 ]. Added a frozenFlow option to reactingFoam to stop solution of p and U while the energy-composition system including reactions continues to be solved [ commit a620e9 ].
  • Numerics: Improved discretisation of pressure work term in compressible and reacting flow solvers [ commit 90831f ]. Chemistry integration is now correctly initialised with old time properties [ commit 07adb1 ].
  • Chemistry: The EulerImplicit chemistry solver is updated to use the standard chemistry model Jacobian [ commit bddd82 ].  Corrected the temperature derivative terms of the Jacobian in chemistry modelling [ commit 955d9d ]. Simplified reaction rate calculations [ commit ad8262 ]. ISAT now runs in variable time-step mode as standard [ commit 672afc ].

Meshes

  • snappyHexMesh: Fixed mesh distortion and bugs in patch indices and ordering in coupled (cyclic and processor) patches [ commits f85dbc ]. Simplified the settings for refinement levels in regions [ commit be9fb8 ]. Simplified various castellatedMeshControls [ commits 0ef0247 ].
  • Decomposition: Mesh redistribution has undergone some refactoring and redesign [ commits f02d5e3 ]. Removed the delta parameter in geometric decomposition by setting a default value [ commit 9c73d4 ].
  • Reconstruction: Maintenance of reconstructParMesh and fvMeshDistribute prevents a reconstruction failure associated with incorrect point merging [ commit 9e740b ].
  • blockMesh: Replaced the m4 scripts in the blockMesh configuration with codeStream in the example cases including the angleDuct  [ commit 35f73c ] and sloshingTank [ commit c5b6e6 ].
  • Manipulation: transformPoints has a new syntax to support a sequence of multiple transformations correctly [ commit 845d5b ]. Replaced mergeOrSplitBaffles with two dedicated applications, splitBaffles and mergeBaffles [ commit 45a005 ]. Standardised the naming of coordinate axes in refineMesh [ commit 926ba2 ].
  • Mesh Motion: Dynamic mesh refinement can be controlled by region and multiple fields [ commit fe9de1 ].
  • Regions: patchDistanceToCell selects cells in topoSet within a distance of specified patches [ commit 1440b6 ]. New internal patch field type for exposed internal faces from a subset of a mesh [ commit 520440 ].
  • Tutorials: New drivaerFastback example case of automotive aerodynamics with scripted options to specify mesh size and processor cores [ commits 2bd0fd ].
  • Surface geometry: surfaceTransformPoints has a new syntax to support correctly a sequence of multiple transformations [ commit 45dca3 ].

Surface Film

  • Usage: Simplified the input file format for surface film modelling with backward compatibility [ commit 3838df ].
  • Models: Corrected heat and mass transfer between surface film and the primary flow region [ commit 0eafc1 ]. Standard thermodynamics now provide thermophysical properties for the film [ commit 76e07b ].
  • Examples: New plateFilm example case of VoF with film modelling [ commit b0a573 ].

Function Objects

  • General: Overhaul of packaged function objects so that their configuration is equally effective using local files or by arguments in the function call [ commit 5d0d9a ]. Function objects can be configured in the controlDict with parameters as arguments, including the new funcName parameter to simplify output directory/file names [ commit f5b0a2 ].
  • Sampling: The topoSet utility now has an improved searchableSurfaceToFaceZone option to enable users to produce reliable face zones corresponding to a surface geometry file [ commit 89b9e2 ]; used to monitor flow rate in the TJunction tutorial [ commit ea3e7f ]. New volumetricFlowRateTriSurface function object calculates the flow rate through a surface defined by a geometry (e.g. OBJ, STL) file [ commit bda074 ]. Refactored data writing code as a setWriter class in the sampling library [ commit f4a65f ].
  • Visualisation: The streamline function object now writes age, i.e. the total integration time from the starting point of the streamline, [ commit aa4cb4 ]. Improved robustness of generation of isoSurfaces, e.g. cutting planes [ commit cb8be0 ]. The polygon triangulation has been replaced with a robust algorithm [ commit 02b97a ].
  • Fields: A specific phase can now be selected in the turbulenceFields function object [ commit a09465 ]. New cylindrical functionObject transforms velocity into cylindrical polar co-ordinates [ commit 501f3d ]. Improved usability and performance of general surfaceFieldValue and volFieldValue function objects [ commit 056cc2 ].
  • Time: The setTimeStep function object allows the user to configure a writeInterval which changes over time [ commit bae95b ].

For an updated list of packaged function objects, see User Guide: 6.2 Post-Processing CLI.

Models and Constraints

  • General: fvOptions is replaced with fvModels for physical sources and fvConstraints for numerical constraints, with backward compatibility [ commit da3f4c ]. Removed the active switch which is inefficient and incomplete [ commit 19b3a5 ].
  • fvModels: heatTransfer provides a source term with heat transfer coefficient to an ambient temperature [ commit 07a0af ]. heatSource provides a source term for heat as a total power or power per unit volume [ commit 8d707b ]. Rationalised interRegionHeatTransfer [ commit 4442ce ]. New clouds and surfaceFilm fvModels provide pluggable particle and film modelling with coupling to the continuum in general solvers, e.g. reactingFoam. New massSource fvOption (subsequently, fvModel) specifies a mass source to the continuity equation and to all field equations [ commit 69e98d ].
  • Switches: To accompany the new fvModels, new models, thermophysics and flow switches have been added to the solver applications which allow users to deactivate those components of a simulation [ commit 49ce8f ]. Initialisation of hydrostatic pressure with hydrostaticInitialisation switch, enabling buoyantReactingFoam to replicate the functionality of fireFoam, which is now deprecated [ commit a997dd ], and implemented in buoyantPimpleFoam, buoyantSimpleFoam [ commit 789bdc ].
  • fvConstraints: limitPressure provides more flexible control of pressure limits [ commit ab7d01 ].
  • Co-ordinate Systems: Local coordinate systems can now be defined in a general constant/coordinateSystems file [ commit 31891a ].

For more information on models and constraints, see “OpenFOAM Models & Constraints”.

Case Configuration

  • Data Visualisation: New timeStep functionObject writes the (variable) time step at each time which can be viewed live with foamMonitor [ commit 564e21 ]. Improved VTK output for files with points only, e.g. for particles [ commit 933572 ].
  • Case Initialisation: Case files can now #include other files containing binary data [ commit 80eecb ]. foamDictionary now allows setting of parameters in input files directly with the -set option [ commit 312a56 ]foamDictionary includes a simple keyword=value syntax to make substitutions in case files [ commit bf7ac2 ]. New foamCleanCase script cleans a case directory, resetting it to its initial state [ commit fac831 ].
  • Case Management: New stopAtFile function object causes a case to stop on creation of a specified file [ commit 7379f4 ] and stopAtClockTime stops a simulation when a specified clock time is exceeded [ commit 5bfd3b ]. Changed the default scoping syntax to “/” which supports reading values from other files, e.g. Uinlet  0/U!internalField; [ commit 6c8732 ]. When running applications with the -region option, the -dict option specifies the configuration file by default in the system/<region> directory, [ commit cce3e1 ]. foamInfo now lists models of the same family as a specified model [ commit e00316 ].
  • Function1/2: New Function2 for input data which is a function of 2 variables with complex functions and interpolated tabulated data [ commit 2cd197 ]. Replaced specialised table lookups with Function1 [ commits bfedfc ] and Function2 [ commits 2c6e43 ] including all thermophysical functions, NSRDS, API and the fast uniform and non-uniform tables [ commit 0c79b6 ]. Standardised tabulated data with the NonUniformTable1 and UniformTable2 functions [ commits 6fe12e ]. New squarePulse Function1 enables switching on a parameter at a specified time and duration [ commit aa4151 ].

Programming and Computation

  • Data Input: Maintenance of IOdictionary, improving global controlDict handling, including support for #calc [ commits fe4181 ]. Improved reading of ASCII and binary data and transfers across processors when running parallel [ commits aa8e4b ]. Removed the version entry in FoamFile headers by defaulting it to 2.0 [ commit 014944 ].
  • Data Output: When a case is stopped and restarted, results are now written to subsequent time directories referenced to the original start time of the case rather than the restart time [ commit 7aca9b ].
  • Fields and Dimensions: Simplified the global switches and constants [ commit bbc00c ] and improved specification of dimensionedConstants in the case controlDict file [ commit a121ba ].
  • Architecture: Standardised and centralised the argument list parser [ commit 560db9 ].
  • Other Numerics: Standardised the Rx, Ry, Rz and Ra rotational transformations to operate in a right-handed co-ordinate system [ commit 227734 ]. New deferred correction for advection provides an implicit upwind contribution with an explicit correction based on the selected scheme to ensure diagonal dominance of the matrix [ commit ed2ca6 ]. Rationalised the pressure reference code to improve consistency between flux and flux correction [ commit e8ff92 ].
  • Compilation: Updated to the C++14 version of the ISO/IEC 14882 standard of the C++ programming language [ commit 0257ab ]. Decreased the memory requirement to compile OpenFOAM and reduced parallel compilation time [ commit 1cd084 ]. For compilation with wmake, cpp is no longer used to process Make/files to enable the inclusion of comments and conditionals [ commit 848ec1 ].

Credits

OpenFOAM 9 was produced by:

Licence

OpenFOAM 9 is distributed under the General Public Licence v3 by the OpenFOAM Foundation.

Artwork