# How heat spreads

> Watch heat spread across a plate, add warm patches, and compare insulated and cooled edges.

A hot patch gradually spreads through a square plate. The Prelude computes each new temperature from the previous field and its four neighbours. The diffusion coefficient a stays between 0 and 1/4, so each step averages temperatures without inventing new extremes. The white line marks a horizontal cross-section; the orange strip below the plate shows its temperature, from zero at the strip's bottom to one at its top.

Set b to 0 for insulated edges, which conserve total heat E, or 1 for edges coupled to a zero-temperature reservoir. Set o to 1 to insert an insulating wall with a central gap. Drag the brush point and press Add heat to warm a circular patch. Restart restores the original patch. Editing the Prelude lets you change the update rule, seed, and wall geometry.

- [Open the interactive version](https://graph-paper.io/showcase/en/heat-spread)
- [Learn more on Wikipedia](https://en.wikipedia.org/wiki/Heat_equation)
