physics2u
Tier
⌕ Search ⌘K
Derivation

The Canonical Commutator [x,p] = i hbar

D-142 Home PU-202 Threads symmetry · matter Depends on Expectation Values and the Operator Dictionary
Statement

Working in the position representation, where the momentum operator acts on a differentiable wavefunction as p̂ = −iℏ ∂/∂x and position acts multiplicatively as x̂ ψ = xψ, the two operators fail to commute by exactly one quantum of action: [x̂, p̂] = x̂p̂ − p̂x̂ = iℏ, understood as the operator that multiplies any state by the constant iℏ.

Why it matters

This single relation is the algebraic seed of quantum mechanics. Everything structural — the Heisenberg uncertainty principle, the discreteness of the harmonic-oscillator ladder, the impossibility of simultaneous eigenstates of position and momentum, the very appearance of as the scale of quantum effects — follows from the fact that and do not commute, and specifically from the value of their commutator.

It is also the bridge to classical mechanics: the commutator [x̂, p̂] = iℏ is the operator image of the Poisson bracket {x, p} = 1, via Dirac's rule [Â, B̂] = iℏ {A, B}PB. The limit ℏ → 0 is the classical limit precisely because it makes the operators commute.

Assumptions
Momentum is represented as p̂ = −iℏ ∂/∂x.Drop this and the derivation has no content — the differential form is the input. It is not arbitrary: it is fixed (up to a phase convention) by requiring to generate spatial translations, e−i a p̂/ℏψ(x) = ψ(x−a).
Position acts by multiplication, (x̂ψ)(x) = x ψ(x).Without a definite representation for the product x̂p̂ is undefined and the commutator cannot be evaluated concretely.
The test wavefunction ψ(x) is differentiable and the product rule applies.The identity is proved by letting both sides act on an arbitrary ψ; if ψ is not differentiable at some point, p̂ψ is not defined there and the pointwise argument fails, though the operator identity still holds on the dense domain of smooth states.
The operators share a common dense invariant domain (e.g. Schwartz space).Both and are unbounded, so the naive "[x̂,p̂]=iℏ everywhere" cannot hold on all of Hilbert space — a trace argument would give 0 = iℏ · ∞. Restricting to a common core makes the manipulations rigorous.
Derivation
1
[x̂, p̂] ψ(x) = x̂ p̂ ψ(x) − p̂ x̂ ψ(x)
Definition of the commutator; let it act on an arbitrary differentiable state ψ. Proving an operator identity means proving it on every such ψ. A
2
x̂ p̂ ψ = x ⋅  (−iℏ ∂ψ/∂x) = −iℏ x ∂ψ/∂x
Apply first, then multiply by x. Order matters: here differentiates ψ alone, before the factor of x is attached. A
3
p̂ x̂ ψ = −iℏ ∂/∂x (x ψ)
Now the other ordering: multiply by x first, then differentiate the whole product . This is where the two orderings diverge. A
4
∂/∂x (x ψ) = ψ + x ∂ψ/∂x
Product (Leibniz) rule. The extra term ψ — the derivative of the operator variable acting on itself, ∂x/∂x = 1 — is the entire origin of the commutator. B
5
p̂ x̂ ψ = −iℏ (ψ + x ∂ψ/∂x) = −iℏ ψ − iℏ x ∂ψ/∂x
Substitute Step 4 and distribute the constant −iℏ. A
6
[x̂, p̂] ψ = (−iℏ x ∂ψ/∂x) − (−iℏ ψ − iℏ x ∂ψ/∂x)
Insert Steps 2 and 5 into Step 1. Symbols only; no numbers have entered. A
7
= −iℏ x ∂ψ/∂x + iℏ ψ + iℏ x ∂ψ/∂x = iℏ ψ
The two x ∂ψ/∂x terms cancel exactly. Only the Leibniz remainder survives. A
8
[x̂, p̂] ψ = iℏ ψ  ∀ψ  ⇒  [x̂, p̂] = iℏ
Because this holds for every state ψ in the domain, the operators themselves are equal: the commutator is the constant iℏ times the identity. A
Result
[x̂, p̂] = iℏ 𝟙

