The Inverse QFT
The inverse QFT (written or ) undoes the quantum Fourier transform. It is an essential building block of quantum phase estimation and Shor's algorithm: after the QFT encodes a phase into register amplitudes, the inverse QFT reads that phase back out as a measurable bit string.
Inverting a unitary circuit
Every quantum gate is unitary, so its inverse is its conjugate transpose. For a product of unitaries the reversal rule is
To invert a circuit, reverse the gate order and replace each gate with its adjoint. Two useful special cases:
- The Hadamard is self-inverse: .
- The controlled-phase gate conjugates as , because negating the angle complex-conjugates the phase .
The 3-qubit inverse QFT
Recall the 3-qubit forward QFT (without final bit-reversal SWAPs), with qubit 0 as the most significant bit:
| Step | Gate | |------|------| | 1 | | | 2 | | | 3 | | | 4 | | | 5 | | | 6 | |
Applying the reversal rule gives the inverse QFT:
| Step | Gate | |------|------| | 1 | | | 2 | | | 3 | | | 4 | | | 5 | | | 6 | |
The structure is a mirror image of the forward circuit: the coarsest qubit () is processed first, and the phase rotations go in the negative direction.
Why it matters
In quantum phase estimation, a register is left in a state whose amplitudes encode a phase as for each basis state . Applying transforms that "Fourier-encoded" state back to a computational-basis state close to , making directly readable by measurement. Without the inverse QFT, the phase information would be locked in the amplitudes and inaccessible.
The gate count of is identical to that of the QFT: Hadamards and controlled-phase gates, totalling operations for an -qubit register.
Try it
Implement the 3-qubit by reversing the forward QFT's gate sequence and negating all phase angles. The grader checks the full unitary matrix — leaving the circuit empty or incorrect will fail.
Sign in on the full site to ask questions and join the discussion.