Starlight Tools

Physics · Quantum · Private, in-browser

Schrodinger Equation Solver (1D Particle in a Box)

Compute infinite square-well energies, normalized wavefunctions, and visualize |psi(x)|^2. Adjust length, mass, and quantum number to see how the ladder changes.

Setup

1

Selected state (n = 1)

Energy E_n (J)
E_n = n^2 h^2 / (8 m L^2)
Energy E_n (eV)
Uses 1 eV = 1.602e-19 J
Wavelength lambda_n
lambda_n = 2L / n (one spatial period)
Nodes
Nodes = n − 1 (excluding walls)
Energy vs ground (n=1)

Energy ladder

Wavefunction & probability density

psi_n(x) = sqrt(2/L) sin(n pi x/L). The probability curve is rescaled so |psi|^2 peaks at 1.

How this solver works

This Schrodinger equation solver is a simple, visual way to explore the famous particle-in-a-box problem from quantum mechanics. It calculates the allowed energy levels and wavefunctions for a particle trapped in an infinite square well, then plots the wavefunction and the probability density so you can see what the math means. Think of it as a guided look at how quantum confinement creates discrete, ladder-like energy states instead of a smooth, continuous spectrum.

The model assumes perfectly rigid walls at x=0 and x=L. Inside the box, the Schrodinger equation becomes a standing-wave problem, so only specific sine-wave patterns are allowed. Each pattern is labeled by the quantum number n. As n increases, the wavefunction gains more nodes and the energy grows with n squared. The calculator uses the standard formulas for a 1D infinite square well to show the energy E_n in joules and electron volts, the wavelength for that mode, and the normalized wavefunction psi_n(x) along with |psi_n(x)|^2.

To use the calculator, start by entering the box length L and the particle mass. You can choose a common particle or enter a custom value, then pick the quantum number n you want to examine. Press Calculate to update the energy readout, the energy ladder, and the plots. The ladder compares relative energy levels up to the number you select, while the graph shows the wavefunction shape and the probability density, which indicates where the particle is most likely to be found.

This tool is useful for building intuition about quantum wells and related systems. The same ideas appear in semiconductor quantum dots, nanowires, and thin films where electrons are confined to tiny regions. Students often use the particle-in-a-box model to understand why smaller systems have higher energy gaps, why heavier particles have lower energies, and how standing waves translate into measurable probabilities. Since everything runs in your browser, it is a quick, private way to explore the Schrodinger equation without setup or downloads.

Quick quantum facts

No degeneracy here

In a 1D box, each n is unique. Higher n simply adds nodes and raises energy by n^2.

n^2 scaling

Shorter box = hotter states

Cut L in half and the whole ladder jumps up by 4x. Confinement is expensive.

E ∝ 1/L^2

Probability piles at antinodes

|psi|^2 is largest where the sine peaks. For odd n, the center is a maximum; for even n, it is a node.

Standing waves

Real boxes leak

Finite wells allow tunneling and change the energies. This ideal model is the clean textbook limit.

Idealization

Use it for intuition

The same math powers quantum dots, nanowires, and the particle-in-a-ring/2D well variants.

Nanotech link

Explore more tools