Let $\mathcal H$ be a Hilbert space and let $A,B$ be two unbounded, densley defined self-adjoint operators on $\mathcal H$ with $dom(A) = ran(A) = dom(B) = ran(B)$. Then both $AB$ and $BA$ are unbounded, densley defined operators with the same domain, so $$AB - BA$$ is again an unbounded, densely defined operator.
Question: Are the following statements equivalent ?
a) $AB - BA = 0$
b) For any bounded borel function $\phi$ over $\mathbb R$, $F_A$ the Borel functional calculus of $A$, and any $x \in Dom(B)$, we have $[F_A(\phi)B - BF_A(\phi)](x) = 0$.
The analogue statement for bounded operators is an immediate consequence of the spectral theorem. However, I don't quite see how to generalize the statement to the unbounded case, since the operator $A$ is only indirectly "seen" by its functional calculus $F_A$.
The answer is no.
First of all, $dom A=ran A$ can hold only for bounded self-adjoint operators.
The statement b) in your question implies the so-called strong commutativity of $A$ and $B$, in particular, that the unitary operators $e^{iA}$ and $e^{iB}$ commute.
In the book by Reed, Simon "Methods of mathematical physics" vol.1, chapter 8 there is an example of self-adjoint operators, such that $AB=BA$ holds on the common domain, but exponentials $e^{iA},e^{iB}$ do not commute.