Inversion of Stokes Profiles from Solar Magnetic Elements

Abstract
We describe a new LTE inversion code for the analysis of Stokes profiles emerging from unresolved magnetic elements. It has been specifically designed to obtain the thermal, dynamic, and magnetic properties of these structures in a self-consistent manner by fitting the whole shape of the observed spectra. The inversion code is based on a previous scheme by Ruiz Cobo & del Toro Iniesta and implements the thin flux-tube model as a reasonable description of reality. All physical parameters considered relevant for the problem (including velocity fields) are retrieved by means of a Marquardt nonlinear least-squares algorithm. We present the results of extensive tests aimed at characterizing the behavior of the code so as to understand its limitations for the analysis of real observations. The code is found to produce accurate results even with only two spectral lines and noisy Stokes I and V profiles. A detailed error treatment, in which the covariances between parameters are explicitly included, is also carried out in order to investigate the uniqueness and reliability of the inferred model atmospheres.