Date: 2021-09-20
Written by: Johannes Borgqvist
If you cannot install the two relevant conda environments from the provided yml files, you can try to do it manually using the conda installation of FEniCS. It is recommended to create and activate a conda environment in order to install and access all relevant parts of FEniCS. To create and activate a conda environment by the name of "fenicsproject", use the following two steps:
- conda create -n fenicsproject -c conda-forge fenics
- source activate fenicsproject
The first point installs all packages involved in the fenicsproject and stores them in a conda environment called "fenicsproject". The installation process will most likely take hours to complete. The second point activates the conda environment and when this environment is activated all important packages necessary to run FEM simulations using FEniCS are installed.
In order to be able to generate the meshes and to visualise the results of the FEM-simulations, Gmsh and ParaView must be added to the conda environment "fenicsproject". This is done by typing the following four commands:
- conda config --add channels conda-forge
- conda config --set channel_priority strict
- conda install --name fenicsproject gmsh python-gmsh
- conda install --name fenicsproject paraview . Lastly, as these platforms are under constant development the versions of the involved packages changes often. Therefore, the versions of the packages involved in this project have been documented in the Markdown-file "VERSIONS_OF_PACKAGES.md" in this repositry.
Unfortunately, step 3 listed above does not install the latest version of Gmsh which is needed. So type the following command to create another environment in which the latest version of Gmsh is installed:
conda create -n gmsh_latest_version -c conda-forge python=3.9 gmsh=4.8 python-gmsh
This environment is also activate and deactivated exactly in the same manner as the environment "fenicsproject". The environment "gmsh_latest_version" is activated when the meshes are created and "fenicsproject" is activated when we want to simulate the PDE system.
Alternatively, if you want to install all packages without anaconda, they are all listed in the document "VERSIONS_OF_PACKAGES.md".