OpenFOAM does not assume units, it checks them. Every dimensioned quantity carries a vector of seven exponents in square brackets, and the solver refuses to add or compare quantities whose dimensions do not match.
The order is fixed: mass, length, time, temperature, quantity, current, luminous intensity. So [0 2 -2 0 0 0 0] is length squared over time squared, which is the kinematic pressure that incompressible solvers work with.
That last point catches most newcomers. In the incompressible solvers pressure is divided by density, so the value you enter and the value you read out is not in pascals. Multiplying by the density is what returns the pressure to the units you expected.
@ET-DC@eyJkeW5hbWljIjp0cnVlLCJjb250ZW50IjoicG9zdF90aXRsZSIsInNldHRpbmdzIjp7ImJlZm9yZSI6IiIsImFmdGVyIjoiIn19@
The I/O format for a dimensionSet is 7 scalars delimited by square brackets, e.g.
| No. | Property | SI unit | USCS unit |
|
|
|
|
|
| 1 | Mass | kilogram (kg) | pound-mass (lbm) |
| 2 | Length | metre (m) | foot (ft) |
| 3 | Time |
— — — — second (s) — — — —
|
|
| 4 | Temperature | Kelvin (K) | degree Rankine (R) |
| 5 | Quantity | kilogram-mole (kgmol) | pound-mole (lbmol) |
| 6 | Current |
— — — — ampere (A) — — — —
|
|
| 7 | Luminous intensity |
— — — — candela (cd) — — — —
|
|
|
|
|
|
|
In this tutorial, you will learn how to works the units in OpenFOAM.
Convert Photography to Mesh using Gmsh
Learn how to generate a CFD mesh from any photograph using the Gmsh mesher.
OpenFOAM Tutorial | Multiphase Simulation
In this tutorial you will learn how to simulate a multiphase simulation through lockExchange tutorial that comes by default with OpenFOAM.
Related Articles
OpenFOAM Tutorial | Multiphase Simulation
In this tutorial you will learn how to simulate a multiphase simulation through lockExchange tutorial that comes by default with OpenFOAM.
OpenFOAM Tutorial | motorBike (simpleFoam)
In this video you will learn how to simulate motorBike tutorial using OpenFOAM with simpleFoam solver.
OpenFOAM Tutorial | How to create an Animation
In this tutorial you will learn how to create an animation using OpenFOAM through Paraview (paraFoam Command).
Stay Up to Date With The Latest News & Updates
Help us keep growing
CFD.NINJA is financed with its own resources, if you want to support us we will be grateful.
Join Our Newsletter
Subscribe to receive emails with detailed information related to the CFD.
Follow Us
Subscribe to our social networks to receive notifications about our new tutorials




