nv cavity qed tutorial