The light we receive from a given galaxy is emitted by a large number of stars that may have different masses, ages, and metallicities. In order to interpret the observed spectral energy distribution, we need to predict how each of these stars contributes to the total spectrum. Unlike many of the ingredients in galaxy formation, the theory of stellar evolution, is reasonably well understood. This allows us to compute not only the evolution of the luminosity, color and spectrum of a star of given initial mass and chemical composition, but also the rates at which it ejects mass, energy and metals into the interstellar medium. If we know the star-formation history (i.e. the star-formation rate as a function of time) and IMF of a galaxy, we can then synthesize its spectrum at any given time by adding together the spectra of all the stars, after evolving each to the time under consideration. In addition, this also yields the rates at which mass, energy and metals are ejected into the interstellar medium, providing important ingredients for modeling the chemical evolution of galaxies .
Most of the energy of a stellar population is emitted in the optical, or, if the stellar population is very young (∼ < 10Myr), in the ultraviolet . However, if the galaxy contains a lot of dust, a significant fraction of this optical and UV light may get absorbed and re-emitted in the infrared. Unfortunately, predicting the final emergent spectrum is extremely complicated. Not only does it depend on the amount of the radiation absorbed, it also depends strongly on the properties of the dust, such as its geometry, its chemical composition, and (the distribution of) the sizes of the dust grains .