Skip to content

Quantum Information Formulas

These cards collect compact formulas for representing qubits, comparing states, manipulating circuits, summarizing information, and using stabilizer structure. Quantum-information notation is unusually convention sensitive: state and channel metrics, squared and root fidelity, qubit ordering, logarithm base, and Pauli phases must be stated.

NeedCardCore statement
Represent a qubit stateBloch Vectorρ=(I+r⋅σ)/2\rho=(I+\mathbf r\cdot\boldsymbol{\sigma})/2
Apply common one- and two-qubit gatesQuantum GatesU†U=IU^\dagger U=I
Compare state overlapFidelityF=[Tr⁡ρ σρ]2F=[\operatorname{Tr}\sqrt{\sqrt\rho\,\sigma\sqrt\rho}]^2
Bound state distinguishabilityTrace DistanceD=12∥ρ−σ∥1D=\tfrac12\lVert\rho-\sigma\rVert_1
Relate entropic quantitiesEntropy IdentitiesI(A:B)=SA+SB−SABI(A:B)=S_A+S_B-S_{AB}
Work with stabilizer states or codesStabilizer IdentitiesPS=∣S∣−1∑g∈SgP_S=\lvert S\rvert^{-1}\sum_{g\in S}g

A qubit density operator can be written as

ρ=12(I+r⋅σ),∥r∥≤1.\rho = \frac12 \left( I+\mathbf r\cdot\boldsymbol{\sigma} \right), \qquad \lVert\mathbf r\rVert\leq1.

Its purity is

Tr⁡(ρ2)=1+∥r∥22.\operatorname{Tr}(\rho^2) = \frac{ 1+\lVert\mathbf r\rVert^2 }{2}.

For a Pauli measurement along unit vector n\mathbf n,

p(±)=12(1±r⋅n).p(\pm) = \frac12 \left( 1\pm\mathbf r\cdot\mathbf n \right).

The Bloch ball is complete for one qubit. Multiqubit and higher-dimensional states require more coefficients and positivity constraints; one Bloch vector per subsystem does not determine joint correlations.

No single scalar answers every comparison question.

QuantityQuestionRangeKey warning
Purity γ(ρ)=Tr⁡(ρ2)\gamma(\rho)=\operatorname{Tr}(\rho^2)How concentrated is one state’s spectrum?[1/d,1][1/d,1] in dimension ddNot a distance to a target
Squared fidelity F(ρ,σ)F(\rho,\sigma)How much do two states overlap?[0,1][0,1]Some sources use root fidelity
Trace distance D(ρ,σ)D(\rho,\sigma)How distinguishable are two states?[0,1][0,1]State distance, not channel distance
Entropy S(ρ)S(\rho)How uncertain is the spectral distribution?[0,log⁡d][0,\log d]Logarithm base matters

This site uses

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

and

D(ρ,σ)=12∥ρ−σ∥1.D(\rho,\sigma) = \frac12 \lVert\rho-\sigma\rVert_1.

Their Fuchs–van de Graaf bounds are

1−F≤D≤1−F.1-\sqrt F \leq D \leq \sqrt{1-F}.

For two pure states, the upper bound is an equality. For mixed states it need not be.

Trace distance controls the largest statistical separation available to any measurement:

D(ρ,σ)=max⁡{Ex}12∑x∣Tr⁡[Ex(ρ−σ)]∣.D(\rho,\sigma) = \max_{\{E_x\}} \frac12 \sum_x \left\lvert \operatorname{Tr} \left[ E_x(\rho-\sigma) \right] \right\rvert.

For equal priors, the optimal one-copy guessing probability is

Pguessopt=12(1+D).P_{\mathrm{guess}}^{\mathrm{opt}} = \frac12 \left( 1+D \right).

Fidelity has a purification interpretation:

F(ρ,σ)=max⁡∣⟨Ψρ∣Ψσ⟩∣2.F(\rho,\sigma) = \max \lvert \langle\Psi_\rho\rvert\Psi_\sigma\rangle \rvert^2.

Purity has a two-copy swap identity:

Tr⁡(ρ2)=Tr⁡[S(ρ⊗ρ)].\operatorname{Tr}(\rho^2) = \operatorname{Tr} \left[ S(\rho\otimes\rho) \right].

These formulas use different experiments and answer different questions. Numerical similarity of their values does not make them interchangeable.

The cards in this section primarily compare states. A channel

N:ρ↦N(ρ)\mathcal N:\rho\mapsto\mathcal N(\rho)

is a map on every allowed input, possibly with an entangled reference. Testing one output state does not determine worst-case channel behavior.

Common channel-level quantities include:

  • diamond distance;
  • entanglement fidelity;
  • average gate fidelity;
  • process or Choi-state fidelity, with stated normalization;
  • unitarity and leakage metrics.

These quantities have different averaging, ancilla, and input assumptions. Do not label a state overlap from one test input as “gate fidelity.”

For state trace distance,

