Skip to main content

Quantum core · institution-dependent · Interactive lesson

Transfer matrices for piecewise-constant potentials

Any potential you can draw as a staircase is already solved, once you can solve one wall and one slab. This lesson turns each into a 2×2 matrix, multiplies them in the order the electron meets them, and then shows you exactly where that innocent product destroys itself in floating point.

UPV-06.03 · Lesson 3 of 9 in this unit. Position is not a completion score.
Starting model: Transfer matrices for piecewise-constant potentialsLog-amplitude of the two solutions inside one forbidden slab, both set to 1 at the entry face: the filled dot is the growing branch e^(+κx), the open dot the decaying one, and at the exit they differ by 2κL = 7.2. The dashed pair is 36.0 apart, the span of a double, so once the dots cross it the decaying solution is rounding noise.ln |amplitude| across a forbidden slab2κL = 7.2dashed pair sits 36.0 apart = ln(1/ε)growing branch e(+κx)decaying branch e(−κx)0 at the entry face, L at the exit, cut into 1 slabs
Start with a picture. Change the model in the lab below.

Quantum core · institution-dependent. Your university determines the required depth of these quantum topics, including the use of operators, differential equations and computation. Institution-dependent does not automatically mean optional.

1

Build the model

Two-by-two matrices, multiplied in the order the wave meets them.

The key idea

A transfer matrix is the 2×2 matrix that carries the pair of plane-wave amplitudes (A, B) from one constant-potential region across to the next, so an entire staircase potential is solved by one ordered product of such matrices.

Example. At a single step from E = 2.00 eV onto a 1.00 eV plateau, s = kL/kR = √2 and M = ½[[1+√2, 1−√2], [1−√2, 1+√2]]; det M = √2 = kL/kR, and r = −M₂₁/M₂₂ = 0.1716, so R = 2.94%.

The complete physical model and assumptions

A piecewise-constant potential leaves no differential equation to solve. Inside each slab the equation is ψ″ = −k²ψ with k constant, so the solution there is pinned by exactly two complex numbers: the right-going and left-going amplitudes (A, B). All the physics sits in how that pair changes from slab to slab, and because ψ and ψ′ are continuous across a finite jump, the change is linear — one 2×2 matrix per wall, one diagonal 2×2 per slab. Chain them in the order the wave meets them and a staircase of any complexity collapses to a single M, with the whole scattering problem readable from two of its entries. What M is not is unitary. It conserves the σ₃-weighted probability current, M†σ₃M = (kL/kR)σ₃, and that indefinite metric leaves its entries unbounded: in a forbidden slab the propagation matrix is diag(e(−κd), e(+κd)), stretching one direction by e(κd) and squeezing the other by the same factor. That is the price. The exact staircase solution arrives in a representation whose condition number is e(2κL), and by κL ≈ 18 the decaying solution has been rounded out of a double-precision number entirely. The transfer matrix is the right object to think with and, past a certain thickness, the wrong object to compute with.

1Two amplitudes are the entire state inside a slab

Set V(x) = Vⱼ on the interval [xⱼ, xⱼ₊₁]. There H|ψ⟩ = E|ψ⟩, written in the position basis as ψ(x) = ⟨x|ψ⟩, reduces to ψ″ = −kⱼ²ψ with kⱼ = √(2m(E − Vⱼ))/ħ constant, whose general solution is Aⱼe(ikⱼ(x−xⱼ)) + Bⱼe(−ikⱼ(x−xⱼ)). Two constants, so the state inside that slab is a vector (Aⱼ, Bⱼ) in ℂ² — the two-fold degeneracy of the continuum, written as a basis. Anchoring the exponentials at the slab's own left edge rather than at a global origin is a bookkeeping choice, and it is the one that keeps the matrices free of stray phases. When E < Vⱼ nothing in the algebra changes: kⱼ = iκⱼ with κⱼ = √(2m(Vⱼ − E))/ħ real, and the right-goer becomes the decaying exponential while the left-goer becomes the growing one. For an electron ħ²/2mₑ = 3.810 × 10⁻² eV nm², so k = 5.123 √(E/eV) nm⁻¹: one electronvolt buys about 5.1 inverse nanometres.

2One matrix per wall, one per slab

