The magnetic quantum number formula_29 only affects the electron's energy if it is in a magnetic field because in the absence of one, all spherical harmonics corresponding to the different arbitrary values of formula_29 are equivalent.