Formation energy, Ef, as a function of Fermi level, εF. Ef was calculated for various defects in (A) diamond and (B) 4H-SiC (in C-rich conditions). The shaded areas show the range of stability of NV-1 in diamond, and (Blue), (Green), and (Purple) in SiC.