Outgoing multiphonon resonant Raman scattering and luminescence in Be- and C-implanted GaN