PySCo: A fast Particle-Mesh -body code for modified gravity simulations in Python
arXiv:2410.20501 · doi:10.1051/0004-6361/202452770
Abstract
We present PySCo, a fast and user-friendly Python library designed to run cosmological -body simulations across various cosmological models, such as CDM and CDM, and alternative theories of gravity, including , MOND and time-dependent gravitational constant parameterisations. PySCo employs Particle-Mesh solvers, using multigrid or Fast Fourier Transform (FFT) methods in their different variations. Additionally, PySCo can be easily integrated as an external library, providing utilities for particle and mesh computations. The library offers key features, including an initial condition generator based on up to third-order Lagrangian Perturbation Theory (LPT), power spectrum estimation, and computes the background and growth of density perturbations. In this paper, we detail PySCo's architecture and algorithms and conduct extensive comparisons with other codes and numerical methods. Our analysis shows that, with sufficient small-scale resolution, the power spectrum at redshift remains independent of the initial redshift at the 0.1\% level for 125, 30, and 10 when using first, second, and third-order LPT, respectively. Although the seven-point Laplacian method used in multigrid also leads to power suppression on small scales, this effect can largely be mitigated when computing ratios. In terms of performance, PySCo only requires approximately one CPU hour to complete a Newtonian simulation with particles (and an equal number of cells) on a laptop. Due to its speed and ease of use, PySCo is ideal for rapidly generating vast ensemble of simulations and exploring parameter spaces, allowing variations in gravity theories, dark energy models, and numerical approaches. This versatility makes PySCo a valuable tool for producing emulators, covariance matrices, or training datasets for machine learning.
Accepted in A&A. 21 pages, 17 figures. The code can be found at https://github.com/mianbreton/pysco
References in corpus (29)
- Array Programming with NumPy
- The Astropy Project: Sustaining and Growing a Community-oriented Open-source Project and the Latest Major Release (v5.0) of the Core Package
- Models of f(R) Cosmic Acceleration that Evade Solar-System Tests
- Transients from Initial Conditions in Cosmological Simulations
- Measuring the dark side (with weak lensing)
- New Perspective on Galaxy Clustering as a Cosmological Probe: General Relativistic Effects
- Bimetric MOND gravity
- Non-linear evolution of f(R) cosmologies I: methodology
- Initial Conditions for Large Cosmological Simulations
- Large-scale dark matter simulations
- A simple multigrid scheme for solving the Poisson equation with arbitrary domain boundaries
- The modified Newtonian dynamics-MOND-and its implications for new physics
- The Cosmological -body Code
- How well is our universe described by an FLRW model?
- Towards optimal parallel PM N-body codes: PMFAST
- Phantom of RAMSES (POR): A new Milgromian dynamics N-body code
- Cosmological Structure Formation under MOND: a new numerical solver for Poisson's equation
- Lagrangian perturbations and the matter bispectrum I: fourth-order model for non-linear clustering
- Rings and shells of "dark matter" as MOND artifacts
- RAyMOND: An N-body and hydrodynamics code for MOND
- Speeding up -body simulations of modified gravity: Chameleon screening models
- Euclid. V. The Flagship galaxy mock catalogue: a comprehensive simulation for the Euclid mission
- Simulation techniques for modified gravity
- The e-MANTIS emulator: fast predictions of the non-linear matter power spectrum in CDM cosmology
- Generalizations of Quasilinear MOND (QUMOND)
- BullFrog: Multi-step perturbation theory as a time integrator for cosmological simulations
- Euclid preparation. Simulations and nonlinearities beyond CDM. 1. Numerical methods and validation
- Starting Cosmological Simulations from the Big Bang
- Fast particle-mesh code for Milgromian dynamics