Diffusion Front
z = erf(x/(2 · sqrt(0.05 + y + 6)))
Open in the app The dials and keys named below are the app's.
What it draws
Not a surface in space, but a history. The x axis is position, and y stands for time, running from 0.05 at the near edge to 12.05 at the far one. Each line across the sheet is the whole line of material at one instant, so the sheet holds every instant at once.
Time cannot run backwards, and the formula says so: below y = −6.05 the square root has nothing to work on and the mesh simply stops. At the span this opens with, the sheet is whole.
The shape is erf, and it starts as a step: cold on the left, hot on the right, meeting at the origin. Heat then leaks across. At the earliest time the change happens within half a unit of the origin. By the latest it is spread over about seven, and the sharp edge has become a long ramp.
The square root of time
The width comes from the denominator, 2√t. That is the whole content of the picture: a diffusing front spreads as the square root of elapsed time, not in proportion to it. Four times as long gives only twice the reach, which is why the sheet's edge is a parabola rather than a wedge.
The reason is that diffusion has no speed of its own. Each particle wanders, and a random walk of n steps ends about √n steps from where it began, so the crowd spreads as the root of the count. It also means the process never quite finishes: at the latest time here the ends have reached ±0.78, still short of the ±1 they are heading for.
History
Adolf Fick wrote the law down in 1855, taking it directly from Fourier's equation for heat of 1822 and arguing that a dissolved substance must obey the same rule. The erf solution is what that law gives for a step, and it describes a metal bar quenched at one end as readily as ink meeting water.
Try
- Press Side. Looking along the time axis, the front is a single curve and the spreading reads as the sheet fanning out.
- Slow the diffusion with erf(x/(0.5 · sqrt(0.05 + y + 6))). A smaller coefficient keeps the front sharp for far longer.
- Take the shape of the gradient instead, exp(−x² /(4(0.05 + y + 6))). A bell that widens as time runs, though it holds its height: the true heat kernel also carries a 1/√(πt) in front, which this drops.
- Replace y + 6 with y + 6.5 to start a little later. The sharpest early edge is gone, and the near rows already show a spread front.