Emission and absorption spectra simulation