Sparse exact diagonalization and symmetry sectors
Organize finite many-body Hilbert spaces using conserved quantities and test eigenpairs with residuals.
On this page
The question for today
What you’ll understand
- Compute full and fixed-particle-number Hilbert-space dimensions.
- Explain how local Hamiltonian actions enable sparse and matrix-free calculations.
- Separate an eigenpair residual from finite-size and model errors.
Exact diagonalization solves a specified finite Hamiltonian without restricting its states to a variational ansatz. The word exact describes the retained finite problem, not arithmetic precision or the infinite material being modeled. An iterative eigensolver still needs convergence tests, and a perfectly converged small lattice can have substantial boundary effects. The first practical task is therefore to define the physical sector and basis before choosing an algorithm or allocating a dense matrix whose size grows much faster than the lattice itself.
Dimension follows the retained degrees of freedom
A chain of L spin-one-half sites has product states. If total spin projection is conserved, a sector containing up spins has dimension . A spinless-fermion lattice with fixed particle number has the same combinatorial count, although its matrix elements carry fermionic signs. For spinful fermions with independently conserved up and down counts, multiply the two binomial dimensions. Local boson occupation requires either an exact physical bound or an explicitly tested numerical cutoff.
A symmetry block is invariant only when its projector commutes with the Hamiltonian. A transverse field breaks conservation of spin projection along a different axis; restricting to that projection anyway removes genuine dynamics. Translation and reflection can reduce dimensions further when compatible with boundaries and each other. Their sectors are not always obtained by dividing a total dimension by the group size, because some product states have shorter symmetry orbits. The absolute ground state also requires comparing all relevant sectors, rather than assuming its quantum numbers.
Use local actions rather than dense storage
A local lattice Hamiltonian is a sum of operators acting on short neighboring groups. In a product basis, each term connects only a limited set of configurations. One can enumerate those connected states and accumulate their amplitudes without storing every matrix entry. This matrix-free action is sufficient for Krylov methods. Sparse storage saves memory when nonzero entries are few, but the state vector still has one amplitude per basis state, preserving an exponential barrier in generic many-body problems.
Implementation checks should include Hermiticity, conservation of sector labels after every local move, and normalization of recovered eigenvectors. Fermionic operator order matters: exchanging occupied orbitals changes signs even when the allowed destination configuration is correct. For small systems, compare the matrix-free action against an independently assembled dense matrix. This is a useful verification because a wrong sign can leave the matrix Hermitian and all computed vectors normalized while changing the physical spectrum.
Certify the finite eigenproblem, then study size
For a normalized approximate vector v, compute its Rayleigh energy and residual using the original Hamiltonian action. For Hermitian H, the residual norm bounds the distance from that energy to at least one exact eigenvalue. It does not by itself identify that eigenvalue as the ground state. Inferring an eigenvector overlap additionally needs spectral separation; a degenerate manifold permits rotations of its eigenvectors without changing their energies. Report a subspace when individual vectors are not uniquely defined.
After numerical convergence, vary lattice size, boundary conditions, and any local basis cutoff. These probe different errors from an eigensolver tolerance. A finite-system gap may be a physical excitation or merely momentum quantization; its limiting behavior needs a scaling argument. Small exact calculations are especially valuable as benchmarks for approximate methods, provided both use the same Hamiltonian and sector. The two-state lab illustrates normalized amplitudes only and has neither a lattice-size control nor a sparse Hamiltonian constructor.
Work it through
Memory in a conserved spin sector
A four-site spin-one-half chain conserves total z projection. Compare the full basis with the two-up-spin sector. How many bytes would each real dense Hamiltonian require at eight bytes per entry, ignoring overhead?
The full basis contains configurations. Choosing the two up-spin positions gives sector configurations, without introducing any approximation when the Hamiltonian preserves that count.
A dense square matrix has the square of its basis dimension in entries: 256 for the full problem and 36 for this sector. This is a storage comparison, not a claim that every entry is nonzero.
Multiplying by eight gives 2048 bytes and 288 bytes respectively. A real sparse calculation stores only actual connections, while a complex representation would generally double the per-entry storage in this simple accounting.
The exact symmetry restriction reduces the basis from sixteen to six states and dense real-matrix storage from 2048 to 288 bytes.
The living notebook
Explore the model
Interactive lab · quantum
Normalization in a tiny retained space
Reset and set mixing angle , phase : predict probabilities 0.75 and 0.25, summing to one. Repeat from Reset with both controls , : the probabilities become equal and remain normalized. These are pure two-state coefficients, not a spin-chain sector enumerator or exact-diagonalization solver.
- Probability |0⟩
- 71.1%
- Probability |1⟩
- 28.9%
- Bloch (x, y, z)
- 0.78, 0.45, 0.42
A normalized two-level pure state, not an interacting field simulation. Playback adds one radian per second to the relative phase; basis probabilities stay fixed. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.
Look forNormalization is a necessary numerical check, while correct symmetry sectors and matrix elements need separate verification.
Pause & reason
Check your understanding
Your turn
Try it yourself
In the two-spin zero-projection basis up-down, down-up, let with . Find its normalized eigenvectors and energies; check their residuals.
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
Test the symmetric and antisymmetric combinations, keeping their normalization and the off-diagonal sign explicit.
Compare with the solution
The symmetric vector has energy ; the antisymmetric vector has energy . Each has unit norm and substitution gives zero residual. The antisymmetric state is lower for positive J. These are exact results for the stated two-spin block, while other spin-projection sectors complete the triplet degeneracy of the isotropic two-spin Hamiltonian.
Keep the idea
Take it with you
- An invariant symmetry sector reduces dimension without changing its exact finite-system spectrum.
- Sparse or matrix-free actions reduce matrix costs while state-vector dimension can remain exponential.
- Residual convergence, sector identification, and thermodynamic extrapolation answer different questions.
Read further
Original sources and deeper explanations to follow at your own pace.
Optional progress, saved in this browser when available. Revisit any lesson at any time.
Lesson not marked complete.