Let's say we have a planet-sized sphere of some uniform material floating isolated in space, not rotating, with the only significant gravity acting on it coming from its own mass. How would the density vary with depth? Would it be linear, quadratic, cubic, or something else?

For example, say the sphere is composed of iron, with a density at the surface of 7874 kg/m$^3$, and a total mass equivalent to the Earth at 5.972 × 10$^{24}$ kg. How dense would it be, say, at the core, or halfway between the core and the surface? If density were constant such a sphere would have a radius of approximately 5657 km, instead of Earth's own 6357-6371, but due to gravity we would expect the outer mass of the sphere to contract and compress the inner material. I want to know how this gravitational compression affects the density.

  • $\begingroup$ If the composition is uniform then the density is also uniform. Iron doesn't get compressed. $\endgroup$ Aug 4, 2021 at 20:35
  • $\begingroup$ @Pete under the extreme pressure created by the gravity of a sphere more than 10,000 km in diameter, iron does compress. The density of Earth's core is estimated at 13,100 kg/m³. Iron and nickel, which make up the majority of Earth's core, only have densities at the surface of 7,874 kg/m³ and 8,900 kg/m³ respectively, so their density must increase inside the Earth's core. $\endgroup$
    – Lawton
    Aug 4, 2021 at 20:42
  • $\begingroup$ I stand corrected. That's a lot of pressure! $\endgroup$ Aug 5, 2021 at 21:46

1 Answer 1


Conceptually, the density increases until a pressure gradient is formed which balances the force of gravity, leading to hydrostatic equilibrium. This depends on how the pressure and density are related. A common approximation is to treat the pressure-density relationship as a polytrope. As a result, the answer to your question depends on which assumptions you make. Treating the Earth as an n=0 polytrope is instructive, but as a result one would simply say the density is basically constant, because rock/iron don't compress very well.

See here for more detailed theoretical treatments:



Solutions to the Lane-Emden equation are usually more complicated than linear/quadratic/cubic.

In practice, the density of the Earth can be directly measured. If you trust the data here: http://hyperphysics.phy-astr.gsu.edu/hbase/Geophys/earthstruct.html then the core has a density of 13, 1/2 out has a density of 10, and the crust has a density of 2.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.