ψQuantum Computing 2026

CHAPTER 06

Density matrices and subsystems

Learning goals. Represent mixtures, calculate partial traces, test physical density matrices, and use entropy and fidelity with explicit conventions.

6.1 The density operator

For a pure state, define ρ=|ψψ|\rho=|\psi\rangle\langle\psi|. If |ψ=α|0+β|1|\psi\rangle=\alpha|0\rangle+\beta|1\rangle, then

ρ=(|α|2αβ*βα*|β|2).\rho=\begin{pmatrix} |\alpha|^2&\alpha\beta^*\\ \beta\alpha^*&|\beta|^2 \end{pmatrix}.

For a preparation choosing states |ψj|\psi_j\rangle with classical probabilities pjp_j,

ρ=jpj|ψjψj|.\rho=\sum_jp_j|\psi_j\rangle\langle\psi_j|.

This is an average of outer products, not an average ket. A valid density operator is Hermitian, positive semidefinite, and trace one. Positivity means v|ρ|v0\langle v|\rho|v\rangle\ge0 for all vectors. The eigenvalues are probabilities in an eigenstate mixture.

The Born rule and unitary evolution become

p(m)=Tr(Pmρ),ρUρU.p(m)=\operatorname{Tr}(P_m\rho),\qquad \rho\longmapsto U\rho U^\dagger.

The trace identity Tr(AB)=Tr(BA)\operatorname{Tr}(AB)=\operatorname{Tr}(BA) explains why the formula agrees with ψ|Pm|ψ\langle\psi|P_m|\psi\rangle for a pure state.

6.2 Coherence is basis dependent

Compare

ρ+=|++|=12(1111),ρmix=12|00|+12|11|=12(1001).\rho_+=|+\rangle\langle+|=\frac12\begin{pmatrix}1&1\\1&1\end{pmatrix}, \qquad \rho_\mathrm{mix}=\frac12|0\rangle\langle0|+\frac12|1\rangle\langle1| =\frac12\begin{pmatrix}1&0\\0&1\end{pmatrix}.

Both have Z probabilities 1/2,1/21/2,1/2. But Tr(|++|ρ+)=1\operatorname{Tr}(|+\rangle\langle+|\rho_+)=1, while the same expression for the mixture is 1/21/2. The off-diagonal terms in the Z representation encode coherence between the Z alternatives.

The mixture has many ensemble decompositions: I/2=(|++|+||)/2I/2=(|+\rangle\langle+|+|-\rangle\langle-|)/2 as well. No local measurement can reveal which of these preparation stories occurred if only the density operator is available. A density operator summarizes the statistics, not a unique hidden list of constituent pure states [4].

6.3 Bloch ball and purity

Every qubit density operator has the form

ρ=I+xX+yY+zZ2=12(1+zxiyx+iy1z).\rho=\frac{I+xX+yY+zZ}{2} =\frac12\begin{pmatrix}1+z&x-iy\\x+iy&1-z\end{pmatrix}.

Its eigenvalues are (1±r)/2(1\pm r)/2, where r=x2+y2+z2r=\sqrt{x^2+y^2+z^2}. Positivity requires r1r\le1. Pure states lie on the sphere; mixed states lie inside the ball. The center is I/2I/2, which is not a pure state with zero amplitudes.

Purity is

Tr(ρ2)=1+r22.\operatorname{Tr}(\rho^2)=\frac{1+r^2}{2}.

It equals one exactly for pure states. For a general DD-dimensional system it lies between 1/D1/D and one. Purity alone does not characterize every aspect of a state’s usefulness.

6.4 Partial trace: forgetting access, not measuring a hidden value

Let |Ψ=a,bcab|aA|bB|\Psi\rangle=\sum_{a,b}c_{ab}|a\rangle_A|b\rangle_B. The state available to A is

ρA=TrB|ΨΨ|,(ρA)aa=bcabcab*.\rho_A=\operatorname{Tr}_B|\Psi\rangle\langle\Psi|, \qquad (\rho_A)_{aa'}=\sum_bc_{ab}c_{a'b}^*.

Derive this by expanding the joint outer product:

ρAB=a,b,a,bcabcab*|aa||bb|.\rho_{AB}=\sum_{a,b,a',b'}c_{ab}c_{a'b'}^* |a\rangle\langle a'|\otimes|b\rangle\langle b'|.

The trace of |bb||b\rangle\langle b'| is δbb\delta_{bb'}, which eliminates terms with different environment indices. We sum matching indices, not all entries of the matrix.

For a Bell pair,

ρAB=12(|0000|+|0011|+|1100|+|1111|).\rho_{AB}=\tfrac12( |00\rangle\langle00|+|00\rangle\langle11| +|11\rangle\langle00|+|11\rangle\langle11|).

The two cross terms vanish under TrB\operatorname{Tr}_B because Tr(|01|)=0\operatorname{Tr}(|0\rangle\langle1|)=0. Hence ρA=I/2\rho_A=I/2. The joint state is pure, but each subsystem is mixed. A local mixed state need not reflect ordinary ignorance about an independently existing local pure state.

