In case of lanthanoids, 4f orbitals lie too deep and hence the magnetic effect of the motion of the electron in its orbital is not quenched out. Here spin contribution S and orbital contribution L couple together to give a new quantum number J. Thus magnetic moment of lanthanoids is given by, $\mu \, = g \sqrt{J(J+1)}$ where J = L - S when the shell is less than half fill J = L + S when the shell is more than half fill and $g=1\frac{1}{2}+ \frac{S(S+1)-L(L+1)}{2J(J+1)}$