It turns out that degeneracy occurs whenever a nontrivial unitary operator U commutes with the Hamiltonian. To see this, suppose that | a ⟩ ⟩ is an energy eigenket. Then U | a ⟩ ⟩ is an energy eigenket with the same eigenvalue, since