From tensor products to entangled EPR pairs — an interactive guide to composite quantum systems, the CNOT gate, and the mathematics of entanglement
1 / 7 explored
Use ←→ arrow keys to switch tabs
Keyboard Shortcuts
←→Switch tabs
1-7Jump to tab
RReset current view
SpaceToggle auto-play
⊗ Why Tensor Products?
In classical computing, combining two bits is simple: you just list them side by side. A pair of bits has 4 possible values (00, 01, 10, 11). In quantum mechanics, the situation is richer because of superposition.
When we combine two quantum systems, the resulting state space is not a simple Cartesian product — it is the tensor product \(\otimes\) of the individual Hilbert spaces. This mathematical operation captures all the ways the two systems can be correlated, including entanglement.
Key idea: The tensor product of two vector spaces \(\mathcal{H}_A\) and \(\mathcal{H}_B\) produces a new space \(\mathcal{H}_A\otimes\mathcal{H}_B\) whose dimension is the product of the original dimensions: \(\dim(\mathcal{H}_A\otimes\mathcal{H}_B) = \dim(\mathcal{H}_A)\times\dim(\mathcal{H}_B)\).
⊗ Tensor Product of Two Qubits
A single qubit \(|\psi\rangle = \alpha|0\rangle+\beta|1\rangle\) lives in \(\mathbb{C}^2\). When we combine two qubits, the tensor product gives us \(\mathbb{C}^2\otimes\mathbb{C}^2 = \mathbb{C}^4\), with the computational basis:
which represents the state \(\alpha\gamma|00\rangle + \alpha\delta|01\rangle + \beta\gamma|10\rangle + \beta\delta|11\rangle\).
⚡ Interactive Tensor Product Calculator
Choose a state for each qubit and see the tensor product computed step by step.
Qubit A:
|0⟩ +|1⟩
Qubit B:
|0⟩ +|1⟩
✎ Worked Example — Compute \(|+\rangle\otimes|1\rangle\)
1
Write \(|+\rangle\) as a column vector: \(|+\rangle = \tfrac{1}{\sqrt2}\begin{pmatrix}1\\1\end{pmatrix}\).
2
Write \(|1\rangle\) as a column vector: \(|1\rangle = \begin{pmatrix}0\\1\end{pmatrix}\).
3
Multiply each entry of the first vector by the entire second vector:
\(\tfrac{1}{\sqrt2}\begin{pmatrix}1\cdot\begin{pmatrix}0\\1\end{pmatrix}\\[4pt]1\cdot\begin{pmatrix}0\\1\end{pmatrix}\end{pmatrix} = \tfrac{1}{\sqrt2}\begin{pmatrix}0\\1\\0\\1\end{pmatrix}\)
4
Read off the state: \(\tfrac{1}{\sqrt2}(|01\rangle + |11\rangle)\). Try it in the calculator above — select |+⟩ for A and |1⟩ for B!
Not commutative: In general \(|a\rangle\otimes|b\rangle \neq |b\rangle\otimes|a\rangle\) (the ordering of subsystems matters).
Not surjective: Not every vector in the tensor product space can be written as a single tensor product. Those that cannot are entangled (see Tab ⑤).
Common misconception: The tensor product is not the same as the Cartesian product or the outer product, although it is related to both. It produces a new vector space, not a set of pairs.
💡 Pause & Think
If a single qubit lives in \(\mathbb{C}^2\), what is the dimension of the state space for a system of 3 qubits?
6
8
9
3
⊕ From 1 Qubit to \(n\) Qubits
An \(n\)-qubit quantum register lives in the tensor product of \(n\) copies of \(\mathbb{C}^2\):
Each \(c_x\) is a complex amplitude — to fully describe the state classically, you need all \(2^n\) of them.
📈 The Exponential Explosion
This exponential scaling is the fundamental reason quantum computers can be powerful. Click a number of qubits to see how the dimension grows.
🔍 Explore the Computational Basis
Select the number of qubits, then click a basis state to see its tensor-product decomposition.
Qubits:
⬡ Quantum Registers as Subsystems
A multi-qubit system can be divided into subsystems (also called registers). For example, a 4-qubit state can be viewed as:
Four individual qubits: \(\mathcal{H}_A\otimes\mathcal{H}_B\otimes\mathcal{H}_C\otimes\mathcal{H}_D\)
Two 2-qubit registers: \(\mathcal{H}_{AB}\otimes\mathcal{H}_{CD}\)
One 3-qubit register and one qubit: \(\mathcal{H}_{ABC}\otimes\mathcal{H}_D\)
Partial measurement: When you measure one register of a composite system, the other register collapses into a state that depends on the measurement outcome. This is the physical basis of entanglement.
≡ Reference: Dimensions by Qubit Count
Qubits \(n\)
Basis states \(2^n\)
Amplitudes needed
1
2
2
2
4
4
3
8
8
5
32
32
10
1,024
1,024
20
1,048,576
≈ 10⁶
50
≈ 10¹⁵
≈ 10¹⁵
300
2³⁰⁰
More than atoms in the universe
⊕ What is the CNOT Gate?
The Controlled-NOT (CNOT) gate is the most important two-qubit gate in quantum computing. It operates on a pair of qubits: a control qubit and a target qubit.
Rule: The CNOT flips the target qubit if and only if the control qubit is \(|1\rangle\). Otherwise, it leaves both qubits unchanged.
Self-inverse: \(\mathrm{CNOT}^{2}=I\) — applying it twice returns the original state
Entangling: it can create entanglement from separable states (see Tab ④)
✦ CNOT on Superpositions
The real power of CNOT appears when the control qubit is in superposition. Click to see what happens:
Key insight: When the control is in superposition, CNOT creates entanglement — the output cannot be factored as a product of single-qubit states. This is exactly how Bell pairs are created!
💡 Pause & Think
If the control qubit is in state \(|0\rangle\) (not in superposition), can CNOT ever create entanglement?
Yes — CNOT always entangles
No — the output is always separable
It depends on the target qubit
⟁ The EPR Circuit
An EPR pair (Einstein–Podolsky–Rosen pair), also called a Bell pair, is the simplest entangled two-qubit state. It is created by just two gates:
Apply a Hadamard gate \(H\) to the first qubit.
Apply a CNOT with the first qubit as control and the second as target.
Starting from \(|00\rangle\), this circuit produces the Bell state
\(|\Phi^+\rangle = \tfrac{1}{\sqrt{2}}\!\left(|00\rangle+|11\rangle\right)\).
▶ Step-by-Step Construction
Click the steps below or use the buttons to watch the circuit build the EPR pair.
What's happening
✦ All Four Bell States
By choosing different input pairs, the same \(H\)+CNOT circuit produces all four maximally-entangled Bell states:
Input
Name
State
|00⟩
|Φ⁺⟩
\(\tfrac{1}{\sqrt2}(|00\rangle+|11\rangle)\)
|01⟩
|Ψ⁺⟩
\(\tfrac{1}{\sqrt2}(|01\rangle+|10\rangle)\)
|10⟩
|Φ⁻⟩
\(\tfrac{1}{\sqrt2}(|00\rangle-|11\rangle)\)
|11⟩
|Ψ⁻⟩
\(\tfrac{1}{\sqrt2}(|01\rangle-|10\rangle)\)
Orthonormal basis: The four Bell states form a complete orthonormal basis for the 4-dimensional two-qubit space. Any two-qubit state can be decomposed into a superposition of Bell states.
✦ How Entanglement Is Born
Watch the quantum state evolve as it passes through the Hadamard and CNOT gates. The entanglement link appears when the state can no longer be factored.
⚡ Try Different Inputs
Select a starting two-qubit state to see which Bell state the circuit produces.
🎲 Measure an EPR Pair
Experience entanglement first-hand! Start with \(|\Phi^+\rangle=\tfrac{1}{\sqrt2}(|00\rangle+|11\rangle)\), then measure one qubit and watch the other instantly collapse.
q₁
Qubit 1
q₂
Qubit 2
|00⟩: 0|11⟩: 0Total: 0
Run many measurements to see the 50/50 statistics emerge — but always perfectly correlated!
🎯 Challenge: Predict the Measurement
Test your intuition! You'll be given a two-qubit state and told what Qubit 1 measured. Can you predict Qubit 2?
Click "New Round" to start!
Correct: 0Total: 0Streak: 0
⟐ What is Entanglement?
A two-qubit state \(|\psi\rangle\) is called separable (not entangled) if it can be written as a tensor product of two single-qubit states:
for some single-qubit states \(|\alpha\rangle\) and \(|\beta\rangle\).
Definition: A state that cannot be written as such a product is called entangled.
Entanglement is a uniquely quantum phenomenon with no classical counterpart. When two qubits are entangled, the outcome of measuring one qubit is correlated with the outcome of measuring the other — no matter how far apart they are.
⦿ Non-local Correlations
Measurement outcomes are correlated across any distance. Measuring one qubit instantly constrains the other, yet no information travels faster than light.
✖ No Cloning
Entangled states cannot be perfectly copied. The no-cloning theorem ensures quantum information is fundamentally different from classical bits.
⌘ Monogamy
A qubit maximally entangled with one partner cannot be entangled with another. Entanglement is a limited resource that must be shared carefully.
⚡ Resource for Computation
Entanglement powers teleportation, superdense coding, and quantum error correction. It is the key resource behind quantum advantage.
⚡ Separable vs. Entangled — Visual Comparison
Click each example to see whether it is separable or entangled, and why.
Arrange the amplitudes in a \(2\times 2\) matrix and compute its determinant:
$$M=\begin{pmatrix}\alpha&\beta\\\gamma&\delta\end{pmatrix},\qquad \det M = \alpha\delta-\beta\gamma$$
Criterion: The state is separable ⟺ \(\alpha\delta-\beta\gamma=0\). If this quantity is nonzero, the state is entangled.
Why? If \(|\psi\rangle=(a|0\rangle+b|1\rangle)\otimes(c|0\rangle+d|1\rangle)\), then \(\alpha=ac,\;\beta=ad,\;\gamma=bc,\;\delta=bd\), so \(\alpha\delta-\beta\gamma=acbd-adbc=0\). A nonzero value means no such factorisation exists.
✎ Worked Example — Is \(\tfrac{1}{2}(|00\rangle+|01\rangle+|10\rangle+|11\rangle)\) entangled?
Form the amplitude matrix: \(M = \begin{pmatrix}\tfrac12 & \tfrac12 \\[4pt] \tfrac12 & \tfrac12\end{pmatrix}\).
3
Compute the determinant: \(\det M = \tfrac12 \cdot \tfrac12 - \tfrac12 \cdot \tfrac12 = \tfrac14 - \tfrac14 = 0\).
4
Since \(\det M = 0\), the state is separable. It factors as \(\tfrac{|0\rangle+|1\rangle}{\sqrt2}\otimes\tfrac{|0\rangle+|1\rangle}{\sqrt2} = |+\rangle\otimes|+\rangle\). Try it in the detector below!
🔬 Interactive Entanglement Detector
Enter the amplitudes of any two-qubit state and check whether it is entangled.
💡 Pause & Think
The state \(\tfrac{1}{2}(|00\rangle+|01\rangle+|10\rangle+|11\rangle)\) has amplitudes \(\alpha=\beta=\gamma=\delta=\tfrac{1}{2}\). Is it entangled?
Yes — it has four nonzero amplitudes
No — \(\alpha\delta-\beta\gamma = \tfrac14 - \tfrac14 = 0\)
Cannot tell without measuring
Theorem: \(|\Phi^+\rangle\) is Entangled
We prove that \(|\Phi^+\rangle=\tfrac{1}{\sqrt2}(|00\rangle+|11\rangle)\) cannot be written as a tensor product of two single-qubit states. Click each step to reveal it.
Step 1 — Assume Separability
Assume for contradiction that \(|\Phi^+\rangle\) is separable. Then there exist single-qubit states