GADGET-4-CPPC is an N-body code to study neutrinos and any hot dark matter with linear response, multifluid and hybrid methods. It is based on the code GADGET-4, that is a massively parallel code for N-body/hydrodynamical cosmological simulations and mainly written by Volker Springel.
The neutrino hybrid method implementations have been performed by Joe Chen, and a previous version of the code (for neutrinos only) can be found in gadget4-hybrid_public.
The hot dark matter multifluid part integrated here has been developed by Amol Upadhye. The original repository can be found in MuFLR-HDM.
A brief documentation on the GADGET-4-CPPC additions and methods cane be found here.
For reference on the physics implemented, please refer to the main papers:
- Giovanni Pierobon, Markus R. Mosbech, Amol Upadhye, Yvonne Y.Y. Wong, One trick to treat them all: SuperEasy linear response for any hot dark matter in N-body simulations, 2410.05816
- Joe Zhiyu Chen, Markus R. Mosbech, Amol Upadhye, Yvonne Y.Y. Wong, Hybrid multi-fluid-particle simulations of the cosmic neutrino background, 2210.16012
- Joe Zhiyu Chen, Amol Upadhye, Yvonne Y.Y. Wong, The cosmic neutrino background as a collection of fluids in large-scale structure simulations, 2011.12503
- Joe Zhiyu Chen, Amol Upadhye, Yvonne Y.Y. Wong, One line to run them all: SuperEasy massive neutrino linear response in N-body simulations, 2011.12504
To compile the code and run a typical simulation you will need the following libraries:
- Working C/C++ compilers (for GNU version 4.x or later)
- GNU Scientific Library (GSL)
- Fastest Fourier Transform in the West (FFTW3)
- Hierarchical Data Format (HDF5)
- Message Passing Interface (MPI), version 3.0 or higher. Examples are Intel-MPI, OpenMPI, MPICH
To install the code clone the repository
git clone https://github.com/cppccosmo/gadget-4-cppc.git; cd gadget-4-cppc
Then to start a simulation folder choose between Linear Response (LR), Multifluid (MF) or Hybrid (HYB) and run
bash hsetup.sh /path/to/sim/folder <system>
An example is
bash hsetup.sh /tests/hybrid_sim gadi