The simplest quantum system

Particle in a Box

A particle in a box is a quantum model of a particle trapped between two perfectly hard walls, where it can only have certain energies, given by E = n²h²/(8mL²). It is the simplest problem in quantum mechanics that shows quantized energy, zero-point energy and standing matter waves, and it describes real systems such as quantum dots and dye molecules surprisingly well.

A glowing particle trapped between two walls with a wavy glow between them, illustrating a particle in a box and its standing matter wave
A particle fenced in by two walls behaves like a wave that must fit neatly between them.

At a Glance

A particle in a box is a particle confined to a region of width L by walls it cannot pass. Its allowed energies are E_n = n^2 h^2 / (8 m L^2) with n = 1, 2, 3 and so on, so energy rises with n squared and grows when the box gets narrower or the particle lighter.

Also called
Infinite square well
Energy formula
En = n²h²/(8mL²)
Quantum number
n = 1, 2, 3, … (n = 0 is not allowed)
SI unit of energy
joule (J), often quoted in electronvolts (eV)
Depends on
Particle mass m, box width L, level n
Key idea
Confinement forces energy into discrete steps
On this page
  1. What Is a Particle in a Box?
  2. Particle in a Box Explained Simply
  3. Why Is the Energy of a Particle in a Box Quantized?
  4. What Is the Formula for the Energy Levels?
  5. What Do the Wave Functions Look Like?
  6. Why Can't the Particle Have Zero Energy?
  7. How Do Box Size and Mass Change the Energy?
  8. How Does a Particle in a Box Absorb or Emit Light?
  9. Where Is the Particle in a Box Used in Real Life?
  10. Going Deeper: Boxes in Two and Three Dimensions
  11. Practice Particle in a Box Problems
  12. Common Misconceptions
  13. Key Facts
  14. Quiz
  15. FAQ

What Is a Particle in a Box?

The particle in a box is a thought experiment that strips quantum mechanics down to its bare bones. Imagine a single particle, such as an electron, that can move freely along a straight line but is fenced in by two walls a distance L apart. Inside, nothing pushes or pulls on it. At the walls, the potential energy jumps to infinity, so the particle can never get out.

Physicists also call this setup the infinite square well, because a graph of the potential energy looks like a flat-bottomed well with endlessly tall sides. In classical physics the answer would be boring: a ball bouncing between two walls can have any speed and any energy you like. Quantum mechanics says something very different.

Once the particle is treated as a wave, only certain wave patterns fit between the walls. Each pattern has its own energy, so the energy can take only a ladder of separate values. That single result, called energy quantization, is the heart of the model.

Particle in a Box Explained Simply

Think of a jump rope held tight by two friends. If you shake it, you can make one big hump, or two humps, or three, but never one and a half. The ends are pinned, so only whole numbers of half-waves fit.

A trapped electron behaves the same way. Its wave must fade to zero at both walls, so only a few wave shapes are allowed. More humps mean a shorter wavelength, and in quantum physics a shorter wavelength means more energy. That is why the electron cannot sit at just any energy. It has to stand on one rung of an energy ladder.

There is one more surprise. The electron can never be completely still. Even on the lowest rung it carries some energy, because a wave squeezed into a small space must wiggle at least a little.

Why Is the Energy of a Particle in a Box Quantized?

The particle's state is described by a wave function, written ψ(x). Because the particle can never be found inside or beyond the walls, ψ must equal zero at x = 0 and at x = L. Between the walls, solving the Schrödinger equation with zero potential energy gives simple sine waves.

A sine wave that is zero at both ends has to fit a whole number of half-wavelengths into the box. That gives the condition L=nλ/2, so the allowed wavelengths are λn=2L/n. Each wavelength corresponds to a momentum through the de Broglie relation p=h/λ, and each momentum gives a kinetic energy p2/2m.

Put those three steps together and the energy comes out in steps labeled by the whole number n. Nothing forces the steps in by hand. They appear automatically once the wave is required to vanish at the walls.

Ground-state wave of a particle in a 1 nm box: one half-wavelength, zero at both walls and largest in the middle
The ground state fits exactly one half-wavelength between the walls, so its wavelength is twice the box width.

What Is the Formula for the Energy Levels?

The allowed energies of a particle of mass m in a one-dimensional box of width L are En=n2h28mL2, where h is the Planck constant and n = 1, 2, 3 and so on. Using the reduced Planck constant ħ = h/2π, the same result reads En=n2π2ℏ2/(2mL2).

