13.2 A quantum logic gate 287
13.2 A quantum logic gate
Quantum computing uses nothing more than standard quantum mechan-
ics but it combines operations on the qubits and quantum measurements
in sophisticated ways to give amazingly powerful new methods for com-
putation. Here we consider just one example of the transformations of
the qubits, or quantum logic gates, that form the elementary building
blocks (primitives) of a quantum computer. The controlled-NOT gate
(CNOT) transforms two qubits, as shown in Table 13.1.
The CNOT gate changes the value of the second qubitif and only
ifthe first qubit has the value 1. The first qubit controls the effect
of the gate on the second qubit. The truth Table 13.1 looks the same
as that for ordinary logic, but a quantum logic gate corresponds to
an operation that preserves the superposition of the input states. The
quantum mechanical operator of the CNOT gateUˆCNOTacts on the
wavefunction of the two qubits to give
UˆCNOT{A| 00 〉+B| 01 〉+C| 10 〉+D| 11 〉}
→A| 00 〉+B| 01 〉+C| 11 〉+D| 10 〉.
(13.11)
Alternatively, the effect of this operation can be written as| 10 〉↔| 11 〉,
with the other states unchanged. The complex numbersA,B,CandD
represent the phase and relative amplitude of states within the super-
position.
13.2.1 Making a CNOT gate
The CNOT gate is elementary but it turns out not to be the simplest
gate to make in an ion trap quantum processor—it requires a sequence
of several operations, as described in Steane (1997). So, despite the
fact that quantum computing has been introduced into this book as an
application of ion trapping, this section explains how to make a quan-
tum logic gate for two spin-1/2 particles. This two-qubit system is not
just a convenient theoretical case, but corresponds to actual quantum
computing experiments carried out with the nuclear magnetic resonance
(NMR) technique. Figure 13.4 shows the energy levels of the two inter-
acting spins.
We do not need to go into all the details of how this energy-level struc-
ture arises to understand how to make a CNOT gate, but it is important
Table 13.1Truth table of the CNOT quantum logic gate.
| 00 〉→| 00 〉
| 01 〉→| 01 〉
| 10 〉→| 11 〉
| 11 〉→| 10 〉