Applying Hadamard twice
It seems that the Hadamard gate would delete any information stored in the qubit, because no matter if the initial value is \(\ket{0}\) or \(\ket{1}\), the probability to measure one or the other is 50% in both cases. Thus, according to our measurements, the two states appear indistinguishable. But is that really the case?
My measurements
This time you do not need to perform measurements yourself. As soon as you change the circuit, it is evaluated and the statistics are updated accordingly. After 1000 measurements we get the following distribution:
-
A
Even though, the measurement results are \(\ket{0}\) or \(\ket{1}\) randomly, the qubit is always in a clearly defined state. Otherwise we would not be able to retrieve the state with applying the H gate twice.
-
B
There are three states: \(\ket{0}\), \(\ket{1}\) and a random state as applying a second H gate will transform a qubit into the \(\ket{0}\) or \(\ket{1}\) state randomly.
That's right! Applying Hadamard twice returns the qubit to its initial state again. From this we can conclude that the information stored in the qubit has not been lost. This means that even if the measurement results appear purely random, the qubit was nevertheless in a well-defined state.
Not quite! Applying Hadamard twice returns the qubit to its initial state again. From this we can conclude that the information stored in the qubit has not been lost. This means that even if the measurement results appear purely random, the qubit was nevertheless in a well-defined state.
Answer the question to continue ...
This means we need to differentiate the location on the equator of our Bloch sphere. The rotation angle is now an important part of our quantum state. The state we are in after applying H to a qubit in state \(\ket{0}\) is opposite to the state we are in after applying H to a qubit in state \(\ket{1}\).
All operations can then be thought of as a rotation around some axis of the sphere. The X gate is a 180° rotation along the axis going through the equator. The H gate is a rotation around the diagonal axis between the x and z axis.