Selected Projects

Schnek

Github repository: https://github.com/holgerschmitz/Schnek

Documentation: https://schnek.readthedocs.io/en/latest

Schnek is an open source C++ library that supports the rapid development of parallel simulation software on regular grids. It encapsulates parallelisation strategies together with much of the administration code required to implement flexible high-performance codes. This allows simulation code developers to focus on what matters for their specific problem: solving the model equations using the best numerical scheme.

Regular Grids are a core element for many numerical schemes. Schnek defined classes for n-dimensional grids. It also has support for fields that contain information about the mapping between physical coordinates and grid cells. The grids or fields can use a variety of different storage models. Some predefined models are C- or Fortran-ordered arrays and lazy-allocation schemes. The current development version also includes support for Kokkos Views. Different storage models are defined through a template parameter. This means, the same user code can compile with different models, just by changing a type definition.

Parallelisation Strategies determine how simulation codes make use of compute clusters and high-performanc computing hardware. Schnek supports parallelisation in two ways. Grids can be defined with ghost (or halo) cells. In addition, domain subdivisions allow allocating local ranges for each MPI process in arbitrary dimensions. They also manage the exchange of ghost cells between processes. The upcoming version of Schnek will extend this concept and allow more flexible domain decompositions, including support for multiple regions per process, flexible load balancing, distribution of particle-like data, and support for GPU and hybrid architectures.

Diagnostics encapsulate the output from a simulation run. Schnek defines classes that can save grids into HDF5 files and work seamlessly with the parallelisation strategies. Using a few simple lines of code, the developer can save an n-dimensional grid that is distributed over many MPI processes into a single data file.

Flexibility allows a simulation code to be used many times in different scenarios simulating vastly different physical systems. Schnek allows the development of large community codes by containing a parser for setup files that translates directly into an object hierarchy in the simulation code. Code developers can define modules that are configured through input parameters or even submodules using just a few lines of code. This allows the end user to configure the setup choosing which physical processes apply and how they interact.