For brackets the control-zero branch still does nothing, and the control-one branch applies to the target. Immediately before the final two Hadamard gates, the quantum state isFor the constant function with , the phase oracle is , so . Since is an eigenstate of the Pauli X gate with eigenvalue , for every integer . The final two Hadamard gates therefore giveIn particular, the first qubit always ends in .
For the constant function with , and , so . Thus the target remains in , and the top qubit before its final Hadamard gate is . The sign is a relative quantum phase between the control branches. The Hadamard gate converts it into the integer parity of :The first qubit is therefore for even and for odd , including all requested .
Articles by others on the same topic
There are currently no matching articles.