The Exercise
Take a register of qubits and a unitary gate that, under conjugation, sends every Pauli operator on the register, phase included, to a Pauli operator. The exercise is to build , up to a global phase, from Hadamard gates, phase gates and controlled NOT (CNOT) gates, with a number of gates of order . On a single qubit, Hadamard and phase gates are enough.
The library states both claims.
The Pauli Group
The Pauli matrices are the four complex matrices, with rows and columns indexed by , given by the identity and the matrices , and : (1)✦
For a choice of one Pauli matrix per qubit, the Pauli string is the operator on the qubits whose matrix, with rows and columns indexed by bit strings , has the entries (2)✦
The Pauli group on qubits consists of the operators (3)✦ each fixed by its phase power , an integer modulo , and its Pauli string . The phase is raised to the representative of in , one of the four fourth roots of unity.✦
The Pauli normalizer is the set of unitary matrices on the qubits such that for every there is a with (4)✦
Clifford Circuits
An elementary Clifford gate on a register of qubits, whose wires carry the qubits one each, is a Hadamard gate on a wire , a phase gate on a wire , or a CNOT with control wire and target wire distinct from .✦ The matrix of a Hadamard or phase gate acts as or on qubit , that of a CNOT acts as CNOT on qubits and , and each acts as the identity on the remaining qubits.✦
A Clifford circuit on the register is a finite sequence of elementary Clifford gates, of length .✦ Its matrix is the product of the matrices of its gates, the last gate acting first: (5)
The Claim
Theorem 1. Let be an element of the Pauli normalizer on qubits. Then there are a Clifford circuit on the qubits and a complex number with such that (6)✦
Theorem 2. Let be an element of the Pauli normalizer on one qubit. Then there are a Clifford circuit on that qubit and a complex number with such that (7)✦
What Is Checked
Both theorems are stated over the Pauli normalizer (4), built on the Pauli group (3) and the Pauli matrices (1), and over the matrix (5) of a circuit of Hadamard, phase and CNOT gates together with its length.