Solution (source code)

= Solution

An <observable> is represented by a <self-adjoint operator>. For an ideal <projective measurement>, let $P_a$ be its spectral projector for outcome $a$. The <Born rule> gives $p(a)=\langle\psi|P_a|\psi\rangle$, or $p(a)=\operatorname{tr}(\rho P_a)$ for a <density matrix> $\rho$. Conditional on obtaining $a$, the <Lüders rule> gives
$$
\boxed{|\psi\rangle\longmapsto\frac{P_a|\psi\rangle}{\sqrt{p(a)}},\qquad \rho\longmapsto\frac{P_a\rho P_a}{p(a)}.}
$$
For a degenerate outcome this projects onto the whole associated <eigenspace>, rather than arbitrarily selecting a vector within it. An immediate repeated ideal measurement returns the same outcome, provided there is no intervening evolution or disturbance.

Commuting finite-dimensional <observables> admit a common <orthonormal eigenbasis>; their projectors commute and ideal joint measurements are compatible. Noncommuting <observables> generally have no complete common <eigenbasis>, and measurement order can affect the subsequent statistics. Particular common <eigenvectors> can nevertheless exist, so a nonzero <commutator> does not mean that every state has a nonzero uncertainty in both quantities.

For a quantitative constraint, apply the <Cauchy-Schwarz inequality> to $(A-\langle A\rangle)|\psi\rangle$ and $(B-\langle B\rangle)|\psi\rangle$. The imaginary part of their <inner product> is $\langle[A,B]\rangle/(2i)$, giving the <Robertson uncertainty principle>
$$
\boxed{\Delta A\,\Delta B\geq\frac12|\langle[A,B]\rangle|.}
$$
The <canonical commutation relation> $[x,p]=i\hbar$ gives $\Delta x\,\Delta p\geq\hbar/2$. Retaining the real part of the same <inner product> gives the stronger <Robertson-Schrödinger uncertainty relation>, including a <covariance> term. These are constraints on the preparation of a <quantum state>, not simply statements about a poorly calibrated instrument.

A sequential <spin one-half> example makes the change in statistics explicit. Prepare $|+z\rangle$. An immediate $S_z$ measurement is certainly positive. If an $S_x$ measurement is inserted first, its outcomes each have <probability> $1/2$ and leave states $|\pm x\rangle$. Each then yields either $S_z$ result with <probability> $1/2$, so the final positive fraction is $1/2$. The change reflects projection onto incompatible <spin eigenstates>, even with ideal measuring apparatus. The theory of <measurement in quantum mechanics> allows more general state-update rules, but the operator description and the <Born rule> still constrain their <probabilities>.