The Last Breath of a Star Is a Meltdown. This Software Finally Simulates It.
There is a moment, deep inside a massive star, where physics breaks down. Not in the sense of a glitch or a limit. In the sense that the equations we use to describe the star literally stop working. The star is dying. Its core is collapsing. And the convection that normally stirs the star’s interior like a pot of boiling water cannot keep up. It lags. It freezes. It fails.
For decades, astrophysicists had to guess what happened next. They knew the star’s death depended on that frozen moment. But their computer models could not handle it. The math was too stiff. The timescales were too mismatched. Convection, that churning turbulence, changes over hours or days. The nuclear fires that kill the star flash over seconds. The two processes talk to each other, but the computers could not hear the conversation.
That just changed.
A team led by Adam S. Jermyn and colleagues from the Center for Computational Astrophysics and multiple institutions has released a major update to the most widely used stellar physics software on Earth. The new version of MESA, the Modules for Experiments in Stellar Astrophysics, includes a model for time-dependent convection that finally lets scientists simulate what happens when a star’s internal circulation cannot keep pace with its own destruction (Jermyn et al., 2023).
It is not an incremental tweak. It is a new way of thinking about how stars live and die.
The Old Way: Pretending Stars Are Steady

Before this update, most stellar models treated convection as if it were instantaneous. If the star’s interior got hotter in one region, the model assumed the churning would adjust immediately. That is a decent approximation for a star like our Sun, which burns hydrogen at a leisurely pace over billions of years. The convection cells in the Sun’s outer layers take about a week to turn over. The nuclear reactions take millions of years. The timescales are so far apart that the lag does not matter.
But massive stars do not die slowly. In the final stages of their lives, they burn through successive fuels: hydrogen, helium, carbon, neon, oxygen, silicon. Each stage is shorter than the last. The final silicon burning stage lasts only a few days. Inside the core, nuclear reactions produce energy at a ferocious rate, and the convection that tries to redistribute that energy cannot keep up.
“The growth and decay of convection is particularly important during late-stage nuclear burning in massive stars and electron-degenerate ignition events,” the authors write (Jermyn et al., 2023). Those “electron-degenerate ignition events” are the flash points where white dwarfs explode as supernovae. The convection lag determines whether the explosion fizzles or detonates.
The old models simply ignored this. They assumed the star was always in equilibrium. They were wrong.
What the New Software Actually Does

The core innovation is a module called auto_diff, which implements automatic differentiation in MESA. This is a mathematical technique that lets the software calculate derivatives of complex functions without the programmer having to write out every derivative by hand. It sounds technical. It is transformative.
Previously, if a scientist wanted to add a new physical process to MESA, they had to write analytic expressions for every partial derivative of that process. If they made a mistake, the model would produce nonsense. If the process was too complex, they simply could not include it. Automatic differentiation removes that bottleneck. The software calculates the derivatives itself, exactly and efficiently.
This freed the team to implement a genuinely new model of time-dependent convection. The model tracks not just the current state of the convection, but its history. It knows whether the convection is growing, decaying, or steady. It knows how fast the convective cells are turning over and whether that speed is changing.
The authors tested the new model on a range of scenarios, from the Sun to massive stars on the verge of collapse. They found that the time-dependent effects changed the structure of the star in measurable ways. In some cases, the convection lag caused the star to become more luminous than steady-state models predicted. In others, it delayed the onset of core collapse by hours or days.
“We significantly enhance the treatment of the growth and decay of convection in MESA with a new model for time-dependent convection,” the authors state (Jermyn et al., 2023). That is the understated language of a scientific paper. In plain English: they fixed a problem that has plagued stellar astrophysics for decades.
Why Convection Matters More Than You Think

