2
$\begingroup$

In the quantum search algorithm below, also known as Grover's algorithm, what observable do we measure at the end of the protocol?

That is, in the red box, it says "measure the first $n$ qubits", but which observable are we measuring?

Thanks.

enter image description here

$\endgroup$
3
$\begingroup$

Usually, when we don't specify, we measure in the computational basis, i.e. each qubit is measured using the observable $Z$.

$\endgroup$
2
  • $\begingroup$ I see, but in that case, how can we output the string of classical bits $x_0$ by measuring Z on the final state of the algorithm? Since the possible outcomes of Z are 1 and -1. Do we simply agree to associate the outcome 1 to the bit 0, and the outcome -1 to the bit 1? $\endgroup$ – Stephen Feb 11 '20 at 21:04
  • $\begingroup$ Yes exactly. We measure every qubit in Z basis, and if you get a 1 as output for the nth qubit, then you set the nth bit of $x_0$ to be 0, if you get a -1 then you set the bit to 1. $\endgroup$ – Léo Colisson Feb 11 '20 at 23:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.