# How does Spin Measurement correspond to quantum NOT gate?

Newbie in quantum computing (and stack overflow) here. I am confused regarding the relation between spin measurement in quantum mechanics and the quantum NOT gate.

I have a Bloch sphere picture of a single qubit in mind:

From the Stern-Gerlach experiment, we know that for spin oriented in the z-direction ($$|0\rangle$$ or $$|1\rangle$$) with a detector oriented in the z-direction ($$S_z$$) to leave the spin of the particle unchanged, whereas if our detector was tilted to be aligned with the x-axis ($$S_x$$), then there is a 50% probability of our detector outputting $$\hbar/2$$ and orienting the particle in $$|+X\rangle$$, and there is a 50% probability of our detector outputting $$-\hbar/2$$ and orienting the particle in $$|-X\rangle$$. However, we also know that the quantum NOT (bit-flip) gate is simply applying Pauli matrix $$\sigma_x$$

such that $$\sigma_x |0\rangle$$ = $$\sigma_x \begin{bmatrix} 1 \\ 0 \end{bmatrix}$$ = $$\begin{bmatrix} 0 \\ 1 \end{bmatrix}$$ = $$|1\rangle$$ and similarly $$\sigma_x |1\rangle$$ = $$|0\rangle$$.

I guess I see how the matrix multiplication works out for the NOT gate, but this doesn't seem to fit with our SG-experiment picture! We know $$S_x = \frac{\hbar}{2} \sigma_x$$, it seems as if applying $$S_x$$ on $$|Z+\rangle$$ (aka $$|0\rangle$$) doesn't orient the spin to $$|X+\rangle$$ or $$|X-\rangle$$, but instead simply flips the spin to $$|Z-\rangle$$.

Where does my intuition go wrong? Is applying a NOT gate to a qubit and "measuring" a qubit with a perfectly oriented detector not the same thing? (If not, how do we physically apply a gate on a qubit?)

• Be careful those big Stern-Gerlach boxes X and Z, represent a measurement in x and z direction, respectively, and not Pauli gates May 25, 2021 at 11:01
• @Mauricio Thanks for the comment! I think this is the exact point in which I was confused.... spin measurement operators for a spin-1/2 particle are scaled versions of the Pauli matrices (2.38 in depts.washington.edu/jrphys/ph248A11/qmch2.pdf). However, this spin operator suggests that when I take a x-measurement of a z-oriented particle, I get a definite outcome (not random) for the orientation of the particle after our measurement :(
– Nav
May 27, 2021 at 2:28