Query algorithms ยท Algorithms

Deutsch-Jozsa algorithm

Theorem statement

Suppose $f:\{0,1\}^n\to\{0,1\}$ satisfies exactly one of the following two conditions: either $f(x)=f(x')$ for all $x,x'\in\{0,1\}^n$, or $|f^{-1}(0)|=|f^{-1}(1)|=2^{n-1}$. Given access to an oracle $O_f$ such that $O_f\ket{x,y}=\ket{x,y\oplus f(x)}$, there exists a quantum circuit that uses one query to $O_f$ and $2n+1$ Hadamard gates to determine which condition holds with certainty.

Sources

  1. Quantum Algorithms Revisited

    Richard Cleve, Artur Ekert, Chiara Macchiavello, Michele Mosca, 1998

  2. Quantum Computing: Lecture Notes

    Ronald de Wolf, 2019

  3. Rapid solution of problems by quantum computation

    David Deutsch, Richard Jozsa, 1992

Lean context

Copy a short prompt with the import, theorem name, citations, and public source link.

Open Lean source