Reading. Measuring position then momentum is not the same operation as measuring momentum then position; the two orders differ by the fixed amount iℏ, independent of the state. The factor i makes the right-hand side anti-Hermitian in a way consistent with both and being Hermitian: [x̂,p̂] = [p̂,x̂] = −[x̂,p̂], and indeed (iℏ)* = −iℏ. The presence of sets the scale below which the non-commutativity, and hence quantum behaviour, becomes unavoidable.

Units check. [x̂] has units of length (m), [p̂] has units of momentum (kg m s−1). Their product carries kg m2 s−1 = J s, which is exactly the dimension of action — the dimension of (ℏ = 1.055×10−34 J s). Both sides balance.

Limiting cases
  • Classical limit ℏ → 0: the commutator vanishes, x and p become simultaneously well-defined c-numbers, and the algebra collapses to ordinary commuting phase-space coordinates.
  • Same-index only: in three dimensions [x̂i, p̂j] = iℏ δij. Different components commute ([x̂, p̂y] = 0) because ∂/∂y ignores the multiplicative factor x.
  • Position–position and momentum–momentum: [x̂i, x̂j] = 0 and [p̂i, p̂j] = 0; a coordinate commutes with itself and derivatives commute with each other (equality of mixed partials).
  • Momentum representation: the same relation reappears with roles swapped, x̂ = +iℏ ∂/∂p, giving [x̂,p̂] = iℏ again — the value is representation-independent.
Breaks when
  • Compact or discrete configuration space. For a particle on a ring the natural pair is angle φ̂ and angular momentum z = −iℏ ∂/∂φ. One cannot have [φ̂, L̂z] = iℏ literally, because φ is multivalued and z has a discrete spectrum; the naive relation fails and must be replaced by a bounded (Weyl-form) statement.
  • Finite-dimensional Hilbert space. Taking the trace of [x̂,p̂]=iℏ gives Tr(x̂p̂) − Tr(p̂x̂) = 0 on the left (cyclicity) but iℏ Tr𝟙 = iℏ N ≠ 0 on the right. No finite matrices satisfy it; the relation demands unbounded operators on an infinite-dimensional space.
  • Non-differentiable or boundary-restricted domains. On a box with hard walls, p̂ = −iℏ ∂/∂x is not self-adjoint (boundary terms in ∫ψ*p̂φ do not vanish), so the tidy operator identity acquires domain caveats even though it holds formally in the interior.
  • Lattice / minimal-length theories. If space is discretised or a fundamental length is postulated (some quantum-gravity models), the commutator is deformed, e.g. [x̂,p̂] = iℏ(1 + βp̂2), and the canonical form is only the low-energy approximation.
Failure modes
  • Forgetting the product rule. Writing p̂(xψ) = −iℏ x ∂ψ/∂x drops the ψ term and yields the wrong answer [x̂,p̂]=0. The single surviving term is the whole result.
  • Treating and as numbers. "They're both just variables, so they commute" ignores that is a differential operator. Operators need a test function to reveal their algebra.
  • Sign / i errors. Using p̂ = +iℏ ∂/∂x (wrong translation-generator sign) flips the result to −iℏ. The convention −iℏ ∂/∂x is fixed by eikx having momentum +ℏk.
  • Dropping the identity operator. Writing "[x̂,p̂] = iℏ" and then trying to add it to an operator forgets that the right side means iℏ 𝟙; the number multiplies every state.
  • Claiming [x̂,p̂y] = iℏ. Mixing indices; only matched components fail to commute.
  • Applying it to a state where p̂ψ is ill-defined (e.g. a step) and then being surprised the pointwise identity misbehaves at the discontinuity.
Discussion

