Main Navigation

Secondary Navigation

Page Contents

Contents

Using OpenFOAM

When you just try to load some of the newer OpenFoam modules, like

module add openfoam/v2006
you will be prompted what to do instead. Just follow the instructions given.

OpenFoam in elder versions have been compiled with Platform MPI and require special setups:

  1. Loading libraries
  2. loading OpenFOAM environment

Hint: Include the following into your .bashrc if you are plan to use OpenFOAM frequently.

Version 2.4.0

module load gcc/latest-4.9
module load platform-mpi/9.1.2-CE
. /software/openfoam/2.4.0/OpenFOAM-2.3.1/etc/bashrc

Version 2.3.1

module load gcc/latest-4.7
module load platform-mpi/latest
. /software/openfoam/2.3.1/OpenFOAM-2.3.1/etc/bashrc

Version 3.0.1

module load gcc/latest-4.7
module load platform-mpi/latest
. /software/openfoam/2.3.0/OpenFOAM-3.0.1/etc/bashrc

Run your job for the above specified versions with

mpirun -srun -n$SLURM_NTASKS

Version 4.0

module load openmpi/1.10
. /software/openfoam/4.1/OpenFOAM-4.1/etc/bashrc

Version 1612+

module load openmpi/1.10
. /software/openfoam/v1612+/OpenFOAM-v1612+/etc/bashrc

Run your job simply with

mpirun