← Latest papers
🔭 astrophysics

halox: Dark matter halo properties and large-scale structure calculations using JAX

The paper introduces **halox**, a JAX-powered Python library that enables differentiable and accelerated computations of dark matter halo properties and the halo mass function, facilitating their integration into gradient-based workflows such as Hamiltonian Monte Carlo sampling and machine learning applications.

Original authors: Florian Kéruzoré, Lance A. Moreau

Published 2026-06-02
📖 5 min read🧠 Deep dive

Original authors: Florian Kéruzoré, Lance A. Moreau

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine the universe as a giant, invisible scaffolding made of "dark matter." You can't see this scaffolding, but it holds everything together. The heavy, clumpy parts of this scaffolding are called dark matter halos. These halos are like the invisible foundations of a city; they are the gravitational "wells" where galaxies (our cities) and clusters of galaxies (our metropolises) eventually form and settle.

To understand how the universe grew, scientists need to measure these invisible foundations very precisely. They need to know their size, their density, and how many of them exist at different times in the universe's history.

The Problem: The Old Tools Were Too Slow
For a long time, scientists used software tools (like a toolbox called colossus) to calculate these properties. Think of these old tools as a very skilled, but slow, human accountant. They could do the math, but if you asked them to calculate the properties of millions of halos at once, or if you needed to tweak the numbers slightly to see how the results changed (a process called "gradient-based analysis"), the human accountant would take forever. They were also stuck working on a single desk (a standard computer processor) and couldn't easily use the super-fast power of modern graphics cards (GPUs).

The Solution: Enter halox
The authors of this paper built a new tool called halox. If the old tools were a human accountant, halox is like a team of super-fast robots working in a high-tech factory, all coordinated by a smart brain called JAX.

Here is what makes halox special, using simple analogies:

  1. The "Smart Brain" (Differentiability):
    In the past, if a scientist wanted to see how a tiny change in the universe's rules would affect the halos, they had to manually re-calculate everything from scratch. halox is "differentiable." Imagine driving a car where the dashboard instantly tells you exactly how much your speed will change if you press the gas pedal just a tiny bit. halox does this for the universe. It can instantly tell scientists how the results change if they tweak the input numbers. This is crucial for advanced methods like "Hamiltonian Monte Carlo," which is a fancy way of saying "finding the best answer by exploring many possibilities efficiently."

  2. The "Super-Fast Factory" (Hardware Acceleration):
    While the old tools worked on a single lane road, halox is built to drive on a massive highway. It is designed to run on GPUs (the powerful chips usually found in video game computers). The paper shows that when halox runs on these GPUs, it can calculate the properties of dark matter halos 20 to 65 times faster than the old tools, depending on the task.

  3. The "Cheat Sheet" (Neural Network Emulators):
    Some of the math required to understand these halos involves complex integrals (summing up infinite tiny pieces), which is like trying to count every grain of sand on a beach one by one. It takes a long time.
    halox includes a "neural network emulator." Think of this as a highly trained student who has studied the beach so thoroughly that they can guess the number of grains of sand almost instantly with 99% accuracy. Instead of doing the slow, heavy math every time, halox can use this "cheat sheet" to get the answer 95 times faster than the baseline method, while still being incredibly accurate.

What Does halox Actually Do?
The paper lists specific "ingredients" the tool can calculate:

  • Cosmology: It calculates the basic rules of the universe (like how dense space is).
  • Halo Shapes: It describes the shape of the dark matter clouds (using models like NFW and Einasto), telling us how dense they are at the center versus the edge.
  • Concentration: It figures out how "clumped" the matter is in a halo.
  • The "Mass Function": It predicts how many halos of a certain size exist at a specific time in the universe.
  • Bias: It calculates how likely these halos are to cluster together.

The Results
The authors tested halox against the old standard (colossus).

  • On a standard computer (CPU), the old tool was still slightly faster for simple tasks because it uses very optimized, traditional code.
  • However, on a GPU, halox crushed the competition, running 20 to 65 times faster.
  • When using the "cheat sheet" (emulator), it was 34 times faster than the old tool even on the GPU.

Who is Using It?
The paper mentions that halox is already being used in upcoming scientific projects, such as creating realistic simulations of the sky and analyzing data for the LSST Dark Energy Science Collaboration (a major project studying the mysterious force pushing the universe apart).

In Summary
halox is a new, super-fast, and "smart" calculator for the invisible foundations of the universe. It allows scientists to run complex simulations on powerful graphics cards and instantly see how small changes in their theories affect the results, speeding up the discovery process for understanding how our universe is built.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →