Hydrostatic Equilibrium

At every layer within a stable star, there is a balance between the inward pull of gravitation and the gas pressure. This is a stable equilibrium, for if gravity were greater than the gas pressure, the star would contract. On the other hand, if the gas pressure were greater, then the star would expand. In a stable configuration, the two must balance. Gas pressure in any layer thus is just equal to the weight (gravitational force) on all the matter above that given layer, in the same manner that the pressure at any depth in a pool of water equals the weight of the water above that depth, hence the term hydrostatic equilibrium. An immediate consequence is that gas pressure must increase inward toward the center of a star.