Effect of Pressure on the Spectra of Transition Metal Ions in MgO and Al2O3