Worked partial trace. For |χ=(|00+2i|01+2|10)/3|\chi\rangle=(|00\rangle+2i|01\rangle+2|10\rangle)/3,

ρA=19(5224),ρB=19(52i2i4).\rho_A=\frac19\begin{pmatrix}5&2\\2&4\end{pmatrix},\qquad \rho_B=\frac19\begin{pmatrix}5&-2i\\2i&4\end{pmatrix}.

For example (ρA)01=c00c10*+c01c11*=(1/3)(2/3)+(2i/3)(0)=2/9(\rho_A)_{01}=c_{00}c_{10}^*+c_{01}c_{11}^* =(1/3)(2/3)+(2i/3)(0)=2/9. Their purities both equal (25+4+4+16)/81=49/81(25+4+4+16)/81=49/81, as required for the reductions of a bipartite pure state.

Laboratory L07 — Entanglement and partial trace. Edit all four complex amplitudes of two qubits. Inspect both reduced matrices, their Bloch vectors, purity, entropy, and pure-state concurrence. Compare a Bell state with a product having the same Z distribution on each subsystem.

6.5 Schmidt coefficients and entropy

The singular-value decomposition of the coefficient matrix gives the Schmidt form

|Ψ=jλj|ujA|vjB,λj0,jλj=1.|\Psi\rangle=\sum_j\sqrt{\lambda_j}|u_j\rangle_A|v_j\rangle_B, \qquad \lambda_j\ge0,\quad\sum_j\lambda_j=1.

The λj\lambda_j are the nonzero eigenvalues of both reduced density matrices. One nonzero Schmidt coefficient means a product state. More than one means entanglement for a pure joint state.

Von Neumann entropy is S(ρ)=Tr(ρlog2ρ)=jλjlog2λjS(\rho)=-\operatorname{Tr}(\rho\log_2\rho) =-\sum_j\lambda_j\log_2\lambda_j. For a bipartite pure state, S(ρA)=S(ρB)S(\rho_A)=S(\rho_B) quantifies entanglement. For a mixed joint state, local entropy alone is not an entanglement measure. A classically correlated mixture of 00 and 11 also has locally maximally mixed states.

6.6 Distinguishability and generalized measurements

Our fidelity convention is the squared convention:

F(ρ,σ)=(Trρσρ)2.F(\rho,\sigma)= \left(\operatorname{Tr}\sqrt{\sqrt\rho\,\sigma\sqrt\rho}\right)^2.

For two pure states it is |ψ|ϕ|2|\langle\psi|\phi\rangle|^2. Some papers use its square root; compare definitions before comparing numbers. Trace distance is D(ρ,σ)=12ρσ1D(\rho,\sigma)=\tfrac12\|\rho-\sigma\|_1, where the trace norm sums singular values. It bounds the difference in probability assigned to any measurement event.

A generalized measurement, or POVM, consists of positive operators EmE_m summing to I, with p(m)=Tr(Emρ)p(m)=\operatorname{Tr}(E_m\rho). Effects specify outcome probabilities, but not the full postmeasurement state. For that one needs measurement operators MmM_m or an instrument, with Em=MmMmE_m=M_m^\dagger M_m and conditioned state MmρMm/p(m)M_m\rho M_m^\dagger/p(m). Several instruments can realize the same POVM.

6.7 Exercises

6.1. Find ρ\rho for the recurring single-qubit example.

Show solution / guidance

ρ=113(46i6i9)\rho=\frac1{13}\begin{pmatrix}4&-6i\\6i&9\end{pmatrix}. Its determinant is (3636)/169=0(36-36)/169=0, trace one, and purity one.

6.2. Is (1/23/43/41/2)\begin{pmatrix}1/2&3/4\\3/4&1/2\end{pmatrix} physical?

Show solution / guidance

No. It is Hermitian with trace one, but eigenvalues are 5/4,1/45/4,-1/4. Positivity is a separate requirement.

6.3. Reduce 3/4|00+1/4|11\sqrt{3/4}|00\rangle+\sqrt{1/4}|11\rangle.

Show solution / guidance

Each reduction is diag(3/4,1/4)\operatorname{diag}(3/4,1/4), purity 5/85/8, and entropy h2(1/4)0.8113h_2(1/4)\approx0.8113 bits. The off-diagonal joint terms vanish under the trace.

6.4. Explain why a locally maximally mixed state does not prove joint entanglement.

Show solution / guidance

Both the Bell state and the separable mixture (|0000|+|1111|)/2(|00\rangle\langle00|+|11\rangle\langle11|)/2 have reduction I/2I/2. Joint coherences or correlations in additional bases are needed.

6.5. Calculate fidelity of |0|0\rangle with |+|+\rangle, and of |0|0\rangle with I/2I/2.

Show solution / guidance

Both equal 1/21/2 in the squared convention. Fidelity with a pure target is 0|ρ|0\langle0|\rho|0\rangle.