The commutator is best read not as a curious algebraic fact but as a statement about generators. Momentum is the generator of spatial translations: e−i a p̂/ℏ shifts a wavefunction by a. The commutator [x̂,p̂]=iℏ is precisely the infinitesimal statement that translating a particle changes its position coordinate by the amount of the translation — e−i a p̂/ℏ x̂ e+i a p̂/ℏ = x̂ + a𝟙. Non-commutativity here is the quantum encoding of the geometric fact that position and translation are conjugate.

From the commutator alone, without ever solving a Schrödinger equation, one derives the Robertson uncertainty relation. For any Hermitian Â, B̂, ΔA ΔB ≥ ½|⟨[Â,B̂]⟩|. Feeding in [x̂,p̂]=iℏ gives directly Δx Δp ≥ ℏ/2. Heisenberg's principle is thus a corollary of the commutator, not an independent postulate.

The relation also underlies algebraic quantisation of the harmonic oscillator. Defining â ∝ x̂ + i p̂/(mω), the canonical commutator forces [â, â] = 1, which in turn dictates the entire equally-spaced spectrum En = ℏω(n+½) and the zero-point energy. The ladder structure of quantum mechanics is bookkeeping on [x̂,p̂].

At the deepest level the Stone–von Neumann theorem states that, up to unitary equivalence, there is only one irreducible representation of the canonical commutation relation for finitely many degrees of freedom — the Schrödinger representation used here. This uniqueness fails for infinitely many degrees of freedom (quantum field theory), where inequivalent representations proliferate and give rise to distinct phases, spontaneous symmetry breaking, and the need for renormalisation. The humble [x̂,p̂]=iℏ is therefore also the dividing line between ordinary quantum mechanics and field theory.

Common misconceptions. The commutator does not say "you cannot measure position and momentum" — each is perfectly measurable alone, to arbitrary precision. It says no state is a simultaneous eigenstate of both, so their statistical spreads cannot both vanish. Nor does it depend on any disturbance from a measuring apparatus; it is a property of the states themselves, provable before any measurement is discussed.

Worked examples
1
Minimum momentum spread of a confined electron. Given Δx = 0.10 nm (an electron localised to one atom), find the least possible Δp and the corresponding velocity spread.
The commutator fixes the uncertainty bound. A
2
Δx Δp ≥ ½|⟨[x̂,p̂]⟩| = ℏ/2  ⇒  Δpmin = ℏ/(2Δx)
Robertson relation with the canonical commutator inserted; rearrange for Δp symbolically first. A
3
Δpmin = (1.055×10−34 J s) / (2 ⋅ 1.0×10−10 m) = 5.3×10−25 kg m s−1
Substitute numbers with units; Δx = 0.10 nm = 1.0×10−10 m. A
4
Δv = Δpmin/me = (5.3×10−25) / (9.11×10−31 kg) ≈ 5.8×105 m s−1
Divide by the electron mass to convert momentum spread to speed spread. A
Δpmin ≈ 5.3×10−25 kg m s−1,   Δv ≈ 5.8×105 m s−1

Reading. Squeezing an electron into atomic dimensions forces a velocity spread of order 0.1% of the speed of light — a direct, quantitative consequence of [x̂,p̂]=iℏ. This is why atomic electrons cannot simply "sit still" in a nucleus.

1
The derived commutator [x̂, p̂2] = 2iℏ p̂ and Ehrenfest velocity. Use the canonical relation to build [x̂, Ĥ] for a free particle Ĥ = p̂2/2m, then evaluate for ⟨p̂⟩ = 1.0×10−24 kg m s−1, m = me.
Higher commutators are algebraic consequences of the fundamental one. B
2
[x̂, p̂2] = p̂[x̂,p̂] + [x̂,p̂]p̂ = p̂(iℏ) + (iℏ)p̂ = 2iℏ p̂
Leibniz identity for commutators [Â,B̂Ĉ]=[Â,B̂]Ĉ+B̂[Â,Ĉ]; the only input is [x̂,p̂]=iℏ. B
3
[x̂, Ĥ] = [x̂, p̂2/2m] = (1/2m) ⋅ 2iℏ p̂ = iℏ p̂/m
Divide the previous result by 2m. This gives Ehrenfest's theorem d⟨x̂⟩/dt = ⟨p̂⟩/m via d⟨x̂⟩/dt = ⟨[x̂,Ĥ]⟩/iℏ. B
4
d⟨x̂⟩/dt = ⟨p̂⟩/m = (1.0×10−24) / (9.11×10−31) ≈ 1.1×106 m s−1
Insert numbers and units into the operator result. A
[x̂, Ĥ] = iℏ p̂/m  ⇒  d⟨x̂⟩/dt ≈ 1.1×106 m s−1

