How do astronomers use spectrographs?
Spectographs are used to identify the molecular and elemental composition of stars and interstellar gases.
All “spectroscopy” methods use light wavelengths from infrared to UV. The wavelength used will correspond to different characteristics of molecules and atoms.
Absorption spectroscopy measures the amount of a wavelength absorbed by a substance. Emission spectroscopy measures the amount of a wavelength emitted by a substance after excitation. In both versions, a molecule is interacted with by external light or energy, and the way that energy is used or transformed by the molecule is specific to its structure.
Infrared spectroscopy in organic chemistry is most often used to identify chemical structures from the characteristic adsorption of IR light by different organic functional groups. Thus, the existence of hydroxyl groups, double bonds, and other active parts of a molecule can be deduced.