Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 4 10D b Solution Created 2026-09-24 Updated 2026-10-03
Choose a power of two withSince the multiplicative order is less than , this guarantees . Prepare two quantum registers in the stateand use quantum modular exponentiation to obtain
Measure the second register. The order as the exact period of modular exponentiation implies that, conditional on the measured value, the first register is a normalized truncated periodic cosetwhere is the largest integer for which .
Apply the quantum Fourier transform to the first register and measure it, obtaining . The supplied Fourier-transform theorem states that, with probability of order , is an integer nearest to for some coprime to . On that event,The supplied continued-fraction theorem, applied through continued-fraction recovery in quantum order finding, therefore recovers the reduced fraction from . Because and are coprime, its denominator is the exact order . The candidate is checked classically by verifying .
The quantum Fourier transform, quantum modular exponentiation, continued-fraction algorithm, and final modular check all take polynomial time in . Since , the successful event has probability of order , as required.