Part II. Mathematical Core · Chapter 13
Tensor Products and State-Space Growth
Three qubits need eight amplitudes; thirty need about a billion; fifty need more memory than your laptop has. The tensor product is the rule behind that growth — and the reason the growth cannot be cashed out as readable output.
In this chapter 8 sections
Reader question. How are independently described quantum systems combined, and why does their joint statevector grow exponentially?
The joint state space is the tensor product: subsystem dimensions multiply, product-state amplitudes are pairwise products in a declared basis order, and n qubits require 2^n complex coordinates even though a measurement returns only n classical bits.
- This chapter does not claim exponential statevector size automatically yields exponential computational speedup.
- It does not yet classify general entanglement or introduce tensor-network algorithms in depth.
Dimensions multiply when systems combine
Derive .
One qubit has two basis states. Two qubits have four. Three have eight, and qubits have computational basis states, each carrying its own complex amplitude in the statevector.
The growth is real, and it is easy to misread. The statevector has one amplitude per basis state, but measurement does not print amplitudes; it returns one basis state, sampled according to their squared magnitudes. The craft of quantum algorithms is shaping amplitudes so that this thin sampled sliver carries the answer. Tensor products supply the language for all of it: multi-qubit states, entanglement, and circuit simulation alike.
Evidence boundary. Composite finite-dimensional quantum systems use tensor-product state spaces whose dimensions multiply. [John Watrous] [Michael A. Nielsen]
Kronecker products set the coordinates
Expand two symbolic qubits in an ordered joint basis.
If:
Then the combined state is the product, expanded term by term:
Dimensions multiply:
Two-dimensional systems composed times give the familiar . Every amplitude in the big vector is a product of amplitudes from the small ones; when the state factors at all. Entangled states are precisely the ones that cannot be written this way.
Evidence boundary. Product-state coordinates are Kronecker products in a specified ordered basis. [Michael A. Nielsen] [John Preskill]
A four-amplitude example by hand
Compute |+>⊗|-> and verify normalization.
Evidence boundary. An n-qubit pure statevector has 2^n complex coordinates while computational-basis measurement returns an n-bit outcome. [Michael A. Nielsen] [National Academies of Sciences]
Notation contract: Subsystem order A⊗B; basis order (|00>,|01>,|10>,|11>); n qubits have 2^n coordinates; memory units distinguish GB/GiB.
Product structure versus arbitrary joint vectors
Identify the coefficient constraint for factorability.
Tensor products explain why naive simulation dies young: a statevector for qubits holds complex amplitudes, and memory follows. But the same growth implies no automatic application advantage; only that the physical state space is large and hard to represent classically in the straightforward way. Good simulators and compilers survive by exploiting what the naive representation ignores: sparsity, tensor-network structure, and limited entanglement.
A debugging habit worth keeping: write the basis index table before the vector. For two qubits, decide whether index means or under your convention, and write it down. Many wrong circuit traces are not deep physics errors; they are indexing errors that stay invisible while the notation stays implicit.
Memory doubles with every qubit
Quantify naive statevector storage and the thin classical readout.
A dense statevector has 2^n complex entries. With complex128 storage, its payload is 16 times 2^n bytes before allocator, checkpoint, and parallel-distribution overhead. Thirty qubits require 16 GiB; forty require 16 TiB. This is a statement about the naive representation, not a lower bound for every classical simulator: low entanglement, sparsity, stabilizer structure, or repeated tensor structure can permit compressed methods.
Tensor-product growth calculator
| Field | Reader-visible record |
|---|---|
| Format | Notebook and browser calculator for coordinates, memory, and factorability |
| Verification | Tests Kronecker products against fixtures, preserves norm, verifies 2^n sizing, and checks factorability for selected states. |
| Availability | Source-embedded acceptance record; no separate download is claimed |
{
"artifact": "Tensor-product growth calculator",
"format": "Notebook and browser calculator for coordinates, memory, and factorability",
"acceptance_test": "Tests Kronecker products against fixtures, preserves norm, verifies 2^n sizing, and checks factorability for selected states.",
"publication_state": "source-embedded contract and worked fixture"
}Executable reference fixture
Run with Python 3.11 or later. The final assertion is the chapter-level pass condition for this small instance.
import math
def kron(left, right):
if not left or not right:
raise ValueError("tensor factors must be nonempty")
return tuple(a * b for a in left for b in right)
def norm2(vector):
return sum(abs(value) ** 2 for value in vector)
def factorability_gap(two_qubit_state):
if len(two_qubit_state) != 4:
raise ValueError("factorability fixture expects two qubits")
a00, a01, a10, a11 = two_qubit_state
return abs(a00 * a11 - a01 * a10)
def resources(qubits, bytes_per_amplitude=16):
if qubits < 1 or bytes_per_amplitude < 1:
raise ValueError("resource parameters must be positive")
coordinates = 1 << qubits
return coordinates, coordinates * bytes_per_amplitude
scale = math.sqrt(0.5)
zero, one, plus, plus_i = (1, 0), (0, 1), (scale, scale), (scale, 1j * scale)
product_pairs = ((zero, one), (plus, plus_i), ((0.6, 0.8j), (scale, -scale)))
product_gaps = []
for left, right in product_pairs:
state = kron(left, right)
assert abs(norm2(state) - norm2(left) * norm2(right)) < 1e-12
product_gaps.append(factorability_gap(state))
assert max(product_gaps) < 1e-12
bell_states = ((scale, 0, 0, scale), (0, scale, scale, 0))
entangled_gaps = [factorability_gap(state) for state in bell_states]
assert min(entangled_gaps) > 0.49
ket_010 = kron(kron(zero, one), zero)
assert len(ket_010) == 8 and ket_010[2] == 1
assert kron(one, zero) != kron(zero, one)
for qubits in range(1, 16):
coordinates, memory = resources(qubits)
assert coordinates == 2 ** qubits and memory == 16 * coordinates
largest_coordinates, largest_memory = resources(30)
assert largest_coordinates == 1_073_741_824 and largest_memory == 17_179_869_184
empty_rejected = False
try:
kron((), zero)
except ValueError:
empty_rejected = True
assert empty_rejected
dimension_rejected = False
try:
factorability_gap((1, 0, 0))
except ValueError:
dimension_rejected = True
assert dimension_rejected
print(f"PASS: 13 tensor calculator verifies {len(product_pairs)} product and {len(bell_states)} entangled states; Bell determinant gap={min(entangled_gaps):.3f}, 30-qubit memory={largest_memory / 2**30:.1f} GiB")
Scope boundary
- This chapter does not claim exponential statevector size automatically yields exponential computational speedup.
- It does not yet classify general entanglement or introduce tensor-network algorithms in depth.
Depth commitment. One general expansion, one numerical state, one factorability condition, and one memory calculation.
Practice problem
Expand , verify normalization, and estimate memory for 30 complex128 qubits.
- Deliverable
- Exact four amplitudes, norm calculation, and byte/GiB conversion.
- Pass condition
- The calculator reproduces the vector and memory value using 16 bytes per complex128 entry.
Verification record
Expected solution form. Symbolic expansion plus executable memory/factorization report.
Model answer. The amplitudes in |00>,|01>,|10>,|11> order are sqrt(3)/(2sqrt(2)), -i sqrt(3)/(2sqrt(2)), 1/(2sqrt(2)), and -i/(2sqrt(2)). Their squared magnitudes sum to one. Thirty complex128 qubits require 2^30 times 16 bytes, exactly 16 GiB before overhead.
Model result and check. CI compares each amplitude, norm, entry count, and unit conversion.
Acceptance test. The calculator reproduces the vector and memory value using 16 bytes per complex128 entry.
Companion work
Artifacts for this chapter
These entries resolve to checked-in local source. Commands are reproduced exactly from the chapter manifest, and source-embedded fixtures are exported as direct downloads.
executable derivation
Tensor-product growth calculator
Reproduce or test
python3 tools/validate_briefs.py --briefs data/editorial_briefs_00_35.json --from 0 --through 35 --check-rewritten-sources --execute-artifacts
Provenance
Sources and review
- John Watrous. The Theory of Quantum Information. Cambridge University Press / University of Waterloo. 2018textbook
- Michael A. Nielsen and Isaac L. Chuang. Quantum Computation and Quantum Information. Cambridge University Press. 2010textbook
- John Preskill. Lecture Notes for Physics 219: Quantum Computation. California Institute of Technology. 2018graduate lecture notes
- National Academies of Sciences, Engineering, and Medicine. Quantum Computing: Progress and Prospects. National Academies Press. 2019consensus study report
The load-bearing claims in the chapter are mapped inline to this registered source set. A citation supports only the bounded claim beside it.