Structural and vibrational spectroscopic studies of phase transitions in alkyl substituted ammonium nitrates and perchlorates