Reading. The canonical commutator, propagated through the Heisenberg equation of motion, reproduces the classical relation velocity = momentum/mass as an operator identity. The recovery of v = p/m shows the quantum algebra contains Newtonian kinematics as its expectation-value shadow.

Problems
  1. Verify by direct action on a test function that [x̂, p̂2] = 2iℏ p̂, using p̂ = −iℏ d/dx.
    Solution 2ψ = −ℏ2ψ″. Then x̂p̂2ψ = −ℏ2xψ″ and 2x̂ψ = −ℏ2(xψ)″ = −ℏ2(2ψ′ + xψ″). Subtracting: [x̂,p̂2]ψ = −ℏ2xψ″ + ℏ2(2ψ′+xψ″) = 2ℏ2ψ′. Since p̂ψ = −iℏψ′, we have 2ℏ2ψ′ = 2iℏ(−iℏψ′) = 2iℏ p̂ψ. Hence [x̂,p̂2] = 2iℏ p̂. ✓
  2. An electron is confined to a one-dimensional region of width L = 1.0×10−9 m. Estimate its minimum kinetic energy using Δx ≈ L and Δp ≥ ℏ/2Δx.
    Solution Δpmin = ℏ/(2L) = (1.055×10−34)/(2 ⋅ 1.0×10−9) = 5.3×10−26 kg m s−1. Taking p ≈ Δp, Emin ≈ p2/2m = (5.3×10−26)2/(2 ⋅ 9.11×10−31) ≈ 1.5×10−21 J ≈ 9.6×10−3 eV. About 10 meV. ✓
  3. Show that [x̂, p̂n] = iℏ n p̂n−1 for integer n ≥ 1. What operator identity does this resemble?
    Solution By induction. Base n=1: [x̂,p̂]=iℏ = iℏ ⋅ 1 ⋅ p̂0. Assume true for n. Then [x̂,p̂n+1] = [x̂,p̂n]p̂ + p̂n[x̂,p̂] = iℏ n p̂n−1p̂ + p̂n(iℏ) = iℏ(n+1)p̂n. ✓ It mirrors the calculus rule d(pn)/dp = n pn−1: the operation (1/iℏ)[x̂, ⋅] acts as ∂/∂p̂.
  4. Compute the trace of both sides of [x̂,p̂] = iℏ formally, and explain what the resulting contradiction tells you about the operators.
    Solution Left side: Tr[x̂,p̂] = Tr(x̂p̂) − Tr(p̂x̂) = 0 by cyclicity of the trace, if the trace exists. Right side: Tr(iℏ𝟙) = iℏ dim. Equating gives 0 = iℏ dim, impossible for finite nonzero dimension. Conclusion: and cannot be finite matrices, nor bounded (trace-class-friendly) operators — the canonical relation requires unbounded operators on an infinite-dimensional Hilbert space. ✓
  5. For a Gaussian minimum-uncertainty state ψ(x) = (2πσ2)−1/4e−x2/4σ2 with σ = 2.0×10−10 m, state Δx, then use the commutator bound at saturation to find Δp, and give the product Δx Δp in units of .
    Solution For this Gaussian, Δx = σ = 2.0×10−10 m. A Gaussian saturates the bound, so Δx Δp = ℏ/2 exactly, giving Δp = ℏ/(2σ) = (1.055×10−34)/(2 ⋅ 2.0×10−10) = 2.6×10−25 kg m s−1. The product Δx Δp = ℏ/2 = 0.50 ℏ — the minimum permitted by [x̂,p̂]=iℏ. ✓