Lean, informalized

Nielsen & Chuang · Chapter 5, The quantum Fourier transform and its applications · p. 243

Problem 5.3 - The probability of reading zero on the control, for a unitary and for its powers

A controlled unitary turns an eigenphase into a probability.

Hover over a blue or green term in the text, or a node in the graph, to find it in the other. Select it to read its declaration both in Lean and in words.

The Exercise

A unitary UU acts on a system SS, and |u⟩|u\rangle is an eigenstate of UU with eigenvalue e2πiφe^{2\pi i\varphi} for a real phase φ\varphi. A control qubit is prepared in |0⟩|0\rangle beside the target in |u⟩|u\rangle. A Hadamard gate acts on the control, then UU acts on the target if the control is |1⟩|1\rangle, then a second Hadamard gate acts on the control, and the control is measured in the computational basis. The outcome 00 occurs with probability cos⁡2(πφ)\cos^2(\pi\varphi), and with UkU^k in place of UU it occurs with probability cos⁡2(πkφ)\cos^2(\pi k\varphi).

Systems and States

A quantum system SS is a physical object whose state space is a finite dimensional complex Hilbert space.✦ Any such space is the state space of a system, and the qubit is the two level system whose state space is ℂ2\mathbb{C}^2. The composite system S⊗TS \otimes T of two systems SS and TT is the system whose state space is the tensor product of their state spaces.✦

A pure state |ψ⟩|\psi\rangle of SS is a unit vector in the state space of SS.✦ The basis states |0⟩|0\rangle and |1⟩|1\rangle of the qubit, the computational basis, are the pure states whose vectors are the standard basis vectors e0e_0 and e1e_1 of ℂ2\mathbb{C}^2.✦ For pure states |ψ⟩|\psi\rangle of SS and |χ⟩|\chi\rangle of TT, the product |ψ⟩⊗|χ⟩|\psi\rangle \otimes |\chi\rangle is the pure state of S⊗TS \otimes T whose vector is the tensor product of the two vectors.✦

A state ρ\rho of SS, also called a density operator, is a positive operator of unit trace on the state space of SS.✦ A pure state |ψ⟩|\psi\rangle of SS determines the state |ψ⟩⟨ψ||\psi\rangle\langle\psi| of SS, the projector onto its vector.✦

Gates and the Circuit

A unitary UU of SS is an operator on the state space of SS with U†U=UU†=1U^\dagger U = U U^\dagger = 1.✦ It carries a pure state |ψ⟩|\psi\rangle of SS to the pure state U|ψ⟩U|\psi\rangle.✦ A pure state |ψ⟩|\psi\rangle of SS is an eigenstate of UU with eigenvalue the complex number μ\mu when U|ψ⟩=μ|ψ⟩U|\psi\rangle = \mu|\psi\rangle.✦

The identity evolution of SS is the unitary 11.✦ For two unitaries UU and VV of SS, UU after VV is the unitary UVUV of SS, first VV then UU, and for a natural number kk the power UkU^k applies UU kk times in succession.✦ The product unitary U⊗VU \otimes V of a unitary UU of SS and a unitary VV of TT is the unitary of S⊗TS \otimes T whose operator is the tensor product of the two operators. Acting with a unitary UU of SS on the first factor of S⊗TS \otimes T is the gate U⊗1U \otimes 1, the product unitary of UU and the identity evolution of TT.✦

The Hadamard gate HH is the unitary of the qubit whose matrix in the computational basis is H=12(111−1).H = \frac{1}{\sqrt{2}} \begin{pmatrix} 1 & 1 \\ 1 & -1 \end{pmatrix}.(1)✦ For a unitary UU of SS, the controlled gate C(U)C(U) is the unitary of the composite of the qubit, the control, and SS, the target, with the operator C(U)=|0⟩⟨0|⊗1+|1⟩⟨1|⊗U.C(U) = |0\rangle\langle 0| \otimes 1 + |1\rangle\langle 1| \otimes U .(2) For a unitary UU of SS, the circuit W(U)W(U) of the exercise is the unitary of the composite of the qubit and SS given by W(U)=(H⊗1)C(U)(H⊗1)W(U) = (H \otimes 1)\, C(U)\, (H \otimes 1)(3)

Measuring the Control

A measurement MM on SS with a finite set of outcomes ι\iota is a family of operators MiM_i on the state space of SS, one for each outcome i∈ιi \in \iota, satisfying the completeness relation ∑iMi†Mi=1.\sum_i M_i^\dagger M_i = 1 .(4) The effects of the measurement are the positive operators Ei=Mi†MiE_i = M_i^\dagger M_i; together they form its positive operator valued measure (POVM).

In a state ρ\rho of SS, a measurement MM on SS gives the outcome ii with probability, by the Born rule, p(i)=Tr⁡(Eiρ)=Tr⁡(MiρMi†).p(i) = \operatorname{Tr}(E_i \rho) = \operatorname{Tr}(M_i \rho M_i^\dagger) .(5)✦

The projective measurement of SS in an orthonormal basis {|bi⟩}\{|b_i\rangle\} of its state space is the measurement whose operator for the outcome ii is the projector |bi⟩⟨bi||b_i\rangle\langle b_i|.✦ For a measurement with operators MiM_i on SS and a further system TT, the measurement on the first factor of S⊗TS \otimes T has the same outcomes and the operators Mi⊗1M_i \otimes 1.✦ The measurement of the control is the projective measurement of the qubit in the computational basis, performed on the first factor of the composite of the qubit and SS: its operators are |0⟩⟨0|⊗1|0\rangle\langle 0| \otimes 1 and |1⟩⟨1|⊗1|1\rangle\langle 1| \otimes 1.✦

The Claim

Theorem 1. Let UU be a unitary of a system SS, let φ\varphi be a real number, and let |u⟩|u\rangle be a pure state of SS that is an eigenstate of UU with eigenvalue e2πiφe^{2\pi i\varphi}. Let |ψ⟩=W(U)(|0⟩⊗|u⟩)|\psi\rangle = W(U)\,(|0\rangle \otimes |u\rangle). Then the measurement of the control, performed on the state |ψ⟩⟨ψ||\psi\rangle\langle\psi|, gives the outcome 00 with probability p(0)=cos⁡2(πφ).p(0) = \cos^2(\pi\varphi) .(6)✦ For every natural number kk, with W(Uk)W(U^k) in place of W(U)W(U), the outcome 00 has probability p(0)=cos⁡2(πkφ).p(0) = \cos^2(\pi k \varphi) .(7)✦

What Is Checked

The claim is stated over the circuit (3), built from the Hadamard gate (1) on the first factor and the controlled gate (2), acting on the product state |0⟩⊗|u⟩|0\rangle \otimes |u\rangle, and over the Born probability (5) of the measurement of the control in the state that the circuit produces.

About these constructions the library proves that the operator (2) is unitary, so that C(U)C(U) is a gate, and that the Hadamard matrix, composites of unitaries and their tensor products are unitary, so that W(U)W(U) is a unitary of the composite. It proves that the projectors onto an orthonormal basis, and with them the operators |i⟩⟨i|⊗1|i\rangle\langle i| \otimes 1, for i=0,1i = 0, 1, of the measurement of the control, satisfy the completeness relation (4), and that |ψ⟩⟨ψ||\psi\rangle\langle\psi| is a density operator.