Particle in a Box

Set the width of the box and the level you want to look at. Add π electrons to turn the box into a dye molecule: they fill the levels two at a time, and the page finds the light the molecule should absorb.

Loading interactive simulation...

Lesson

The theory — Particle in a Box

A particle in a box moves freely between two walls a distance L apart and cannot get past them, so its wavefunction must be zero at both. Only whole numbers of half-wavelengths fit, L = nλ/2, and since λ = h/p each fit has one energy: Eₙ = n²h²/(8mL²), with n = 1, 2, 3, … The wavefunctions are ψₙ = √(2/L) sin(nπx/L), and |ψₙ|² dx is the probability of finding the particle between x and x + dx.

What each symbol means

L
the width of the box
n
the level, a whole number from 1 up; level n has n − 1 nodes
Eₙ
the energy of level n, n² times E₁
ψₙ
the wavefunction of level n
|ψₙ|²
the probability density; its integral over the box is 1
m
the mass of the particle, here an electron's, 9.109×10⁻³¹ kg
N
the number of π electrons in a dye, two to each level from the bottom up
Assumes
Walls infinitely high and infinitely thin, so the wave is exactly zero at x = 0 and x = L. One dimension. For the dyes, π electrons that do not repel one another, two to a level, in a box that runs half a bond length past each end carbon: L = Nℓ, with ℓ = 0.1397 nm, the carbon–carbon distance in benzene.
Breaks when
Real walls have a finite height and the wave leaks a little way into them, so the levels sit lower than this page says, and a thin enough wall lets the particle through: that is quantum tunnelling. In a molecule the π electrons repel one another and are held by the atoms' positive cores, so the floor dips at every atom. Where single and double bonds alternate, as in a polyene, that corrugation leaves a gap the flat box does not have, and the box's colours come out far too red for long chains.

The lowest energy in the box is not zero 🖖

Press 1 nm box, ground state. The lowest level is at 0.3760 eV, not at zero, and there is nothing below it. The wave has to vanish at both walls, so the longest it can be is twice the box, and a standing wave that long is two waves running opposite ways, each with momentum h/2L, so it still has an energy h²/8mL². A ψ with no wiggle at all would be zero everywhere, which is a box with no electron in it. So the electron keeps 0.3760 eV however cold it gets. That is 14.89 times kT at 20 °C, and level 2 is another 1.128 eV up, so the jostling of a room-temperature world almost never lifts it there. Press Half the box: the floor rises to 1.504 eV, four times as high, because E₁ goes as 1/L².

In its lowest level the electron is in the middle third 60.9% of the time 🖖

A ball bouncing between the walls at a steady speed spends equal time everywhere, so it is in the middle third of the box a third of the time. The electron in level 1 is there 60.9% of the time: |ψ₁|² is a single hump, highest at the centre and zero at the walls, where the ball spends as long as anywhere else. Press Level 2 and the picture turns over. The centre is now a node, where |ψ|² is zero, and the middle third holds only 19.6%. The ladder below shows the swings settling: 33.3% at n = 3, 40.2% at n = 4, 27.8% at n = 5, 33.3% again at n = 6. Whenever 3 divides n the answer is exactly a third, and otherwise it misses by √3/(2nπ), so set n to 10 and it is 36.1%. High up the ladder the quantum answer becomes the classical one, as Niels Bohr's correspondence principle requires.

The box nearly places butadiene's absorption and misses a carrot's by a factor of three 🖖

In the late 1940s Hans Kuhn treated the π electrons of a conjugated chain as free electrons in a box as long as the chain. Press Butadiene: four π electrons fill levels 1 and 2, the lowest absorption lifts one of them to level 3, and with L = 4 × 0.1397 nm the box says 205.9 nm. Butadiene absorbs at 217 nm. Now press β-Carotene, with 22: the box says 1,354 nm, in the infrared, and the carrot pigment absorbs at 455 nm, blue light, which is why it looks orange. The table shows how the gap opens. From butadiene on, the box adds between 125 and 129 nm for every CH=CH it is given; hexatriene and octatetraene add 41 nm and then 32, and the seven further double bonds of β-carotene average 24 each. Cyanine dyes, whose charge is shared between nitrogen atoms at the two ends of the chain, do take steady steps, about 100 nm per CH=CH, as the box's are steady. The difference is the bonds. A short, symmetric cyanine can be drawn two equally good ways, with the single and double bonds swapped, and its C–C bonds come out nearly the same length all along the chain. A polyene's single and double bonds alternate, the electrons move over a floor that rises and falls every two bonds, and that leaves a gap a longer box does not close.

Problem solved in full

  1. How the middle third settles on a third 5 steps

    How likely is the electron to be in the middle third of the box in level n, for any n? The page prints it one level at a time. Find it for every n at once, and say how fast it approaches the classical third. Press 1 nm box, ground state for the first case.

    Open this problem in the tool

    1. In the ground state the page prints:

    2. The density is (2/L) sin²(nπx/L). Writing sin² as ½(1 − cos), the integral over the middle third is a third minus a sine term:

    3. For n = 1 the bracket is sin(4π/3) − sin(2π/3) = −√3, so P is a third plus √3/(2π):

    4. For n = 2 it is +√3, and P is a third minus √3/(4π), the 19.6% of the second preset:

    5. Both sines vanish whenever 3 divides n. Otherwise the bracket is −√3 or +√3, as n leaves 1 or 2 on division by 3:

    Answer

    P = 1/3 + √3/(2nπ) when n leaves remainder 1 on division by 3, 1/3 − √3/(2nπ) when it leaves 2, and exactly 1/3 when 3 divides n. The quantum answer swings either side of the classical third by a margin that shrinks as 1/n: 27.6 percentage points at n = 1, 2.76 at n = 10, 0.0276 at n = 1,000. The ripples in |ψ|² are still there at high n, but they are so close together that any stretch of the box you can name holds very nearly its classical share. That is the correspondence principle, worked out for one box.

Learning path

Quantum mechanics: matter as waves

References (3)