Discretization
Discretization replaces an infinite-dimensional continuum problem by a finite problem that a computer can store and solve. A wavefunction becomes a vector of samples or basis coefficients; a differential operator becomes a matrix; an integral becomes a weighted sum.
The act of discretizing is not a harmless implementation detail. It chooses a finite domain, a resolution, a basis, an inner product, boundary conditions, and a notion of convergence. Those choices can change spectra, symmetries, conservation laws, and numerical stability.
Why Quantum Mechanics Needs It
Section titled “Why Quantum Mechanics Needs It”Most analytically interesting quantum systems live in infinite-dimensional Hilbert spaces. A numerical calculation must make them finite:
- a wavefunction on is sampled on a finite grid;
- inner products are replaced by weighted sums;
- differential operators become finite matrices;
- continuous spectra are approximated in a finite box;
- a basis expansion is truncated at finite ;
- time evolution is computed on a finite state vector by a chosen time-stepping method;
- a many-body Hilbert space is cut down by symmetries, occupation limits, or basis choices.
Every numerical result therefore has at least two layers of error: error from the finite model and error from solving that finite model.
What Discretization Chooses
Section titled “What Discretization Chooses”Before solving, specify:
- the physical domain or box;
- the grid, mesh, or basis;
- the boundary conditions;
- the inner product and quadrature weights;
- the finite operator matrices;
- the units and scaling;
- the refinement parameter, such as grid spacing or basis size .
Without these choices, a reported numerical wavefunction or spectrum is not reproducible.
Grid Representation
Section titled “Grid Representation”For a one-dimensional coordinate interval, choose grid points
A wavefunction is represented by values
The continuum norm
becomes a weighted sum
For a uniform grid with a simple rectangle rule, for interior points. More accurate Numerical Quadrature rules use different weights. The weights are part of the discrete Hilbert-space structure, not decoration.
Operators Become Matrices
Section titled “Operators Become Matrices”On a grid, multiplication by a potential is usually represented by a diagonal matrix:
Derivative operators require an approximation. Finite Difference Methods owns the derivative-stencil details. For the one-dimensional Hamiltonian
a basic centered approximation gives
This formula is a discretized operator, not the original operator. Its eigenvalues should approach the continuum eigenvalues only in an appropriate refinement limit and only for states resolved by the grid and domain.
Boundary Conditions Are Part of the Operator
Section titled “Boundary Conditions Are Part of the Operator”The same differential expression can define different operators depending on boundary conditions. On a finite interval, examples include:
- Dirichlet: at the boundary;
- Neumann: normal derivative vanishes at the boundary;
- periodic: values and derivatives match across the endpoints;
- absorbing or outgoing approximations for scattering problems.
Changing the boundary condition changes the discrete matrix and may change the spectrum. A finite box with Dirichlet boundaries is not the same physical problem as a particle on the line, although it may approximate localized bound states if the box is large enough.
The continuum background is Boundary Conditions.
Basis Truncation
Section titled “Basis Truncation”Instead of sampling in position space, one may choose basis functions and approximate
If the basis is orthonormal, the coefficients are the coordinates of the truncated state. The Hamiltonian matrix is
Solving the finite matrix eigenproblem gives approximate energies and coefficients. This is the Rayleigh-Ritz idea behind many variational and Spectral Methods calculations.
If the basis is not orthonormal, the overlap matrix
appears, and the eigenvalue problem becomes
Near-linear dependence in the basis can make ill conditioned; see Conditioning and Stability.
Projection Versus Collocation
Section titled “Projection Versus Collocation”Two common philosophies are:
| Method | Basic idea |
|---|---|
| projection or Galerkin | require the residual to be orthogonal to a finite test space |
| collocation | require the equation to hold at selected points |
Basis truncation is often projection-based. Grid methods often look like collocation, although finite-volume and finite-element methods add additional structures.
The distinction matters because it affects conservation laws, Hermiticity, variational bounds, and convergence. A method that gives a Hermitian matrix in the correct discrete inner product is usually easier to validate for closed-system quantum mechanics.
Resolution and Momentum Cutoffs
Section titled “Resolution and Momentum Cutoffs”A grid cannot represent arbitrarily short wavelengths. On a uniform grid, the largest resolvable wavenumber is of order
Features with wavelengths comparable to or smaller than the grid spacing are under-resolved and may alias into incorrect low-frequency behavior.
For quantum mechanics, this means that the grid spacing must resolve the shortest de Broglie wavelength relevant to the state, the potential, and the observable being measured. Low-energy bound states may converge while high-energy states on the same grid do not.
Finite Boxes and Continuum Spectra
Section titled “Finite Boxes and Continuum Spectra”A finite numerical domain usually turns a continuum spectrum into a discrete set of levels. This is useful but must be interpreted carefully.
For a localized bound state, increasing the box size should leave the low-lying energy nearly unchanged once the wavefunction is negligible at the boundary. For a scattering state, box levels depend strongly on boundary conditions and box size; extracting physical phase shifts requires additional analysis.
Thus a finite-box spectrum is not automatically the spectrum of the original infinite-domain problem.
Error Sources
Section titled “Error Sources”A discretized calculation can contain several distinct errors:
- domain truncation error from replacing an infinite domain by a finite one;
- grid or basis truncation error from finite resolution or finite ;
- quadrature error in inner products and matrix elements;
- operator approximation error from replacing derivatives by finite formulas;
- algebraic solver error from diagonalization or linear solves;
- roundoff error from finite-precision arithmetic.
These errors may move in opposite directions. For example, a finer grid can reduce discretization error while increasing roundoff amplification in derivative formulas.
Convergence Tests explains how to vary grid spacing, domain size, basis size, and time step systematically. Error Estimates explains how to turn refinement behavior, residuals, and statistical uncertainty into an honest numerical error budget.
Convergence Checks
Section titled “Convergence Checks”A numerical result should be tested under refinement. Typical checks include:
- decrease grid spacing while holding the physical domain fixed;
- increase the domain size while holding resolution fixed;
- increase basis size ;
- compare different boundary placements;
- verify normalization with the discrete inner product;
- check matrix Hermiticity in the weighted inner product;
- compare with an exactly solvable case.
When two refinements change the answer in different ways, vary them separately. A single calculation at one grid size cannot reveal its own discretization error.
Discrete Inner Products and Hermiticity
Section titled “Discrete Inner Products and Hermiticity”The discrete inner product should approximate the continuum one:
An operator matrix that looks symmetric under the ordinary Euclidean dot product may not be Hermitian under this weighted inner product if the weights are nonuniform. Conversely, a carefully constructed discretization may preserve Hermiticity in the correct weighted sense.
This matters because Hermiticity controls real eigenvalues, orthogonality, and unitary time evolution.
Practical Checklist
Section titled “Practical Checklist”Before trusting a discretized quantum calculation, record:
- the domain and boundary conditions;
- the grid or basis definition;
- the inner-product weights;
- the operator approximation;
- the units and scaling;
- the refinement parameter;
- the residual or convergence test used;
- any symmetry or conservation law checked.
Discretization should be treated as part of the mathematical model. The finite problem is what the computer actually solves.
Common Mistakes
Section titled “Common Mistakes”- Normalizing grid wavefunctions with when the quadrature weights are needed.
- Forgetting that a finite box changes a continuum spectrum.
- Comparing high-energy states before checking that the grid resolves their wavelength.
- Treating a finite matrix Hamiltonian as automatically Hermitian in the correct inner product.
- Refining grid spacing without also checking box-size effects.
- Interpreting spurious boundary-localized states as physical states.
- Reporting eigenvalues without saying how the continuum problem was discretized.
- Mistaking agreement at one grid size for convergence.
Cross-Links
Section titled “Cross-Links”- Floating-Point Arithmetic
- Conditioning and Stability
- Finite Difference Methods
- Spectral Methods
- Numerical Quadrature
- Error Estimates
- Convergence Tests
- Matrix Diagonalization
- Sparse Matrices
- Time-Stepping Methods
- PDE Solvers
- Bases and Coordinates
- L2 Spaces
- Boundary Conditions
- Eigenvalue Problems
- Position and Momentum Representations
- Time-Independent Schrödinger Equation
References
Section titled “References”- J. M. Thijssen, Computational Physics, 2nd ed., Cambridge University Press, 2007.
- T. Pang, An Introduction to Computational Physics, 2nd ed., Cambridge University Press, 2006.
- R. J. LeVeque, Finite Difference Methods for Ordinary and Partial Differential Equations, SIAM, 2007.
- L. N. Trefethen, Spectral Methods in MATLAB, SIAM, 2000.
- S. C. Brenner and L. R. Scott, The Mathematical Theory of Finite Element Methods, 3rd ed., Springer, 2008.
Exercises
Section titled “Exercises”- A normalized continuum wavefunction on a uniform grid is represented by samples . Why should the discrete normalization usually include a factor of ?
Solution
The continuum normalization is
On a uniform grid, the rectangle-rule approximation is
The factor carries the length element. Omitting it changes the scale of the discrete vector and makes the normalization depend on the number of grid points.
- Explain why putting a free particle in a finite box with Dirichlet boundary conditions changes the spectrum.
Solution
On the infinite line, the free particle has a continuous momentum and energy spectrum. In a finite box with at both endpoints, only standing waves fitting the box are allowed. The boundary condition quantizes the allowed wavelengths, so the spectrum becomes discrete. The box problem can approximate some aspects of the line problem, but it is not the same operator.
- In a nonorthogonal basis, derive why the finite eigenvalue problem has the form .
Solution
Approximate
The eigenvalue equation is projected against :
Thus
where and . In matrix form this is .
- A uniform grid has spacing . Why is a wave with wavelength much smaller than not reliably represented?
Solution
The grid samples the wave only at separated points. If the wave oscillates substantially between adjacent grid points, the samples do not determine its oscillation pattern. A uniform grid resolves wavenumbers only up to order , so wavelengths comparable to or smaller than are under-resolved and can alias into incorrect lower-frequency behavior.
- A bound-state energy changes when the box size is increased but hardly changes when the grid spacing is reduced. What error source is suggested?
Solution
The dominant error is likely domain truncation or boundary placement, not grid resolution. The grid is already fine enough for the chosen box, but the finite box is still affecting the state. One should increase the physical domain until the localized wavefunction is negligible near the boundary, then refine the grid again if needed.