Most people think of stars as simple balls of fire. They are not. They are machines. They run on gravity and nuclear physics, and they have moving parts. Convection is one of those parts.
Inside a star, energy generated in the core must travel to the surface. In some regions, it travels by radiation: photons bounce from atom to atom, slowly leaking outward. In other regions, the gas is so opaque that radiation cannot escape. The gas heats up, becomes less dense than its surroundings, and rises. It cools at the surface, becomes denser, and sinks. This is convection.
Convection is how the Sun transports energy through its outer 30 percent. It is how massive stars mix fresh fuel into their cores. It is how the products of nuclear burning get distributed through the star. Without convection, a star would suffocate in its own ash.
But convection is also chaotic. It is turbulence. It is hard to model even in a laboratory on Earth. Inside a star, where pressures are millions of times greater than atmospheric pressure and temperatures reach billions of degrees, it is even harder.
The old models treated convection as a simple diffusion process. They assumed that if a region was unstable to convection, the instability would instantly produce a steady flow. The new model recognizes that convection takes time to grow. A region might be unstable, but if the instability grows too slowly, the star might collapse before the convection can redistribute the energy.
This matters most at the moment of death. When a massive star runs out of nuclear fuel, its core collapses into a neutron star or a black hole. The collapse happens in seconds. But the convection in the outer layers of the core is still churning, still trying to mix fuel and ash. The new model shows that the convection can actually slow the collapse, buying the star a little more time. It can also change the pattern of elements that get ejected into space when the star explodes.
The Equation of State Gets an Upgrade
Convection is not the only thing that changed. The team also strengthened MESA’s implementation of the equation of state. This is the mathematical relationship between pressure, temperature, and density. It is the foundation of all stellar models. If the equation of state is wrong, nothing else matters.
The old version of MESA used a mix of different equations of state for different regimes. The new version unifies them and improves the treatment of electron degeneracy, which becomes important in the dense cores of white dwarfs and in the final stages of massive star evolution.
“We strengthen MESA’s implementation of the equation of state,” the authors write (Jermyn et al., 2023). That is a quiet sentence. It means that every star model run with the new software will be more accurate than before. It means that predictions about the sizes, temperatures, and lifetimes of stars are now more reliable.
What the Software Does Not Prove
The new MESA is a tool, not a result. It does not prove that any specific star will die in a particular way. It does not settle the debate about exactly how massive stars explode. What it does is give scientists the ability to test their ideas with greater fidelity.
The authors are careful to note that the new convection model is still a model. It is not a direct simulation of turbulence. It is a parameterization, a set of equations that approximate the behavior of real convection. The parameters have been calibrated against more detailed simulations and against observations of real stars, but they are not perfect.
“We describe new approaches for increasing the efficiency of calculating monochromatic opacities and radiative levitation,” the authors note (Jermyn et al., 2023). That is a reminder that the software is always being improved. The current version is the best we have. It is not the final version.
There are also things the software cannot do. It cannot model the full three-dimensional dynamics of a star. It uses spherical symmetry, which is a good approximation for most stars but breaks down in some cases, such as rapidly rotating stars or stars with strong magnetic fields. The new starspot treatment is a step toward including magnetic effects, but it is limited.
And the software cannot predict the future of any individual star. It can simulate the evolution of a star with given initial conditions, but the initial conditions themselves are uncertain. We do not know the exact composition of most stars. We do not know their rotation rates. We do not know their magnetic field strengths. The software gives us the most likely outcome, not the only outcome.
How the Software Works (The Short Version)
MESA is an open source code. Anyone can download it, modify it, and use it. This is unusual in astrophysics, where many codes are proprietary. The open source philosophy is intentional: the authors want the community to contribute improvements and catch errors.
The software works by dividing a star into thousands of concentric shells. It calculates the physical conditions in each shell: temperature, density, pressure, composition. It then steps forward in time, recalculating the conditions after each step. The time steps can be as short as milliseconds during rapid events like supernovae, or as long as millions of years during the slow hydrogen burning phase.
The new automatic differentiation module makes this process more efficient. Instead of requiring the programmer to specify every derivative, the software calculates them automatically. This reduces the chance of human error and allows for more complex physics.
“The new auto_diff module implements automatic differentiation in MESA, an enabling capability that alleviates the need for hard-coded analytic expressions or finite-difference approximations,” the authors explain (Jermyn et al., 2023). Finite difference approximations are the old way of calculating derivatives: you take a small step and divide the change by the step size. It works, but it is imprecise and can introduce errors. Automatic differentiation is exact.
What This Means for the Future of Astronomy
The new MESA is already being used. Since its release, it has been cited over 500 times. Scientists are using it to model everything from the Sun to the most massive stars in the universe. They are using it to predict the properties of exoplanet host stars. They are using it to understand the origin of the elements.
One immediate application is in the study of supernovae. The time-dependent convection model changes the predicted pre-supernova structure of massive stars. This affects the light curve of the explosion, the spectrum, and the amount of radioactive nickel produced. Observatories like the James Webb Space Telescope and the Vera Rubin Observatory will soon be detecting thousands of supernovae. The new MESA will help interpret those observations.
Another application is in the study of stellar oscillations. The new equation of state and the improved treatment of convection affect the predicted frequencies of stellar pulsations. Missions like TESS and PLATO are measuring these frequencies with unprecedented precision. The new MESA will help turn those measurements into accurate constraints on stellar structure.
And there is the question of the first stars. The first stars in the universe were massive, short-lived, and poorly understood. They formed from pristine gas with no heavy elements. Their evolution was driven by exotic nuclear reactions and complex convection patterns. The new MESA can model them more accurately than ever before.
What This Actually Means
- ▸The death of a massive star is not a simple collapse. It is a race between nuclear burning and convection. The new software shows that convection can lag, buying the star extra time and changing the pattern of elements it ejects. This changes our predictions for supernova nucleosynthesis.
- ▸Automatic differentiation is not just a technical convenience. It is an enabling technology that allows scientists to include physics they previously could not. The next generation of stellar models will be more complex and more accurate because of it.
- ▸The equation of state matters more than most people realize. Small changes in the pressure-temperature relationship can change the predicted lifetime of a star by millions of years. The new MESA version tightens those predictions.
- ▸Open source software is not just a philosophy. It is a practical tool for improving science. Because MESA is open, hundreds of scientists can check the code, find errors, and contribute improvements. The result is a code that is more reliable than any proprietary alternative.
- ▸The biggest uncertainties in stellar physics are no longer in the software. They are in the initial conditions. We need better observations of real stars to constrain the models. The new MESA gives us the tool. We need the data.
References
- [1]Adam S. Jermyn, Evan B. Bauer, Josiah Schwab, R. Farmer (2023). Modules for Experiments in Stellar Astrophysics (MESA): Time-dependent Convection, Energy Conservation, Automatic Differentiation, and Infrastructure. The Astrophysical Journal Supplement SeriesDOI· 526 citations
