DiFfRG#

DiFfRG: DiFfRG C++ API
DiFfRG
Discretization Framework for functional Renormalization Group flows
DiFfRG C++ API

Overview

DiFfRG (Discretization Framework for functional Renormalization Group flows) is a C++20 scientific-computing library for solving fRG flow equations. It provides spatial and temporal discretization of quantum field theory systems, built on deal.II (FEM), Kokkos (GPU/CPU parallelization) and SUNDIALS (implicit solvers).

This is the reference for the C++ library. A simulation is assembled from a small number of components along a fixed pipeline:

The pipeline

Model → Discretization → Assembler → Timestepper → Output

  1. Entry point. Init initializes the runtime (Kokkos, and MPI if enabled) and hands back a ConfigurationHelper that parses the parameter.json/toml file and command-line overrides.
  2. Model. The physics is defined by deriving from the CRTP base def::AbstractModel, which fixes the mass, flux and source functions of the flow equations. Behaviour is composed from mixins: def::fRG (RG time / cutoff scale), def::LLFFlux (local Lax-Friedrichs numerical flux), def::FlowBoundaries (inflow/outflow boundaries) and def::AD (automatic-differentiation Jacobians). Finite volume models additionally pick a boundary stencil, e.g. def::FVDefaultBoundaries or def::RhoSymmetricLinearExtrapolationBoundaries. The degrees of freedom are declared with ComponentDescriptor / FEFunctionDescriptor and Scalar.
  3. Discretization. The field space is discretized with one of CG, DG, LDG or FV discretizations on a RectangularMesh (whose grading and extents are configured through Config::ConfigurationMesh).
  4. Assembler. An assembler implementing AbstractAssembler computes residuals and Jacobians from the model and discretization; the concrete variants are CG, DG, dDG, LDG and FV.
  5. Finite volume policies. The Kurganov-Tadmor assembler takes its advective face reconstruction, its wave-speed estimate and (optionally) a separate reconstruction for the Jacobian as template policies. The reconstructor is either def::FirstOrderReconstructor (piecewise constant) or def::TVDReconstructor, which is in turn parameterized by a slope limiter — def::MinModLimiter (the default), def::CentralLimiter, def::SuperbeeLimiter or def::VanAlbadaLimiter. The local wave speed entering the numerical flux comes from MaxEigenvalueWaveSpeed; diffusive fluxes always use def::CorrectedWeightedLeastSquaresDiffusionReconstructor.
  6. Timestepper. A timestepper implementing AbstractTimestepper evolves the system in RG time. The recommended default is the differential-algebraic TimeStepperSUNDIALS_IDA; explicit (Euler, Runge-Kutta, Adams-Bashforth-Moulton) and further implicit (implicit Euler, TRBDF2) steppers are also provided. The solution is held in AbstractFlowingVariables (FE::FlowingVariables). Implicit steppers solve their linear systems through an AbstractLinearSolver, e.g. GMRES, ScaledLinearSolver or UMFPack.
  7. Output. Results are written through run-owned OutputSession instances and scoped OutputFrame events (CSV / HDF5 / VTK) below an OutputPath; diagnostic messages go to the ReportPort the session hands out. The mesh can be refined adaptively with HAdaptivity.

Momentum-space integration

Fully momentum-dependent flow equations are evaluated by integrators implementing AbstractIntegrator, such as Integrator_p2, which share quadrature rules through a QuadratureProvider. The corresponding kernels are generated from Mathematica (see the Mathematica reference and Tutorial 3 of the wider documentation site).

Getting started

For installation instructions and worked, end-to-end examples, see the Getting Started section and the Tutorials of the documentation site. Including the umbrella header #include <DiFfRG/DiFfRG.hh> pulls in the whole library.