D(N(ρ),N(σ))≤D(ρ,σ),D \left( \mathcal N(\rho), \mathcal N(\sigma) \right) \leq D(\rho,\sigma),

while squared fidelity obeys

F(N(ρ),N(σ))≥F(ρ,σ).F \left( \mathcal N(\rho), \mathcal N(\sigma) \right) \geq F(\rho,\sigma).

Both statements express loss of distinguishability under common physical processing.

Quantum gates are unitary matrices:

U†U=UU†=I.U^\dagger U = UU^\dagger = I.

For a register, the tensor-factor convention must be explicit. The matrix called controlled-NOT differs depending on:

  • whether the first displayed bit is the most or least significant;
  • whether basis states are ordered ∣00⟩,∣01⟩,∣10⟩,∣11⟩\lvert00\rangle,\lvert01\rangle,\lvert10\rangle,\lvert11\rangle or differently;
  • which subsystem is control and which is target;
  • whether matrices act on column vectors from the left.

Global phase does not change a closed-system state:

UandeiαUU \quad\hbox{and}\quad e^{i\alpha}U

induce the same transformation on state vectors up to global phase. Relative phases and controlled phases remain observable.

The von Neumann entropy is

Sb(ρ)=−Tr⁡(ρlog⁡bρ).S_b(\rho) = - \operatorname{Tr} \left( \rho\log_b\rho \right).

Quantum-information work often uses base two and reports bits:

S2(ρ)=−Tr⁡(ρlog⁡2ρ).S_2(\rho) = - \operatorname{Tr} \left( \rho\log_2\rho \right).

Statistical mechanics often uses the natural logarithm, sometimes with a factor kBk_{\mathrm B}. Convert before comparing values.

For a bipartite state,

I(A:B)=S(ρA)+S(ρB)−S(ρAB).I(A:B) = S(\rho_A) + S(\rho_B) - S(\rho_{AB}).

Conditional entropy,

S(A∣B)=S(AB)−S(B),S(A\mid B) = S(AB)-S(B),

can be negative for quantum states. Importing every classical intuition without checking the quantum theorem is unsafe.

An nn-qubit stabilizer group SS is an abelian subgroup of the Pauli group that does not contain −I-I. The projector onto its simultaneous +1+1 eigenspace is

PS=1∣S∣∑g∈Sg.P_S = \frac1{\lvert S\rvert} \sum_{g\in S}g.

If SS has nn independent generators, the code space has dimension one and defines a stabilizer state. If it has r<nr<n independent generators, the code space has dimension

2n−r.2^{n-r}.

State whether Pauli phases {±1,±i}\{\pm1,\pm i\} are retained, quotiented, or represented symplectically. A binary stabilizer table without phase data is insufficient for every update rule.

Before using a matrix formula, record:

  1. Hilbert-space dimension.
  2. Ordered basis.
  3. Tensor-factor order.
  4. Endianness for bit strings.
  5. State-vector or density-matrix convention.
  6. Operator action side and vector orientation.
  7. Fidelity convention.
  8. Entropy logarithm base.
  9. State metric or channel metric.
  10. Any truncation, leakage space, or postselection.

Most apparent disagreements between software libraries reduce to one of these conventions.

  • Density matrices must be Hermitian, positive, and trace one.
  • State vectors must have unit norm.
  • Gates must satisfy U†U=IU^\dagger U=I within tolerance.
  • Channel outputs must retain positivity and the declared trace condition.
  • Computed fidelity and trace distance must lie in [0,1][0,1].
  • Qubit Bloch vectors must obey ∥r∥≤1\lVert\mathbf r\rVert\leq1.
  • Stabilizer generators must commute and exclude −I-I.
  • Entropy eigenvalues must be handled with the limit 0log⁡0=00\log0=0.
  • Tensor permutations must be tested on labeled product basis states.

Never repair a substantial violation by blind clipping or renormalization. Identify whether the cause is numerical tolerance, reconstruction noise, basis mismatch, or an invalid model.

  • Using purity to measure closeness to a target.
  • Reporting fidelity without squared/root convention.
  • Replacing trace norm by Frobenius norm.
  • Calling one-output state fidelity a gate fidelity.
  • Comparing states in different subsystem orders.
  • Treating a reduced state as a full description of correlations.
  • Suppressing identity factors in local operators.
  • Forgetting entropy log base.
  • Assuming conditional entropy is always nonnegative.
  • Ignoring phase conventions in stabilizer arithmetic.
  • Applying single-qubit Bloch formulas to multiqubit states.
  • Confusing postselection with a trace-preserving channel.
  • M. A. Nielsen and I. L. Chuang, Quantum Computation and Quantum Information, 10th anniversary ed., Cambridge University Press, 2010.
  • M. M. Wilde, Quantum Information Theory, 2nd ed., Cambridge University Press, 2017.
  • J. Watrous, The Theory of Quantum Information, Cambridge University Press, 2018.
  • J. Preskill, Lecture Notes for Physics 229: Quantum Information and Computation, California Institute of Technology.