Page cover

QuickStart

Installation

Download code

The code can be obtained in the usual way

  1. Clone the repository with all submodules

    git clone --recursive git@github.com:salvadornm/cerisse.git
  2. Or clone the bare repository (and install Submodules later)

    git clone  git@github.com:salvadornm/cerisse.git
  3. Same using GitHub CLI

    $ gh repo clone salvadornm/cerisse
  4. Or download latest release from Github

Pre-requisites

  1. C++ compiler A compiler with C++20 standard is required. Examples include gcc version 8 and above and Clang version 10 and above (both compilers may need -std=c++20 flag)

  2. GNU Makefile It will usually be installed by default in most systems (MacOS/Linux)

  3. MPI libraries (optional) required for parallel simulations. Similarly CUDA/OpenMPI may be required for more advanced parallelization strategies.

  4. cmake (optional) required for some installation options, mostly related to GPU and chemistry. Easy to install, version required >3.2

  5. AMReX AMR libraries AMREXarrow-up-right This is the AMR library that controls grid generation/IO/parallelization. Required for the code, see Installation AMREX and PelePhysics

  6. PelePhysics (optional) Is a repository of physics databases PelePhysicsarrow-up-right It is required for complex chemistry and transport properties. Includig stiff chemcial sytems integration. It also has, spray , soot and radiation modules as well as many support utilities for Pele suite of codes that can also be used in Cerisse. To install see Installation AMREX and PelePhysics If the chemistry solvers are used, the SUNDIAL library will need to be installed as well Installation SUNDIALS

  7. CGAL (optional) This is the Computational Geometry Algorithms Library CGALarrow-up-right, required to do the needed geometric computation in the case of immersed boundaries. To install see Installation CGAL

  8. Visualization Cerisse/AMREx/PeleC format is supported by VisItarrow-up-right, Paraviewarrow-up-right, ytarrow-up-right (allows Python) and check for more options AMReX Visualizationarrow-up-right

circle-check

Installation AMREX and PelePhysics

To install auxiliar packages, AMReX and PelePhysics

It will connect to Github and download the required packages. $ ./install git, will install latest release commit in the development branch of AMReX. The install safe option will install versions 23.11 of AMReX and 23.03 of PelePhysics. Downloads are fast with 27 and 30 Mb respectively. All installation files will live under cerisse/lib

triangle-exclamation

Installation CGAL

There are two ways to install CGAL libraries. In Linux systems go to folder

This will install the CGAL version 6.0.1 as well as BOOSTarrow-up-right version 1.81.0. All installation files will live under cerisse/lib.

Alternatively, CGAL may have already been installed in the machine. For example in MacOS using homebrewarrow-up-right

The key idea is that the Boost and CGAL libraries must be compatible with the compiler used to build the code. Installing CGAL via Homebrew on macOS defaults to the Clang compiler, so Cerisse should also be compiled using Clang to ensure compatibility.

Installation SUNDIALS

SUNDIALS is a libary of differential and algebraic equation solvers used by PelePhysics for CVODE to integrate the chemistry. To install go to an example involving chemistry (for example tst/test2) and execute

This will download and install version 6.5 if not present. Sundials cannot be installed before compiling as some options (such as GPU) require re-compiling. All sundials files will live undercerisse/lib.

Quick Example

This quick example shows the workflow of Cerisse in a simple example

1) Go to problem folder

In this example, Cerisse will solve a very coarse classic one-dimensional Sod Test.

The directory contains the following files

A detailed explanation of the files is in tutorial Tutorial, but basically inputs is the simulation control file (mesh size, number of steps, etc...), while prob.h determines the problem to solve.

2) Compile code

The compiling stage will create the executable, to compile use:

circle-info

Utilize $make -j4 if feasible, as it will expedite the compilation process. This step may be time-consuming, especially during the initial execution, depending on your system and configuration options. However, in most cases, this step needs to be done only once .

After compilation, the code will create a temporary folder tmp_build_dir and, if succesful, an executable named main1d.gnu.MPI.ex The executable name will change depending on the compiler, parallelization and dimension of the problem.

4) Run

To run type (using one core only)

It will run very quickly for 200 steps, and the final output should be like this (exact numbers can change machine to machine)

The solver will create a new folder plot

Where the directories plt* store the data files, every 100 steps, including the initial step.

5) See the Results

The results can be seen by a python script

which should show something like

test1plot

You need to have the Python module yt installed to visualise this. Refer to the Tips section for installation guidance . For a more in-depth walkthrough, see the Tutorial

Last updated