At the wall xⱼ₊₁ the potential jumps but stays finite, so ψ and ψ′ are both continuous there. Let a = Aⱼe(ikⱼdⱼ) and b = Bⱼe(−ikⱼdⱼ) be the amplitudes carried across the slab of width dⱼ = xⱼ₊₁ − xⱼ. Continuity of ψ gives Aⱼ₊₁ + Bⱼ₊₁ = a + b; continuity of ψ′ gives kⱼ₊₁(Aⱼ₊₁ − Bⱼ₊₁) = kⱼ(a − b). Add and subtract, and with s = kⱼ/kⱼ₊₁ you get Aⱼ₊₁ = ½[(1+s)a + (1−s)b] and Bⱼ₊₁ = ½[(1−s)a + (1+s)b]. That is the interface matrix I = ½[[1+s, 1−s], [1−s, 1+s]], with det I = ¼[(1+s)² − (1−s)²] = s. The carrying step is the diagonal Pⱼ = diag(e(ikⱼdⱼ), e(−ikⱼdⱼ)), determinant 1, which in a classically forbidden slab reads diag(e(−κⱼdⱼ), e(+κⱼdⱼ)). Every piecewise-constant problem in one dimension is built from those two matrices and nothing else.

3The staircase is a single ordered product

Compose them: M = I(N−1→N) P(N−1) ⋯ P₁ I(0→1), so that (AR, BR)ᵀ = M (AL, BL)ᵀ. Because a matrix acts on what stands to its right, the leftmost interface is the rightmost factor — the product is written in reverse spatial order, and getting it backwards silently builds the mirror-image stack. Flux forces that mirror image to have the same T and the same R, but a different reflection phase and a completely different interior field, so the mistake hides from the two numbers you are most likely to check. Determinants are the free diagnostic: slab matrices contribute 1, interface matrices contribute kⱼ/kⱼ₊₁, and the chain telescopes to det M = k₀/kN = kL/kR. Code that returns anything else has an interface ratio upside down, a wrong wavenumber, or a lost phase, and it should be caught there rather than in a transmission curve. A reversed product is the one bug this test cannot see, since det(AB) = det(BA).

4Flux, not norm: what M really conserves

The probability current in a lead is j = (ħkⱼ/m)(|Aⱼ|² − |Bⱼ|²) = (ħkⱼ/m) v†σ₃v with v = (Aⱼ, Bⱼ) and σ₃ = diag(1, −1). Equating the current in the two leads for every incoming state gives M†σ₃M = (kL/kR)σ₃: M preserves an indefinite form, not a norm. Taking determinants of that identity recovers |det M| = kL/kR; entry by entry it gives |M₁₁|² − |M₂₁|² = kL/kR, |M₂₂|² − |M₁₂|² = kL/kR, and M₁₁*M₁₂ = M₂₁*M₂₂. Because the metric is σ₃ and not the identity, the flux-rescaled matrix √(kR/kL) M sits in SU(1,1), a group of hyperbolic boosts whose entries grow without bound. Time reversal is a separate symmetry: for real V and propagating leads ψ* also solves the equation, which swaps (A, B) into (B*, A*) and forces σ₁Mσ₁ = M*, so M₂₂ = M₁₁* and M₂₁ = M₁₂*. Then M = [[a, b], [b*, a*]] with |a|² − |b|² = kL/kR — unimodular only when the leads match. Give V an absorptive imaginary part and the conjugate pairing goes with it.

5Reading r, t, R and T off two entries

Scattering fixes the boundary condition: unit amplitude in from the left, nothing in from the right, so vL = (1, r) and vR = (t, 0). The second row of (t, 0)ᵀ = M(1, r)ᵀ gives 0 = M₂₁ + M₂₂ r, hence r = −M₂₁/M₂₂; the first row, tidied with the determinant, gives t = det M/M₂₂ = (kL/kR)/M₂₂. Probabilities are current ratios: R = |r|² and T = (kR/kL)|t|² = (kL/kR)/|M₂₂|², and R + T = 1 then follows from the pseudo-unitarity identity instead of being imposed by hand. Run it on a rectangular barrier with matched leads and the three factors multiply out to M₂₂ = cosh(κL) − (i/2)(k/κ − κ/k) sinh(κL). Squaring, |M₂₂|² = 1 + sinh²(κL)(k² + κ²)²/(4k²κ²) = 1 + V₀² sinh²(κL)/(4E(V₀ − E)), so T = 1/|M₂₂|² is the textbook barrier formula — reached by multiplying three matrices rather than solving four matching equations.

