🌱Aadam's Garden

Search

Search IconIcon to open search

Phase Oracle

Last updated Jun 23, 2022

Phase oracle is a representation of quantum oracle where the answer Qubit is unchanged and only the input qubit is multiplied by a phase. 1

We first need to set the answer qubit $\ket{y}$ to $\ket{-}$ $$\ket{x}\ket{0} \xrightarrow{I\otimes X} \ket{x}\ket{1} \xrightarrow{I \otimes H} \ket{x}\ket{-}.$$
If we expand $\ket{x}\ket{-}$, we get $(-1)^{f(x)}\ket{x}\ket{-}$. We can interpret this as the answer qubit staying in the $|−⟩$ state while the input qubit goes from $|x⟩$ to $(−1)^{f(x)}|x⟩$, i.e. the input qubit acquires a phase. This is called phase kickback.

Often, we drop the answer qubit, since it stays in the $|−⟩$ state, and only write the input qubit: $$\ket{x} \xrightarrow{U_f} (-1)^{f(x)}\ket{x}.$$