RepositoryC++
FE

FEniCS/dolfinx

Next generation FEniCS problem solving environment for solving finite element problems

1.3kstars
265forks
74issues
26views

Featured achievements

The project's latest awards

1
TINIX TRENDING·Topic: fenicsx

#1 Repository of the week

2
TINIX TRENDING·Topic: finite-element-methods

#2 Repository of the week

2
TINIX TRENDING·Topic: partial-differential-equations

#2 Repository of the week

DOLFINx

DOLFINx CI Actions Spack build Actions Conda install Actions macOS/Homebrew install Actions Docker images Actions Windows/vcpkg install

DOLFINx is the computational environment of FEniCSx and implements the FEniCS Problem Solving Environment in C++ and Python. DOLFINx is a new version of DOLFIN and is actively developed.

For questions about using DOLFINx, visit the FEniCS Discourse page or use the FEniCS Slack channel (use this link to sign up to the Slack channel).

Documentation

Documentation can be viewed here.

Installation

From source

For detailed instructions and a list of dependencies, see here.

C++ core

To build and install the C++ core, in the cpp/ directory, run:

mkdir build
cd build
cmake ..
make install

Python interface

To install the Python interface, first install the C++ core, and then in the python/ directory run:

pip install scikit-build-core
python -m scikit_build_core.build requires | python -c "import sys, json; print(' '.join(json.load(sys.stdin)))" | xargs pip install
pip install --check-build-dependencies --no-build-isolation .

Spack

To build the most recent release using Spack (assuming a bash-compatible shell):

git clone https://github.com/spack/spack.git
. ./spack/share/spack/setup-env.sh
spack env create fenicsx-env
spack env activate fenicsx-env
spack install --add py-fenics-dolfinx+petsc4py+slepc4py

Spack is the recommended approach for HPC systems.

Although Spack already contains FEniCS Project packages, we also maintain a separate overlay package repository which may contain bug fixes and package specs for newer releases of the FEniCS Project components, particularly after a recent release.

spack repo add https://github.com/fenics/spack-fenics
spack repo ls # shows fenics above builtin

Binary packages

Recommendations

conda

To install the latest release of the Python interface, including pyvista for visualisation, using conda:

conda create -n fenicsx-env
conda activate fenicsx-env
conda install -c conda-forge fenics-dolfinx mpich pyvista # Linux and macOS
conda install -c conda-forge fenics-dolfinx pyvista pyamg # Windows

Windows only: Windows conda packages are currently in beta testing. PETSc and petsc4py are not available on Windows. Because FEniCS uses just-in-time compilation it necessary to install Microsoft Visual Studio.

conda is distributed with Anaconda and Miniconda. The recipe is hosted on conda-forge.

NameDownloadsVersionPlatforms
Conda RecipeConda DownloadsConda VersionConda Platforms

Ubuntu packages

The Ubuntu PPA provides FEniCSx packages. To install:

add-apt-repository ppa:fenics-packages/fenics
apt update
apt install fenicsx

When a version of DOLFINx is released we aim to provide a package for the most recent LTS version of Ubuntu. All other versions are provided on a best-effort basis.

Debian packages

DOLFINx is included with various versions of Debian. Install with apt-get install fenicsx.

Docker images

To run a Docker image with the latest release of DOLFINx:

docker run -ti dolfinx/dolfinx:stable

To switch between real and complex builds of DOLFINx/PETSc.

source /usr/local/bin/dolfinx-complex-mode
source /usr/local/bin/dolfinx-real-mode

A Jupyter Lab environment with the latest release of DOLFINx:

docker run --init -ti -p 8888:8888 dolfinx/lab:stable  # Access at http://localhost:8888

A Docker image with DOLFINx built nightly:

docker run -ti dolfinx/dolfinx:nightly

A development image with all of the dependencies required to build the latest release of the FEniCSx components:

docker run -ti dolfinx/dev-env:stable

A development image with all of the dependencies required to build the main branch of the FEniCSx components:

docker run -ti dolfinx/dev-env:current

The Docker images support arm64 and amd64 architectures. For a full list of tags, including versioned images, see https://hub.docker.com/u/dolfinx

Contributing

Information about how to contribute to DOLFINx can be found here.

License

DOLFINx is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

DOLFINx is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with DOLFINx. If not, see https://www.gnu.org/licenses/.

Similar Projects

Discover other similar projects and AI models.

RepositoryPython
FEniCS/ffcx

Next generation FEniCS Form Compiler for finite element forms

196
Nov 27, 2026
RepositoryC++
FreeFem/FreeFem-sources

FreeFEM source code

971
Nov 28, 2026
RepositoryC++
cbritopacheco/rodin

A modern C++ finite element library for shape optimisation, multiphysics and distributed GPU computing

56
Nov 30, 2026
RepositoryFortran
ElmerCSC/elmerfem

Official git repository of Elmer FEM software

1.8k
Nov 30, 2026
RepositoryPython
adtzlr/felupe

Open finite element infrastructure for nonlinear computational mechanics.

192
Nov 26, 2026
RepositoryJupyter Notebook
jorgensd/dolfinx-tutorial

A reimplementation of the Springer book: https://github.com/hplgit/fenics-tutorial/, covering new topics as well as transitioning from dolfin to dolfinx

170
Nov 4, 2026
RepositoryJulia
PetrKryslUCSD/FinEtools.jl

Finite Element tools in Julia

163
Nov 2, 2026
RepositoryPython
FEniCS/ufl

UFL - Unified Form Language

153
Nov 27, 2026
RepositoryPython
jorgensd/dolfinx_mpc

Extension for dolfinx to handle multi-point constraints.

63
Nov 30, 2026