Spectra are implemented by calculating the Green's function. We calculate the complex energy dependent quantity: $$ G(\omega) = \bigg\langle \psi_i \bigg| T^{\dagger} \frac{1}{\omega - H + \imath \Gamma/2} T \bigg| \psi_i \bigg\rangle, $$ with $T$ and $H$ an operator given in second quantization and $\psi_i$ a many particle wavefunction.

- Example.Quanty
-- Creating a spectrum from a starting state psi -- a transition operator T -- and an Hamiltonian H G = CreateSpectra(H,T,psi)

For photoemission the transition operator $T$ would be an annihilation operator, for absorption the product of a creation and annihilation operator and for inverse photoemission a creation operator. In the section on standard operators we describe several possible transition operators related to real experimental situations.