Inside the Earth

How Volcanoes Work 🏆

Chapter 1 · Inside the Earth

Stand on Arthur's Seat in Edinburgh and you are standing on the worn-down remains of a volcano. It last erupted a very long time ago (roughly 340 million years, check), long before there were any people, or even dinosaurs, to be alarmed by it. The city around it is built on lava, ash and the rock that cooled inside the old vent. Volcanoes are not strange exceptions to how a planet behaves: they are the planet letting off heat. So the first chapter does not start with eruptions at all. It starts underground, with three questions: what is the Earth made of, where does its heat come from, and how does solid rock end up as liquid?

What was run
Every Python snippet in this chapter and in the three exercise solutions was executed, and the output shown in the comments is what Python printed. You only need Python 3 and its standard library. The numbers are round, textbook-style values, good for building intuition and not for a geophysics paper. Where a figure is approximate or not checked against a source it is marked (check).

The Layers of the Earth

The Earth is not a uniform ball of rock. It is layered like a peach with a thin skin, a very thick flesh and a stone at the centre, except that this peach has a liquid layer and a solid centre. The layers are known from earthquake waves: waves speed up, slow down, bend and vanish as they cross boundaries between different materials, and that is how we "see" things nobody can drill to. (The deepest borehole ever made goes about 12 km down, which is less than 0.2% of the way to the centre.)

LayerDepth (approx.)StateWhat it is made of
Crust0 to 5-10 km under oceans, 30-50 km under continentssolid rockbasalt (oceans), granite-like rock (continents)
Mantleto about 2890 kmsolid rock that flows very slowlyiron- and magnesium-rich silicate rock (peridotite)
Outer core2890 to about 5150 kmliquid metalmostly iron and nickel
Inner core5150 km to the centre (6371 km)solid metaliron and nickel, held solid by pressure

Notice that the only layer that is liquid is the outer core, and no volcano ever draws from it. Volcanoes are fed from the top of the mantle and the crust, a layer only a few hundred kilometres thick. Here is how big each layer is, using Python to work out its share of the radius and of the volume:

R = 6371 # radius of the Earth in km layers = [("crust", 35), ("mantle", 2890 - 35), ("outer core", 5150 - 2890), ("inner core", 6371 - 5150)] inner = R for name, t in layers: outer = inner inner = outer - t vol = (outer**3 - inner**3) / R**3 * 100 # volume of a shell, as a % of the whole print(f"{name:11s} {t:5d} km {t / R * 100:5.1f}% of radius {vol:5.1f}% of volume") # crust 35 km 0.5% of radius 1.6% of volume # mantle 2855 km 44.8% of radius 82.0% of volume # outer core 2260 km 35.5% of radius 15.6% of volume # inner core 1221 km 19.2% of radius 0.7% of volume

The crust is about half a percent of the radius and under two percent of the volume: proportionally thinner than the skin of an apple. The mantle is by far the biggest piece, over 80% of the planet by volume. (The 35 km crust is a typical continental figure. Ocean crust is thinner, so the true average is lower.) Almost everything volcanic happens in that thin skin and the part of the mantle just beneath it.

Lithosphere and asthenosphere: the mechanical layers

Geologists also split the outer Earth by how it behaves and not what it is made of. The lithosphere is the crust plus the very top of the mantle: cold, stiff and brittle, broken into the tectonic plates. Below it the asthenosphere is hotter mantle that is still solid but soft enough to creep, like very stiff toffee over millions of years. Plates ride on it. This division matters for volcanoes because most magma is made in or just under the lithosphere, and the plates decide where it can get out (Chapter 2 of this course, and Geology & Plate Tectonics Fundamentals 1 for the full plate story).

Where Does the Heat Come From?

A planet 4.5 billion years old should have cooled down. It has not, and the reason is that the Earth has three heat sources:

