garth-wells / dolfinx

Experimental new FEniCS problem solving environment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DOLFINx

DOLFINx CI CircleCI Actions Docker images Actions Spack build

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 being actively developed.

Documentation

Documentation can be viewed at:

Installation

From source

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 .

(you may need to use pip3, depending on your system).

For detailed instructions, see https://docs.fenicsproject.org/dolfinx/main/python/installation.

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 add py-fenics-dolfinx cflags="-O3" fflags="-O3"
spack install

See the Spack documentation for comprehensive instructions.

conda

To install the Python interface, with pyvista support for visualisation, using conda:

conda install -c conda-forge fenics-dolfinx mpich pyvista

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

Note Windows packages are not available. This is due to some DOLFINx dependencies not supporting Windows.

Docker images

A Docker image with DOLFINx built nightly:

docker run -ti dolfinx/dolfinx:latest

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 DOLFINx built nightly:

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

A development image with all of the dependencies required to build DOLFINx:

docker run -ti dolfinx/dev-env:latest

All Docker images support arm64 and amd64 architectures.

For more information, see https://hub.docker.com/u/dolfinx

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 http://www.gnu.org/licenses/.

Contact

For questions about using DOLFINx, visit the FEniCS Discourse page:

https://fenicsproject.discourse.group/

or use the FEniCS Slack channel:

https://fenicsproject.slack.com/

(use https://fenicsproject-slack-invite.herokuapp.com/ to sign up)

For bug reports visit:

https://github.com/FEniCS/dolfinx

About

Experimental new FEniCS problem solving environment

License:GNU Lesser General Public License v3.0


Languages

Language:C++ 66.9%Language:Python 29.3%Language:CMake 2.9%Language:Dockerfile 0.8%Language:Makefile 0.1%Language:Shell 0.0%Language:C 0.0%