The fvOptions functionality in OpenFOAM is flexible framework to add various source terms to the governing equations without the need to rewrite the original source code. The available options in the latest versions of OpenFOAM (v4.0 and v1606+) are listed below.
My explanations are available for the options shown in red.
I’ll extend the coverage.
Available Options |
General Sources:
Pressure Gradient Sources:
- meanVelocityForce:
to adjust the average velocity in the whole domain or user-specified cellZone or cellSet to the desired value Ubar by adding a momentum source
- [3.0+] directionalPressureGradientExplicitSource
Heat Exchanger Sources:
- constantHeatTransfer
- variableHeatTransfer
- tabulatedHeatTransfer
- [3.0+] tabulatedNTUHeatTransfer
- effectivenessHeatExchangerSource
Buoyancy Sources:
- buoyancyForce:
to add the gravitational force term \(\rho\boldsymbol{g}\) to the momentum conservation equation in XiFoam, reactingFoam and rhoReactingFoam
- buoyancyEnergy:
to add the work done by gravitational force \(\rho(\boldsymbol{u} \cdot \boldsymbol{g})\) to the energy conservation equation
Porosity Sources:
- explicitPorositySource:
to add a porosity momentum source term in all cells or user-specified cellZone or cellSet (available porosity models: fixedCoeff, powerLaw and DarcyForchheimer)
- interRegionExplicitPorositySource:
to emulate a flow blockage effect due to the neighbour region by adding a inter-regional porosity momentum source in the overlapped volume with the neighbour region
Acceleration Source:
- tabulatedAccelerationSource:
to simulate the fluid flow in a domain that is in 6-DoF solid-body motion without dynamic mesh by adding the fictitious force terms, e.g., the Coriolis, Centrifugal and Euler forces in a non-inertial reference frame
Phase Change Source:
Acoustic Damping Source:
- [1606+] acousticDampingSource:
to damp the acoustic waves before they reach the boundaries by adding a momentum source term in a buffer region so that the solution will not be contaminated by the reflected waves from the boundaries
Other Sources:
Solver Robustness:
- limitVelocity:
to limit maximum velocity magnitude to the user-specified max value in all cells (and all non-Dirichlet boundary faces) or user-specified region
- [3.0+] velocityDampingConstraint
- limitTemperature
Set Value:
- [4.0] fixedValueConstraint (Old version: explicitSetValue):
to explicitly set the field values within user-specified region
- fixedTemperatureConstraint
How to Set Source Region |
When specifying a source term using fvOptions in OpenFOAM, we can select the selectionMode (how to set the source region) from the following four options:
- points
- cellSet
- cellZone
- all
The meanings of these options are described in this post.