6Where the product dies, and what to use instead

Each forbidden slab contributes P = diag(e(−κd), e(+κd)), singular values e(∓κd) and condition number e(2κd). Those numbers multiply, so a total forbidden path L costs e(2κL) whether you cross it in one slab or five hundred: slicing finer never helps, because the exponents merely add. Double precision carries ε = 2.22 × 10⁻¹⁶, so significance is exhausted at 2κL = ln(1/ε) = 36.0, which is 15.65 decimal digits; for an electron 4.00 eV below a barrier top, κ = 10.25 nm⁻¹ and that width is only 1.76 nm. What survives is whatever lives in the growing direction: M₂₂ is dominated by e(+κL) and keeps full relative accuracy, so T = 1/|M₂₂|² is reliable even at 10⁻¹⁶. What dies is whatever needs the decaying direction — the field inside the barrier, the resonance peaks of a double-barrier stack where terms of size e(2κL) must cancel down to order 1, and the root M₂₂ = 0 that locates a bound state. The cure is to compose scattering matrices: in flux-normalised amplitudes S is unitary, every entry has modulus at most 1, and the star product t = t₂(1 − r₁′r₂)⁻¹t₁ holds no growing exponential.

2

Key equations

Read the units, assumptions and limits before substituting.

Amplitude pair inside one constant slab

ψⱼ(x) = Aⱼ e(ikⱼ(x−xⱼ)) + Bⱼ e(−ikⱼ(x−xⱼ))

Two complex numbers replace the whole function in a slab, which is why a 2×2 matrix is enough to step from one slab to the next.

kⱼ = √(2m(E − Vⱼ))/ħ in m⁻¹; for E < Vⱼ write kⱼ = iκⱼ with κⱼ real. Aⱼ, Bⱼ are complex amplitudes.

Interface matrix at a wall

I(j→j+1) = ½ [[1+s, 1−s], [1−s, 1+s]], s = kⱼ/kⱼ₊₁

One matrix per wall, fixed entirely by the ratio of the wavenumbers either side — the wall's position never enters it.

From continuity of ψ and ψ′ across a finite jump. det I = s, so it is unimodular only when the two wavenumbers agree.

Slab propagation matrix

Pⱼ = diag(e(ikⱼdⱼ), e(−ikⱼdⱼ)) → diag(e(−κⱼdⱼ), e(+κⱼdⱼ))

Its condition number is e(2κⱼdⱼ): every forbidden slab crossed costs 2κd/ln 10 significant decimal digits.

dⱼ = xⱼ₊₁ − xⱼ is the slab width in m; det Pⱼ = 1, so slabs never touch the determinant.

The staircase as one ordered product

(AR, BR)ᵀ = M (AL, BL)ᵀ, M = I(N−1→N) P(N−1) ⋯ P₁ I(0→1)

The rightmost factor acts first, so the matrices are written in reverse spatial order, and they do not commute.

det M = kL/kR exactly: the interface determinants telescope and the slab determinants are 1.

Flux conservation as pseudo-unitarity

M† σ₃ M = (kL/kR) σ₃, σ₃ = diag(1, −1)

The conserved quantity carries an indefinite metric, so M is not unitary and none of its entries is bounded by 1.

j = (ħk/m)(|A|² − |B|²) is the current in a lead, in s⁻¹. Entrywise: |M₁₁|² − |M₂₁|² = kL/kR.

Scattering data from two entries

r = −M₂₁/M₂₂, t = det M/M₂₂, R = |r|², T = (kR/kL)|t|²

T is a ratio of currents, not of amplitudes: |t|² can exceed 1 whenever the right lead is slower than the left.

From (t, 0)ᵀ = M (1, r)ᵀ. T collapses to (kL/kR)/|M₂₂|², and to 1/|M₂₂|² for matched leads.
3

Interactive lab

Predict first. Explore the model. Compare the result.

Explore the model

2.00 eV
1 to 6 eV; steps of 0.25.
0.50 nm
0.25 to 1.6 nm; steps of 0.05.
1
1 to 5; steps of 1.

Try this. Take L to 1.6 nm with the barrier 6 eV above E: 2κL passes 36 and both dots cross the dashed lines, where the decaying solution is gone. Then raise the slab count — cutting the same barrier finer moves the boundaries but never the dots, because the exponents just add.

