First, what is light?
Most of the light that we perceive is made from many colours. For example, what we experience as “white” light is a mixture of many colours. What we perceive as a coloured light is only the result of a dominant set of colours over others. But talking about colours can be misleading. Light itself is actually a set of electromagnetic waves. Each of these waves can be identified by its wavelength, which ranges from the radio to the gamma rays. A “colour” is therefore a specific wavelength within the whole range of the light. With our human eyes, what we perceive as light is only limited to a small part of the spectrum, called the visible light. Infra-red, X-rays, Ultra-violet wavelengths are therefore invisible to us, while other animals can have access to some of these ranges (for example, snakes have the ability to sense heat thanks to their infrared vision).
What is a spectrum?
The light that comes from our Sun is in majority ‘’white’’ light, meaning that it is made from a large mix of different wavelengths. Prisms can separate the colours, or the wavelengths of the light. Nature for example showcases beautiful rainbows as raindrops, acting like millions of tiny prisms and fanning out the sunlight into its multiple colours. Rainbows, and more generally the different wavelengths of the light, can be split into multiple components experimentally with prisms and diffraction grating. A spectrum is therefore the result of splitting the light into its many wavelength components.
What information does a spectrum give?
First, the spectrum provides a splitting between different wavelengths in an order manner. Each wavelength is associated with the energy that is transported by the associated portion of light. For example, the light carried by long wavelengths has low energy, while the light carried by short wavelengths has high energy. A spectrum therefore shows the amount of brightness of the light at each of the energy (or wavelength) range.
The spectrum of the light gives us information on what is the composition of the source of light. In the case of the Sun, the many "rays" we see in the spectrum give us an clear picture of what are the ions that compose the Sun's atmosphere.
Spectroscopy not only gives us an idea of the chemical composition of the Sun as a source of light, it also gives an idea of how the "soup of ions and electrons" that makes the Sun's atmosphere moves. We see this as a shift in the spectrum, or blue/redshift.
SPICE, which focuses on the Sun's atmosphere, will also informs us about the density, temperature of the region we are looking at, the turbulence, the abundance of elements... It's a rich science that provides many insights on this very hot atmosphere!
Lines vs continuum
Looking at a spectrum, one can point out two trends. The first trend is the smooth underlying curve that makes most of the spectrum. This curve comes from the large-scale emission produced by the light source (for example, an excited gas or a plasma). In the example of a star, which is made of plasma, the continuum is the same as the blackbody continuum. Different continua exist (for example, a supernova remnant has a different continuum than a normal star, due its relativistic particles). At the atomic level, the continuum emission is due to the capture of a free electron (with “continuum” energy) by a nearby proton. The electrons, when captured by the proton, slow down and therefore lose energy. This energy is in fact emitted in the form of light by a processus called the bremsstrahlung radiation, which is a continuum-emitting process.
The second trend is the peaks (and sometimes “wells”) in the spectrum that are superposed on the continuum and called emission lines. Similarly to the continuum, the peaks are due to radiation (light) emitting or absorbing processes at the atomic level. However, contrary to the continuum, the electrons involved are those already within the atoms. Picturing an atom as a nucleus made of neutrons and protons and surrounding electrons, electrons actually orbit at different, discrete levels. While electrons preferentially fill first the lowest energy level-orbits, they can move to higher energy level-orbit by collision or because they absorb energy from passing light: this is an “excited” state. However, they will eventually go back to lower energy levels, therefore releasing discrete packets of energy (again, in the form of light). Because this light has a discrete energy, and therefore an associated wavelength, the release of energy is imprinted at one point only in the spectrum, where the emission line forms. Finally, because the discrete energy levels are different from one atome to another, from one excited state to another, studying the spectrum of a gas or a plasma tells us what are the elements that compose them and how numerous they are, how fast the gas or the plasma moves, what its temperature and its density are. Spectroscopy therefore allows us to interpret the language of light to understand the properties of its source.