Skip to content

Installation

Licensing

The Community tier is free for academic and commercial use. If you install or use mufem, you agree to the Terms of Service. See Licensing for the paid tiers.

Supported Platforms

Architecture Operating System Python Version Parallel Mode Status
x86-64 Linux 3.12, 3.13, 3.14 MPI Stable
x86-64 Windows 3.13 OpenMP Alpha
arm64 (Apple silicon) macOS 3.13 OpenMP Alpha

The Windows and macOS packages are alpha releases. Some validation cases can fail on these platforms.

If you need support for an unsupported platform, please create an issue.

Install mufem package

Before you install mufem, make sure your platform is supported. Also install Python and pip. We also recommend that you first create a separate Python virtual environment with:

    python -m venv ~/mufem-env

This stores the environment data in the mufem-env folder in your home directory. To activate the new Python environment, run this command:

source ~/mufem-env/bin/activate
~\mufem-env\Scripts\Activate.ps1

mufem is a Python package on PyPI. Install it with pip:

pip install mufem

The Windows and macOS packages are pre-releases. Add the --pre option:

pip install --pre mufem

The mufem package installs numpy. The validation suite also needs matplotlib for the plots and gmsh for the meshes. Install them with:

   pip install matplotlib gmsh

Run a case

After the installation completes, run a case file with this command:

pymufem case.py

The pymufem command launches the case in parallel mode with MPI. To launch it in serial mode, use the python3 case.py command.

python case.py

The pymufem MPI launcher is available only on Linux. On Windows and macOS, mufem uses OpenMP threads on one machine. To set the number of threads, set the OMP_NUM_THREADS environment variable before you start the case.