Lean, informalized

Nielsen & Chuang · Chapter 10, Quantum error-correction · p. 460

Exercise 10.36 - Conjugation by the controlled NOT gate on XX and ZZ of either qubit, as identities of matrices

How CNOT conjugates the Pauli operators of two qubits.

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

Two qubits pass through a controlled NOT (CNOT) gate UU, the first qubit as control and the second as target. On the pair act the Pauli operators X1X_1 and Z1Z_1 on the first qubit and X2X_2 and Z2Z_2 on the second. The exercise is to compute the image of each of the four under conjugation by the gate, g↦UgU†g \mapsto U g U^\dagger with U†U^\dagger the adjoint of UU, and to write it as a product of the same four operators.

Conjugation says how an operator applied before the gate looks after it.

Two Qubits

The 4×44 \times 4 matrix of an operator MM on two qubits, whose rows and columns are labelled by pairs of bits (i,j)(i, j), is MM with both relabelled through (i,j)↦2i+j(i, j) \mapsto 2i + j, so that they follow the computational basis in the order |00⟩,|01⟩,|10⟩,|11⟩.|00\rangle, \quad |01\rangle, \quad |10\rangle, \quad |11\rangle .(1)✦

On a single qubit, the identity II, the bit flip XX and the phase flip ZZ are the complex 2×22 \times 2 matrices I=(1001),X=(0110),Z=(100−1)I = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix}, \qquad X = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix}, \qquad Z = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix}(2) in the basis |0⟩,|1⟩|0\rangle, |1\rangle.

A Pauli operator on one qubit of the pair is the tensor product of XX or ZZ on that qubit with II on the other, written as a 4×44 \times 4 matrix in the order (1): X1=X⊗I,X_1 = X \otimes I ,(3)✦ X2=I⊗X,X_2 = I \otimes X ,(4)✦ Z1=Z⊗I,Z_1 = Z \otimes I ,(5)✦ Z2=I⊗Z.Z_2 = I \otimes Z .(6)✦

The CNOT gate UU with the first qubit as control is the 4×44 \times 4 matrix that exchanges |10⟩|10\rangle and |11⟩|11\rangle and fixes |00⟩|00\rangle and |01⟩|01\rangle, so that it flips the second qubit exactly when the first is 11: U=(1000010000010010).U = \begin{pmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \end{pmatrix} .(7)✦

The Claim

Theorem 1. Let UU be the CNOT gate (7) and let X1X_1, X2X_2, Z1Z_1 and Z2Z_2 be the Pauli operators (3), (4), (5) and (6). Then UX1U†=X1X2,U X_1 U^\dagger = X_1 X_2 ,(8)✦ UX2U†=X2,U X_2 U^\dagger = X_2 ,(9)✦ UZ1U†=Z1,U Z_1 U^\dagger = Z_1 ,(10)✦ and UZ2U†=Z1Z2.U Z_2 U^\dagger = Z_1 Z_2 .(11)✦

What Is Checked

The claim is stated over the matrix UU of the CNOT gate (7) and the four Pauli operators (3), (4), (5) and (6), each a tensor product of matrices from (2) written in the order (1).

About these matrices the library proves the four relations (8), (9), (10) and (11), each an equality of complex 4×44 \times 4 matrices.