Numerical Mathematics
A trustworthy numerical result is a mathematical argument supported by computation. It identifies the intended continuum or finite-dimensional problem, explains how that problem was represented, chooses an algorithm appropriate to its structure, quantifies error, and survives independent checks. A solver returning a number is only the beginning of that argument.
This chapter develops method-level foundations. Software interfaces, implementation environments, and project workflows are outside its canonical scope; Math Needed for Computational QM connects these tools to computation-facing study routes.
The numerical trust chain
Section titled “The numerical trust chain”Most quantum calculations pass through several distinct problems:
Each arrow introduces different assumptions and failure modes.
| Stage | Typical choice | Essential evidence |
|---|---|---|
| mathematical problem | operator domain, boundary data, initial state | well-posed equations and physical units |
| finite representation | grid, basis, box, cutoff, quadrature | refinement and boundary checks |
| algorithm | eigensolver, linear solve, time step, transform | stability and residual diagnostics |
| arithmetic | precision, scaling, summation order | roundoff and conditioning analysis |
| reported quantity | energy, norm, phase, rate, expectation value | propagated uncertainty and benchmark comparison |
Validation should target the observable being claimed. A small eigenpair residual does not by itself prove that the continuum eigenvalue is converged; it only says that the computed vector nearly solves the finite matrix problem.
Arithmetic, conditioning, and stability
Section titled “Arithmetic, conditioning, and stability”Standard floating-point analysis models a basic rounded operation by
when the exact result is in the normal range and no exceptional case intervenes. Here is the unit roundoff. Repeated operations can amplify these perturbations, especially through cancellation, poor scaling, or ill-conditioned transformations.
Conditioning belongs to the mathematical problem. For an invertible matrix,
measures worst-case sensitivity in the chosen norm. Stability belongs to the algorithm. A backward-stable method returns the exact answer to a nearby problem. Their roles combine schematically as
Floating-Point Arithmetic owns representation, roundoff, cancellation, scaling, and reproducibility. Conditioning and Stability separates sensitive problems from unstable algorithms and explains why residuals must be interpreted in scale-aware norms.
Discretizing continuum quantum mechanics
Section titled “Discretizing continuum quantum mechanics”A discretization replaces an infinite-dimensional problem by finite data. That replacement includes more than a grid spacing or basis size:
- the spatial domain and its truncation;
- boundary conditions;
- grid points or basis functions;
- the discrete inner product and quadrature weights;
- operator matrices;
- ultraviolet and infrared resolution;
- symmetry and Hermiticity properties.
For example, the centered second derivative is
This interior order does not guarantee second-order convergence if boundary rows are lower order or the solution lacks the required smoothness. A nontrivial quadrature matrix may also change the discrete adjoint condition from to
Discretization owns the continuum-to-finite transition. Finite Difference Methods develops local stencils and Laplacian matrices. Spectral Methods develops global basis and pseudospectral approximations, whose rapid convergence depends on smoothness and boundary matching. Numerical Quadrature supplies the weighted sums used for normalization, overlaps, expectation values, and matrix elements.
Dense and sparse spectral problems
Section titled “Dense and sparse spectral problems”After discretization, a stationary problem often becomes
or, in a nonorthogonal basis,
Dense Hermitian diagonalization is appropriate when the matrix fits comfortably in memory and many eigenpairs are needed. Large local Hamiltonians are often sparse: only a small fraction of matrix entries are nonzero, and the important primitive is then the matrix-vector product rather than explicit factorization.
For a normalized approximate eigenvector , the residual
tests the finite algebraic problem. A useful scale-aware form is
Residuals should be accompanied by orthogonality checks, symmetry labels, and refinement in the underlying grid or basis. Near degeneracy, the invariant subspace is usually better conditioned than an individual basis of eigenvectors.
Matrix Diagonalization covers dense Hermitian eigensolvers and eigenpair validation. Sparse Matrices covers storage, matrix-free actions, and weighted Hermiticity. Sparse Eigensolvers covers Lanczos and Arnoldi methods, targeting, restarts, and convergence diagnostics.
Time evolution and differential equations
Section titled “Time evolution and differential equations”Spatial discretization turns the time-dependent Schrödinger equation into
For a time-independent Hermitian Hamiltonian, exact evolution over one step is
Different methods approximate this structure in different ways. Crank–Nicolson uses
and is unitary for a time-independent Hermitian in exact arithmetic. Exponential-action methods approximate without necessarily forming . Split-operator methods alternate kinetic and potential evolution, often using a fast Fourier transform to move between position and momentum grids.
General ODE and PDE solvers add concerns such as stiffness, adaptive local error control, boundary-value shooting, multidimensional domains, and sparse linear solves. Norm conservation alone is not enough: a propagator can preserve norm while accumulating unacceptable phase or observable error.
Time-Stepping Methods compares explicit, implicit, and structure-aware propagators. Matrix Exponentials Numerically covers diagonalization, scaling and squaring, and Krylov exponential actions. Fast Fourier Transform fixes discrete transform and momentum-grid conventions. ODE Solvers and PDE Solvers own the broader initial-value, boundary-value, stability, and convergence frameworks.
Error budgets and convergence evidence
Section titled “Error budgets and convergence evidence”A numerical error budget may include:
- model or approximation error;
- finite-domain error;
- spatial discretization or basis-truncation error;
- time-step error;
- algebraic solver error;
- quadrature error;
- floating-point error;
- statistical uncertainty and bias.
These terms need not be independent, so adding all estimates in quadrature is not automatically justified. The dominant contribution should be identified by controlled variation.
Suppose a scalar result has asymptotic behavior
Three refinements estimate the observed order:
Agreement with the formal order is meaningful only after entering the asymptotic regime and controlling other errors such as box size, solver tolerance, and roundoff. Refining every parameter simultaneously can hide which source controls the result.
Error Estimates gives the error taxonomy and reporting standards. Convergence Tests gives the refinement workflow. Benchmark Problems provides exact and controlled tests for spectra, tunneling, radial equations, two-level dynamics, and periodic grids.
Recommended routes
Section titled “Recommended routes”- First stationary spectrum: Floating-Point Arithmetic → Discretization → Finite Difference Methods → Matrix Diagonalization → Convergence Tests.
- Large sparse Hamiltonian: Sparse Matrices → Sparse Eigensolvers → Conditioning and Stability → Error Estimates.
- Real-time wave packet: Discretization → Time-Stepping Methods → Matrix Exponentials Numerically → Fast Fourier Transform → Benchmark Problems.
- Radial boundary problem: ODE Solvers → Numerical Quadrature → Convergence Tests.
- Continuum PDE: Discretization → Finite Difference Methods or Spectral Methods → PDE Solvers → Error Estimates.
Page map
Section titled “Page map”| Page | Central question |
|---|---|
| Floating-Point Arithmetic | How does finite representation of real numbers affect quantum calculations? |
| Conditioning and Stability | Is sensitivity intrinsic to the problem or introduced by the algorithm? |
| Discretization | Which finite problem is replacing the continuum one? |
| Finite Difference Methods | How do local derivative stencils become operator matrices? |
| Spectral Methods | When do global basis expansions converge rapidly? |
| Numerical Quadrature | How are normalization and matrix-element integrals approximated reliably? |
| Matrix Diagonalization | How are dense Hermitian eigenpairs computed and checked? |
| Sparse Matrices | How should large local Hamiltonians be stored or applied? |
| Sparse Eigensolvers | How are selected eigenpairs extracted without dense diagonalization? |
| Time-Stepping Methods | Which time steps control stability, phase error, and unitarity? |
| Matrix Exponentials Numerically | When should one compute an exponential or only its action? |
| Fast Fourier Transform | How do discrete Fourier grids support derivatives and split evolution? |
| ODE Solvers | How are initial-value and shooting problems integrated and validated? |
| PDE Solvers | How are multidimensional quantum equations discretized and evolved? |
| Error Estimates | Which uncertainties limit the claimed observable? |
| Convergence Tests | Does the answer approach a stable limit under controlled refinement? |
| Benchmark Problems | Which exact or controlled cases expose implementation failures? |
Common mistakes
Section titled “Common mistakes”| Mistake | Correction |
|---|---|
| Treating displayed digits as accuracy | report only digits supported by an error estimate |
| Confusing conditioning with algorithmic stability | diagnose the problem map and the algorithm separately |
| Refining grid spacing while holding a too-small box fixed | vary ultraviolet and infrared controls independently |
| Assuming a Hermitian continuum operator yields a Hermitian array automatically | include boundary rows and the discrete inner product |
| Accepting an eigenvalue because the solver converged | check residuals, symmetries, subspaces, and discretization refinement |
| Choosing a time step only from norm drift | check phase, energy, observables, and spectral stability |
| Comparing wavefunctions without aligning phase and normalization | compare invariant observables or phase-aligned states |
| Using one benchmark that shares the production method’s failure mode | triangulate with exact limits and independent algorithms |
Exercises
Section titled “Exercises”1. Centered second derivative
Section titled “1. Centered second derivative”Use Taylor expansions of and through fifth order to derive the centered second-derivative formula and its leading error.
Solution
The expansions are
Adding and solving for gives
Thus the approximation has leading truncation error and is second order when the required derivatives exist.
2. What an eigenpair residual guarantees
Section titled “2. What an eigenpair residual guarantees”Let be Hermitian, , and . Show that at least one exact eigenvalue satisfies
Solution
Expand in an orthonormal eigenbasis of . Then
If every eigenvalue were farther than from , the right-hand side would be strictly greater than
a contradiction. The result concerns the finite Hermitian matrix; it does not bound continuum discretization error.
3. Crank–Nicolson unitarity
Section titled “3. Crank–Nicolson unitarity”For time-independent Hermitian , define and
Show that .
Solution
Because ,
Every factor is a function of the same matrix , so the factors commute. Therefore
Finite linear-solver tolerances and roundoff can still introduce small norm errors in an implementation.
4. Observed convergence order
Section titled “4. Observed convergence order”A quantity is computed on three successively halved grids:
Estimate the observed order.
Solution
The consecutive differences are and , whose ratio is . Hence
This is consistent with second-order asymptotic convergence, but more refinements and independent control of box size and solver tolerance are still needed before reporting an error bar.
References
Section titled “References”- N. J. Higham, Accuracy and Stability of Numerical Algorithms, 2nd ed., SIAM, 2002.
- G. H. Golub and C. F. Van Loan, Matrix Computations, 4th ed., Johns Hopkins University Press, 2013.
- L. N. Trefethen and D. Bau, Numerical Linear Algebra, SIAM, 1997.
- R. J. LeVeque, Finite Difference Methods for Ordinary and Partial Differential Equations, SIAM, 2007.
- L. N. Trefethen, Spectral Methods in MATLAB, SIAM, 2000.
- E. Hairer, C. Lubich, and G. Wanner, Geometric Numerical Integration, 2nd ed., Springer, 2006.
- Y. Saad, Numerical Methods for Large Eigenvalue Problems, revised ed., SIAM, 2011.
- J. M. Thijssen, Computational Physics, 2nd ed., Cambridge University Press, 2007.
- D. J. Tannor, Introduction to Quantum Mechanics: A Time-Dependent Perspective, University Science Books, 2007.