Three patterns stand out. Energy grows with n², so the second level is four times the first and the third is nine times the first. Energy falls with L², so halving the box width makes every level four times higher. And energy falls with mass, so a heavy particle has levels packed so closely that they blur into a smooth range.

For a full collection of related equations, from photon energy to the Bohr levels, see our modern physics formulas sheet.

Here is the energy formula with each symbol and its SI unit, plus the rearranged forms for box width and quantum number. Energies are usually converted to electronvolts, where 1 eV = 1.602 176 634 × 10⁻¹⁹ J.

En=n2h28mL2=n2π2ℏ22mL2
What each symbol means
SymbolQuantitySI unit
Enenergy of level njoule (J)
nquantum number (1, 2, 3, ...)dimensionless (1)
hPlanck constant (6.626 × 10⁻³⁴ J·s (exact: 6.62607015 × 10⁻³⁴))joule second (J·s)
mmass of the particlekilogram (kg)
Lwidth of the boxmeter (m)

Rearranged to find another variable:

L=nh8mEnn=L8mEnh

Valid for: infinite square well (1D).

Example 1 Ground state of an electron in a 2 nm box

An electron (m = 9.109 383 7139 × 10⁻³¹ kg) is trapped in a one-dimensional box 2.0 nm wide. Using h = 6.626 070 15 × 10⁻³⁴ J·s, what is its lowest allowed energy in electronvolts?

  1. Given:
    • quantum number (1, 2, 3, ...): n=1
    • Planck constant: h=6.626×10−34 J·s
    • mass of the particle: m=9.109×10−31 kg
    • width of the box: L=2×10−9 m
  2. Formula: En=n2h28mL2=n2π2ℏ22mL2
  3. Substitute: n=1,h=6.626×10−34 J·s,m=9.109×10−31 kg,L=2×10−9 m
  4. Answer: En=0.09401 eV

This is a quarter of the value for a 1 nm box, because the energy scales with 1/L².

What Do the Wave Functions Look Like?

Inside the box, the normalized wave functions are ψn(x)=2/Lsin⁡(nπx/L). The ground state, n = 1, is a single smooth hump that peaks in the middle. The n = 2 state has two humps of opposite sign with a node at the center, and every step up in n adds one more node.

What you can measure is not ψ itself but its square, |ψ|², which gives the probability of finding the particle at each point. For n = 1 the particle is most likely near the middle and least likely near the walls. For n = 2 it is never found at the exact center, even though it spends time on both sides. A classical ball would show no such pattern; it would be equally likely to be anywhere.

The diagram below draws the n = 3 state. Its three half-waves give two interior nodes, the places where the particle has zero chance of being detected.

The n = 3 wave function in a 1 nm box with three half-waves, two inside nodes and largest values at three antinodes
The n = 3 state has three half-waves and two interior nodes; its energy is nine times the ground-state energy.

Why Can't the Particle Have Zero Energy?

Setting n = 0 would make ψ zero everywhere, which means no particle at all, so the lowest allowed level is n = 1. Its energy, E1=h2/(8mL2), is called the zero-point energy. A confined quantum particle always keeps at least this much, even at absolute zero temperature.

The uncertainty principle gives the same message from another angle. Trapping the particle in a width L pins down its position, so its momentum cannot be exactly zero. A spread in momentum means some kinetic energy, and the tighter the box, the larger that leftover energy has to be.

How Do Box Size and Mass Change the Energy?

Because E depends on 1/(mL²), the model explains why quantum effects matter for electrons in atoms but vanish for everyday objects. An electron in a box 1 nm wide has a ground-state energy of about a third of an electronvolt, comparable to chemical energies. The table below lists its first five levels, all computed from the formula.

Now try a 50 g marble rolling in a 10 cm groove. Plugging in those numbers gives a ground-state energy of roughly 10⁻⁶⁴ J, so tiny that the gaps between levels can never be noticed. The marble seems to have a continuous range of energies, which is exactly what classical physics assumes. Our classical vs quantum physics comparison explores where that boundary lies.

Example 3 How wide must the box be?

You want an electron's ground-state energy in a box to be exactly 1.0 eV, which is 1.602 176 634 × 10⁻¹⁹ J. With n = 1, h = 6.626 070 15 × 10⁻³⁴ J·s and m = 9.109 383 7139 × 10⁻³¹ kg, how wide must the box be, in nanometers?

  1. Given:
    • quantum number (1, 2, 3, ...): n=1
    • Planck constant: h=6.626×10−34 J·s
    • mass of the particle: m=9.109×10−31 kg
    • energy of level n: En=1.602×10−19 J
  2. Formula: L=nh8mEn
  3. Substitute: n=1,h=6.626×10−34 J·s,m=9.109×10−31 kg,En=1.602×10−19 J
  4. Answer: L=0.6132 nm