SourceWhat it isNote
Leftover formation heatenergy from the Earth's violent assembly out of colliding rock, and from iron sinking to form the corethe "primordial" heat, still escaping
Radioactive decayuranium, thorium and potassium-40 atoms in the rocks slowly decay and release heata major continuing source; most of it sits in the crust and mantle (check the exact share)
Core crystallisationas the liquid outer core slowly freezes onto the inner core, it gives out latent heata smaller but steady supply from the centre

The total heat flowing out through the surface is tiny per square metre, only about 0.09 watts (check), less than a thousandth of the heat the Sun delivers to the same patch of ground. You never feel it. But over the whole planet it adds up to roughly 40 trillion watts (check), and that is the engine behind plate tectonics, mantle flow and volcanoes. A volcano is simply a place where a lot of that heat reaches the surface in a hurry.

Temperature and Pressure Going Down

Two things rise as you go deeper: temperature and pressure. Pressure is the easy one: it is just the weight of the rock above, so pressure = density × g × depth. A gigapascal (GPa) is a billion pascals, about ten thousand times atmospheric pressure.

G = 9.81 def pressure_gpa(depth_km, density=3000): return density * G * depth_km * 1000 / 1e9 # kg/m3 * m/s2 * m = pascals; /1e9 = GPa for d in (10, 35, 100, 410): print(d, round(pressure_gpa(d), 2)) # 10 0.29 # 35 1.03 # 100 2.94 # 410 12.07

At the base of a 35 km crust the pressure is about 1 GPa, ten thousand times what we live under at the surface. (Density really increases with depth, so these round figures drift; they are fine for a first picture.)

Temperature is trickier. Near the surface it climbs at roughly 25 °C for every kilometre, the geothermal gradient (it varies a lot from place to place). If that straight line continued unchanged, rock at 100 km would be at about 2500 °C and the centre would be hotter than anything known. It does not continue. Below the stiff lithosphere, heat is carried by rock slowly flowing upward, and the temperature climbs far more gently: roughly 1300 to 1400 °C at the top of the asthenosphere and perhaps 4000 °C or more at the core boundary (check). You will test this in Exercise 3.

Why Does Rock Melt?

Here is the puzzle that surprises most people: the mantle is almost entirely solid, even though it is hotter than the melting point of rock at the surface. The reason is pressure. Squeezing a material makes it harder for its atoms to spread out into the looser arrangement of a liquid, so the melting temperature rises with depth. Rock that would be liquid at 1300 °C on the surface stays solid at 1300 °C a hundred kilometres down.

That leads to the three ways to make magma, and only one of them is "just make it hotter":

Way to meltWhat changesWhere it happens
Decompression meltinghot mantle rises, pressure drops, the melting point drops below the rock's temperaturemid-ocean ridges, rifts, many hotspots (the most common source of magma on Earth)
Flux meltingwater and other volatiles from sinking plates lower the melting pointsubduction zones, such as the Andes and Japan
Heat-transfer meltinghot magma rising into the crust melts the surrounding rockcontinental crust over a magma supply, e.g. the source of some silica-rich magmas

Decompression melting is the heart of this chapter, and a small model shows it. Say dry mantle rock starts to melt (its solidus) at about 1100 °C at the surface and the temperature rises by about 130 °C for every GPa of pressure (rough values, check). Take mantle at 1350 °C that rises without losing much heat. At what depth does it begin to melt?

G = 9.81 def solidus(p_gpa): return 1100 + 130 * p_gpa # melting temperature at pressure p mantle_t = 1350 p = (mantle_t - 1100) / 130 # pressure where solidus = mantle temperature depth = p * 1e9 / (3300 * G) / 1000 # pressure -> depth in km print(round(p, 2), round(depth, 1)) # 1.92 59.4 for d in (100, 80, 60, 40, 20, 0): p = 3300 * G * d * 1000 / 1e9 s = solidus(p) print(d, round(s), "melting" if mantle_t > s else "solid") # 100 1521 solid # 80 1437 solid # 60 1353 solid # 40 1268 melting # 20 1184 melting # 0 1100 melting

