freefem++

Partial differential equation solver based on the finite element method

Introduction

Freefem++ is a powerful software package for solving partial differential equations using finite element methods. It comes equipped with its own scripting language as well as some visualization tools.

Using Freefem++ on RCC Resources

Freefem++ can be run using either serial or parallel versions, but different executable files are used. Additionally, freefem++ can be used interactively or via job submission. If using the software interactively, the user must tunnel X in the ssh command (using ssh -Y), since the solution for the following examples will require a window or two to be displayed. The freefem++ software does not require the use of a module, but does require a parallel module (gnu-openmpi, or gnu-mvapich2) if you want to use parallel version. Note that only two of the example files are available on the HPC. Other example files are available in the source code download, located here.

Example Program Running freefem++ in Serial

Log into a spear node (or the HPC), tunneling X:

ssh -Y [username]@spear-login.hpc.fsu.edu

We use the executable located in the directory /opt/hpc/gnu/bin/ named FreeFem++ to run a simple example available on the HPC located in /panfs/storage.local/opt/userfiles/freefem to run the example.

FreeFem++ /panfs/storage.local/opt/userfiles/freefem/aaa-adp.edp 

Successful execution should display two pop-up windows.

Example Program Running freefem++ in Parallel

Log into a spear node (or the HPC), tunneling X:

ssh -Y [username]@spear-login.hpc.fsu.edu

Load the GNU Open MPI compiler:

module load gnu-openmpi

The executable is located in the /opt/hpc/gnu/openmpi/bin/ directory, named FreeFem++-mpi (the mvapich2 version is in /opt/hpc/gnu/mvapich2/bin/). The example is available in the directory /panfs/storage.local/opt/userfiles/freefem. Run the program using the usual mpirun -np [processors] command, followed by the FreeFem executable, noting the -mpi extension. This specific example requires that only 2 cores be used.

mpirun -np 2 FreeFem++-mpi /panfs/storage.local/opt/userfiles/freefem/schwarz-c.edp

Successful execution should display a pop-up window. To suppress the pop-up window, use -np at the end of the command. To submit a job on the HPC, use the same command as above inside of a SLURM submission script.