GRAVITAX: testing gravity with a differentiable Boltzmann code
astro-ph.CO, astro-ph.IM
Submitted: 2026-12-03
Updated: 2026-12-03
Comments: 27 pages, 10 figures. GRAVITAX available at https://github.com/ECLIPSE-AI4Science/gravitax
License: http://creativecommons.org/licenses/by/4.0/
The gist: Departures from general relativity on cosmological scales can be described by two functions of time and scale, μ and Σ, which modify the Poisson and lensing equations.
Abstract
Departures from general relativity on cosmological scales can be described by two functions of time and scale, μ and Σ, which modify the Poisson and lensing equations. The most general tests let both vary in bins of redshift and scale, but every bin adds a parameter to the Einstein-Boltzmann equations, and sampling costs have limited such analyses to a few bins. We show that Hamiltonian Monte Carlo (HMC) keeps this cost affordable when a differentiable code solves the equations at every step on GPUs. We therefore developed GRAVITAX, a new Einstein-Boltzmann code in JAX that computes the lensed cosmic microwave background (CMB) and lensing-potential spectra, and linear and nonlinear matter power spectra, with their exact derivatives. To our knowledge, these are the first such HMC analyses of Stage IV likelihoods. In Λ CDM, with 158 parameters for a simulated Simons Observatory-like CMB experiment and three Stage IV surveys, GRAVITAX reproduces the posterior of CAMB and Cobaya, with means within 0.07 standard deviations and widths within 5 per cent, and one GPU-hour does the work of about 270 CPU core-hours per effective sample. With μ and Σ free in four bins of redshift and four of scale, it reproduces the 90-parameter posterior of MGCAMB, with one GPU-hour doing the work of about 2100 CPU core-hours, and recovers an injected departure from general relativity. Emulators of binned models must be retrained for every choice of bins; GRAVITAX needs none, and it can also help to develop emulators for such models. GRAVITAX is publicly available at https://github.com/ECLIPSE-AI4Science/gravitax
Related papers
- Dark Energy Survey Year 3 results: optimized w CDM simulation-based inference with weak lensing map-level hybrid statistics
- 21cmEMUv3: a hybrid diffusion-LSTM emulator of 21cmFAST summary observables
- Simulation-Based Priors and BAO Shifts from the Lyman- alpha Forest at the Field Level
- Improved constraints on axion inflation with the new code AxioGen: an efficient generator of curvature perturbations
- Connecting field-level and n-point function measurements of galaxy bias
- The Impact of Cosmic Variance and Satellites on JWST Clustering Measurements at Redshift around 6