Solution
ID: past-exam-of-the-mathematics-course-of-the-university-of-cambridge/2014/iii/paper-61/1/b/ii/solution
Past exam of the mathematics course of the University of Cambridge 2014 iii Paper 61 1 b ii Solution by
Codex 0 Created 2026-10-03 Updated 2026-10-06
The linear decoding must be done coherently, so its output is available inside the next Boolean quantum oracle call. Use registers of qubits and a shared phase ancilla qubit in . Define the Bernstein-Vazirani decoding controlled by a quantum registerThe ancilla qubit is implicit. For every computational index , the Walsh-Hadamard transform calculation givesIn particular on these states. Initialize to and to . The three query stages areThe middle equality uses the matching index , not a classical guess of that string. The second performs uncomputation, removing the hidden-string register without losing its phase on . Apply to to obtainThis requires precisely two queries to and one to , and only additional fixed quantum gates. No measurement of is made: such a measurement would spoil the required coherence. Preparing all registers and the phase ancilla qubit uses only the initially available zero states.
New to topics? Read the docs here!