Hippo is a MOOSE app wrapping OpenFOAM's fluid solver. It provides tools for solving coupled conjugate heat transfer problems.
Some simple 1 and 2D validation cases can be found in the tests.
Hippo's documentation is a work in progress, and can be found here. It includes an example of how to set up a coupled conjugate heat transfer problem.
Note: Only tested with GCC.
Unfortunately hippo relies on patching OpenFOAM,
there is a script scripts/install-openfoam.sh that will clone
OpenFOAM-10, apply the patch, and build it.
First install the build dependencies:
apt install \
bison \
flex \
libptscotch-dev \
libqt5opengl5-dev \
libqt5x11extras5-dev \
libxt-dev \
make \
paraview \
paraview-dev \
qtbase5-dev \
qttools5-dev \
qttools5-dev-toolsThen run the script (use flag -h for help, this will take ~1 hour):
bash ./scripts/install-openfoam.shTo set the OpenFOAM build options (e.g., Opt or Debug mode),
copy scripts/openfoam-prefs.sh to ~/.OpenFOAM/prefs.sh,
and update the environment variables within.
The variables will be loaded when <path/to/OpenFOAM>/etc/bashrc is sourced
(which is done automatically by the install script).
Follow instructions here to build MOOSE.
Hippo requires MOOSE release 2024-09-05-release or higher.
Set (recommend direnv for this)
MOOSE_DIR=/path/to/moose/dir
MPI_ROOT=/path/to/mpich/root
MPI_ARCH_INC="-I/path/to/mpi/includes"
MPI_ARCH_LIBS="-L/path/to/mpi/libs -lmpi"
source /path/to/OpenFOAM/etc/bashrcOnce the dependencies are built, then (in theory) you should be able to make in the root directory:
makeOr, for a debug build:
METHOD=dbg makeHippo's tests are written using MOOSE's
test harness system.
Just run ./run_tests.
Note that you must have the required Python packages installed:
pip install -r requirements.test.txtSome code quality checks are set up with
pre-commit.
Install the pre-commit hooks to run on each new commit:
pre-commit installRun the hooks manually:
pre-commit run --allTo bypass the pre-commit checks, use the --no-verify (or -n) flag:
git commit --no-verifyThis is a work in progress. So far, Hippo can:
- Create a 2D MOOSE boundary mesh from the boundary of an OpenFOAM mesh.
- Run a fluid solver case via a MOOSE input file.
- Transfer temperatures and or heat fluxes from an OpenFOAM mesh to the MOOSE boundary mesh.
- Set OpenFOAM temperature field boundary conditions using values from a MOOSE mesh.
If you have floating point error (FPE) trapping enabled in OpenFOAM, you may run into errors when running Hippo.
Hippo input files that run a MOOSE case do not require a Kernel or variables. However, MOOSE will still happily go off and calculate a residual. Since there are no variables defined, the residual calculation results in a division by zero and an FPE signal. OpenFOAM will catch this signal and abort the application.
Either of these two workarounds will work:
-
Disable trapping for floating point exceptions.
unset FOAM_SIGFPE && unset FOAM_SETNAN. -
Add a dummy variable to the MOOSE input file. E.g.,
[Variables] [dummy] initial_value = 999 [] []