Crank–Nicolson unitarity and solver tolerance
Analyze a unitary rational propagator and the errors introduced by phase distortion and incomplete linear solves.
On this page
The question for today
What you’ll understand
- Derive the Cayley update for a finite Hermitian Hamiltonian.
- Compute its eigenmode phase and distinguish unitarity from temporal accuracy.
- Relate a linear-solve residual to a one-step state error.
An implicit method can preserve the norm of a closed finite quantum system while avoiding the growth of explicit Euler propagation. Crank–Nicolson achieves this through a rational approximation to the exponential, often called a Cayley transform. Its useful structure has precise conditions: the Hamiltonian must be Hermitian in the stated inner product, and the implicit system must actually be solved. Even then, finite-timestep phase error remains and can accumulate into observable mistakes.
Derive the rational update from midpoint averaging
For a time-independent finite Hamiltonian, average the right-hand side of the Schrödinger equation between old and new states. Rearranging gives one matrix multiplying the unknown new state and its adjoint multiplying the old state. Since both are polynomials in the same Hermitian H, they commute. Their ratio is unitary in exact arithmetic. Implementations should solve this linear system directly rather than forming a dense matrix inverse merely because inverse notation is convenient.
The norm statement uses the ordinary inner product for an orthonormal finite basis. With an overlap matrix, the update and adjoint relationships must be formulated in that metric. An absorbing non-Hermitian Hamiltonian or a dissipative density-matrix generator belongs to a different analysis. Calling every midpoint-looking update unitary ignores the operator and state-space assumptions that make this particular proof work.
Measure the eigenphase rather than only the norm
On an eigenvector with real energy E, the update multiplies by a complex number of unit magnitude. Its phase is minus twice the arctangent of E times timestep over twice hbar. The exact phase is instead minus E times timestep over hbar. They agree at small dimensionless timestep through the expected order, but a large step can badly distort relative phases between energy levels even while the norm remains exactly one.
For constant H, the rational propagator also commutes with H and preserves its finite expectation value. Thus norm and energy can both pass while a superposition rotates at the wrong relative rate. For a driven Hamiltonian, using a properly time-centered Hermitian matrix retains per-step unitarity and can give second-order temporal accuracy under appropriate smoothness. Replacing the true time ordering by a poorly sampled midpoint still requires independent step-size checks.
Include iterative-solver error in the propagation budget
Let the linear residual be b minus A times the computed new state. Subtracting the exact linear equation gives the state error as minus the inverse of A applied to that residual. For a finite Hermitian Hamiltonian and the ordinary two-norm, every singular value of A is at least one, so its inverse norm is at most one. This gives a clean one-step absolute error bound for this specific system, without assuming that all unrelated implicit solves share the same conditioning.
Across many steps, solver residuals can accumulate and compete with truncation error. A tolerance fixed at an inconvenient absolute scale may dominate a timestep-refinement study. Renormalizing after every step can hide norm drift without removing phase error or replacing the missing solve accuracy. Adaptive tests should therefore compare step-subdivided states or selected observables and track both linear residuals and temporal changes. Small norm drift is useful evidence, but never the whole error estimate.
Work it through
A norm-preserving but phase-biased two-level step
Take , initial plus state, and . Compute the Crank–Nicolson relative factor, final Bloch vector and excited-state probability. Compare the numerical relative phase with the exact one.
The ground-state factor is one. For the excited level the ratio is , so the final state is .
Both probabilities remain one half, and the Bloch vector is . The state norm is exactly one under this solved finite update.
Its relative phase is minus pi over two, while exact evolution gives minus two radians. The phase discrepancy is radians in magnitude, even though norm, energy and these basis probabilities are conserved.
The Cayley step produces a minus-i relative factor and Bloch y minus one, but its relative phase differs from exact evolution by about 0.4292 radians.
The living notebook
Explore the model
Interactive lab · quantum
Equal populations can hide a phase difference
Reset and set mixing angle ninety degrees, phase minus ninety degrees; predict Bloch coordinates and equal basis probabilities. Compare a fresh Reset run at ninety degrees, phase zero; predict Bloch x one with the same probabilities. This pure-state geometry does not execute Crank–Nicolson or measure a solver residual.
- 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 forPopulation agreement alone does not control coherent phase error.
Pause & reason
Check your understanding
Your turn
Try it yourself
For the scalar Cayley system , , suppose a solver returns . Compute its residual, its error relative to the exact solution, and its squared norm. Does renormalization make the linear equation exact?
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
The exact ratio is minus i. Compute b minus A times the supplied approximation before taking magnitudes.
Compare with the solution
The residual is with magnitude . The exact solution is minus i, so the state error magnitude is 0.01, equal to residual magnitude divided by . The approximate squared norm is . Renormalizing can restore unit norm but changes the supplied vector without generally satisfying the original linear equation or removing its phase error. Solve accuracy must be checked through the residual and its propagation effect.
Keep the idea
Take it with you
- The Cayley proof needs finite Hermitian structure and an accurate solve.
- Unit modulus and conserved energy do not guarantee the correct relative phase.
- Linear residuals belong in the same budget as timestep and basis errors.
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.