# If two operators commute, does it mean that every eigenfuction of one is also an eigenfunction of the other?

I have trouble interpreting the result of a problem. If we have a function $$\psi ( \theta , \phi) = e^{-3i\phi}cos \theta$$ and two operators $$A=\frac{\partial}{\partial \phi}$$ $$B=\frac{\partial} {\partial \theta}$$ It is clear that $$\psi(\theta, \phi)$$ is an eigenfunction of A and not B. But, on the other hand, I tried to evaluate the operator $$[A, B]$$ on a general function $$\psi(\theta, \phi)$$ that is separable, such that $$\psi(\theta, \phi)=\chi(\theta)\xi(\phi)$$, and therefore $$[A, B]\psi(\theta, \phi)=[A, B]\chi(\theta)\xi(\phi)=$$$$=\frac{\partial}{\partial \phi}\frac{\partial} {\partial \theta}(\chi(\theta)\xi(\phi)) - \frac{\partial} {\partial \theta}\frac{\partial}{\partial \phi}(\chi(\theta)\xi(\phi)) =$$$$=\chi'(\theta)\xi'(\phi)-\chi'(\theta)\xi'(\phi)=$$$$=\psi'(\theta, \phi)-\psi'(\theta, \phi)=0$$, which means that the commutator is 0 if applied to a separable function of $$\phi$$ and $$\theta$$. I know that if two operators commute, that means that they have a common set of eigenfunctions. Does "common set" mean that every eigenfunction of A is also an eigenfunction of B, or that some of the eigenfunctions of A are also eigenfunctions of B? I previously thought that it was the first choice, but here, $$\psi ( \theta , \phi) = e^{-3i\phi}cos \theta$$ is an eigenfunction of A only. Is there a way to find a general solution for functions that are eigenfunctions for both A and B?

The opposite however is not necessarily true: if the eigenfunctions are eigenfucntions of one operator, they do not have to be automatically the einegfunctions of the other. In this case it is obvious, since the operators act on different variables. However, it may also happen in the cases, where they act on the same variable: e.g., if one of the operators have degenerate eigenfunctions, they are not automatically the eigenfunctions of the other operators, but we can always construct their linear combinations, which will be the eigenfunctions of both. As an example one could take the operators of momentum and kinetic energy: $$\hat{p_x} = -i\hbar\partial_x, \hat{K}_x = -\frac{\hbar^2}{2m}\partial_x^2.$$ Functions $$\psi_c(x) = \cos(x), \psi_s(x)=\sin(x)$$ are eigenfunctions of the kinetic energy, but not of the momentum. We can however combine them into $$\psi_\pm(x) = \psi_c(x) \pm \psi_s(x) = e^{\pm ikx},$$ which will be eigenfunctions of the momentum operators, while remaining the eigenfunctions of the kinetic energy.