DFT computation of relative spin-state energetics of transition metal compounds