Original search algorithm and the O(√N) query comparison with classical search.
arxiv.org/abs/quant-ph/9605043 ↗Grover unstructured search
The canonical search primitive, paired with the linear classical baseline it is meant to improve.
Atlas stars stay in the public catalog. Saving this entry to your workspace starts an unstarred private copy.
Grover amplifies the amplitude of marked states using an oracle and a diffusion step. It is useful for testing whether a claimed speedup includes oracle construction and readout costs.
Circuit & simulation
What this takes and returns
TakesNothingWhat joins here
No input port at this edge: the record publishes no gate sequence and no register, so there is nothing here to read one off — and unlike a declared hole, nothing has been recorded about what belongs here.
Nothing in the Atlas meets this end.
ReturnsNothingWhat joins here
No output port at this edge: the record publishes no gate sequence and no register, so there is nothing here to read one off — and unlike a declared hole, nothing has been recorded about what belongs here.
Nothing in the Atlas meets this end.
This record publishes no gate sequence and no register, so there is nothing here to read an interface off. Absent rather than empty. See all 152 →
Where this sits
This record is named by the layer graph at:
- Fixed-iteration amplitude rotation Method
Takes A check evaluable in superposition on any candidate, the size of the domain it ranges over, and the promise that fixes the schedule — Grover assumes exactly one accepted candidate; a method may instead require the check to answer about partial commitments rather than whole candidates. Returns One accepted candidate, with the number of queries spent and the probability the answer is right — or the report, at a stated confidence, that the domain holds none.
How it works
For an unstructured search space of size with a single marked item, Grover's algorithm reaches the marked state with high probability using oracle queries, versus expected queries for classical exhaustive search — a quadratic query-complexity separation, not a claim about wall-clock time on any given hardware. The construction alternates an oracle that flips the sign of the marked amplitude with the diffusion operator ; each pass rotates the state by (where ) toward the marked subspace, and the success amplitude after iterations is , so overshooting past the optimal actually reduces success probability. This record's two-qubit () toy oracle and diffusion layer are checked against the ideal circuit — small-instance evidence for the construction — while the asymptotic claim rests on the cited literature and assumes a coherent oracle where oracle calls, not classical readout, dominate cost.
Implementation
from qiskit import QuantumCircuit
qc = QuantumCircuit(2)
qc.h([0, 1])
# Oracle marks one basis state.
qc.cz(0, 1)
qc.h([0, 1])
qc.x([0, 1])
qc.cz(0, 1)
qc.x([0, 1])
qc.h([0, 1])
FINAL_CIRCUIT = qcThe oracle is intentionally small so the circuit can be inspected. Scaling claims belong to the cited query-complexity result.
Quantum vs classical
| Metric | Classical | Quantum |
|---|---|---|
| Query complexity | O(N) | O(√N) |
| Queries (1 of N marked) | ~N/2 avg | ⌊(π/4)√N⌋ |
| Register (N = 2ⁿ) | n bits | n qubits |
| Asymptotic speedup | baseline | quadratic |
Classical baseline
Linear scan or a classical indexed data structure, depending on whether the oracle is already available.
Quantum claim
Quadratic improvement in oracle queries for an unstructured search problem.
How to compare
Include oracle synthesis, state preparation, error correction, measurement repetitions, and data-loading costs before calling it an application speedup.
Declared gaps
Nobody has reviewed this record for gaps yet.