What does "commuting with the Hamiltonian" mean? In quantum mechanics an observable or an attribute to a particle (like spin) is conserved if and only if it commutes with the Hamiltonian. What does this mean? What observables do not commute with the Hamiltonian?
 A: Two operators $A$ and $B$ commute if (and only if) their commutator $[A,B]$ vanishes
\begin{equation}
[A,B] \equiv AB - BA = 0 \implies A,B\ {\rm commute}
\end{equation}
Consider a Hamiltonian operator for a single particle in 1 dimension
\begin{equation}
H = \frac{p^2}{2m} + V(x)
\end{equation}
where $x$ the position operator, $p$ is the momentum operator, and $m$ is the mass of the particle (which is just a number).
$x$ and $p$ have a commutator
\begin{equation}
[x,p]=i\hbar
\end{equation}
Using this, it is easy to see that $[H,x]\neq 0$, and $[H,p]\neq 0$ unless $V(x)$ is a constant. Therefore, in general, neither the position nor the momentum are conserved. The momentum is conserved only if the potential is constant.
A: Apart from two other answers, consider the Heisenberg picture and the equation of motion where its written as
$$\frac{dA}{dt} = - \frac{i}{\hbar} [A , H]$$
So if an operator commutes with the Hamiltonian, from the above equation its obvious that
$$\frac{dA}{dt} = 0$$
So the quantity attributed to $A$ is conserved.
A: In quantum mechanics, observables are represented by Hermitian operators. Mathematically, two operators $\hat A$ and $\hat B$ commute if $$\tag 1 [ \hat A, \hat B]=\hat A \hat B- \hat B \hat A = 0$$
Hermitian operators which satisfy (1) are also called compatible observables meaning that both can be measured simultaneously.
Hermitian operators which do not commute and do not satisy (1) are called incompatible observables, and a good example of this in quantum mechanics are the canonical commutation relations.
Now:
Operators or observables that commute with the Hamiltonian of the system are conserved quantities, e.g. angular momentum or spin. This means that these quantities do not change with time. Those that do not commute with the Hamiltonian, are not conserved quantities.
To summarise, if $\hat H$ is the Hamiltonian of the system then if
$$[\hat H, \hat O] = 0$$ then $\hat O$ is conserved and $$\frac{d \hat O}{dt}=0$$ but if
$$[\hat H, \hat O] \ne 0$$ then $\hat O$ is not conserved and $$\frac{d \hat O}{dt} \ne 0$$
Commutation relations also do not depend on our choice of basis meaning they work just as well in coordinate space as they do in momentum space. This is a powerful result used in quantum mechanics.
A: Most observables do not commute with the Hamiltonian:
$$
[\hat A,\hat H]\equiv \hat A\hat H-\hat H\hat A\ne 0\, .
$$
For instance, if the potential is not constant, it will not in general commute with $\hat H$; neither will the kinetic energy operator for that matter.
Since for the simplest operators $[\hat A,\hat B]=i\hbar\widehat{\{A,B\}}$, where $\{A,B\}$ is the classical Poisson bracket, the statement that two operators commute is the quantum version of the statement that two classical quantities Poisson-commute, and the statement that an operator is conserved if it commutes with $\hat H$ is the quantum version of the well-known statement that a classical quantity will be conserved when it Poisson-commutes with $H$.
