First-principles Calculations of Phonons and Raman and Infrared Spectra in Cd-IV-N2 compounds