Field-Level Comparison and Robustness Analysis of Cosmological N-body Simulations
arXiv:2505.13620 · doi:10.3847/1538-4357/adef4e
Abstract
We present the first field-level comparison of cosmological N-body simulations, considering various widely used codes: Abacus, CUBEPM, Enzo, Gadget, Gizmo, PKDGrav, and Ramses. Unlike previous comparisons focused on summary statistics, we conduct a comprehensive field-level analysis: evaluating statistical similarity, quantifying implications for cosmological parameter inference, and identifying the regimes in which simulations are consistent. We begin with a traditional comparison using the power spectrum, cross-correlation coefficient, and visual inspection of the matter field. We follow this with a statistical out-of-distribution (OOD) analysis to quantify distributional differences between simulations, revealing insights not captured by the traditional metrics. We then perform field-level simulation-based inference (SBI) using convolutional neural networks (CNNs), training on one simulation and testing on others, including a full hydrodynamic simulation for comparison. We identify several causes of OOD behavior and biased inference, finding that resolution effects, such as those arising from adaptive mesh refinement (AMR), have a significant impact. Models trained on non-AMR simulations fail catastrophically when evaluated on AMR simulations, introducing larger biases than those from hydrodynamic effects. Differences in resolution, even when using the same N-body code, likewise lead to biased inference. We attribute these failures to a CNN's sensitivity to small-scale fluctuations, particularly in voids and filaments, and demonstrate that appropriate smoothing brings the simulations into statistical agreement. Our findings motivate the need for careful data filtering and the use of field-level OOD metrics, such as PQMass, to ensure robust inference.
15 pages, 7 figures, 2 tables
References in corpus (34)
- The cosmological simulation code GADGET-2
- E pur si muove: Galiliean-invariant cosmological hydrodynamical simulations on a moving mesh
- Cosmological Hydrodynamics with Adaptive Mesh Refinement: a new high resolution code called RAMSES
- Simulating Galaxy Formation with the IllustrisTNG Model
- Simulating galaxy formation with black hole driven thermal and kinetic feedback
- GIZMO: A New Class of Accurate, Mesh-Free Hydrodynamic Simulation Methods
- Enzo: An Adaptive Mesh Refinement Code for Astrophysics
- The Santa Barbara cluster comparison project: a comparison of cosmological hydrodynamics solutions
- The Arepo public code release
- Bayesian physical reconstruction of initial conditions from large scale structure surveys
- The CAMELS project: Cosmology and Astrophysics with MachinE Learning Simulations
- A non-linear solution to the tension?
- Early Structure Formation in PBH Cosmologies
- Matter power spectrum and the challenge of percent accuracy
- High Performance P3M N-body code: CUBEP3M
- Physical Bayesian modelling of the non-linear matter distribution: new insights into the Nearby Universe
- The Cosmological -body Code
- Towards optimal extraction of cosmological information from nonlinear data
- A High-Fidelity Realization of the Euclid Code Comparison -body Simulation with Abacus
- A rigorous EFT-based forward model for large-scale structure
- Discreteness Effects in Lambda Cold Dark Matter Simulations: A Wavelet-Statistical View
- The CAMELS Multifield Dataset: Learning the Universe's Fundamental Parameters with Artificial Intelligence
- The CAMELS project: public data release
- How much information can be extracted from galaxy clustering at the field level?
- Unbiased Cosmology Inference from Biased Tracers using the EFT Likelihood
- LtU-ILI: An All-in-One Framework for Implicit Inference in Astrophysics and Cosmology
- Consistency tests of field level inference with the EFT likelihood
- The DESI -body Simulation Project I: Testing the Robustness of Simulations for the DESI Dark Time Survey
- Impacts of the physical data model on the forward inference of initial conditions from biased tracers
- EFTofLSS meets simulation-based inference: from biased tracers
- Joint velocity and density reconstruction of the Universe with nonlinear differentiable forward modeling
- A comparative study of cosmological constraints from weak lensing using Convolutional Neural Networks
- Good and Proper: Self-similarity of N-body Simulations with Proper Force Softening
- Massive s through the CNN lens: interpreting the field-level neutrino mass information in weak lensing