The Balancing Act — Hydrostatic Equilibrium
Section 5 of 7
The Virial Theorem
Part 4: The Virial Theorem for Stars
Force balance tells us what support a star needs at each radius, but not how gravity and thermal energy are linked as the star contracts, radiates, and evolves. For that we need an energy argument. The
Virial theorem
For a bound, self-gravitating system in equilibrium, , so the total thermal energy is fixed at half the magnitude of the (negative) gravitational potential energy. It implies that gravitational contraction heats a star.
Energy balance in self-gravitating systems
Hydrostatic equilibrium is a force-balance statement; the virial theorem is an energy-balance statement relating the star’s total thermal energy to its gravitational potential energy. For a bound star, the gravitational potential energy has a characteristic scale.
The minus sign matters: a bound self-gravitating object has less energy than the same mass dispersed to infinite separation. Contraction (smaller ) makes larger.
For a star in hydrostatic equilibrium, the virial theorem links this to the thermal energy.
Rearranging, , and the total energy — the star is bound. In quasi-static contraction, roughly half the released gravitational energy increases the thermal energy of the gas, while roughly half must be radiated away.
Numeric answer
Using , if a star contracts to one-third its radius at fixed mass, by what factor does change?
At fixed mass, , so shrinking from to gives . That is a large change in binding energy, not a tiny correction — the star becomes much more tightly bound. In quasi-static contraction, part of that released gravitational energy goes into thermal energy, so the gas heats substantially.
The negative heat capacity paradox
A star radiates energy from its surface, so its total energy becomes more negative. Because , this means also becomes more negative — the star contracts into a more tightly bound state. But the virial theorem also says , so if becomes more negative, becomes larger. More thermal energy means higher typical particle speeds and a higher temperature.
So the star gets hotter as it loses energy. This is
Negative heat capacity
The property of a self-gravitating system whereby losing total energy raises its temperature: radiation drives contraction, contraction deepens the gravitational well, and the virial theorem converts that into a higher thermal energy. It is how gravitational contraction heats a protostar toward fusion.

Protostars shrink and heat instead of free-falling
Protostars radiate energy while gradually shrinking, instead of collapsing in free fall.
A bound self-gravitating gas obeys the virial theorem
A bound self-gravitating gas obeys .
Losing energy makes the core hotter
As radiation removes total energy, the star contracts, becomes more negative, and the thermal energy increases. The core gets hotter as the star loses energy.
Think first — energy logic
A protostar loses energy by radiation. Before using any equations, reason physically: does it expand or contract? Does the temperature rise or fall?
Then open the reasoning below to check.
Quick check
Check your prediction: as a protostar radiates energy away, does it expand or contract, and does its core temperature rise or fall? Reason physically.
As the protostar radiates energy away, its total energy becomes more negative, and a self-gravitating object responds by contracting into a tighter, more strongly bound state. That contraction deepens the gravitational well and increases the typical particle speeds, so the core temperature rises. This is exactly why contraction is good news for fusion: hydrogen fusion requires , and a protostar begins too cool — contraction steadily heats the core until fusion can ignite.
You now hold the two halves of the equilibrium story. Force balance (Parts 2–3) fixed the pressure a star must build, . Energy balance (Part 4, the virial theorem) explained where the heat comes from: contraction converts gravitational energy into thermal energy, so the core grows hotter as the star radiates. Part 5 now joins them — turning that required pressure into a required temperature. Nothing new about gravity is needed; only the ideal-gas law.