Melting starts at roughly 60 km, where the pressure has fallen to about 1.9 GPa. The rock has not been heated: it has only been released. Below 60 km it is solid; above that it begins to melt, and the higher it rises the more it melts. In reality only a few percent of the rock melts, a trace of liquid soaked between solid crystals, like water in a sponge. That liquid is lighter than the rock around it, so it seeps upward and collects.

Hot spots and melt volume
A hotter plume of mantle crosses the solidus deeper, so it has a taller column in which to melt, and it makes more magma. That is one reason hotspot volcanoes such as Hawaii and Iceland are so productive. Exercise 2 puts numbers on it.

Magma or Lava?

The words are not interchangeable, and getting them right is the quickest way to sound like you know what you are talking about:

TermMeaningContains
Magmamolten rock undergroundliquid melt, dissolved gas, and often crystals and bits of solid rock
Lavamolten rock that has reached the surface (and the rock it forms when it cools)most of the dissolved gas has escaped
Tephrafragments of rock blown out of a volcano: ash, lapilli, bombsit is magma that has been torn apart by escaping gas (Chapter 4)

The difference is more than vocabulary. Magma carries dissolved gas, held in the liquid by pressure like the fizz in a sealed drinks bottle. When magma nears the surface and the pressure drops, the gas wants out. How that gas escapes, gently or violently, decides whether you get a calm lava flow or an explosion. That is the subject of Chapter 4, and the reason this course keeps returning to pressure.

Common mistakes
Thinking the mantle is liquid (it is solid rock that flows over millions of years; only the outer core is liquid); thinking volcanoes tap the core (they do not: magma forms in the top of the mantle and the crust); thinking magma needs a higher temperature than the surroundings (decompression melting needs lower pressure, not more heat); and using "lava" for molten rock that is still underground.

Where This Leads

You now have the starting kit: a thin, brittle crust floating on a huge, slowly flowing mantle, a steady heat supply, a melting point that rises with pressure, and three ways of making magma. Arthur's Seat is what is left when one of those magma supplies reached the surface and then went quiet. Chapter 2 asks the obvious next question: why are volcanoes found where they are, in long lines around the Pacific, in the middle of oceans and along the African rift, and not scattered at random? The answer is the plates.

Exercise 1

Write pressure_gpa(depth_km) using a density of 3300 kg/m³ (typical upper mantle rock) and print the pressure at 10, 50, 100, 200 and 400 km. Then rearrange the formula to work out the depth at which the pressure reaches exactly 1 GPa. About how many kilometres of rock add one gigapascal?

📄 View solution
Exercise 2

Using the model from the chapter (solidus = 1100 + 130 × P, in °C with P in GPa; density 3300 kg/m³), write a function that returns the depth where melting starts for a given mantle temperature. Compare ordinary mantle at 1350 °C with a hot plume at 1500 °C. How much deeper does the plume start to melt, and how many times taller is its melt column? Predict the answer before you run it.

📄 View solution
Exercise 3

Take the near-surface geotherm T = 15 + 25 × depth (°C, km). Print the temperature it predicts at the Moho (35 km), find the depth where it would reach 1350 °C, and print what it predicts at 100, 400 and 2890 km. Which of those answers is obviously impossible, and what does that tell you about how heat really moves through the deep Earth?

📄 View solution

Quick Reference

  • Layers: crust, mantle (solid, flowing slowly), outer core (liquid), inner core (solid)
  • Mechanical layers: lithosphere (stiff, plates) over asthenosphere (soft, creeping)
  • Heat sources: leftover formation heat, radioactive decay, core crystallisation
  • Pressure: density × g × depth; about 1 GPa at 30 to 35 km
  • Melting: the melting point rises with pressure, so most magma is made by reducing pressure (decompression), by adding water (flux) or by heating from hot magma
  • Magma is underground; lava has reached the surface; tephra is blown-out fragments
Coming next
How Volcanoes Work 2 shows where volcanoes live: the plate boundaries, hotspots and rifts, and the Ring of Fire around the Pacific.