A box only a few atoms wide is enough to give an electron a ground-state energy of about one electronvolt.

First five energy levels of an electron in a 1 nm box
Level nEnergy (eV)Compared with n = 1Nodes inside the box
10.37601×0
21.5044×1
33.3849×2
46.01616×3
59.40125×4
Source: Computed with E = n²h²/(8mL²) using h and the electron mass from NIST CODATA 2022 · Retrieved October 2026

How Does a Particle in a Box Absorb or Emit Light?

A particle can jump from one level to another by absorbing or giving off a photon whose energy matches the gap exactly. Going from level ni down to nf releases ΔE=(ni2−nf2)h2/(8mL2), and the photon's wavelength follows from λ=hc/ΔE. You can turn any such gap into a wavelength or frequency with our photon energy calculator.

The gaps widen as n grows, because n² climbs faster than n. This is the opposite of the hydrogen atom, where the energy levels crowd together near the top. Comparing the two shows how the shape of the trap controls the spacing of the rungs.

Example 2 Light from a jump between levels

An electron in a 1.2 nm box drops from the n = 2 level to the n = 1 level and emits one photon. Using h = 6.626 070 15 × 10⁻³⁴ J·s, c = 299 792 458 m/s and the electron mass 9.109 383 7139 × 10⁻³¹ kg, what is the photon's wavelength in nanometers?

  1. Given:
    • Planck constant: h=6.626×10−34 J·s
    • speed of light in vacuum: c=299,792,458 m/s
    • m: m=9.109×10−31 kg
    • L: L=1.2×10−9 m
    • n_i: ni=2
    • n_f: nf=1
  2. Formula: λ=hcEni−Enf=8mL2ch(ni2−nf2)
  3. Substitute: h=6.626×10−34 J·s,c=299,792,458 m/s,m=9.109×10−31 kg,L=1.2×10−9 m,ni=2,nf=1
  4. Answer: λ=1,583 nm

This photon lands in the near infrared; a narrower box would push the light toward the visible band.

Where Is the Particle in a Box Used in Real Life?

Real traps never have infinitely hard walls, yet the simple model still gives useful estimates:

  • Quantum dots. These semiconductor crystals, only a few nanometers across, glow in colors set by their size. Smaller dots have wider level gaps and emit bluer light, just as 1/L² predicts.
  • Dye molecules. In long chain molecules with alternating single and double bonds, some electrons roam along the chain almost freely. Treating the chain as a box predicts roughly which colors the dye absorbs.
  • Nanowires and thin films. When one dimension of a material shrinks to a few nanometers, electrons are confined in that direction and the material's electrical and optical behavior shifts.
  • Nuclei. A proton confined to a region about the size of a nucleus has level spacings in the millions of electronvolts, which hints at why nuclear energies dwarf chemical ones.

When a wall is finite rather than infinite, the wave leaks a short distance into it, and a thin enough barrier lets the particle escape. That leak is the starting point for quantum tunneling.

Row of glass vials glowing blue to red under ultraviolet light, like quantum dots whose color depends on their size
Quantum dots of different sizes glow in different colors, a real-life echo of the particle in a box.

Going Deeper: Boxes in Two and Three Dimensions

A particle in a rectangular three-dimensional box has one quantum number for each direction, and its energy is the sum of three one-dimensional terms: E=h28m(nx2Lx2+ny2Ly2+nz2Lz2). In a cube, different combinations such as (2, 1, 1), (1, 2, 1) and (1, 1, 2) share the same energy. Physicists call such matching levels degenerate.

The same counting of states inside a box is used to model electrons in a metal and photons in a hot oven. Related models, such as the quantum harmonic oscillator, replace the hard walls with a smooth spring-like potential and produce evenly spaced levels instead.

Practice Particle in a Box Problems

Work through a few level and wavelength calculations on your own, then check the photon side of each jump with the photon energy calculator. Our atomic structure worksheets add printable practice on energy levels and quantum numbers, and the Erwin Schrödinger profile tells the story behind the wave equation this model solves.

Common Misconceptions

Myth: A particle in its lowest state is sitting still at the bottom of the box.

Physics: The ground state has a nonzero zero-point energy. The particle cannot have zero momentum while it is confined to a finite width.

Myth: The energy levels are evenly spaced, like rungs on a normal ladder.

