|q⟩ Bad Qubits

beginner · Programming · Entanglement & Bell States

Product vs Entangled: A Test

Not every two-qubit state that looks complicated is entangled. The key question is whether the state can be factored into independent parts for each qubit — what physicists call a product state.

The separability criterion

A general two-qubit pure state can be written

ψ=α00+β01+γ10+δ11,|\psi\rangle = \alpha|00\rangle + \beta|01\rangle + \gamma|10\rangle + \delta|11\rangle,

where α2+β2+γ2+δ2=1|\alpha|^2 + |\beta|^2 + |\gamma|^2 + |\delta|^2 = 1. The state is a product state — meaning qubit 0 and qubit 1 are completely independent — if and only if it can be factored as (a0+b1)(c0+d1)(a|0\rangle + b|1\rangle)\otimes(c|0\rangle + d|1\rangle). Expanding that product gives ac00+ad01+bc10+bd11ac|00\rangle + ad|01\rangle + bc|10\rangle + bd|11\rangle, so we need α=ac, β=ad, γ=bc, δ=bd\alpha = ac,\ \beta = ad,\ \gamma = bc,\ \delta = bd. Multiplying the corner pair gives αδ=abcd\alpha\delta = abcd; multiplying the other pair gives βγ=abcd\beta\gamma = abcd. Therefore:

ψ is a product state    αδ=βγ.|\psi\rangle\ \text{is a product state} \iff \alpha\delta = \beta\gamma.

Equivalently, the 2×22\times 2 coefficient matrix (αβγδ)\begin{pmatrix}\alpha & \beta \\ \gamma & \delta\end{pmatrix} has determinant zero. If the determinant is non-zero, the state is entangled.

Two worked examples

Example 1 — product state. Consider

++=12(00+01+10+11).|{+}{+}\rangle = \tfrac{1}{2}\big(|00\rangle + |01\rangle + |10\rangle + |11\rangle\big).

Here α=β=γ=δ=12\alpha = \beta = \gamma = \delta = \tfrac{1}{2}. Then αδ=14\alpha\delta = \tfrac{1}{4} and βγ=14\beta\gamma = \tfrac{1}{4}. Because they match, this is a product state — indeed ++=++|{+}{+}\rangle = |+\rangle \otimes |+\rangle.

Example 2 — entangled state. The Bell state

Φ+=12(00+11)|\Phi^+\rangle = \tfrac{1}{\sqrt{2}}\big(|00\rangle + |11\rangle\big)

has α=δ=12\alpha = \delta = \tfrac{1}{\sqrt{2}} and β=γ=0\beta = \gamma = 0. Then αδ=12\alpha\delta = \tfrac{1}{2} but βγ=0\beta\gamma = 0. The determinant is 120\tfrac{1}{2} \neq 0, so the state is entangled: there is no way to write it as ψ0ϕ1|\psi\rangle_0 \otimes |\phi\rangle_1.

Try it

Apply the determinant test to the Bell state Φ+=12(00+11)|\Phi^+\rangle = \tfrac{1}{\sqrt{2}}(|00\rangle + |11\rangle). Return true if the state is entangled, or false if it is a product state.

Run your code to see the quantum state.

Sign in on the full site to ask questions and join the discussion.