CosmoLattice is a modern package for lattice simulations of field dynamics in an expanding universe. We have developed CosmoLattice to provide a new up-to-date, relevant numerical tool for the scientific community working in the physics of the early universe.
Version 1-0 of CosmoLattice can simulate the dynamics of i) interacting scalar field theories, ii) Abelian U(1) gauge theories, and iii) non-Abelian SU(2) gauge theories, either in flat spacetime or an expanding FLRW background, including the case of self-consistent expansion sourced by the fields themselves. CosmoLattice is ready to simulate the dynamics of field theories described by an action and a background metric of the type:
We have conceived CosmoLattice as an evolving package that we plan to upgrade successively, by further developing modules for new tasks. To mention just a few, we plan to add e.g. the computation of gravitational waves (now developed in version 1.1), new initialization routines, and different evolution algorithms. CosmoLattice is in fact a platform to implement any system of dynamical equations suitable for discretization on a lattice, as it introduces its own language describing fields and operations between them, and hence it is a natural platform to implement new libraries to solve arbitrary field problems (related or not to cosmology).
Some features:
CosmoLattice incorporates a series of features that makes it very versatile and powerful. We list some of them:
- It is written in C++, and fully exploits the object oriented programming paradigm, with a modular structure and a clear separation between the physics and the technical details.
- It is MPI-based and uses a discrete Fourier transform parallelized in multiple spatial dimensions, which makes it specially appropriate for probing scenarios with well-separated scales, running very high resolution simulations, or simply very long ones.
- It introduces its own symbolic language, defining field variables and operations over them. This way, one can introduce differential equations and operators in a manner as close as possible to the continuum.
- it includes a library of numerical algorithms, ranging from second-order to tenth-order accuracy methods, suitable for simulating global and gauge theories in an expanding grid.
- Our evolution algorithms conserve energy up to the accuracy set by the order of the evolution algorithm, reaching even machine precision in the case of the highest order integrators.
- All our evolution algorithms for gauge theories (for both Abelian and non-Abelian) respect the Gauss constraint to machine precision.
- Relevant observables are provided for each algorithm, such as field average amplitudes, relevant field spectra, energy density components, or 3D lattice snapshots.
- It comes with the core library TempLat, which implements fields and algebraic operations and the handling of the parallelization technical details. It works in arbitrary dimensions (smaller or larger than 3), which makes it an ideal tool to develop new modules to solve problems in higher dimensions.