Physics: The levels grow as n², so the gaps get wider as you go up: the jump from 2 to 3 is bigger than the jump from 1 to 2.

Myth: The particle is most likely to be found near the walls, where it turns around.

Physics: In the ground state the probability is highest at the center and drops to zero at the walls, the opposite of a slow classical ball near its turning points.

Myth: The model only applies to imaginary boxes and has no real use.

Physics: It gives good first estimates for quantum dots, conjugated dye molecules and thin semiconductor layers, and it is the starting point for more realistic wells.

Key Facts

  • A particle in a box is a particle trapped between two infinitely high walls, also called an infinite square well.
  • Its allowed energies are E = n²h²/(8mL²), where n is a whole number starting at 1.
  • Energy rises with the square of n, so the third level has nine times the energy of the first.
  • A narrower box or a lighter particle gives larger energies and wider gaps between levels.
  • The lowest energy is never zero; this leftover zero-point energy comes from confinement.
  • The wave functions are sine waves that fit a whole number of half-wavelengths between the walls.
  • Quantum dots and dye molecules behave roughly like particles in a box, which is why their colors depend on size.
Did you know? Two vials of quantum dots made from the very same material can glow green and red side by side, purely because the red-glowing crystals are a little larger and their electron energy levels sit closer together.

Quick Quiz: How Well Do You Know Particle in a Box?

6 questions. Tap an answer to check it.

  1. How does the energy of level n = 3 compare with the ground state?

  2. What happens to the ground-state energy if the box width is halved?

  3. Why is the lowest allowed quantum number n = 1 and not n = 0?

  4. In the n = 2 state, where is the particle never found?

  5. Which change makes the energy levels of a particle in a box closer together?

  6. Why do smaller quantum dots glow bluer?

Frequently Asked Questions

What is a particle in a box in simple terms?

It is a particle, usually an electron, that can move freely along a line but is trapped between two walls it can never cross. Quantum mechanics treats it as a wave that must vanish at the walls. Only certain wave shapes fit, so the particle can only have certain energies. It is the simplest example of how confinement creates quantized energy.

What is the formula for a particle in a box?

The allowed energies are E_n = n^2 h^2 / (8 m L^2), where n is 1, 2, 3 and so on, h is the Planck constant, m is the particle's mass and L is the width of the box. The wave functions are psi_n(x) = sqrt(2/L) sin(n pi x / L). Energies are usually converted from joules to electronvolts for small particles like electrons.

Why can't n be zero for a particle in a box?

With n = 0 the sine function would be zero everywhere inside the box, which means the probability of finding the particle anywhere is zero. That describes no particle at all, so it is not a valid state. The smallest allowed value is n = 1, and that is why the ground state always carries a nonzero zero-point energy.

What happens to the energy levels if the box gets bigger?

Every level drops, because the energy depends on 1 over L squared. Doubling the width cuts each energy to one quarter and squeezes the levels closer together. For a very wide box the gaps become so small that the energy looks continuous, which is how quantum results smoothly turn into classical behavior for large systems.

Is the particle in a box a real system?

No real wall is infinitely high, so the model is an idealization. Still, it describes several real systems well enough to be useful, including electrons in quantum dots, electrons moving along long conjugated molecules, and carriers in very thin semiconductor layers. Engineers and chemists use it for quick estimates before turning to more detailed calculations.

What is the probability of finding the particle in the middle of the box?

It depends on the level. In the ground state the probability density peaks at the center, so the middle is the most likely place. In the n = 2 state there is a node at the center, so the chance of finding the particle exactly there is zero. Odd values of n have a peak in the middle and even values have a node.

How is a particle in a box different from a classical ball in a box?

A classical ball can have any energy, including zero, and is equally likely to be found anywhere along its path. A quantum particle can only take discrete energies, never zero, and its probability of being found varies from place to place, with nodes where it is never detected. The differences fade as the mass or box size grows.

What is the difference between an infinite and a finite square well?

In an infinite square well the walls are impossibly high, so the wave function is exactly zero outside. In a finite well the walls have a limited height, so the wave function leaks a little way into them and the energies come out slightly lower. A finite well also has only a limited number of trapped levels, and a particle can tunnel through a thin wall.

Sources

Constants come from NIST CODATA 2022 (public domain) and unit definitions from the BIPM SI Brochure (CC BY 4.0). Text, diagrams and illustrations are original work by Physics Tribune.

Physics Tribune Editorial Team
Written by our editors and checked against NIST and BIPM reference data. Every worked example is recomputed in code. Read our editorial policy. Last updated October 2026.