Live results

DECAY CONSTANT κ
7.25 nm⁻¹
2κL AT THE EXIT
7.25
DIGITS LOST
3.1 of 15.65
DIGITS PER SLAB
3.15

Results follow this lesson’s model and assumptions. Displayed values are rounded.

Interactive Physics V modelLog-amplitude of the two solutions inside one forbidden slab, both set to 1 at the entry face: the filled dot is the growing branch e^(+κx), the open dot the decaying one, and at the exit they differ by 2κL = 7.2. The dashed pair is 36.0 apart, the span of a double, so once the dots cross it the decaying solution is rounding noise.ln |amplitude| across a forbidden slab2κL = 7.2dashed pair sits 36.0 apart = ln(1/ε)growing branch e(+κx)decaying branch e(−κx)0 at the entry face, L at the exit, cut into 1 slabs
Log-amplitude of the two solutions inside one forbidden slab, both set to 1 at the entry face: the filled dot is the growing branch e(+κx), the open dot the decaying one, and at the exit they differ by 2κL = 7.2. The dashed pair is 36.0 apart, the span of a double, so once the dots cross it the decaying solution is rounding noise.

Predict → change one variable → check

Plan a change before running it. Every other input stays at the saved baseline.

Saved baseline. Barrier height above E: 2.00 eV; Slab width L: 0.50 nm; Slabs the barrier is cut into: 1

Baseline 2.00; choose 1 to 6, in steps of 0.25.
4. Compared with the saved baseline, this result will…

This experiment is kept only while this page is open. It does not change saved course progress.

4

Catch the common trap

The tempting error is to call M unitary because probability is conserved, and then read R = |M₂₁|² and T = |M₁₁|² straight off its entries. Conservation is real, but what is conserved is the σ₃-weighted current, M†σ₃M = (kL/kR)σ₃, an indefinite metric. Unitarity would bound every entry by 1; M's entries grow like e(κL) without limit, which is exactly why a thick barrier ruins the product. The correct readings invert a matrix element instead: t = det M/M₂₂ and T = (kL/kR)/|M₂₂|², so a large M₂₂ means small transmission, not large. The object that really is unitary is the scattering matrix S, and that is precisely why the numerically stable recursion is written for S and never for M.

5

Practice & worked examples

3 authored examples. Make an attempt, then reveal the reasoning one step at a time.

EasyExample 1

An electron with E = 2.00 eV crosses a single potential step at x = 0, from V = 0 up to V = 1.00 eV. Build the transfer matrix, then read off r, t, R and T, and check that flux balances.

Sketch your answer or reasoning, then compare it with the authored solution. Your writing is not automatically graded or saved.

0 of 5 steps revealed.

MediumExample 2

An electron of E = 1.00 eV meets a rectangular barrier of height V₀ = 3.00 eV and width L = 0.500 nm, with V = 0 on both sides. Form M as the ordered product I⋅P⋅I, extract M₂₂, and get T. Check it against the closed-form barrier result and against the opaque limit.

Sketch your answer or reasoning, then compare it with the authored solution. Your writing is not automatically graded or saved.

0 of 6 steps revealed.

HardExample 3

An electron with E = 1.00 eV meets a barrier of height V₀ = 5.00 eV, so it sits 4.00 eV below the top, with V = 0 on both sides. Show that the transfer-matrix product's condition number is e(2κL), find the width at which IEEE double precision has no significant digits left, evaluate T there, and say which computed quantities survive and which do not.

Sketch your answer or reasoning, then compare it with the authored solution. Your writing is not automatically graded or saved.

0 of 6 steps revealed.

6

Quick check

Select an answer and explain it before checking.

A transfer-matrix product for a barrier with matched leads (kL = kR) returns M₂₂ = 18.73 + 6.61i. What is the transmission probability T?
7

Review & continue

A transfer matrix is the 2×2 matrix that carries the pair of plane-wave amplitudes (A, B) from one constant-potential region across to the next, so an entire staircase potential is solved by one ordered product of such matrices.

  • Explain the relationship without looking at the equation.
  • Check a sign, a unit and a model assumption in your working.
  • Return to the lab or worked example if a step is still unclear.

Extra challenging questions

Connect several ideas, explore supplied data, and compare your reasoning with a worked solution.