OpenFOAM

OpenCFD releases patched OpenFOAM 1.5

OpenCFD released a patched version of OpenFOAM 1.5 today, via a git repository. You can find the official announcement here.

The procedure to install it on openSUSE 11.0 is straightforward:

  • Be sure to have git installed. You can check it with
rpm -qa git

If it is not installed, you can easily install it with the command (as root):

zypper in git

provided you have the OSS repository in your repository list (check with zypper lr, and eventually add it using Yast -> Software -> Installation sources).

  • As a user, download the OpenFOAM patched source code using the command:
git clone git://repo.or.cz/OpenFOAM-1.5.x.git

This will create a directory called OpenFOAM-1.5.x, containing the source code.

  • Create a directory in your home called OpenFOAM, and copy the OpenFOAM-1.5.x directory into it.
  • Copy the ThirdParty directory containing all the third party packages provided in the release from OpenCFD into the OpenFOAM directory in your home.
  • Edit your .bashrc file in your home directory, so that it contains the line:
. $HOME/OpenFOAM/OpenFOAM-1.5.x/etc/bashrc

and remove previous OpenFOAM settings if present.

  • Open a terminal and move to ~/OpenFOAM/OpenFOAM-1.5.x.
  • Run the ./Allwmake script to proceed with the compilation process.

When future updates are released, it will be possible to download them using the command:

git pull

and compiling the source again.

Note openSUSE 11.0 comes with Qt 4.4.0. To successfully compile Paraview and paraFoam reader for Paraview, it is necessary to comment the following line out in the ~/OpenFOAM/ThirdParty/ParaView3.3-cvs/CMakeLists.txt file:

MESSAGE(SEND_ERROR “Qt ${QTVERSION} not supported.  Please use Qt 4.3 (you may need to clean your dirtied cache).”)

as explained in this discussion on the OpenFOAM discussion board.

Enjoy 🙂