More than a century has elapsed since George Ellery Hale in 1908 succeeded in performing for the first time the polarimetric analysis of the light coming from an astronomical object. He observed a sunspot on our nearest star, and thus discovered the existence of a magnetic field on a celestial object far away from earth. With the work of Hale, a new discipline entered the realm of Astronomy: polarimetry or spectropolarimetry. This discipline has revealed of being one of the most powerful tools available to mankind for diagnosing the physical structure of celestial objects, with particular emphasis on geometrical effects and on the presence of agents capable of breaking the symmetry of the emitting body, like for instance the magnetic field.
Things have rapidly evolved since the discovery of Hale. Thanks to the development of new technologies, we are nowadays capable of measuring polarization signals with unprecedented sensitivities (one part over 100,000 in unresolved solar observations performed in the visible). This has raised a serious challenge to the theoretical interpretation of the polarimetric signals observed from celestial objects either in the continuum spectrum or across spectral lines. There are indeed several different mechanisms capable of generating polarization signatures in spectral lines and many others that can modify them during the propogation in an astrophysical environment. Some of these mechanisms have been known since a long time from laboratory atomic physics (Zeeman effect, resonance polarization, Hanle effect, collisional quenching, etc.). Other mechanisms are charactersitic of optically thick plasmas and are related to the propagation of radiation in anisotropic media (dichroism effects, anomalous dispersion effects, etc.).
In the present talk we will review the basic physical mechanisms that are involved in the generation (or in the relaxation) of polarization in astrophysical environments and in the transfer effects that polarization suffers during its propagation in an optically thick medium. The last part of the talk will be devoted to pinpoint the relevant aspects of spectropolarimetry in the development of the more modern theoretical methods that are nowadays used for the diagnostics of solar magnetic fields.