In Chapter 5, we formulated quantum computation and traced circuits acting on a single qubit. Useful computations, however, require registers of many qubits. While Chapter 4 introduced the state space of a composite system, we now need to see how gates and measurements act on multi-qubit registers.
We first describe multi-qubit states and gates using tensor products and distinguish independent qubits from entangled ones. We then explore the physical consequences of multi-qubit states for copying, communication, and evaluating functions.
How do gates and measurements act on a register of qubits?
A single qubit has two basis configurations, \(\ket{0}\) and \(\ket{1}\), and its state is specified by two complex amplitudes. When two qubits are combined into a register, there are four basis configurations—\(\ket{00}, \ket{01}, \ket{10}, \ket{11}\)—and four complex amplitudes.
If two qubits are prepared independently in states \(\alpha\ket{0}+\beta\ket{1}\) and \(\gamma\ket{0}+\delta\ket{1}\), how are the four amplitudes of the combined register related to the amplitudes of the individual qubits—and can every two-qubit state be formed this way?
Reading guide · preparation, aims, and assumptions
Extend the single-qubit model to computations on joint registers, including measurement and classical control.
Before you begin
Use the state and composition rules of Chapter 4 and the single-qubit circuits of Chapter 5.
What you should be able to do
Track joint amplitudes through local and controlled gates.
Calculate joint, marginal, and conditional measurement probabilities.
Distinguish entanglement from classical correlation and explain the limits on copying and signalling.
Follow teleportation through all four outcomes and corrections.
Explain what one parallel evaluation of a function produces, and why a measurement reveals only one input–value pair.
The example to follow
Compute a two-qubit circuit, prepare and test a Bell state, use a shared pair in teleportation, then evaluate AND on all four inputs at once.
Scope and assumptions
Teleportation transfers a state using shared entanglement and classical communication; it does not transmit a controllable signal faster than light.
6.1
Registers and Operations
The composite-state postulate of Chapter 4 tells us what states a multi-qubit register can occupy. To build computations on a register, we must establish a standard basis for \(n\) qubits, recognize when qubits remain statistically and quantum-mechanically independent, count how many amplitudes a general register state requires, and see how both single-qubit local gates and two-qubit controlled gates transform the register.
When a computational problem takes an \(n\)-bit input string, our quantum computer uses an \(n\)-qubit register. How do we write the basis states of \(n\) qubits? For two qubits, we saw in Section 4.2.3 that the composite-state postulate assigns an amplitude to each two-bit configuration, and that two independently prepared qubits combine via the tensor product:
Adding a third qubit—or \(n\) qubits in general—simply repeats the tensor product. For each \(n\)-bit string \(x = x_1x_2\cdots x_n \in \{0,1\}^n\), the corresponding computational basis vector of the register is the tensor product of the individual qubit basis states:
These \(2^n\) mutually orthogonal unit vectors form the product basis (or computational basis) of the \(n\)-qubit register. By convention, the leftmost bit \(x_1\) labels the first (topmost) qubit, so \(\ket{01}\) means qubit \(1\) is in \(\ket{0}\) and qubit \(2\) is in \(\ket{1}\), and we order the basis configurations in standard binary order (\(00, 01, 10, 11\) for two qubits).
In addition to the qubits that hold the problem input, a quantum register often includes extra working qubits called ancillas, initialized in \(\ket{0}\), just like the scratchpad bits of our reversible circuits in Chapter 2. Preparing ancillas and resetting them via uncomputation are part of the algorithm's total cost.
In a multi-qubit circuit diagram, each qubit has its own horizontal wire, ordered from qubit \(1\) at the top to qubit \(n\) at the bottom. A gate box placed on a single wire acts on that qubit alone, whereas a gate spanning multiple wires couples those qubits together. When a wire is drawn with a diagonal slash through it (sometimes labeled with an integer \(n\)), it represents an entire bundle of \(n\) qubit wires drawn compactly as a single line.
A and B are single-qubit preparation unitaries. Their independent actions give the four joint amplitudes ac, ad, bc, bd; each box can require several elementary gates.Problems
Compute \(\bigl(\tfrac1{\sqrt2},\tfrac1{\sqrt2}\bigr)^T\otimes(1,0)^T\) and \(\bigl(\tfrac35,\tfrac45\bigr)^T\otimes(0,1)^T\).
Show solutionHide solution
Each joint amplitude is a product of local amplitudes, in the order \(00,01,10,11\): the first is \(\bigl(\tfrac1{\sqrt2},0,\tfrac1{\sqrt2},0\bigr)^T\), and the second is \(\bigl(0,\tfrac35,0,\tfrac45\bigr)^T\).
Compute \((H\otimes I)\ket{01}\) and \((I\otimes H)\ket{01}\).
Show solutionHide solution
\((H\otimes I)\ket{01}=(H\ket0)\otimes\ket1=(\ket{01}+\ket{11})/\sqrt2\). \((I\otimes H)\ket{01}=\ket0\otimes(H\ket1)=(\ket{00}-\ket{01})/\sqrt2\). The same gate on a different qubit gives a different joint state.
Show that \(\braket{a\otimes b}{c\otimes d}=\braket ac\braket bd\) for vectors of two coordinates, and deduce that the tensor product of two unit vectors is a unit vector.
Show solutionHide solution
The coordinates of \(a\otimes b\) are \(a_ib_j\), so \[\braket{a\otimes b}{c\otimes d}=\sum_{i,j}(a_ib_j)^*c_id_j\]\[=\Bigl(\sum_ia_i^*c_i\Bigr)\Bigl(\sum_jb_j^*d_j\Bigr)=\braket ac\braket bd.\] With \(c=a\) and \(d=b\), \(\|a\otimes b\|^2=\|a\|^2\|b\|^2=1\) for unit vectors.
When can an \(n\)-qubit register be described by assigning each qubit its own individual state vector? Precisely when the joint state vector factors into a tensor product of single-qubit states, \(\ket{\psi_1}\otimes\ket{\psi_2}\otimes\cdots\otimes\ket{\psi_n}\). As we saw for two qubits in Section 4.2.3, such a state is called a product state. In a product state, every joint amplitude is the product of the corresponding single-qubit amplitudes, which guarantees that measurements on different qubits are statistically independent.
How can we tell from a list of joint amplitudes whether a state is a product state? Do not be fooled by how many basis terms appear in the superposition! A state with two or four nonzero computational-basis terms can still be a simple product state. For example, \((\ket{00}+\ket{10})/\sqrt{2}\) is a superposition of two bit strings, yet factoring out \(\ket{0}\) on the second qubit reveals
meaning the first qubit is in \(\ket{+}\) and the second is definitely in \(\ket{0}\). Even a state in which all four two-qubit basis configurations have nonzero amplitudes can be a product state:
Here, measuring the first qubit yields \(0\) with probability \(3/4\) regardless of what happens to the second qubit, and measuring the second yields \(0\) or \(1\) with probability \(1/2\) regardless of the first. Whether a two-qubit state \(c_{00}\ket{00} + c_{01}\ket{01} + c_{10}\ket{10} + c_{11}\ket{11}\) factors into \((a\ket{0}+b\ket{1})\otimes(c\ket{0}+d\ket{1})\) depends not on how many amplitudes are nonzero, but on whether the amplitudes satisfy the factorization test \(c_{00}c_{11} = c_{01}c_{10}\). When they do, the qubits are independent; when they do not, the state is entangled.
H acts only on the first wire; the second remains zero. The output is a product despite having two nonzero joint amplitudes.Problems
Is \((\ket{00}+\ket{01}+\ket{10}+\ket{11})/2\) a product state? If so, factor it.
Show solutionHide solution
Yes: \(\tfrac{\ket0+\ket1}{\sqrt2}\otimes\tfrac{\ket0+\ket1}{\sqrt2}=\ket+\ket+\). Every product of the local amplitudes \(1/\sqrt2\) is \(1/2\).
Factor \((\ket{00}-\ket{01}+\ket{10}-\ket{11})/2\), and find the probability that the second qubit gives \(0\).
Show solutionHide solution
The sign depends only on the second label, so the state is \(\tfrac{\ket0+\ket1}{\sqrt2}\otimes\tfrac{\ket0-\ket1}{\sqrt2}=\ket+\ket-\). The second qubit gives \(0\) with probability \(1/2\).
Show that a two-qubit state with amplitudes \(\alpha_{00},\alpha_{01},\alpha_{10},\alpha_{11}\) is a product state exactly when \(\alpha_{00}\alpha_{11}=\alpha_{01}\alpha_{10}\).
Show solutionHide solution
For a product \((a\ket0+b\ket1)\otimes(c\ket0+d\ket1)\), \(\alpha_{00}\alpha_{11}=acbd=adbc=\alpha_{01}\alpha_{10}\). Conversely, suppose the condition holds. If \(\alpha_{00}\neq0\), then \((\alpha_{00}\ket0+\alpha_{10}\ket1)\otimes(\ket0+\tfrac{\alpha_{01}}{\alpha_{00}}\ket1)\) has amplitudes \(\alpha_{00},\alpha_{01},\alpha_{10}\), and \(\alpha_{10}\alpha_{01}/\alpha_{00}=\alpha_{11}\). If \(\alpha_{00}=0\), the condition gives \(\alpha_{01}\alpha_{10}=0\): if \(\alpha_{01}=0\) the state is \(\ket1\otimes(\alpha_{10}\ket0+\alpha_{11}\ket1)\), and if \(\alpha_{10}=0\) it is \((\alpha_{01}\ket0+\alpha_{11}\ket1)\otimes\ket1\).
How many complex numbers are required to specify the state of an \(n\)-qubit register? By the composite-state postulate, any normalized superposition of the \(2^n\) product-basis states is a valid physical state:
Thus a general \(n\)-qubit state vector carries \(2^n\) complex amplitudes—one for every \(n\)-bit string \(x\). By contrast, an \(n\)-qubit product state \(\ket{\psi_1}\otimes\cdots\otimes\ket{\psi_n}\) is completely specified by giving two amplitudes for each qubit, or just \(2n\) complex numbers in total. Each additional qubit doubles the dimension \(2^n\) of the full state space while adding only \(2\) coordinates to a product-state description.
Does measuring an \(n\)-qubit register read out those \(2^n\) complex amplitudes? Never. A computational-basis measurement of all \(n\) qubits returns a single \(n\)-bit string \(x\) with probability \(|c_x|^2\)—just \(n\) classical bits of output from a state vector of \(2^n\) complex numbers.
Simulating a general \(n\)-qubit circuit by tracking all \(2^n\) amplitudes on a classical computer quickly becomes prohibitive: \(30\) qubits require more than a billion complex numbers, and \(300\) qubits require more amplitudes than there are atoms in the observable universe. Yet the sheer size of the state space does not automatically make a quantum computer fast: because readout yields only \(n\) bits, an algorithm achieves a speedup only when it uses interference to concentrate probability onto the specific \(n\)-bit string that answers the problem.
A joint unitary updates four amplitudes on two qubits, but measurement returns a single pair of bits. U denotes the complete operation, not a free elementary gate.Problems
How many amplitudes describe a general state of \(10\) qubits? How many bits does a measurement of all \(10\) qubits return?
Show solutionHide solution
\(2^{10}=1024\) amplitudes, but a measurement returns only \(10\) bits.
A classical simulation stores each amplitude as two \(8\)-byte numbers. How much memory does a general \(40\)-qubit state need?
Show solutionHide solution
\(2^{40}\cdot16\) bytes \(\approx1.8\times10^{13}\) bytes, about \(18\) terabytes. Each additional qubit doubles this.
A product state of \(n\) qubits is described by \(n\) pairs of amplitudes. Show that applying one one-qubit operation to each qubit of a product state can be simulated with work proportional to \(n\). What does this show about the size of the state space as a source of difficulty?
Show solutionHide solution
\((U_1\otimes\cdots\otimes U_n)(\ket{\psi_1}\otimes\cdots\otimes\ket{\psi_n})=U_1\ket{\psi_1}\otimes\cdots\otimes U_n\ket{\psi_n}\), so it suffices to multiply each \(2\times2\) matrix by its pair of amplitudes: \(n\) small multiplications. The state space has \(2^n\) dimensions, yet this computation is easy to simulate. Difficulty requires entangling operations, not a large state space alone.
When we apply a single-qubit gate \(U\) to the first wire of a two-qubit register and do nothing (\(I\)) to the second wire, how does the combined operation transform the four-dimensional state space? It updates the first bit label according to the arrows of \(U\) while leaving the second bit label untouched: for each value \(b\in\{0,1\}\) of the second qubit, the transition amplitude from \(\ket{ib}\) to \(\ket{jb}\) is simply \(\bra{j}U\ket{i}\). We write this tensor-product operator as \(U\otimes I\). Acting on a product state, each operator acts independently on its own slot:
More generally, applying \(U\) to the first qubit and \(V\) to the second is written \(U\otimes V\), which maps \(\ket{\psi}\otimes\ket{\phi}\) to \((U\ket{\psi})\otimes(V\ket{\phi})\); when the same gate \(H\) is applied to each of \(n\) qubits, we write \(H^{\otimes n}\). Gates that act on individual wires separately are called local gates. Because local gates on distinct wires operate on independent subsystems, hardware can execute them in parallel during a single time step.
Can local gates ever entangle two initially independent qubits? The equation \((U\otimes V)(\ket{\psi}\otimes\ket{\phi}) = (U\ket{\psi})\otimes(V\ket{\phi})\) immediately says no: any tensor product of local gates sends every product state to another product state. To create correlations or entanglement between wires, a circuit needs a multi-qubit gate whose action on one qubit depends on the state of another.
The fundamental two-qubit coupling gate is the controlled-NOT, or CNOT, which we met for classical reversible bits in Chapter 2. With the first qubit as the control and the second as the target, CNOT acts on the computational basis states by flipping the target bit if and only if the control bit is \(1\):
where \(\oplus\) is addition modulo \(2\) (XOR). In a circuit diagram, CNOT is drawn as a filled dot on the control wire connected by a vertical line to a \(\oplus\) symbol on the target wire. Remember that the control dot is not a measurement: CNOT is a coherent linear operator that applies this basis rule simultaneously to every branch of a superposition.
Written as a \(4\times 4\) matrix in the basis order \(00, 01, 10, 11\), CNOT leaves the first two coordinates (\(\ket{00}\) and \(\ket{01}\)) unchanged and swaps the last two coordinates (\(\ket{10}\) and \(\ket{11}\)):
Because permuting coordinates preserves vector lengths and swapping twice restores the original column, CNOT is unitary and equals its own inverse (\(\operatorname{CNOT}^2 = I\)). More generally, for any single-qubit unitary \(U\), a controlled gate (controlled-\(U\)) applies the identity \(I\) to the target wire on branches where the control is \(\ket{0}\) and applies \(U\) to the target wire on branches where the control is \(\ket{1}\).
Let us trace a two-qubit circuit that combines local gates and a CNOT. Starting from \(\ket{00}\), apply \(H\) to the top wire and \(X\) to the bottom wire in parallel:
If we measured both qubits right now, we would obtain \(01\) or \(11\) with probability \(1/2\) each—the second bit would always be \(1\). Instead, apply CNOT before measuring: the branch \(\ket{01}\) (control \(0\)) stays \(\ket{01}\), while \(\ket{11}\) (control \(1\)) flips its target to become \(\ket{10}\), producing \((\ket{01}+\ket{10})/\sqrt{2}\). Now measuring both qubits yields \(01\) or \(10\) with probability \(1/2\) each, so the two bits are guaranteed to be opposite!
Algebraically, the full unitary evolution before measurement is \(U = \operatorname{CNOT}(H\otimes X)\), read right to left. This circuit uses two qubits (its width) and three elementary gates (\(H\), \(X\), and CNOT). Because \(H\) and \(X\) act on separate wires during the first time step and CNOT acts in the second time step, the circuit has two sequential gate layers—a quantity called the circuit depth.
A two-qubit circuit read from left to right. In the first layer, the local gates \(H\) and \(X\) act in parallel on separate wires; in the second layer, CNOT couples the control and target wires; finally, computational-basis measurements (\(\mathrm{M}\)) output classical bits on double lines.Problems
Apply CNOT to \((\ket{00}+i\ket{11})/\sqrt2\). What are the measurement probabilities?
Show solutionHide solution
CNOT fixes 00 and exchanges 11 with 10, giving \((\ket{00}+i\ket{10})/\sqrt2\). Outcomes 00 and 10 each have probability \(1/2\); the phase does not change this immediate readout.
In the circuit above, move CNOT before both local gates. Starting from \(\ket{00}\), calculate the output and compare the measured bit pairs.
Show solutionHide solution
CNOT first leaves 00 unchanged. The local gates then give \((\ket{01}+\ket{11})/\sqrt2\). The second bit is always 1, unlike the original order, whose outcomes 01 and 10 always disagree. Gate order matters.
Can local gates alone turn a product state into an entangled state? Use \((U\otimes V)(\ket\psi\otimes\ket\phi)\) to justify your answer.
Show solutionHide solution
The output is \((U\ket\psi)\otimes(V\ket\phi)\), still a product. Repeating local gates cannot change that. A joint gate is needed to create entanglement from a pure product input; even a joint gate need not entangle every input.
6.2
Entangled States
Local gates preserve product states, whereas CNOT can couple two wires into a non-factorizable superposition. In this section, we use a Hadamard gate and a CNOT gate to prepare the canonical two-qubit entangled state—a Bell state—verify algebraically why its amplitudes cannot factor into separate single-qubit states, and show how measuring in rotated bases distinguishes genuine quantum entanglement from a classical coin-flip mixture.
Suppose we start two qubits in the product state \(\ket{00}\), apply a Hadamard gate \(H\) to the first qubit, and then apply CNOT with the first qubit as control and the second as target. Let us follow the state vector step by step:
First, \(H\otimes I\) puts the control qubit into \(\ket{+}\) while leaving the target in \(\ket{0}\), giving the product state \((\ket{00}+\ket{10})/\sqrt{2}\). Second, CNOT acts linearly on the two branches: it leaves \(\ket{00}\) unchanged (since the control bit is \(0\)) and flips the target of \(\ket{10}\) to produce \(\ket{11}\) (since the control bit is \(1\)):
This famous two-qubit state is called a Bell state (or EPR pair), denoted \(\ket{\Phi^+}\).
Notice again that the vertical control line of CNOT does not measure the first qubit to decide whether to flip the second. Because CNOT acts coherently on both branches of the superposition without recording which branch was taken outside the pair, the output is the single coherent superposition \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\), rather than a random choice between \(\ket{00}\) and \(\ket{11}\).
Preparing the Bell state \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\): apply \(H\) to the first qubit of \(\ket{00}\), followed by CNOT from the first qubit to the second.
Interactive figure. This circuit stepper prepares a two-qubit state from \(\ket{00}\) using a Hadamard gate \(H\) on the first qubit followed by a CNOT gate. Step through the two gates to compare the intermediate product state with the final correlated outcome probabilities.
What to observe
After \(H\), outcomes \(00\) and \(10\) each have probability \(1/2\). The CNOT gate flips the target when the control is \(1\), turning \(10\) into \(11\) and leaving \(00\) and \(11\) with probability \(1/2\) each.
Problems
Apply \(H\) to the first qubit of \(\ket{10}\), then CNOT with the first qubit as control. Which state results?
Show solutionHide solution
\(H\ket1=(\ket0-\ket1)/\sqrt2\), giving \((\ket{00}-\ket{10})/\sqrt2\). CNOT sends \(10\) to \(11\), so the result is \((\ket{00}-\ket{11})/\sqrt2\), the Bell state \(\ket{\Phi^-}\).
Apply the same circuit to \(\ket{01}\) and to \(\ket{11}\).
Show solutionHide solution
From \(\ket{01}\): \((\ket{01}+\ket{11})/\sqrt2\to(\ket{01}+\ket{10})/\sqrt2\), the Bell state \(\ket{\Psi^+}\). From \(\ket{11}\): \((\ket{01}-\ket{11})/\sqrt2\to(\ket{01}-\ket{10})/\sqrt2\), the Bell state \(\ket{\Psi^-}\).
Show that the four states produced from \(\ket{00},\ket{01},\ket{10},\ket{11}\) form an orthonormal basis, and give a circuit that turns each of them back into its label.
Show solutionHide solution
The circuit is unitary, and a unitary preserves inner products, so it maps the orthonormal computational basis to an orthonormal set of four vectors in a four-dimensional space: a basis, the Bell basis. The inverse circuit undoes the gates in reverse order: CNOT, then \(H\) on the first qubit, since each is its own inverse. Followed by a computational-basis measurement, it identifies which Bell state was present.
Why is \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\) an entangled state rather than a product state? As we checked in Section 4.2.3, any two-qubit product state \((a\ket{0}+b\ket{1})\otimes(c\ket{0}+d\ket{1})\) has amplitudes \(c_{00}=ac\), \(c_{01}=ad\), \(c_{10}=bc\), and \(c_{11}=bd\), which must satisfy \(c_{00}c_{11} = c_{01}c_{10}\). For \(\ket{\Phi^+}\), we have \(c_{00}c_{11} = (1/\sqrt{2})(1/\sqrt{2}) = 1/2\), whereas \(c_{01}c_{10} = 0\cdot 0 = 0\). No choice of single-qubit amplitudes \(a, b, c, d\) can make \(ac\) and \(bd\) nonzero while keeping \(ad\) and \(bc\) zero!
Look at where entanglement entered the circuit: after the local gate \(H\otimes I\), the state \((\ket{0}+\ket{1})/\sqrt{2}\otimes\ket{0}\) was still a product state. It was the two-qubit CNOT gate that turned the local superposition of the control qubit into a non-factorizable joint superposition of the pair.
In an entangled state like \(\ket{\Phi^+}\), the two-qubit register as a whole has a completely definite unit state vector, allowing us to calculate the probability of any joint or single-qubit measurement. What fails is any attempt to assign a standalone single-qubit state vector to qubit \(1\) and another to qubit \(2\).
Does observing perfectly correlated bits (\(00\) half the time and \(11\) half the time) in the computational basis prove that two qubits are in the state \(\ket{\Phi^+}\)? Not by itself! Suppose someone flips a fair classical coin and prepares the product state \(\ket{00}\) on heads or the product state \(\ket{11}\) on tails. In such a classical mixture, each run contains a definite basis state (\(\ket{00}\) or \(\ket{11}\)), and we average classical probabilities across runs rather than adding amplitudes within a single state. Yet measuring that classical mixture in the computational basis yields \(00\) with probability \(1/2\) and \(11\) with probability \(1/2\)—the exact same histogram as \(\ket{\Phi^+}\). To expose the coherent superposition linking \(\ket{00}\) and \(\ket{11}\) in \(\ket{\Phi^+}\), we must measure in a second basis.
Before CNOT the two wires have a product state. After it, the coefficients of 00 and 11 are nonzero while those of 01 and 10 vanish; no product of two local vectors has these coefficients.Problems
Is \((\ket{00}+\ket{01}+\ket{10}-\ket{11})/2\) entangled?
Show solutionHide solution
A product would need \(ac=ad=bc=1/2\) and \(bd=-1/2\). Then \((ac)(bd)=-1/4\) while \((ad)(bc)=1/4\), but both equal \(abcd\). So no product exists: the state is entangled.
For which real numbers \(\varepsilon\) is \((\ket{00}+\varepsilon\ket{11})/\sqrt{1+\varepsilon^2}\) a product state?
Show solutionHide solution
The product condition \(\alpha_{00}\alpha_{11}=\alpha_{01}\alpha_{10}\) reads \(\varepsilon=0\) (up to the common normalization). Only \(\varepsilon=0\), the state \(\ket{00}\), is a product. However small \(\varepsilon\neq0\) is, the state is entangled, though only slightly.
For a two-qubit state in which both outcomes of the first qubit are possible, measure the first qubit in the computational basis. Show that the state is entangled exactly when the conditional state of the second qubit depends on the outcome.
Show solutionHide solution
After outcome \(0\), the second qubit is proportional to \(\alpha_{00}\ket0+\alpha_{01}\ket1\); after outcome \(1\), to \(\alpha_{10}\ket0+\alpha_{11}\ket1\). These describe the same state exactly when the two vectors are proportional, that is, when \(\alpha_{00}\alpha_{11}=\alpha_{01}\alpha_{10}\), which is the product condition. So the conditional state is the same for both outcomes exactly when the state is a product.
6.2.3 Joint, marginal, and conditional probabilities§
joint probability · marginal · conditional probability
Even when a two-qubit state \(\ket{\Psi} = \sum_{a,b\in\{0,1\}} c_{ab}\ket{ab}\) is entangled, all outcome probabilities follow directly from the Born rule. Measuring both qubits in the computational basis yields the outcome pair \((a,b)\) with joint probability \(p(a,b) = |c_{ab}|^2\). The probability that the first qubit yields outcome \(a\) regardless of what happens to the second is the marginal probability, obtained by summing over the second qubit's outcomes: \(p(a) = \sum_{b\in\{0,1\}} p(a,b) = |c_{a0}|^2 + |c_{a1}|^2\). And once the first qubit is observed to give outcome \(a\) (with \(p(a) > 0\)), the conditional probability that the second qubit yields \(b\) is \(p(b\mid a) = p(a,b)/p(a)\).
For the Bell state \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\), the joint probabilities are \(p(0,0) = 1/2\) and \(p(1,1) = 1/2\) (with \(p(0,1)=p(1,0)=0\)). Each qubit's marginal distribution is completely uniform—\(p(a=0) = 1/2\) and \(p(a=1) = 1/2\)—yet the conditional probabilities are completely locked together: \(p(b=0\mid a=0) = 1\) and \(p(b=1\mid a=1) = 1\).
What happens to the two-qubit state vector if we measure only the first qubit and obtain outcome \(a\)? Just as for a single qubit, we project onto the subspace consistent with the observed outcome—retaining all terms whose first bit is \(a\) and discarding the rest—and renormalize by dividing by \(\sqrt{p(a)}\). For example, if a register is in the state \((\ket{00}+\ket{01}+\ket{11})/\sqrt{3}\) and a measurement of the first qubit yields \(0\) (which occurs with marginal probability \(p(a=0) = 1/3 + 1/3 = 2/3\)), the post-measurement state collapses to \((\ket{00}+\ket{01})/\sqrt{2} = \ket{0}\otimes\ket{+}\).
Now let us see how measuring both qubits in the diagonal \(X\) basis \(\{\ket{+},\ket{-}\}\) cleanly distinguishes the entangled state \(\ket{\Phi^+}\) from a \(50/50\) classical mixture of \(\ket{00}\) and \(\ket{11}\). As we saw in Section 4.2.2, measuring a qubit in the \(X\) basis is equivalent to applying a Hadamard gate \(H\) (which maps \(\ket{+}\mapsto\ket{0}\) and \(\ket{-}\mapsto\ket{1}\)) followed by a computational-basis measurement. Let us apply \(H\otimes H\) to the two terms of \(\ket{\Phi^+}\):
When we add these two expressions with weight \(1/\sqrt{2}\) for \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\), the cross terms \(\ket{01}\) and \(\ket{10}\) destructively cancel while \(\ket{00}\) and \(\ket{11}\) constructively reinforce, leaving \((H\otimes H)\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2} = \ket{\Phi^+}\). Consequently, when both qubits of \(\ket{\Phi^+}\) are measured in the \(X\) basis, their outcomes (whether \(++\) or \(--\)) still agree \(100\%\) of the time! By contrast, in the classical mixture of \(\ket{00}\) and \(\ket{11}\), each run starts in either \(\ket{00}\) alone or \(\ket{11}\) alone; applying \(H\otimes H\) to either basis state spreads probability \(1/4\) across all four outcomes \(00, 01, 10, 11\), so the two \(X\)-basis measurements agree only half the time, by pure chance. Coherence between \(\ket{00}\) and \(\ket{11}\) is invisible in the \(Z\) basis alone, but unmistakable as soon as we also test in the \(X\) basis.
The upper circuit measures a Bell pair directly. The lower circuit first applies H on both wires. Both give matching bits; the corresponding classical mixture gives all four pairs in the lower circuit.Problems
For \(\ket{\Phi^+}\), compute \(p(\text{first}=1)\) and \(p(\text{second}=1\mid\text{first}=1)\).
Show solutionHide solution
\(p(\text{first}=1)=p(10)+p(11)=0+\tfrac12=\tfrac12\), and \(p(\text{second}=1\mid\text{first}=1)=p(11)/p(\text{first}=1)=1\).
For \((\ket{00}+\ket{01}+\ket{11})/\sqrt3\), compute the joint probabilities, both marginal distributions, and \(p(\text{second}=1\mid\text{first}=0)\).
Show solutionHide solution
\(p(00)=p(01)=p(11)=1/3\) and \(p(10)=0\). The first qubit gives \(0\) with probability \(2/3\) and \(1\) with \(1/3\); the second gives \(0\) with \(1/3\) and \(1\) with \(2/3\). Finally, \(p(\text{second}=1\mid\text{first}=0)=p(01)/p(\text{first}=0)=\tfrac{1/3}{2/3}=\tfrac12\).
Compare the Bell state and an equally weighted classical mixture of 00 and 11 after applying H to both qubits and measuring. Why must you add amplitudes in one calculation and probabilities in the other?
Show solutionHide solution
The Bell state gives 00 and 11 with probability one half each: the 01 and 10 amplitudes cancel. Each component of the classical mixture gives all four outcomes with probability one quarter, so their probability average does too. The mixture describes separate preparation alternatives, not coherent paths in the same pure state.
6.3
Quantum Information Constraints
Because entangled states exhibit stronger-than-classical correlations across multiple measurement bases, it is natural to ask whether quantum mechanics permits two dramatic operations: making duplicate copies of an unknown quantum state, or using a shared entangled pair to transmit messages instantaneously across space. In this section, we use linearity and unitarity to prove that both are impossible—establishing the no-cloning theorem and the no-signalling principle.
In classical computing, copying a bit is trivial: fan-out splits a wire, or a CNOT gate with a target initialized to \(0\) copies any basis bit \(x\in\{0,1\}\) via \(\operatorname{CNOT}\ket{x}\ket{0} = \ket{x}\ket{x}\). Specifically, \(\ket{0}\ket{0}\mapsto\ket{0}\ket{0}\) and \(\ket{1}\ket{0}\mapsto\ket{1}\ket{1}\).
What happens if we feed a superposition \(\ket{\psi} = \alpha\ket{0} + \beta\ket{1}\) into the control of that same CNOT gate? By linearity,
Whenever both \(\alpha\) and \(\beta\) are nonzero, the two expressions are completely different: \(\ket{\psi}\otimes\ket{\psi}\) is a product state containing cross terms \(\alpha\beta\ket{01}\) and \(\alpha\beta\ket{10}\), whereas \(\operatorname{CNOT}\ket{\psi}\ket{0} = \alpha\ket{00}+\beta\ket{11}\) is an entangled state that has no \(\ket{01}\) or \(\ket{10}\) terms at all! Instead of cloning the superposition \(\ket{\psi}\), CNOT copies only the computational basis labels \(0\) and \(1\), entangling the two wires in the process.
CNOT copies a basis label into a blank target. For a superposition the joint output is entangled, rather than two independent copies.Problems
Apply CNOT to \(\tfrac{\ket0+\ket1}{\sqrt2}\otimes\ket0\) and to \(\tfrac{\ket0+\ket1}{\sqrt2}\otimes\ket1\).
Show solutionHide solution
\((\ket{00}+\ket{11})/\sqrt2\) and \((\ket{01}+\ket{10})/\sqrt2\). In neither case is the result two copies of \((\ket0+\ket1)/\sqrt2\), which would be \((\ket{00}+\ket{01}+\ket{10}+\ket{11})/2\).
For which states \(\alpha\ket0+\beta\ket1\) does CNOT turn \((\alpha\ket0+\beta\ket1)\ket0\) into two copies, \((\alpha\ket0+\beta\ket1)\otimes(\alpha\ket0+\beta\ket1)\)?
Show solutionHide solution
CNOT gives \(\alpha\ket{00}+\beta\ket{11}\); two copies are \(\alpha^2\ket{00}+\alpha\beta\ket{01}+\alpha\beta\ket{10}+\beta^2\ket{11}\). The \(\ket{01}\) amplitudes require \(\alpha\beta=0\), so the state is \(\ket0\) or \(\ket1\), up to a global phase. Only the basis states are copied.
A unitary \(U\) copies both basis states: \(U\ket0\ket0=\ket0\ket0\) and \(U\ket1\ket0=\ket1\ket1\). Show that, whatever \(U\) does on other inputs, it sends \(\tfrac{\ket0+\ket1}{\sqrt2}\ket0\) to an entangled state.
Show solutionHide solution
By linearity, \(U\tfrac{\ket0+\ket1}{\sqrt2}\ket0=\tfrac1{\sqrt2}(U\ket{00}+U\ket{10})=\tfrac{\ket{00}+\ket{11}}{\sqrt2}\). Its amplitudes give \(\alpha_{00}\alpha_{11}=\tfrac12\neq0=\alpha_{01}\alpha_{10}\), so it is entangled. Copying basis states forces entangling superpositions; it cannot copy them.
Even if CNOT fails to copy superpositions, could some more sophisticated unitary operator \(U\) clone every unknown quantum state? Suppose a hypothetical cloning unitary \(U\) satisfied \(U(\ket{\psi}\otimes\ket{0}) = \ket{\psi}\otimes\ket{\psi}\) for all states \(\ket{\psi}\). Let us test this equation on two arbitrary states \(\ket{\psi}\) and \(\ket{\phi}\) using the fact that every unitary operator preserves inner products. First, how do we compute the inner product between two product states \(\ket{u}\otimes\ket{v}\) and \(\ket{x}\otimes\ket{y}\)? Expanding in the product basis shows that the inner product of tensor products is simply the product of their individual inner products:
Now equate the inner product of the two states before \(U\) acts—namely \(\ket{\phi}\otimes\ket{0}\) and \(\ket{\psi}\otimes\ket{0}\)—with the inner product of their putative cloned outputs \(\ket{\phi}\otimes\ket{\phi}\) and \(\ket{\psi}\otimes\ket{\psi}\):
A complex number \(z = \braket{\phi}{\psi}\) satisfies \(z = z^2\) if and only if \(z = 0\) or \(z = 1\)! That means a single unitary \(U\) can copy both \(\ket{\psi}\) and \(\ket{\phi}\) only if the two states are either identical (\(\braket{\phi}{\psi}=1\)) or orthogonal (\(\braket{\phi}{\psi}=0\)). It can never copy two distinct non-orthogonal states—such as \(\ket{0}\) and \(\ket{+}\), whose inner product is \(\braket{0}{+} = 1/\sqrt{2} \notin \{0,1\}\). This fundamental impossibility is the no-cloning theorem: no unitary operation (even aided by extra workspace qubits) can duplicate an arbitrary unknown quantum state.
Be careful to note what the no-cloning theorem does and does not forbid. It does not forbid copying states chosen from a known mutually orthogonal set (such as \(\{\ket{0},\ket{1}\}\), which CNOT copies perfectly), nor does it prevent us from preparing multiple copies of a state when we know the classical circuit recipe that creates it from \(\ket{0}\). What is physically impossible is a universal copying machine that takes a single copy of an unknown state \(\ket{\psi}\) and outputs \(\ket{\psi}\otimes\ket{\psi}\).
U? is a hypothetical universal copying unitary, not an available gate. The required output overlap differs from the input overlap, so the two requested actions cannot belong to one unitary.Problems
Compute \(\braket0+\) and \(\braket{00}{++}\). Why do these values rule out a unitary that copies both \(\ket0\) and \(\ket+\)?
Show solutionHide solution
\(\braket0+=1/\sqrt2\), while \(\braket{00}{++}=\braket0+^2=1/2\). The inputs \(\ket0\ket0\) and \(\ket+\ket0\) have overlap \(1/\sqrt2\), so a unitary would keep that overlap, but the desired outputs \(\ket{00}\) and \(\ket{++}\) have overlap \(1/2\).
Show that a unitary can copy each of the two states \(\ket+\) and \(\ket-\) into a register prepared in \(\ket0\). Give one.
Show solutionHide solution
Take \(U=(H\otimes H)\,\mathrm{CNOT}\,(H\otimes I)\). For \(\ket+\ket0\): \(H\otimes I\) gives \(\ket{00}\), CNOT leaves it, and \(H\otimes H\) gives \(\ket+\ket+\). For \(\ket-\ket0\): \(\ket{10}\to\ket{11}\to\ket-\ket-\). Orthogonal states can be copied; the no-cloning theorem forbids only a cloner for nonorthogonal ones.
A cloning machine may change its own state: \(U\ket\psi\ket0\ket e=\ket\psi\ket\psi\ket{e_\psi}\), where the final machine state \(\ket{e_\psi}\) may depend on \(\ket\psi\). Show that it can still clone two states only if they are orthogonal or equal up to phase.
Show solutionHide solution
Inner products are preserved: \(\braket\phi\psi=\braket\phi\psi^2\braket{e_\phi}{e_\psi}\). Taking magnitudes with \(c=|\braket\phi\psi|\), we get \(c=c^2|\braket{e_\phi}{e_\psi}|\leq c^2\). So \(c=0\) or \(c\geq1\); since \(c\leq1\) for unit vectors, \(c=0\) or \(c=1\). The states are orthogonal, or equal up to phase. A machine that keeps a record of what it copied gains nothing.
Suppose Alice and Bob sit in distant laboratories, separated by light-years, sharing the entangled Bell pair \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\). Alice holds the first qubit; Bob holds the second. If Alice measures her qubit and observes \(0\), the measurement postulate dictates that the two-qubit state collapses instantaneously to \(\ket{00}\). At that very moment, Bob’s qubit is guaranteed to be \(\ket{0}\). Nothing in the mathematical rule mentions spatial distance or propagation time. Could Alice exploit this instantaneous collapse to send Bob a message faster than light? To settle the question, we must look at what Bob can actually observe in his own laboratory.
Before Alice touches her qubit, what is Bob’s probability of observing \(0\)? Because Bob has access only to his own qubit, his outcome is governed by a marginal probability—the sum of the joint probabilities for all outcomes where the second bit is \(0\):
Now suppose Alice performs a measurement in the computational basis, but does not send Bob a message. Two things can happen. With probability \(1/2\), Alice gets \(0\), collapsing the system to \(\ket{00}\), so Bob is certain to see \(0\). With probability \(1/2\), Alice gets \(1\), collapsing the system to \(\ket{11}\), so Bob is certain to see \(1\). Because Bob has received no communication from Alice, he does not know which branch occurred. His observed probability of seeing \(0\) is therefore the statistical average of the two conditional probabilities, weighted by how likely each case was:
The probability has not moved by a hair. Alice’s measurement certainly collapsed the global state, but because she cannot choose which outcome occurs, her action looks to Bob like a fair coin toss that leaves his local statistics completely undisturbed.
Could this invariance be a mere coincidence of the Bell pair’s perfect \(50/50\) symmetry? Furthermore, Alice has far more freedom than simply measuring: what if she applies an arbitrary local unitary gate \(U_A\) to her qubit, or what if Bob tests his qubit in another basis? To test this rigorously, let us examine an asymmetric, lopsided state:
Each of the three terms carries probability \(1/3\). Initially, Bob sees \(0\) only through \(\ket{00}\) (since there is no \(\ket{10}\) term), so his marginals are \(p_B(0) = 1/3\) and \(p_B(1) = 2/3\). Alice, by contrast, observes \(0\) through \(\ket{00}\) and \(\ket{01}\), giving \(p_A(0) = 2/3\).
Now let Alice apply a local Hadamard gate, \(H\otimes I\). The operation acts solely on Alice's bit while leaving Bob's wire untouched:
Alice’s local statistics shift dramatically: her probability of observing \(0\) jumps from \(2/3\) to \(p_A(0) = 1/6 + 4/6 = 5/6\). But what happens to Bob? Bob sees \(0\) through \(\ket{00}\) and \(\ket{10}\), and \(1\) through \(\ket{01}\):
Even though the global state was transformed and Alice's local distribution changed by \(16.7\%\), Bob's marginal probabilities remain strictly \(1/3\) and \(2/3\)—identical to his starting numbers!
Why does this invariance hold for every state and every possible gate? The key is to group the terms of an arbitrary two-qubit state \(\ket{\Psi} = \sum_{a,b} c_{ab}\ket{ab}\) according to Bob’s bit:
Here \(\ket{v_b} = c_{0b}\ket{0} + c_{1b}\ket{1}\) is the unnormalized state on Alice's qubit that accompanies Bob's bit \(b\). Bob's probability of observing \(b\) is simply the squared Euclidean length of \(\ket{v_b}\): \(p_B(b) = |c_{0b}|^2 + |c_{1b}|^2 = \|\ket{v_b}\|^2\). Any local unitary operation \(U_A\otimes I\) transforms each term to \((U_A\ket{v_b})\otimes\ket{b}\). Because unitary transformations preserve lengths and inner products (they are isometries), \(\|U_A\ket{v_b}\|^2 = \|\ket{v_b}\|^2\). Alice's gate reshuffles amplitudes among her own basis labels, but it can never transfer amplitude across Bob's orthogonal sectors \(\ket{0}\) and \(\ket{1}\).
What if Bob chooses to measure in a different basis, such as the \(X\) basis? Measuring in another basis corresponds to applying a local unitary \(V_B\) before measuring in the computational basis. Because operations on distinct wires act on independent tensor factors, they commute: \((U_A\otimes I)(I\otimes V_B) = (I\otimes V_B)(U_A\otimes I)\). We can mathematically evaluate the circuit as if Bob applied \(V_B\) first, which merely produces a new two-qubit state to which our length-preservation argument immediately applies. Alice’s local gate is undetectable in every basis Bob can choose.
Finally, what if Alice measures her qubit? If Alice measures in the computational basis, she obtains outcome \(a\) with probability \(p_A(a) = |c_{a0}|^2 + |c_{a1}|^2\), collapsing the state and leaving Bob with the conditional probability \(p(b\mid a) = |c_{ab}|^2 / p_A(a)\). Without Alice's message, Bob’s observed distribution is the unconditioned average over Alice’s possible results:
The normalization denominator \(p_A(a)\) of each collapsed branch is exactly cancelled by the probability with which that branch occurs! Bob’s local statistics remain untouched.
This fundamental principle is the no-signalling theorem: no local unitary operation or measurement performed on one half of an entangled state can alter the outcome statistics on the other half. Entanglement creates correlations between separated measurements, but it never constitutes a communication channel. Alice and Bob can witness their correlation only when they meet or transmit their classical measurement records over an ordinary communication channel that respects the cosmic speed limit of light.
Interactive figure. This figure tracks the joint amplitudes and Bob’s marginal readout probabilities for \((\ket{00}+\ket{01}+\ket{11})/\sqrt{3}\). Apply local gates such as \(H\) on Alice’s qubit and compare Bob’s marginal distribution before and after.
Experiment: local operations and no-signalling
Two distant laboratories share an entangled pair. Try applying any local gate (\(H\), \(X\), \(Z\)) or measuring on Alice's qubit: Alice's local marginals change, and the joint state transforms, but Bob's marginal outcome probabilities (shown in his laboratory on the right) remain completely invariant without classical communication.What to observe
Bob’s probability of observing \(0\) stays fixed at \(1/3\). Alice’s local gate redistributes amplitude among her own basis labels while preserving the squared norm accompanying each of Bob’s outcomes, so Bob’s local statistics remain invariant without classical communication.
Problems
Alice and Bob share \(\ket{\Phi^+}\). Alice measures her qubit and does not report the result. What is the probability that Bob obtains \(0\) in a computational-basis measurement?
Show solutionHide solution
With probability \(1/2\), Alice obtains \(0\) and Bob’s qubit is \(\ket0\); otherwise it is \(\ket1\). Bob obtains \(0\) with probability \(\tfrac12\cdot1+\tfrac12\cdot0=\tfrac12\), exactly as without Alice’s measurement.
Alice applies \(X\) to her qubit of \(\ket{\Phi^+}\), without measuring. Find the new joint state and Bob’s computational-basis probabilities.
Show solutionHide solution
\((X\otimes I)\ket{\Phi^+}=(\ket{10}+\ket{01})/\sqrt2\). Bob obtains \(0\) and \(1\) with probability \(1/2\) each, as before. Only the correlations between the two qubits have changed.
Alice measures her half of \(\ket{\Phi^+}\) in either the computational basis or the \(\pm\) basis, without reporting her result. Bob tests for any normalized state \(\ket v=a\ket0+b\ket1\). Show that his probability of success is \(1/2\) for either choice. Why is this stronger than checking only Bob’s computational-basis outcomes?
Show solutionHide solution
For Alice’s computational-basis choice, Bob’s probability is \(\tfrac12|a|^2+\tfrac12|b|^2=1/2\). For her \(\pm\) choice, it is \(\tfrac14|a+b|^2+\tfrac14|a-b|^2=\tfrac12(|a|^2+|b|^2)=1/2\). The cross terms cancel. Thus changing Bob’s measurement basis cannot reveal Alice’s choice. Matching probabilities in just one basis would not establish this: \(\ket+\) and \(\ket-\), for example, agree in the computational basis but are distinguishable in another.
6.4
Quantum Teleportation
The no-cloning theorem and the no-signalling principle establish strict boundaries on quantum information: an unknown state cannot be duplicated, and entanglement alone cannot transmit a message. Within those exact boundaries, quantum teleportation achieves something remarkable: using a pre-shared Bell pair and just two bits of classical communication, Alice can transfer an arbitrary unknown qubit state \(\ket{\psi}\) to Bob without physically sending the qubit through space—destroying her own copy in the process so no-cloning is respected, and requiring a classical message before Bob can recover \(\ket{\psi}\) so no-signalling is respected.
Suppose Alice holds a qubit in an unknown state \(\ket{\psi} = \alpha\ket{0} + \beta\ket{1}\) and wants to deliver that exact state to Bob. She has no quantum channel left to send the physical qubit to Bob, she cannot clone \(\ket{\psi}\), and if she simply measured \(\ket{\psi}\) she would obtain only a single random bit while collapsing the state and losing the amplitudes \(\alpha\) and \(\beta\). However, suppose Alice and Bob previously shared a two-qubit Bell state \(\ket{\Phi^+} = (\ket{00}+\ket{11})/\sqrt{2}\), with Alice holding the first half and Bob holding the second.
The three-qubit system—ordered as (1) Alice's input qubit, (2) Alice's half of the Bell pair, and (3) Bob's half of the Bell pair—starts in the product of \(\ket{\psi}\) and \(\ket{\Phi^+}\):
Notice that Bob's third wire already carries combinations of \(\ket{0}\) and \(\ket{1}\), while Alice holds the first two wires in her laboratory. To couple her unknown input qubit to the shared entangled pair, Alice first applies a CNOT gate with her input qubit (wire 1) as control and her Bell qubit (wire 2) as target. This flips the middle bit whenever the first bit is \(1\), transforming the three-qubit state into
Next, Alice applies a Hadamard gate \(H\) to her first wire so that the two branches \(\alpha\) and \(\beta\) interfere across her local basis states.
Interactive figure. This interactive teleportation circuit steps through Bell-pair sharing, Alice’s CNOT and Hadamard gates, her two-bit measurement \((m_1,m_2)\), and Bob’s conditional Pauli corrections \(X^{m_2}Z^{m_1}\). Step through all four measurement branches to compare Bob’s state before and after the classical correction.
Step-by-step quantum teleportation
The quantum teleportation circuit: the top two wires belong to Alice (her unknown input \(\ket{\psi}=\cos\theta\ket{0}+\sin\theta\ket{1}\) and her half of the shared Bell pair \(\ket{\Phi^+}\)), and the bottom wire belongs to Bob. Step through or run the circuit to watch the Bell pair form, Alice’s CNOT and \(H\) gates spread \(\alpha\) and \(\beta\) across all four two-bit branches \(mn\), Alice’s measurement send two classical bits \((m,n)\) along the dashed channels, and Bob’s conditional Pauli gates \(X^n\) then \(Z^m\) restore \(\ket{\psi}\) on Bob’s wire.What to observe
Each of Alice’s four outcomes \(00,01,10,11\) occurs with probability \(1/4\) regardless of \(\alpha\) and \(\beta\). Before Bob applies \(X^{m_2}Z^{m_1}\), his four branch states average to \(I/2\); applying the two-bit-controlled Pauli correction restores \(\alpha\ket{0}+\beta\ket{1}\) on every branch.
Problems
In teleportation, how many qubits does each party hold at the start? Write the initial three-qubit state for \(\ket\psi=\ket1\).
Show solutionHide solution
Alice holds two qubits, the input and her half of the Bell pair; Bob holds one. The state is \(\ket1\otimes\tfrac{\ket{00}+\ket{11}}{\sqrt2}=\tfrac{\ket{100}+\ket{111}}{\sqrt2}\).
For \(\ket\psi=\ket1\), apply Alice’s CNOT and \(H\), and group the result by the configuration of Alice’s two qubits.
Show solutionHide solution
CNOT gives \((\ket{110}+\ket{101})/\sqrt2\). \(H\) on the first qubit gives \(\tfrac12\bigl(\ket{010}+\ket{001}-\ket{110}-\ket{101}\bigr)\). Grouped: \(\tfrac12\bigl(\ket{00}\ket1+\ket{01}\ket0-\ket{10}\ket1-\ket{11}\ket0\bigr)\), which matches \(X^nZ^m\ket1\) for each outcome \((m,n)\).
Suppose Alice sends Bob only the bit \(m\), and Bob applies \(Z^m\). Show that for \(\ket\psi=\ket0\) his qubit is wrong with probability \(1/2\).
Show solutionHide solution
Bob’s qubit before correction is \(X^nZ^m\ket0=X^n\ket0=\ket n\), and \(Z^m\) does not change a basis state, up to sign. With probability \(1/2\), \(n=1\) and Bob holds \(\ket1\) instead of \(\ket0\). Both classical bits are needed.
Let us see what state emerges when Alice applies \(H\) to the first qubit of \((\alpha\ket{000}+\alpha\ket{011}+\beta\ket{110}+\beta\ket{101})/\sqrt{2}\). Substituting \(H\ket{0} = (\ket{0}+\ket{1})/\sqrt{2}\) and \(H\ket{1} = (\ket{0}-\ket{1})/\sqrt{2}\) on the first wire expands the four terms into eight:
This algebraic identity is the heart of teleportation. Notice that each of the four branches has squared norm \((1/2)^2(|\alpha|^2+|\beta|^2) = 1/4\), completely independent of the unknown amplitudes \(\alpha\) and \(\beta\)! When Alice measures her two qubits in the computational basis, she obtains one of the four two-bit outcomes \(mn\in\{00, 01, 10, 11\}\) with probability \(1/4\) each, and Bob's qubit immediately collapses to the corresponding conditional state \(X^n Z^m\ket{\psi}\).
Alice’s measured bits \(mn\)
Bob’s conditional state
Bob’s recovery gates (in time order)
\(00\)
\(\ket{\psi}\)
Identity \(I\) (do nothing)
\(01\)
\(X\ket{\psi}\)
Apply \(X\)
\(10\)
\(Z\ket{\psi}\)
Apply \(Z\)
\(11\)
\(XZ\ket{\psi}\)
Apply \(X\) first, then \(Z\)
Once Alice transmits her two classical bits \((m,n)\) to Bob, Bob applies \(X^n\) (an \(X\) gate if \(n=1\)) followed by \(Z^m\) (a \(Z\) gate if \(m=1\)). Because \(Z^m X^n (X^n Z^m\ket{\psi}) = Z^m I Z^m\ket{\psi} = \ket{\psi}\), Bob recovers the exact state \(\ket{\psi} = \alpha\ket{0} + \beta\ket{1}\) on every single run—without either Alice or Bob ever learning \(\alpha\) or \(\beta\).
Alice’s two measured bits \(m\) and \(n\) classically control Bob’s recovery gates \(X^n\) and \(Z^m\). Dashed lines carry the two classical bits from Alice to Bob; the shared Bell pair is prepared on the left.Problems
Alice obtains \((m,n)=(1,0)\). Which state does Bob hold, and which correction does he apply?
Show solutionHide solution
Bob holds \(X^0Z^1\ket\psi=Z\ket\psi\), and applies \(Z\), since \(ZZ=I\).
For \(\ket\psi=\ket+\) and Alice’s result \((1,1)\), write Bob’s state before correction, and check that the correction restores \(\ket+\).
Show solutionHide solution
Bob holds \(XZ\ket+=X\ket-=-\ket-\). He applies \(X\), giving \(-X\ket-=\ket-\), and then \(Z\), giving \(Z\ket-=\ket+\).
Bob applies his corrections in the wrong order: \(Z^m\) first, then \(X^n\). Show that he still obtains \(\ket\psi\), up to a global phase.
Show solutionHide solution
He applies \(X^nZ^m\) to \(X^nZ^m\ket\psi\). If \(m=0\) or \(n=0\), this is \(X^{2n}\ket\psi\) or \(Z^{2m}\ket\psi\), which is \(\ket\psi\). If \(m=n=1\), it is \(XZXZ\ket\psi\); since \(ZX=-XZ\), \(XZXZ=-XXZZ=-I\), giving \(-\ket\psi\), the same state up to a global phase.
Why doesn't teleportation violate the no-signalling principle or the no-cloning theorem? Consider first what Bob has before Alice's two classical bits \((m,n)\) arrive. Without knowing \((m,n)\), Bob holds an equally likely mixture of the four states \(\ket{\psi}\), \(X\ket{\psi}\), \(Z\ket{\psi}\), and \(XZ\ket{\psi}\). If he measures his qubit in the computational basis without waiting for Alice's message, his probability of observing \(0\) is the average across the four equally likely branches:
Even if Bob measures in an arbitrary orthonormal basis containing \(\ket{v} = c\ket{0} + d\ket{1}\), the four branches contribute \(|c^*\alpha + d^*\beta|^2\), \(|c^*\beta + d^*\alpha|^2\), \(|c^*\alpha - d^*\beta|^2\), and \(|c^*\beta - d^*\alpha|^2\); averaging them cancels all the opposite-sign cross terms and leaves \(\tfrac{1}{2}(|c|^2+|d|^2)(|\alpha|^2+|\beta|^2) = 1/2\), completely independent of \(\alpha\) and \(\beta\)! Until the two classical bits arrive at or below the speed of light, Bob's qubit behaves like a completely random coin toss that reveals zero information about \(\ket{\psi}\).
Second, why doesn't teleportation violate the no-cloning theorem? Because Alice's measurement projects her two qubits onto a definite computational basis state \(\ket{mn}\), erasing the superposition \(\alpha\ket{0}+\beta\ket{1}\) on her side and consuming the shared Bell pair \(\ket{\Phi^+}\). At the end of the protocol, only one copy of \(\ket{\psi}\) exists—now located in Bob's laboratory rather than Alice's.
Teleportation is crystal clear as long as we keep three descriptions distinct: the pure three-qubit state vector before measurement, Bob's conditional state \(X^n Z^m\ket{\psi}\) once Alice's outcome \(mn\) is known, and Bob's completely uniform marginal statistics when \(mn\) is unknown.
Complete state transfer via teleportation: Alice's Bell-basis measurement destroys the input state on her side and produces two classical bits that select Bob's Pauli corrections, restoring \(\ket{\psi}\) on Bob's wire once the message arrives.Problems
Before the classical bits arrive, what is the probability that Bob obtains \(0\) when measuring his qubit, for \(\ket\psi=\ket0\)?
Show solutionHide solution
His qubit is \(X^nZ^m\ket0=\pm\ket n\), with \(n=0\) or \(1\) equally likely, so he obtains \(0\) with probability \(1/2\).
Show that, before the bits arrive, Bob obtains \(0\) with probability \(1/2\) for every input \(\ket\psi=\alpha\ket0+\beta\ket1\).
Show solutionHide solution
\(Z^m\) changes only signs, so \(Z^m\ket\psi\) gives \(0\) with probability \(|\alpha|^2\); \(X\) swaps the amplitudes, giving \(|\beta|^2\). Averaging over \(n\), Bob obtains \(0\) with probability \(\tfrac12|\alpha|^2+\tfrac12|\beta|^2=\tfrac12\), independent of \(\psi\).
After Bob’s correction, write the three-qubit state for a particular measurement result \((m,n)\). Do Alice’s qubits retain a second copy? Explain the scope of your conclusion.
Show solutionHide solution
The conditional state is \(\ket m\ket n\ket\psi\). Alice’s two qubits are basis states, and each pair \((m,n)\) has probability \(1/4\), independent of \(\psi\). Her remaining registers and the classical record therefore contain no second copy of the unknown input. This describes the systems in this protocol; it does not assert that an external preparer could not already have held another copy.
6.5
Quantum Parallelism
Because an \(n\)-qubit register can hold a superposition of all \(2^n\) bit strings at once, a single execution of a reversible function circuit evaluates the function on every possible input simultaneously. In this section, we trace this phenomenon—called quantum parallelism—examine why a direct measurement of the resulting state reveals no more than a single random input–output pair, and see how extracting a useful global property requires interference without leftover target records.
In Chapter 2, we learned how to evaluate any Boolean function \(f:\{0,1\}^n\to\{0,1\}\) reversibly without losing information: preserve the \(n\)-bit input \(x\) in an input register, XOR the answer \(f(x)\) into a target bit \(y\), and uncompute any temporary workspace. Promoted to a quantum register of \(n\) input qubits and \(1\) target qubit, this reversible map defines the unitary operator \(U_f\):
Because \(U_f\) simply permutes the computational basis states—swapping \(\ket{x}\ket{0}\) and \(\ket{x}\ket{1}\) when \(f(x)=1\) and leaving them fixed when \(f(x)=0\)—it is unitary and can be built directly from Toffoli and CNOT gates at a gate cost comparable to a single classical circuit evaluation of \(f\).
What happens when we feed a superposition of inputs into \(U_f\)? Start with two input qubits initialized to \(\ket{00}\) and apply a Hadamard gate to each wire:
Just two single-qubit gates spread equal amplitude \(1/2\) across all four two-bit strings! More generally, applying \(H^{\otimes n}\) to \(n\) qubits in \(\ket{0\cdots 0}\) uses only \(n\) gates in a single layer to create an equal superposition of all \(2^n\) bit strings, each with amplitude \(2^{-n/2}\).
Now attach a target qubit in \(\ket{0}\) and apply \(U_f\) once. By linearity, \(U_f\) acts on all \(2^n\) basis branches simultaneously:
For a concrete two-bit example, take \(f(x_1,x_2) = x_1\land x_2\) (logical AND, which equals \(1\) only on \(x=11\)). One application of \(U_f\) produces
In a single invocation of \(U_f\), the register now holds a superposition in which every input string \(x\) is paired with its corresponding output \(f(x)\). This capability is called quantum parallelism. It is tempting to think that we have evaluated all \(2^n\) entries of the truth table of \(f\) for the price of one call—but having \(2^n\) values present in the amplitudes of a state vector is very different from being able to read them out.
Two H gates spread the inputs over all four strings. One application of \(U_f\) then places each input beside its own value: \(\tfrac12\sum_x\ket x\ket{f(x)}\).Problems
How many Hadamard gates prepare the uniform superposition of all inputs on five qubits? How many configurations does it contain, and what is the amplitude of each?
Show solutionHide solution
Five gates, one \(H\) on each qubit. The state contains \(2^5=32\) configurations, each with amplitude \(2^{-5/2}=1/\sqrt{32}\). The gate count grows by one per qubit, while the number of configurations doubles.
Write the state that \(U_f\) produces from \(\tfrac12\sum_x\ket x\ket0\) when \(f(x)=x_1\oplus x_2\). Can it be written as an input state times a target state?
Show solutionHide solution
\(\tfrac12(\ket{00}\ket0+\ket{01}\ket1+\ket{10}\ket1+\ket{11}\ket0)\). It is not a product. In a product \(\ket a\otimes(b_0\ket0+b_1\ket1)\), every input would carry the same target amplitudes \((b_0,b_1)\) up to its own factor; here input \(00\) carries target \(0\) only and input \(01\) carries target \(1\) only.
Start the target in \(\ket1\) instead of \(\ket0\). What state does \(U_f\) produce from the uniform input superposition, and does it carry more or less information about \(f\) than the state with target \(\ket0\)?
Show solutionHide solution
\(U_f\ket x\ket1=\ket x\ket{1\oplus f(x)}\), so the result is \(\tfrac12\sum_x\ket x\ket{1\oplus f(x)}\): the same pairs with every target bit complemented. It equals \(X\) on the target applied to the state with target \(\ket0\). A unitary on the target can be undone, so the two states carry exactly the same information about \(f\).
Suppose we try to read out the parallel evaluation of AND by measuring all three qubits in the computational basis right after \(U_f\). Each of the four terms \(\ket{x}\ket{f(x)}\) has amplitude \(1/2\), so by the measurement postulate we observe a single pair \((x, f(x))\)—either \((00,0)\), \((01,0)\), \((10,0)\), or \((11,1)\)—chosen uniformly at random with probability \(1/4\) each. Worse still, the measurement collapses the state vector onto that single observed pair \((x,f(x))\), erasing the other three branches completely!
If our goal is to learn the entire truth table of \(f\), we would have to re-prepare the state and run \(U_f\) again and again—and because each run samples a random input \(x\) (with replacement), collecting all four distinct inputs takes more runs on average than simply evaluating \(f\) classically on \(00, 01, 10, 11\) in order! For \(n\) input bits, the truth table has \(2^n\) entries, whereas a single measurement of \(n+1\) qubits can return at most \(n+1\) classical bits.
Could we bypass this bottleneck by cloning the superposition \(\tfrac{1}{2}\sum_x \ket{x}\ket{f(x)}\) many times before measuring? No: different functions \(f\) produce non-orthogonal parallel states (for instance, the parallel state for AND has inner product \(3/4\) with the parallel state for the constant-\(0\) function), so the no-cloning theorem forbids any unitary device from copying them.
What if we measure only the target qubit of the AND state? Outcome \(0\) occurs with probability \(3/4\), collapsing the input register to \((\ket{00}+\ket{01}+\ket{10})/\sqrt{3}\), while outcome \(1\) occurs with probability \(1/4\), collapsing the input register to \(\ket{11}\). Measuring the target reveals one output value \(y\) and projects the input register onto a uniform superposition of all inputs satisfying \(f(x)=y\).
Notice a crucial structural feature of the state \(\tfrac{1}{2}\sum_x \ket{x}\ket{f(x)}\): whenever \(f\) is not constant, the input register and the target qubit are entangled! Because some input branches carry \(\ket{0}\) on the target while others carry \(\ket{1}\), the target qubit acts as a path record indicating whether \(f(x)=0\) or \(f(x)=1\).
Interactive figure. This simulator applies the reversible evaluation unitary \(U_f\) for AND to an equal superposition of all four 2-bit inputs and then measures the register. Run repeated single-shot measurements to see how many queries are needed to observe all four truth-table rows.
Reading a parallel evaluation
Each row corresponds to a two-bit input \(x\in\{00,01,10,11\}\), and the two columns correspond to target values \(y\in\{0,1\}\). Bar lengths display the amplitudes of \(\ket{x}\ket{y}\), with orange highlighting the outcome selected by a measurement. The table on the right tracks which truth-table entries have been discovered so far: although \(U_f\) populates all four rows in superposition at once, each measurement reveals only a single random row.What to observe
Each measurement collapses the superposition to a single random pair \((x,f(x))\) with probability \(1/4\). Because outcomes repeat at random, collecting all four rows requires \(25/3\approx 8.3\) runs on average without interference.
Problems
After the parallel evaluation of AND, every qubit is measured. List the possible results with their probabilities. What is the state of the register after the result \((10,0)\)?
Show solutionHide solution
The configurations are \(\ket{00}\ket0\), \(\ket{01}\ket0\), \(\ket{10}\ket0\), and \(\ket{11}\ket1\), each with amplitude \(1/2\), so the results \((00,0)\), \((01,0)\), \((10,0)\), and \((11,1)\) each occur with probability \(1/4\). After \((10,0)\), the register is in \(\ket{10}\ket0\). The other three pairs are no longer in the state; another value needs a fresh preparation.
Measure only the target after the parallel evaluation of XOR. Give both outcome probabilities and the conditional state of the inputs in each case. What have you learned about \(f\)?
Show solutionHide solution
The XOR state is \(\tfrac12(\ket{00}\ket0+\ket{01}\ket1+\ket{10}\ket1+\ket{11}\ket0)\). The target gives \(0\) with probability \(1/2\), leaving \((\ket{00}+\ket{11})/\sqrt2\), and \(1\) with probability \(1/2\), leaving \((\ket{01}+\ket{10})/\sqrt2\). We learn that \(f\) takes the observed value and which inputs share it, but a later input measurement still returns only one of them.
Each run of the parallel evaluation of a two-input function, followed by measuring every qubit, reveals one random pair \((x,f(x))\). What is the expected number of runs before all four values are known? Compare with evaluating \(f\) on each input in turn.
Show solutionHide solution
After \(k\) distinct inputs have appeared, a run shows a new one with probability \((4-k)/4\), so the expected wait is \(4/(4-k)\) runs. Adding over \(k=0,1,2,3\) gives \(4(1+\tfrac12+\tfrac13+\tfrac14)=25/3\approx8.3\) runs. Evaluating \(f\) on each input in turn takes exactly four evaluations, so random sampling of the parallel state does worse.
If a single run cannot read out the full truth table of \(f\), what kind of question can quantum parallelism help us answer? Many computational problems ask not for every value \(f(x)\) individually, but for a single bit or short summary that depends on how the values \(f(x)\) relate to one another across the entire domain—for example, whether \(f\) is constant, whether two halves of the table match, or whether any \(x\) satisfies \(f(x)=1\). Such a collective feature is called a global property of \(f\).
To extract a global property, we need paths from different inputs \(x\) to interfere before we measure. Suppose we try the simplest interference test after applying \(U_f\): apply \(H\otimes H\) to the two input qubits and measure them in the computational basis. Because each two-bit state \(\ket{x}\) has transition amplitude \(\bra{00}(H\otimes H)\ket{x} = +1/2\) into the all-zero input state \(\ket{00}\), the outcome \(00\) gathers contributions from all four input branches.
When \(f(x)=c\) is a constant function, all four branches share the exact same target state \(\ket{c}\), so the parallel state factors as \(\bigl(\tfrac{1}{2}\sum_x \ket{x}\bigr)\otimes\ket{c}\). Applying \(H\otimes H\) to the input register brings all four branches together at the common configuration \(\ket{00}\ket{c}\) with amplitude \(4\times(1/4) = 1\), returning the input readout \(00\) with probability \(1\).
What happens when \(f\) is AND? Now the four contributions to input readout \(00\) do not all land on the same three-qubit configuration! The three inputs \(00, 01, 10\) (where \(f(x)=0\)) arrive at \(\ket{00}\ket{0}\) with combined amplitude \(3\times(1/4) = 3/4\), whereas the input \(11\) (where \(f(11)=1\)) arrives at the distinct configuration \(\ket{00}\ket{1}\) with amplitude \(1/4\). Because \(\ket{00}\ket{0}\) and \(\ket{00}\ket{1}\) have orthogonal target states, their amplitudes cannot add coherently; instead, their probabilities add:
Why did the branches with \(f(x)=0\) and \(f(x)=1\) fail to interfere with each other? Because writing \(f(x)\) into a target qubit initialized in \(\ket{0}\) left a record of \(f(x)\) in the target register—the exact path-information effect we discovered in Section 3.4.4! For different function values \(f(x)\) to interfere coherently on the input register, we must evaluate \(f\) in a way that leaves the target qubit in the same state regardless of \(f(x)\) while transferring the value \(f(x)\) into a relative phase. Discovering how to do that is the subject of Chapter 7.
After \(U_f\), H on each input combines contributions from all four inputs. A constant \(f\) returns the readout 00 with certainty; for AND the target’s record keeps the branches apart, and 00 has probability \(5/8\).Problems
For a constant function \(f(x)=c\) on two inputs, show that applying \(H\otimes H\) to the inputs after the parallel evaluation gives the readout \(00\) with certainty.
Show solutionHide solution
The parallel state is \(\tfrac12\sum_x\ket x\ket c=\bigl((H\otimes H)\ket{00}\bigr)\ket c\), a product. Since \(H\) is its own inverse, applying \(H\otimes H\) to the inputs returns \(\ket{00}\ket c\). The readout is \(00\) with probability one.
Repeat the calculation for \(f(x)=x_1\), the first input bit. Find the probability of the readout \(00\).
Show solutionHide solution
The state is \(\tfrac12\bigl((\ket{00}+\ket{01})\ket0+(\ket{10}+\ket{11})\ket1\bigr)\). Each input sends amplitude \(1/2\) to the readout \(00\). Target \(0\): \(\tfrac12(\tfrac12+\tfrac12)=\tfrac12\) at \(\ket{00}\ket0\). Target \(1\): \(\tfrac12\) at \(\ket{00}\ket1\). So \(p(00)=\tfrac14+\tfrac14=\tfrac12\).
Why can contributions that end with different target values not cancel? Use this to explain why the readout \(00\) does not reliably separate a constant \(f\) from AND, and say what the target would need to do instead.
Show solutionHide solution
Amplitudes add only at the same final configuration, and \(\ket{00}\ket0\) and \(\ket{00}\ket1\) are different configurations; their probabilities add instead. For AND the readout \(00\) has probability \(5/8\): neither \(1\), as for a constant, nor \(0\), so one run cannot tell the cases apart. The target would have to end in the same state on every branch, so that it keeps no record of \(x\), while \(f(x)\) still affects the amplitudes in some way that can interfere, for example as a sign.
Registers are tensor products. An \(n\)-qubit register has \(2^n\) basis strings, and independent preparations combine by the tensor product. A local gate acts as \(U\otimes I\), while a controlled gate such as CNOT acts on two qubits jointly.
Entanglement is failure to factor. A superposition of joint configurations may still be a product state. A pure state is entangled when no pair of local vectors reproduces its amplitudes; \(H\) followed by CNOT turns \(\ket{00}\) into \(\ket{\Phi^+}=(\ket{00}+\ket{11})/\sqrt2\).
Joint amplitudes give every probability. Joint, marginal and conditional probabilities all come from squared joint amplitudes. Measuring part of a register keeps the terms that match the outcome and renormalizes them.
Correlation alone does not prove entanglement. A classical mixture of \(00\) and \(11\) gives the same counts in the computational basis. Measuring after \(H\otimes H\) separates the coherent Bell state from the mixture.
No-cloning. No unitary copies every unknown state, because unitaries preserve inner products and two states that can both be copied must be equal or orthogonal. Known states, or states promised to be orthogonal, can still be copied.
No-signalling and teleportation. Operations on one half of an entangled pair do not change the statistics of the other half. Teleportation moves an unknown state using a shared Bell pair and two classical bits. It works for all four outcomes, and it creates no copy and no faster-than-light signal.
Parallel evaluation is not parallel readout. Applying \(U_f\) to a uniform superposition gives \(\sum_x\ket x\ket{f(x)}\), but a measurement returns one random input–value pair. Parallelism helps only when later interference turns many values into one useful bit, and that requires a target that keeps no record of the branch.
Questions and worked problems
Attempt each question before opening a hint. Explain your reasoning, then compare it with the solution.
Two qubits are prepared independently: the first in \((\ket0+\ket1)/\sqrt2\), the second in \(\frac{\sqrt3}{2}\ket0+\frac12\ket1\). Write the four joint amplitudes, the probability that the two measured bits agree, and the marginal probability that the second bit is \(0\).
Hint 1
Joint amplitudes are products of local amplitudes.
Hint 2
“Agree” means the outcomes \(00\) or \(11\).
Worked solution
The amplitudes are \(\frac{\sqrt3}{2\sqrt2}\), \(\frac{1}{2\sqrt2}\), \(\frac{\sqrt3}{2\sqrt2}\), \(\frac{1}{2\sqrt2}\) for \(00,01,10,11\), with probabilities \(\frac38,\frac18,\frac38,\frac18\). The bits agree with probability \(\frac38+\frac18=\frac12\). The second bit is \(0\) with probability \(\frac38+\frac38=\frac34\), exactly its local probability: for a product state the marginals are the single-qubit probabilities, and the joint probabilities factor.
Alice holds the first qubit of \(\ket{\Phi^+}=(\ket{00}+\ket{11})/\sqrt2\). Find the joint state after she applies (a) \(Z\), (b) \(X\), (c) \(Z\) and then \(X\). Does any of these change Bob’s computational-basis probabilities?
Hint 1
Apply the gate to the first label of each term.
Hint 2
Bob’s probability of \(b\) is the sum of \(|\alpha_{ab}|^2\) over \(a\).
Worked solution
(a) \(Z\) gives \((\ket{00}-\ket{11})/\sqrt2\). (b) \(X\) gives \((\ket{10}+\ket{01})/\sqrt2\). (c) \(Z\) then \(X\) gives \((\ket{10}-\ket{01})/\sqrt2\). Together with \(\ket{\Phi^+}\) these are four orthogonal states, so a local gate by Alice changes the joint state in a way a joint measurement could detect. Bob’s computational-basis probabilities stay \(\frac12,\frac12\) in every case, as no-signalling requires: the change is visible only by comparing both qubits.
Prepare \((\ket{01}-\ket{10})/\sqrt2\) from \(\ket{00}\) using X, H, and CNOT. Calculate the outcomes if H is then applied to both qubits before measurement.
Hint 1
Prepare 11 first, then use H on the first qubit followed by CNOT.
Hint 2
Expand the two contributions separately before adding.
Worked solution
X on both wires gives 11. H on the first gives \((\ket{01}-\ket{11})/\sqrt2\), and CNOT gives \((\ket{01}-\ket{10})/\sqrt2\). Applying H on both sends this to \((\ket{10}-\ket{01})/\sqrt2\), differing only by a global minus sign. Outcomes 01 and 10 each occur with probability one half.
Measure the first qubit of \(\ket\Psi=\frac12(\ket{00}+\ket{01}+\ket{10}+i\ket{11})\). Give each outcome probability and the conditional state of the second qubit. Is \(\ket\Psi\) entangled? Then, for each first outcome, find the probability that a \(\pm\)-basis measurement of the second qubit (apply \(H\), then measure) gives \(0\).
Hint 1
Keep the terms with the observed first label and renormalize.
Hint 2
\(H\) maps \((\ket0+e^{i\phi}\ket1)/\sqrt2\) to amplitude \((1+e^{i\phi})/2\) on \(\ket0\).
Worked solution
Each first outcome has probability \(\frac14+\frac14=\frac12\). After outcome \(0\) the second qubit is \((\ket0+\ket1)/\sqrt2\); after outcome \(1\) it is \((\ket0+i\ket1)/\sqrt2\). The conditional state depends on the outcome, so \(\ket\Psi\) is entangled; consistently, \(\alpha_{00}\alpha_{11}=\frac i4\neq\frac14=\alpha_{01}\alpha_{10}\). In the \(\pm\) test, the first conditional state gives \(0\) with probability \(1\); the second gives \(|(1+i)/2|^2=\frac12\). The computational-basis statistics of the second qubit are the same for both outcomes, \(\frac12,\frac12\). The entanglement shows up only in a measurement sensitive to relative phase.
Prepare three qubits from \(\ket{000}\) with \(H\) on the first qubit, CNOT from the first to the second, and CNOT from the second to the third. (a) Track the state. (b) Apply \(H\) to all three qubits and find which outcomes occur and with what probabilities. (c) Compare with a classical mixture of \(000\) and \(111\) prepared by a fair coin.
Hint 1
\(H^{\otimes3}\ket{000}\) has all eight amplitudes \(+\frac{1}{2\sqrt2}\); \(H^{\otimes3}\ket{111}\) has sign \((-1)^{z_1+z_2+z_3}\) on \(\ket z\).
Hint 2
Add the two contributions to each outcome.
Worked solution
(a) \[\ket{000}\to\tfrac{1}{\sqrt2}(\ket{000}+\ket{100})\to\tfrac{1}{\sqrt2}(\ket{000}+\ket{110})\]\[\to\tfrac{1}{\sqrt2}(\ket{000}+\ket{111}).\] (b) The amplitude of outcome \(z\) is \(\frac{1}{\sqrt2}\cdot\frac{1}{2\sqrt2}\big(1+(-1)^{z_1+z_2+z_3}\big)\). It is \(\frac12\) when \(z\) has an even number of ones and \(0\) otherwise. So the four outcomes \(000,011,101,110\) each occur with probability \(\frac14\), and the outcomes with odd parity never occur. (c) For the mixture, each preparation gives all eight outcomes with probability \(\frac18\), and so does their average. In the computational basis the two preparations look identical, but after the Hadamards the coherent state shows a strict parity rule that the mixture lacks.
CNOT copies \(\ket0\) and \(\ket1\) into a blank target. Use it on \(\ket+\ket0\) and test the result as if it were two copies of \(\ket+\): apply \(H\) to both qubits and measure. What fraction of runs pass the test (outcome \(00\)), and what fraction would pass for genuine copies \(\ket+\ket+\)?
Hint 1
CNOT turns \(\ket+\ket0\) into \(\ket{\Phi^+}\).
Hint 2
\((H\otimes H)\ket{\Phi^+}=\ket{\Phi^+}\).
Worked solution
CNOT gives \((\ket{00}+\ket{11})/\sqrt2=\ket{\Phi^+}\). Applying \(H\otimes H\) returns \(\ket{\Phi^+}\) (Section 6.2.3), so the measurement gives \(00\) or \(11\), each with probability \(\frac12\). The test passes in half the runs. Genuine copies \(\ket+\ket+\) become \(\ket{00}\) and would pass every time. CNOT is a perfect copier for the basis states and fails for \(\ket+\): it produces an entangled pair, not two independent copies. No-cloning says this failure is unavoidable for any single device that copies both \(\ket0\) and \(\ket+\).
A student reasons: “Each qubit of \(\ket{\Phi^+}\) gives \(0\) or \(1\) with probability \(\frac12\), so each qubit by itself is in the state \(\ket+\).” Test this by computing the probability that the first qubit alone gives \(0\) in the \(\pm\) basis (apply \(H\) to it, then measure). What would \(\ket+\) predict? Can any single-qubit pure state reproduce the first qubit’s statistics?
For any pure state there is a measurement, after a suitable gate, with a certain outcome.
Worked solution
\((H\otimes I)\ket{\Phi^+}=\frac12(\ket{00}+\ket{10}+\ket{01}-\ket{11})\), so the first qubit gives \(0\) with probability \(\frac14+\frac14=\frac12\). The state \(\ket+\) would give \(0\) with certainty. The first qubit gives \(\frac12,\frac12\) in both the computational and the \(\pm\) basis, and the same holds for every other test. A pure state \(\ket\psi\) always has a test with a certain result, namely the one that checks for \(\ket\psi\) itself. So no pure state describes half of a Bell pair: its statistics match a fair coin in every basis. The precise description of such a part needs the mixed-state tools of Appendix D.
Teleport \(\ket\psi=(\ket0+i\ket1)/\sqrt2\). For each of Alice’s four outcomes \((m,n)\), give Bob’s state before correction and the correction he applies.
Hint 1
Bob holds \(X^nZ^m\ket\psi\).
Hint 2
He applies \(X^n\), then \(Z^m\).
Worked solution
\((0,0)\): \((\ket0+i\ket1)/\sqrt2\), no correction. \((0,1)\): \((i\ket0+\ket1)/\sqrt2\), apply \(X\). \((1,0)\): \((\ket0-i\ket1)/\sqrt2\), apply \(Z\). \((1,1)\): \((-i\ket0+\ket1)/\sqrt2\), apply \(X\) and then \(Z\). In every case the result is \(\ket\psi\).
Repeat the parallel evaluation of Section 6.5 with the target prepared in \(\ket-=(\ket0-\ket1)/\sqrt2\) instead of \(\ket0\). (a) Show that \(U_f\ket x\ket-=(-1)^{f(x)}\ket x\ket-\). (b) Apply \(H\otimes H\) to the inputs and compute \(p(00)\) for a constant \(f\), for \(f(x)=x_1\), and for AND. (c) Why does the target \(\ket-\) succeed where \(\ket0\) failed?
Hint 1
\(U_f\) either leaves \(\ket-\) alone or flips it, and \(X\ket-=-\ket-\).
Hint 2
The amplitude of readout \(00\) is \(\frac14\sum_x(-1)^{f(x)}\).
Worked solution
(a) If \(f(x)=0\), the target is untouched. If \(f(x)=1\), it is flipped, and \(\frac{\ket1-\ket0}{\sqrt2}=-\ket-\). So \(U_f\ket x\ket-=(-1)^{f(x)}\ket x\ket-\). (b) Starting from the uniform input superposition, the state after \(U_f\) is \(\frac12\sum_x(-1)^{f(x)}\ket x\otimes\ket-\), and the readout \(00\) has amplitude \(\frac14\sum_x(-1)^{f(x)}\). Constant \(f\): \(\pm1\), so \(p(00)=1\). \(f(x)=x_1\): two \(+1\) and two \(-1\), so \(p(00)=0\). AND: \(\frac14(3-1)=\frac12\), so \(p(00)=\frac14\). (c) The target ends in \(\ket-\) on every branch, so it keeps no record of the input. The function values move into signs on the input branches, and those signs can reinforce or cancel at the common readout. Chapter 7 develops this effect, phase kickback.
Where this leads. Chapter 7 asks which global property of a function interference can extract, and prepares the target so that it keeps no record of the branch.