Skip to main content
All visualizations
Beginner

Particle in a Box

Trap a particle between two walls and it can only have certain energies. Here is why, and what happens when the walls are not infinitely high.

Particle in a Box visualization

Amber is the potential; each grey line is an allowed energy. The violet curve is the selected state, drawn on top of its own level line — teal dots mark its nodes, and the faint rose band is the region a classical particle could never enter.

Start here

A particle confined between two walls is a wave that has to fit. Both ends are pinned at zero, so only whole numbers of half-wavelengths survive; everything else interferes with itself and cancels. That single constraint is the entire origin of quantized energy — there is no extra rule, no postulate about allowed orbits. Fitting is the rule.

Drag Box width and watch the ladder stretch and compress. Then switch the walls to Finite, drop V₀ toward the floor, and watch levels fall off the top of the well one at a time while the survivor spills out through walls it does not have the energy to cross.

n², and the price of confinement

With infinite walls the answer is exact: Eₙ = n²π²ħ²/2mL². Two things in that formula do real work. The n² means the gaps get wider as you climb — the tenth level is not ten times the first, it is a hundred times. And the 1/L² means squeezing costs energy, violently. Halve the box and every level quadruples. The Eₙ/E₁ readout is showing you the n² directly; it stays 4, 9, 16 no matter how you move the width slider.

That 1/L² is not a curiosity either. It is why an electron cannot simply fall into the nucleus: confining it to a nuclear-sized box would cost more kinetic energy than the electrical attraction could ever pay back. Atoms have a size because confinement has a price.

What just happened: the wall leaks

Switch to finite walls and look at the curve just outside the dashed lines. It is not zero. The particle has less energy than the wall is tall, so the region beyond it is classically forbidden — and the wavefunction is there anyway, decaying exponentially rather than stopping. The probability outside the walls readout is the size of that impossibility, and lowering V₀ pushes it from a fraction of a percent to tens of percent.

Two consequences follow immediately. Every level sits lower than the infinite-well answer for the same box, because the particle is effectively in a slightly wider box than the one you drew. And a well only holds a finite number of states: raise n far enough and the level runs off the top of the walls and the particle is free. Count them as you drop V₀ — the last one is remarkably stubborn. In one dimension, a well of any depth at all, however shallow, always keeps at least one bound state.

Where you have already met this

A quantum dot is a box: change its diameter by a couple of nanometres and the level spacing shifts, which shifts the colour of the light it emits. The same cadmium selenide glows red when the dots are big and blue when they are small, with no change of material at all — that is 1/L², visible to the naked eye, and it is how quantum-dot displays make their primaries.

The leaking tail is the other half of the story. Push two of these wells close together and their tails overlap; the shared state that results is a chemical bond. Make the barrier between them thin and the particle crosses it — which is tunnelling, the same exponential tail seen from the other side.