Wiki
Clone wikiFEMilaro / Home
FEMilaro - a Finite Element toolbox
FEMilaro is a flexible environment to implement, test and use new finite element formulations. In practice, this means that the grid and the finite element basis are defined in order to simplify dealing with continuous, discontinuous, mixed and hybrid formulations.
To help going developing incrementally the code, the grid and the finite element basis, as well as all the executables, are parametrized in the space dimension, so that development (and debugging!) can start in 1D and scale up to the 3D case.
For the pre- and post-processing, a collection of octave and python scripts is provided.
All the code is distributed under GNU GPL v3.
Note: this poject is a continuation of https://code.google.com/archive/p/femilaro/ .
Contributors
Here is a (incomplete) list of people contributing to the project:
- Antonella Abbà, at the Politecnico di Milano, Italy
- Luca Bonaventura, at the Politecnico di Milano, Italy
- Michele Nini
- Marco Restelli, at the Max-Planck-Institut für Plasmaphysik, Germany
- Matteo Tugnoli, at the Politecnico di Milano, Italy
Available executables
The toolbox currently includes the following codes:
- dg-comp: compressible Navier-Stokes code using discontinuous finite elements and explicit or exponential time integration. The emphasis of this code is on LES turbulence models; see also Dynamic models for Large Eddy Simulation of compressible flows with a high order DG method.
- cg-ns: incompressible Navier-Stokes solver with options for both high-order and low-order pressure and velocity stabilization; see also Numerical analysis of penalty stabilized finite element discretizations of evolution Navier–Stokes equations and A posteriori analysis of a positive streamwise invariant discretization of a convection-diffusion equation.
- vp-dg: solve the Vlasov-Poisson equation using discontinuous finite elements in phase space and an energy conserving discretization; see also Energy conserving discontinuous Galerkin spectral element method for the Vlasov–Poisson system.
- ldgh: solve the advection-diffusion-reaction equation using the Local Discontinuous Galerkin - Hybridazable method; see also An hybridizable discontinuous Galerkin method for steady state convection-diffusion-reaction problems.
- hj-dg: solve a generic Hamilton-Jacobi equation with discontinuous finite elements.
- b-fem-adr: a simple solver for two-dimensional advection-diffusion problems using hybrid triangular/quadrilateral grids and SUPG stabilization.
Installation
A note about the Makefiles
To compile the programs, one uses the main Makefile placed in the FEMilaro root folder. A list of the available targets can be seen by typing
make list
presently_working
, so typing
make
make presently_working
make dg-comp
Configuration
-
Select the working precision in mod_kinds.f90 by uncommenting the corresponding definition of
wp
. Due to some limitations in current MPI libraries, some changes could be required also in mod_mpi_utils.f90 to setwp_mpi
(this will hopefully be solved in the future). -
In the folder make.inc there are some configuration makefiles. One can either customize one of them, or create a new one using these as example. The important point is then creating a link in the root directory called Makefile.inc to the chosen file, such as
Makefile.inc -> make.inc/make_plx.inc
-
The examples in make.inc include a Configuration section: this is the only part that should require changes. Essentially, one is required to set:
-
Set in Makefile.inc the required compiler and linker flags for the used external libraries.
Compilation
At this point, you should be able to type make XXX
and get the
corresponding executable. Object and library files will be placed in
./build, while the executables will be in
./bin.
Unit tests (experimental)
The ./test folder contains some unit tests which rely on the pFunit testing harnesses.
Test modules are named after the tested ones, and the structure of the ./test folder mimics the one of the ./src one.
To compile and run the tests:
-
the path to the pFunit include and module files must be set in the ./test/Makefile (this will be improved at a certain point)
-
to build/run/delete the unit tests use
make tests-build make tests-run make tests-clean
Single test modules can be also built and run independently.
Updated