Magic-state injection of a T gate 2026-10-25
Apply a controlled-NOT gate from data to the resource , then measure the resource in the standard basis. Outcome zero leaves data ; outcome one leaves . Both outcomes have probability . Correct outcome one with , using , so the data has undergone the T gate irrespective of the measurement result. The resource is consumed, and its Bloch vector lies outside the stabilizer octahedron.
Squaring the diagonal gate givesThus the T gate is available up to a global phase. Reading the supplied W columns in order , it sends to , to , and fixes the other two vectors: it is CNOT with the second wire controlling the first. Conjugating both wires by the Hadamard gate reverses that orientation:For instance, write . Conjugation uses and , , yielding . Expanding the first-wire Z eigenspaces gives , as required.
We have H directly and finite constructions of CNOT and T up to physically irrelevant global phase. By universality transfer by exact gate synthesis, the assumed universality of proves that is universal under the phase-insensitive convention. There is no assertion of arbitrary strict operator-norm phases: on a fixed register these generators have only a finite set of possible determinants, which would obstruct density in the entire unitary group if global phase were treated as an observable target.
Compute the parity into the second wire, phase that wire with the T gate, then uncompute with the same controlled-NOT gate. The answer isFor computational bits , the successive states are . The parity is one precisely on the two odd-parity inputs. Thus, in the ordered computational basis , the matrix is exactly , with no omitted overall phase. This is a two-qubit parity phase gate.
Here . Both remaining gates fix the all-zero computational vector: the T gate fixes , and the controlled-NOT gate fixes . Therefore every finite circuit, on any number of initially zero wires, leaves unchanged.
It cannot even approximate , whose squared overlap with that unchanged vector is . Thus the gate set is not universal. The needed quantum superposition cannot be created from this input by basis permutations and diagonal phases alone.
The gate set is not universal. The displayed two-qubit matrix is the SWAP gate:Both and the Hadamard gate act on one qubit. Thus every gate preserves a fully factored product state, and induction gives the same property for every quantum circuit built from them. This is the product-state obstruction to SWAP universality.
For a quantitative obstruction to even approximate universality, every two-qubit product state has squared overlap at most with a Bell state. Indeed, for normalized coefficient vectors ,by the Cauchy-Schwarz inequality. A controlled-NOT gate acting on would instead produce that Bell state, so these circuits cannot approximate all unitary transformations. The fact that supplies a T gate up to global phase does not supply an entangling gate.
The gate set is universal. Since the Hadamard gate satisfies and , the supplied is a unitary operator, andTwo applications of therefore realize a Hadamard gate up to a global phase. Together with the supplied controlled-NOT gate and T gate, this simulates the given universal quantum gate set.
An exact matrix representative of can also be synthesized if desired. Put and . Direct multiplication gives , henceThis finite product uses only and , so the conclusion does not rely on discarding a global phase.
In the ordered computational basis , the Pauli X gate, Pauli Y gate, Pauli Z gate, Hadamard gate and T gate areIn the ordered two-qubit computational basis , with the first qubit controlling the second, the controlled-NOT gate isHere the T gate uses the conventional representative with first diagonal entry one; another common representative differs only by a global phase.
Initialize two qubits in . A Hadamard gate on the first followed by a controlled-NOT gate prepares the Bell state . The permitted T gates and Hadamard gates implement the needed Pauli gates exactly:Apply , followed by . These are a Pauli Z gate on the first qubit and a Pauli X gate on the second, givingEvery operation is in the allowed gate set; no quantum measurement or probabilistic branch is needed.
Initialize three qubits in . Apply a Hadamard gate on the first, then controlled-NOT gates and :Apply the T gate twice to the first qubit. Because , the resulting GHZ state with the specified relative quantum phase is
Initialize one qubit in , then apply a Hadamard gate, a T gate, and a Hadamard gate, in that temporal order. Defining the Pauli X eigenstates , the successive quantum states are
Conjugation by the Hadamard gate sends to . Therefore its Bloch vector action isIt is a rotation through about : differs by a global phase from the corresponding spin rotation.
Write and . After the controlled-NOT gate, the joint state isAn ancilla measurement outcome zero leaves the unnormalized data state . Outcome one leaves . Both outcomes have probability . The correction for outcome one is , and , so after correction the data is always , up to an irrelevant global phase. This proves magic-state injection of a T gate.
The resource state's Bloch vector is , outside the stabilizer octahedron. Clifford gates alone preserve stabilizer structure and, with standard-basis preparation and measurement, admit efficient classical simulation by the Gottesman--Knill theorem. Adding the non-Clifford T gate supplies a universal quantum gate set together with Clifford gates: arbitrary finite-qubit unitaries can be approximated to arbitrary precision. The assertion is approximate universality, not exact representation of every unitary by a finite circuit.
A universal quantum gate set can implement any unitary operator on any finite number of qubits, exactly when arbitrary continuous gate parameters are allowed, or to arbitrary accuracy with a suitable finite gate alphabet. More precisely, for every target and there is a finite quantum circuit with in operator norm. This ignores only an overall global phase of the complete operation. Universality lets a fixed collection of controllable elementary operations run arbitrary quantum algorithms rather than requiring a different physical interaction for each algorithm.
All single-qubit unitary gates, together with the controlled-NOT gate between selectable pairs, form an exact universal quantum gate set. One way to see sufficiency is to eliminate entries of a finite unitary matrix by two-level rotations between computational basis vectors; these rotations decompose into controlled single-qubit rotations, which in turn decompose into single-qubit gates and controlled-NOT gates. Single-qubit gates alone preserve product states and cannot supply general quantum entanglement. A finite approximate universal example is the Hadamard gate, the T gate , and the controlled-NOT gate; finite exact words over a finite alphabet cannot represent every continuously parameterized unitary operator exactly.
Distinguish the Hamiltonian operator from the Hadamard gate . For the printed collisional phase gate,As written, has units of energy. The Schrödinger equation givesbecause only has a nonzero energy eigenvalue. In the ordered computational basis , defineIf an interaction strength is instead quoted as an angular frequency , the Hamiltonian operator is and . An alternative definition with would have . The minus sign above follows the usual time-evolution operator convention. At these conventions give the same .
For the quantum circuit, use on the first qubit to move the selective minus sign from to :Conjugating the target of this Controlled-Z gate by the Hadamard gate gives the required controlled-NOT gate:The rightmost matrix acts first. Thus the network applies , then , then , and maps to , where is exclusive or.
Controlled-NOT from the printed collisional phase gate
. Time runs from left to right. Pauli X gates act on the first wire and Hadamard gates on the second, before and after the selective phase gate. The phase gate changes the sign of 01 only. Details.The Hadamard gate H and T gate form a universal quantum gate set for single-qubit operations: finite sequences approximate any target single-qubit unitary arbitrarily well, up to a physically irrelevant global phase. Universality is not a claim that every arbitrary rotation has a finite exact H,T word. With products acting right to left, exact Pauli constructions areIndeed , , and .
Initialize the search register in and the output qubit in , then apply H to all three. The search state becomes , and the output becomes . The oracle obeysThis phase kickback leaves the output qubit factored out, so subsequent analysis can use the phase oracle on the two search qubits alone. Apply one Grover diffusion operator , then measure the search register.
Exact Pauli circuits from H and T, and a two-search-qubit Grover network with a factored output ancilla
. Details. A promise restricts which Boolean functions may be supplied. For the exact one-iteration four-entry search here, promise exactly one marked input. The four functions are precisely when , for . Other known numbers of marked entries require a correspondingly chosen iteration count; uniqueness is the promise for this particular exact circuit.
In basis order , the requested explicit calculation isThus the promised marked entry is found with probability one.
For two weakly coupled spin-half nuclei in nuclear magnetic resonance, a useful rotating-frame Hamiltonian iswhere is in hertz and , . Resonant pulses and refocusing separate local rotations from the scalar coupling. For positive , evolution for supplies . Combining it with local Z phases gives the phase oracleThe scalar global phase is immaterial. Local pulses interchange zero and one, soThis implements the desired change of marked input without an additional output qubit.
A universal quantum gate set can approximate any unitary operation on any finite register, to arbitrary requested accuracy, using a finite sequence of its gates on the register. Unobservable overall global phase is ignored. Approximation matters: a fixed finite alphabet has only countably many finite circuits, whereas there are uncountably many exact unitary matrices.
The Hadamard gate and T gate generate a dense set of single-qubit operations, but cannot themselves entangle different qubits. Adding the controlled-NOT gate gives a universal multi-qubit set. More generally, an available two-qubit gate must be genuinely entangling: it must take at least one product input to an entangled output. A product of local unitaries, or a SWAP gate composed with local unitaries, cannot provide this resource. Together with arbitrary single-qubit control, an entangling two-qubit gate on a connected interaction network supplies universal register control.
A universal quantum gate set can approximate any finite-register unitary operator to arbitrary accuracy, disregarding a common global phase. A finite example is the Hadamard gate, T gate and CNOT gate. In the ordered one-qubit basis ,In the ordered two-qubit basis , with the first qubit the control,The one-qubit gates generate a dense set of one-qubit unitary operators, and CNOT gates supply entangling operations. Approximate universality is the appropriate qualification for a finite discrete set: its finite circuits cannot exactly equal every member of a continuous uncountable unitary group.
An AND gate maps four possible pairs to one bit and loses information, so it is not reversible. A reversible embedding retains both inputs and uses a target bit:This is the Toffoli gate; initializing computes while preserving enough information to invert the operation.
Classical reversible gates on one or two bits alone cannot synthesize every such operation. Every permutation of two bits is an invertible affine map over the finite field : there are of them, exactly the permutations. Their extensions to a larger register and their compositions remain affine. The nonlinear term in the Toffoli gate therefore cannot be generated. Three-bit reversible gates remove this obstruction, with ancillary bits initialized appropriately.
There is no conflict with quantum universality: one- and two-qubit gates may pass through quantum superpositions and use relative phases at intermediate steps. They are not restricted to permutations of computational basis states at every step. For example the Hadamard gate, T gate and CNOT gate can decompose a Toffoli gate exactly. Thus the classical affine obstruction does not apply to their intermediate unitary operators.
Stabilizer octahedron 2026-10-25
The convex hull of the six Pauli eigenstates in the Bloch ball. A mixture has a Bloch vector obeying the displayed inequality. Conversely, assign weights to the corresponding signed vertices and distribute the leftover weight over any opposite pair; this realizes every vector satisfying the inequality. Single-qubit Clifford gates permute its vertices, while a T gate can take a vertex to a pure state outside it.

