Vibrational modulation effects of diatomics in rare gas matrices