beginner · Programming · Two Qubits & Tensor Products
Marginal Probabilities
A two-qubit state can be measured in many ways. Often you care about only one qubit — the other
is not observed, or its result is ignored. The probability of getting a particular outcome on the
qubit you do measure is called a marginal probability.
Where marginals come from
A general two-qubit state is written
∣ψ⟩=c00∣00⟩+c01∣01⟩+c10∣10⟩+c11∣11⟩,
where cij are complex amplitudes satisfying
∣c00∣2+∣c01∣2+∣c10∣2+∣c11∣2=1.
If you measure only qubit 0 (the most significant bit) and ignore qubit 1, the Born rule says
you must sum over every outcome of the unobserved qubit:
Each outcome is equally likely — exactly as you would expect from the symmetric form of
∣Φ+⟩. Notice that you never needed to specify what happens to qubit 1; the marginal
absorbs it by summing over all its values.
Marginals for product states
For a product state∣ψ⟩=∣ψ0⟩⊗∣ψ1⟩, summing over one
qubit simply returns the probability already carried by the other qubit's own state. If
∣ψ0⟩=α∣0⟩+β∣1⟩, then P(q0=0)=∣α∣2 regardless of
∣ψ1⟩. The two qubits are statistically independent. For entangled states this
independence breaks down — the qubits' individual marginals give only a partial picture of the
joint state.
Try it
The state is ∣Φ+⟩=21(∣00⟩+∣11⟩). Use the formula
above to compute the marginal probability that qubit 0 measures 0, and return it.
Run your code to see the quantum state.
Sign in on the full site to ask questions and join the discussion.