\documentclass[11pt]{article}


% tth -e2haicV -Ltalk < talk.tex >! all.htm

\usepackage{epsfig}
%\usepackage{psfig}
%\usepackage{longtable}
%\usepackage{rotating}


\setlength{\oddsidemargin}{0in}         %  1 inch (0 + 1) from left.

%\setlength{\topmargin}{-0.5in}          %  1 inch (1.5 - 0.5) from top.
\setlength{\topmargin}{-1.in}          %  1 inch (1.5 - 0.5) from top.

\setlength{\textwidth}{6.5in}           %  1 inch (8.5 - 1 - 6.5) from right.
%\setlength{\textheight}{9in}            %  1 inch (11 - 1 - 9) from bottom.

\setlength{\textheight}{10.5in}            %  1 inch (11 - 1 - 9) from bottom.

%newcommand{\arcmin}{\hspace{-0.25em}\mbox{\,$\amin$}}           % arcminutes 
%\newcommand{\arcsec}{\hspace{-0.25em}\mbox{\,$\asec$}}           % arcseconds

\newcommand{\arcsec}{\hbox{$^{\prime\prime}$}}
\newcommand{\arcmin}{\hbox{$^{\prime}$}}

\newcommand{\beq}{\begin{equation}}
\newcommand{\eeq}{\end{equation}}

\newcommand{\bi}{\begin{itemize}}
\newcommand{\ei}{\end{itemize}}

\newcommand{\x}{$\times$} 
\newcommand{\deltE}{\Delta\kern-1ptE}

\newcommand{\lo}[1]{\mbox{$\rm _{#1}$}}
\newcommand{\up}[1]{\mbox{$\rm ^{#1}$}}

\newcommand{\Ne}{$N_{\rm e}$}
\newcommand{\Te}{$T_{\rm e}$}

\newcommand{\cm}{cm$^{-3}$}
\def\rsun{R$_\odot$}


\def\hyperlink#1#2{\special{html:<a href="\##1">}#2\special{html:</a>}}
  % Incorrect link name in \TeX\ because # can't be passed properly to a special.
\def\hypertarget#1#2{\special{html:<a name="#1">}#2\special{html:</a>}}
\long\def\tthdump#1{#1} % Do nothing. The following are not done for TtH.
\tthdump{%
\def\title#1{\bgroup\leftskip 0 pt plus1fill \rightskip 0 pt plus1fill
\pretolerance=100000 \lefthyphenmin=20 \righthyphenmin=20
\noindent #1 \par\egroup}% Centers a possibly multi-line title.
 \let\author=\title % Actually smaller font than title in \LaTeX.
 \input epsf     % PD package defines \epsfbox for figure inclusion
  % Macro for http reference inclusion, per hypertex.
 \def\href#1#2{\special{html:<a href="#1">}#2\special{html:</a>}}
 \def\urlend#1{#1\endgroup}
 \def\url{\begingroup \tt 
  \catcode`\_=13 % Don't know why this works.
  \catcode`\~=11 \catcode`\#=11 \catcode`\^=11 
  \catcode`\$=11 \catcode`\&=11 \catcode`\%=11
\urlend}% \url for plain \TeX.
}

\setlength{\parindent}{0in}
\bibliographystyle{plain}               % Define bibliography style.

%%tth: \begin{html} <title> SOHO CDS Guide </title>  \end{html}
%%tth: \begin{html} <BODY BGCOLOR=FFFFFF> \end{html}

\begin{document}

\centerline{\Large\noindent\bf  Spectral diagnostics in the EUV }

\vspace{4mm}
\centerline{ Giulio Del Zanna  \quad (G.Del-Zanna@damtp.cam.ac.uk)}
~\\
\centerline{DAMTP, University of Cambridge}
~\\
\centerline{Sept 2004, advanced summer school, Egham }


\section{Introduction}

These lecture notes are a compilation of various 
material that I largely produced by myself, with 
some contributions from Helen Mason (DAMTP).

For further  details, see 
 e.g.: Mason and Monsignori Fossi (1994); 
my PhD Thesis, available on-line at:


 \url{http://www.damtp.cam.ac.uk/user/astro/gd232/astro.html}

Del Zanna et al. (2002),
and the CHIANTI user guides that I wrote, which can be 
found in the WWW pages, e.g.:

 \url{http://www.chianti.rl.ac.uk/}

and, of course, all the references therein.

\section{Spectrometers - CDS}


Do not be discouraged by the complexities of any 
spectrometer, for spectroscopic
 data have a great diagnostic  potential !
I will give as an example a brief overview of the 
Coronal Diagnostic Spectrometer on-board SOHO.

More information can be found on the CDS main WWW pages:

\url{http://solg2.bnsc.rl.ac.uk/}


\begin{figure}[htpb]
\centerline{\epsfig{figure=cds.ps,width=8.0cm, angle=-90}}
\caption{The optical layout of the CDS instrument.}
\label{fig:cds_layout}
%Figure~\ref{fig:cds_layout}
\end{figure}


The CDS instrument (Figure~\ref{fig:cds_layout}) consists of a 
Wolter-Schwartzschild  %-Schwartzschild 
 type II  grazing incidence telescope, a scan mirror, a set of 
different slits,   and two 
spectrometers that do not observe simultaneously, 
the normal incidence spectrometer (NIS)
and the grazing incidence spectrometer (GIS).


The slits provide various fields of view (2\arcsec \x 2\arcsec, 4\arcsec \x 4\arcsec,
2\arcsec \x 240\arcsec, 4\arcsec \x 240\arcsec, 90\arcsec \x 240\arcsec,
 8\arcsec \x 50\arcsec)
 and are  normally oriented along the solar N-S direction.
 Note that 1\arcsec\ corresponds on the Sun 
to $\simeq$700 km.

The normal incidence spectrometer (NIS)
is composed of two normal incidence 
gratings that disperse the light into the NIS detector.
The gratings are slightly tilted, in order to produce two
wave-bands  
(NIS 1: 308  -- 379 \AA\ and NIS 2: 513 -- 633 \AA;) on the same 
detector, one on top of the other.
The spectral resolution is  $\simeq$ 0.35 \AA~ for NIS 1 
and $\simeq$ 0.5 \AA~ for NIS 2.

The NIS  can provide monochromatic  images of the solar field of view.
This is accomplished with the {\it rastering}  
of a region, moving a mirror and producing contiguous 
images of one of the  long slits. 
The internal scan mirror and slit movement of CDS allow CDS rasters to
               cover a maximum area of 4' square within a single
               raster.  The
               E-W coverage is created by the scan mirror which can
	       move in steps of 2.03".
 Movement can only be in one direction from West to East. 

%               In NIS the N-S coverage is usually provided by the
%               long slit (normal slits are 2"x240" or 4"x240").  


Telemetry constraints usually  make it necessary to
pre-select a number of NIS wavelength windows to be extracted
on-board  from the spectra, before the data are 
telemetered to the ground. 

With any spectroscopic instrument you will 
have a trade-off between the data you want and those 
you can telemter. With Solar Orbiter this will be a particularly
severe problem.



\begin{figure}[htpb]
\centerline{\epsfig{file=s90_GIS1234.ps, width=10.0cm,angle=90 }}
  \caption{[from Del Zanna(1999)]  The first light  GIS spectra of a coronal hole (s90)}
 \label{fig:first_sp1}
\end{figure}

\begin{figure}[htpb]
\centerline
{\epsfig{file= s132_GIS1234.ps,  width=10.0cm,angle=90 }}
  \caption{[from Del Zanna(1999)]  One of the first series of GIS spectra of a quiet sun (s132) region.}
 \label{fig:first_sp2}
\end{figure}


\begin{figure}[htpb]
\centerline{\epsfig{file=ar_GIS1234.ps, width=10.0cm,angle=90 }}
  \caption{[from Del Zanna(1999)]  The first light  GIS spectra of an active region (s110). }
  \label{fig:first_sp3}
\end{figure}


 A series of observed  spectra (black), with superimposed 
CHIANTI synthetic spectra (blue +shaded areas), with second order
contributions (red +shaded areas) is provided. 


\begin{figure*}[htpb] 
 \centerline{\epsfig{file=may_4_97_off_mir5_obs_sint_nis1.ps,
 width=10.0cm , angle=90 }}
 \centerline{\epsfig{file=23_may_99_obs_sint_nis1.ps,width=10.0cm , angle=90 }}
\caption{Top:
The NIS 1 spectrum of an  off-limb quiet sun observation
               (May 4th 1997), with corresponding synthetic spectrum
               overlaid. 
Below: the NIS spectrum  after SOHO loss [on-disc].
}
\end{figure*}


\begin{figure*}[htpb] 
\centerline{\epsfig{file=oct_16_97_mir0_obs_sint_nis2.ps, width=10.0cm, angle=90}}
\centerline{\epsfig{file=may_4_97_off_mir5_obs_sint_nis2_cut.ps,
    width=10.0cm , angle=90 }}
\caption{The NIS 2 spectrum of an on-disc (above) and off-limb (below)  quiet sun observation.
Note the large differences in the spectra.
}
\end{figure*}

\begin{figure*}[htpb] 
 \centerline{\epsfig{file=may_4_97_off_mir5_obs_sint_gis1.ps,
 width=10.0cm , angle=90 }}
 \centerline{\epsfig{file=may_4_97_off_mir5_obs_sint_gis2.ps,
 width=10.0cm , angle=90 }}
\caption{ The GIS 1 and GIS 2 spectra of an off-limb quiet sun observation
(May 4th 1997), with corresponding synthetic spectra overlaid. 
 These types of spectra have been mainly used  for the
               first order internal and cross-detector calibration.}
\end{figure*}
\label{fig:may_4_97_off_mir5_gis12}
% Fig.~\ref{fig:may_4_97_off_mir5_gis12}



\begin{figure*}[htpb] 
 \centerline{\epsfig{file=oct_16_97_mir0_obs_sint_gis3.ps, width=10.0cm , angle=90 }}
 \centerline{\epsfig{file=oct_16_97_mir0_obs_sint_gis4.ps, width=10.0cm , angle=90 }}
\caption[]{ The GIS 3 and GIS 4  spectra of an  on-disc  quiet sun
observation  (October 16th 1997), with corresponding synthetic spectra overlaid.
These types of spectra have been mainly used  for the
               first order internal and cross-detector calibration.}
\label{fig:oct_16_97_mir0_gis34}
\end{figure*}
% Fig.~\ref{fig:oct_16_97_mir0_gis34}


~\\

The  grazing incidence spectrometer (GIS) has a 
grazing incidence  spherical grating  that disperses the incident light 
 to four  microchannel plate (MCP) detectors placed along the Rowland Circle
(GIS 1: 151  -- 221 \AA,  
GIS 2: 256  -- 341 \AA, GIS 3: 393 -- 492 \AA\ and GIS 4: 659  -- 785 \AA;).

The spectral resolution of the GIS detectors is about 0.5 \AA.
Many second order lines have been observed in GIS 3 and GIS 4.

The GIS  is 
astigmatic, focusing the image of the slit along the direction of
dispersion but not perpendicular to it.  

Images of the Sun are obtained using a pinhole slit and combining 
movements of the slit and of the  scan mirror. 



\subsection{Wavelengths }


Always keep in mind that XUV spectrometers 
 do not have an accurate `standard' wavelength calibration,
and therefore
absolute  wavelength measurements are subject to various uncertainties.
Normally spectra have to be calibrated using observed chromospheric 
lines (if observed) or any other lines.

The issue of  rest wavelengths is a serious one.
For accurate analyses, the values found in the databases 
are not always the best ones to be used.
CHIANTI normally uses the values from the NIST database,
which in turn is a compilation of values found in the literature.
It is necessary to go back and read the original literature
to understand the uncertainties associated with measurements.

\subsection{Radiometric Calibration}


 \begin{figure*}[!htbp]
  \centerline{\epsfig{file=nis1_sens.ps, width=8.0cm,angle=90 }}
  \caption{[from Del Zanna 1999] The proposed CDS NIS 1  sensitivity  (solid line), 
 compared with the other  calibrations. The asterisks indicate the
  scaled values of the sensitivities, as derived from ratios of lines
  of the same ion observed within this detector. } 
  \label{fig:nis1_sens}
\end{figure*}
% Fig.~\ref{fig:nis1_sens}



This is an essential requirement.
An entire book could be written on this issue.
For details on the calibration of the SOHO instruments,
see
The Radiometric Calibration of SOHO, ISSI Scientific Report,
2002, Pauluhn,A., Huber M.C.E., von Steiger,R. eds.  

To understand the complexities of the CDS calibration
read 
the first (and still only) comprehensive in-flight
 calibration work:

Del Zanna, G., et al., 2001, A\&A 379, 708-734. 
{\it Solar EUV spectroscopic observations with SOHO/CDS. I. An in-flight
calibration study }
and my WWW pages:

\url{http://www.damtp.cam.ac.uk/user/astro/gd232/cds/}




\section{Spectral line profiles}


Line shifts and broadenings occurr all the times 
at all temperatures.
They give information about the dynamic nature
of the solar atmosphere. 
%The nature of this excess broadening puts constraints on
%possible heating processes.
Systematic redshifts in transition region
lines have been observed in both solar spectra and
stellar spectra of late type stars. On the Sun, outflows of
coronal material have been
correlated with coronal holes.

If the optically thin spectral lines can be fitted with gaussian profiles,
the intensity per unit wavelength $I_\lambda$ is
defined as:

\begin{equation}
I_\lambda ={I \over \sqrt{2 \pi} \sigma}
exp[-(\lambda - \lambda_0)^2 / 2 \sigma^2] \label{gauss-prof}
\end{equation}

where $I=\int I_\lambda d\lambda$ is the integrated intensity and $\sigma$
is the guassian width given by:

\begin{equation}
\sigma^2 = {\lambda^2 \over 2 c^2} ({2 k T \over M} + \xi^2) +
\sigma_I^2 \label{gauss-wid}
\end{equation}

for a Maxwellian velocity distribution of temperature $T$,
usually assumed to be the temperature
corresponding to peak abundance of the ion. Here M is the ion mass,
$\sigma_I$ is the gaussian instrumental width and
$\xi$ is the most probable non-thermal velocity for a 
Maxwellian velocity distribution.

The root-mean-square velocity 
$< v^2 >^{1/2}= (3/2)^{1/2} \xi$

\begin{figure}[!htbp]
\centerline{
\epsfig{file=HRTS_ntv.ps, width=9.0cm,angle=-90 }}
  \caption{[from Dere \& Mason 1993]
Non-thermal velocities from HRTS spectra.}
\end{figure}


\section{Is the plasma always optically thin ?}

Obviously not.
Many processes can affect the observed radiation.

\subsection{Absorption via photoionisation}


For example, absorption via photoionisation by 
overlying cool neutral hydrogen and helium (neutral 
or firstly ionised).
This is very common, in particular when prominences 
are observed, and in TRACE images.

\begin{figure*}[!htbp]
\centerline{
\epsfig{file=0267f2a.ps, width=7cm , angle=90 }
\epsfig{file=0267f2b.ps, width=7cm , angle=90 }}
\caption{[from Del Zanna et al. (2004)]
H$_{\alpha}$ image, TRACE 
195 \AA\ image (negative) of a filament observed on May 9 1998. 
Note the strong depression in the coronal lines 
observed in the TRACE 195 \AA\ band.}
  \label{fig:9_may_98}
\end{figure*}
% Fig.~\ref{fig:9_may_98}


A background intensity $I_{\rm bg}$ becomes absorbed 

\begin{equation}
I_{\rm obs}= I_{\rm bg} e^{-\tau} 
\end{equation}

Given normal abundances, the 
 absorption due to neutral oxygen and carbon is in fact negligible,
and therefore 
at $\lambda > 912$ \AA\ practically no absorption is present.
At $\lambda < 912$ \AA\ we have:

\begin{equation}  
\tau= \sigma_{\rm H I}  \int N_{\rm H I} dl +  \sigma_{\rm He I}  \int
N_{\rm He I} dl
+  \sigma_{\rm He II}  \int N_{\rm He II} dl
\end{equation}
where: $\sigma_{\rm H I}$, $\sigma_{\rm He I}$, $\sigma_{\rm He II}$ 
are the photoionization cross
sections for the neutral hydrogen, neutral helium and singly-ionised helium;
$N_{\rm H I}, N_{\rm He I},  N_{\rm He II}$ are the respective  number densities.

\begin{figure*}
\centerline{\epsfig{file=cross_sections.eps, width=7.0cm , angle=90
}}
 \caption{%
[from Andretta et al. (2003)]
Photoionisation cross sections for 
He I (dot-dashes), 
He II (solid) and H (dashes), 
per hydrogen atom.  In the inset,
these cross sections are compared on a wider wavelength range to XUV
photoabsorption by metals. 
 Vertical lines at the bottom of the
plot mark the wavelengths of the first resonance lines and of continuum edges
for He and H; the gray areas indicate the wavelength
coverage (first spectral order) of the two spectrometers of SOHO/CDS: Normal
Incidence, NIS (lighter gray), and Grazing Incidence, GIS (darker gray).
}
\label{fig:cross_sections}
\end{figure*}

\subsection{Optical depth}

At lower temperatures, in the chromosphere-transition region,
spectral lines become optically thick.
Fortunately, it is possible in a number of cases to check
which lines are optically thick, and to what extent
(see Del Zanna et al. 2002).

One way is to observe the doublets of the Li-like ions
(e.g. Si~IV, C~IV,  N~V, and O~VI).
In the optically thin case, the ratios of the two lines of the doublet
should be equal to the ratio of the oscillator strengths, i.e. 2.
If opacity effects are present, the ratio would decrease, with the 
brightest component $^2$S$_{1/2}$ - $^2$P$_{3/2}$ being more affected,
having a higher oscillator strength. 
In this case, the  ratio is a  direct measure 
of the ratio  of the photon escape probabilities, from which 
the optical depths of the lines can be obtained.

Another way is to observe lines  that  originate from 
a common upper level (a branching ratio). 
In the optically thin case, the ratios are equal to the 
ratios of the A-values (Jordan 1967).



\begin{table}[!htbp]
\caption{[from Del Zanna et al. 2002]
The line ratios in the STIS and FUSE 
spectral ranges useful for optical depth estimates.
The last two columns indicate the theoretical 
(optical thin case)  and the observed ratio values.}
%\begin{center}
\begin{tabular} [c]{lclcc}
\hline
\hline\noalign{\smallskip}

Ion & Terms & Wavelengths (\AA) & Th. & Ob. \\
\hline\noalign{\smallskip}


C~II &  $^2$P$_{3/2}$ -  $^2$S$_{1/2}$ / & &  &  \\
	& $^2$P$_{1/2}$ -  $^2$S$_{1/2}$   & 1037.020/1036.332  & 2 &1.5 \\

Si~II   & $\prime\prime$   & 1533.430/1526.706  & 2 & 1.2 \\

C~III	& $^3$P$_{0}$ - $^3$P$_{1}$ / & &  &  \\
	& $^3$P$_{2}$ - $^3$P$_{1}$   & 1175.265/1176.372  & 0.8 & 1.0 \\

Si III  & $\prime\prime$   & 1296.726/1303.323   & 0.8 &  0.5   \\ 

C~III	& $^3$P$_{2}$ - $^3$P$_{2}$ / & &  &  \\
	& $^3$P$_{1}$ - $^3$P$_{2}$ &1175.713/1174.935   & 3 & 1.9    \\
Si III  & $\prime\prime$   & 1298.944/1294.543  & 3 &  2   \\

Si~IV  & $^2$S$_{1/2}$ - $^2$P$_{3/2}$ / & &  &  \\
	& $^2$S$_{1/2}$ - $^2$P$_{1/2}$  & 1393.755/1402.770 & 2 &   1.7  \\ 

 C~IV	& $\prime\prime$   &1548.201/1550.772 & 2 &   2  \\ 
N~V	& $\prime\prime$   &1238.821/1242.804 & 2 &  2   \\ 
O~VI	& $\prime\prime$   &1031.914/1037.615 & 2 &   2  \\ 

\hline\noalign{\smallskip}

\end{tabular}
%\end{center}
\label{tab:opacity}
\end{table}
% Table~\ref{tab:opacity}



\section{Is the plasma always collisionally excited by electrons ?}

No, but for the lower solar corona the electron densities are such
that  collisional excitations
by electrons is the dominant mechanism creating spectral lines.
In the higher corona, photo-excitation becomes increasingly dominant,
and the spectral lines become radiatively excited.

The diagnostics to be used in this case include doppler 
dimming techniques, but are not discussed here 
(see, e.g. Noci et al. 1987 for details).


%\clearpage

\section{Optically thin emission lines}
\label{sec:opt}

In the `standard model' for interpreting line intensities 
 there are three fundamental assumptions that serve
to simplify the problem considerably
(these are within  the CHIANTI models 
but also normally assumed):

\begin{enumerate}
\item the plasma is in a steady state;
\item atomic processes affecting the ionisation state of an element
can be separated from those affecting the level balance within an ion;
\item all lines are optically thin.
\end{enumerate}

The last one normally holds for the EUV  lines 
that CDS observes (with the exception of the helium lines),
while the major uncertainties reside in the unknown 
ionization state. 
This casts serious doubts on results 
that can be obtained with spectroscopic methods.


The  intensity $I(\lambda_{ij})$, of an optically thin 
 spectral line (having filling factor=1)
 of wavelength $\lambda_{ij}$ (frequency $\nu_{ij}= {c
 \over h \lambda_{ij}}$) is

 \begin{equation}
{I(\lambda_{ij})}={{h \nu_{ij} \over{4 \pi} }\; {\int  
N_j \;A_{ji}\;dh}\; ~~{\rm [ergs\;cm^{-2}\;s^{-1}\;sr^{-1}}]} 
\end{equation}

\noindent where $i, j$ are the lower and upper levels, 
$A_{ji}$ is the spontaneous transition probability, $N_j$ is
the number density of the upper level $j$ of the emitting ion and $h$ is the 
line of sight through the emitting plasma.

In low density plasmas the collisional excitation processes are generally
faster than ionization and recombination timescales, therefore the
collisional excitation is dominant over ionization and recombination in
populating the excited states. 

{\bf This allows the low-lying level
populations to be treated separately from the ionization and
recombination processes.}



For allowed transitions we have $N_j(X^{+m}) A_{ji}  \sim N_e$.
The population of the level $j$ can be expressed as: 

\begin{equation}\label{Ni-expand}
{N_j(X^{+m}) = {N_j(X^{+m}) \over N(X^{+m})}\;{N(X^{+m}) \over N(X)}\;{N(X) \over N(H)} 
{N(H) \over N_e}\;N_e} 
\end{equation}


\begin{itemize}

\item
$N(X^{+m})/N(X)$ is 
the ionization ratio of the ion $X^{+m}$
relative to the total number density of element $X$ 
(contained in the files in the \verb|ioneq/| directory);

\item
$Ab(X)=N(X)/N(H)$ is the elemental abundance relative to Hydrogen
(contained in the files in the \verb|abundance/| directory); 

\item
$N(H)/N_e$ is the Hydrogen density relative to the free electron
density.  Often assumed to be equal to 0.83, as hydrogen and helium are
usually completely ionised for hot optically thin plasmas. 

See the CHIANTI routine PROTON\_DENS for details on how to 
calculate $N(H)/N_e$.


\item
The  fraction $n_{\rm i}= {N_j(X^{+m}) \over N(X^{+m})}$ 
of ions X$^{+{\rm m}}$ lying in the state $j$
is determined within CHIANTI by
solving the statistical equilibrium equations for a number of low-lying 
levels of the ion
including all the important collisional and radiative excitation and
de-excitation mechanisms.

\end{itemize} 

For the basic CHIANTI model these
processes are simply electron and proton excitation and de-excitation, and
the generalised radiative decay:

%
\begin{equation}\label{alpha-short}
\alpha_{ij} = N_{\rm e} C_{ij}^e + N_{\rm p} C_{ij}^p  + {\cal A}_{ij}
\end{equation}
%
where $C_{ij}^e$ is the  electron excitation--de-excitation
rate, $C_{ij}^p$ is the  proton excitation--de-excitation
rate, $N_{\rm p}$ is the proton density, 
${\cal A}_{ij}$ is the generalized radiative decay rate, that includes
$A_{\rm ij}$,  the radiative decay rate which is
zero for i$<$j (the `A-values' are contained in the CHIANTI {\tt
  .wgfa} files), and  the photoexcitation and
stimulated emission.


$C_{ij}^e$ is given by:
\begin{equation}
C_{\rm ij}^e =   N_{\rm e} q_{\rm ij} \quad {\rm i}<{\rm j} 
\end{equation}

\begin{equation}
C_{\rm ij}^e =   N_{\rm e} {\omega_{\rm j} \over \omega_{\rm i} }
                     \exp \left ({\deltE\over kT} \right ) q_{\rm ji} \quad {\rm i}>{\rm j} 
\end{equation}


where $\omega_{\rm i}$ is the statistical weight of level i, $k$ is
Boltzmann's constant, $T$ the electron temperature, and $q_{\rm ij}$
the electron excitation rate coefficient which is given by:
%
\begin{equation}
q_{\rm ij}=2.172\times 10^{-8} \left ( {I_{\infty} \over kT} \right )^{1/2}
           \exp \left ( - { \deltE\over kT} \right )
           {\Upsilon_{\rm ij} \over \omega_{\rm i} } 
           \qquad [{\rm cm}^3~{\rm s}^{-1}]
\end{equation}
%
where $I_{\infty}$ is the Rydberg energy (13.61 eV), and
$\Upsilon_{\rm ij}$ is the thermally-averaged collision strength for
the i $\rightarrow$ j excitation. 


Within CHIANTI, 
the $\Upsilon_{\rm ij}$  are derived from the
scaled data in the {\tt .splups} files.


The solution of the level balance equations is performed by the CHIANTI
routine \verb| pop_solver.pro|, which gives the fraction of ions in the
state i.
The level populations for a given ion 
can be calculated and displayed  with \verb|plot_populations.pro |
(but also see \verb|pop_plot.pro|). 


We rewrite the intensity as:

\begin{equation}
{I(\lambda_{ij})}= {\int{{Ab(X)} C(T,\lambda_{ij},N_e) N_e N_H dh}}
\end{equation}

where the function 

\begin{equation}
 {C(T,\lambda_{ij},N_e)}= {h \nu_{ij} \over{4 \pi} }\; {A_{ji} \over N_e}\;
{N_j(X^{+m}) \over N(X^{+m})} \;{N(X^{+m}) \over N(X)}
~~{\rm [ergs \;cm^{+3} \;s^{-1}]}, 
\end{equation}

 called the {\it contribution function}, 
contains all of the relevant atomic physics parameters and 
is strongly peaked in temperature. 

Within CHIANTI, 
\verb|gofnt.pro| calculates these contribution functions.


\begin{figure}[htbp]
 \centerline{\epsfig{file= test_gt.ps, width=8.0cm, angle=90}}
  \caption{The summed contribution functions
 of the CHIANTI test case. }
  \label{fig:gtsumplot}
\end{figure}


Please note that 
in the literature there are various definitions of {\it contribution
functions}.
Aside from  having values  in either photons or ergs, sometime the 
factor  $ 1 \over{4\pi}$ is not included. Sometimes a value of 
 0.83 for $N(H)/N_e$ is assumed and included. Sometimes the element
abundance factor is also included. 
Any of the above (or any other) variations also affect the definition
of a line intensity in terms of the contribution function and the  DEM.


In the following we will refer to the  functions $C(T,\lambda_{ij},N_e)$ and 

$$G(T,\lambda_{ij},Ab(X),N_e)=  {Ab(X)} ~C(T,\lambda_{ij},N_e)$$ 

( i.e. the contribution function that contains the  abundance  factor ).  


 \subsection{DEM}


If we define, assuming that is a single-value function of the temperature, the 
 differential emission measure $DEM (T)$ function as

\begin{equation}
  DEM (T) = ~N_e N_H {dh \over dT}   ~~{\rm [cm^{-5} K^{-1}]}
\end{equation}

\noindent
the intensity  can be rewritten, assuming that the abundance is
constant along the line of sight:

\begin{equation}
{I(\lambda_{ij})}= {Ab(X)}{\int\limits_T ~{C(T,\lambda_{ij},N_e)} ~DEM (T) ~ dT}\;
~~{\rm [ergs \;cm^{-2} \;s^{-1}\; sr^{-1}]} 
\end{equation}


The $DEM(T)$ gives an indication of the amount
of plasma along the line of sight that is emitting the radiation observed and 
has a temperature between $ T$ and $T+dT$.

 Please note that in the literature many different definitions of
 Differential Emission Measures, Emission Measures and 
approximations can be found 
(see Del Zanna et al., 2002 for some clarifications).



Within CHIANTI, the routine \verb| chianti_dem.pro | 
calculates the Differential Emission Measure
 $DEM(T)$ using the database, from a given set of observed lines.

Important: 

\bi
\item
to reduce any density effects, only lines which have 
contribution functions independent from the density 
should be used to derive the  $DEM(T)$;
\item
only ions that have a peaked ion fraction should 
be used;
\item 
ions for which an anomalous behaviour is present 
(see below) should be avoided;
\item
filling factors (see below) should be taken into 
account.
\item
 appropriate values of the elemental abundances should be 
chosen according to the region of the Sun being observed.
\ei


The inversion problem (to obtain the $DEM$) is not 
simple nor unique. 
See Del Zanna (1999) for details.
Fig.~\ref{demplot} shows the  DEM  of the CHIANTI test case. 
Once the curve is obtained, one way to present the 
uncertainties associated with it is to overplot for each line
at its effective temperature $T_{eff}$  error bars 
with the value $DEM(T_{eff}) I_o / I_{th} $ where 
$I_o$ is the observed intensity and $I_{th}$
is the intensity calculated with the $DEM(T)$ curve.


\begin{figure}[!htbp]
 \centerline{\epsfig{file= test_dem.ps, width=8.0cm, angle=90}}
  \caption[dum]{The DEM  of the CHIANTI test case. }
  \label{demplot}
\end{figure}


\subsection{EMs}

Once the $DEM(T)$ is known, the
total  emission measure $EM$  can be calculated, integrating the 
$DEM(T)$ over a suitable temperature range: 

\beq
 EM  \equiv \int_h N_e N_H dh = \int_T DEM(T)~ dT  \quad~~~ [{\rm cm}^{-5}]   
\eeq


Note that sometimes the total emission measure is defined as 
$EM  = \int N_e^2 dh = \int  DEM(T) dT $, 
with the differential emission measure defined as 
$DEM(T)=  N_e^2  ({dT / dh})^{-1} $.


Following Pottasch (1963), 
various approximations 
and methods have been introduced 
in order  to simplify the inversion and  to deduce elemental abundances.
One method is to  define for each observed line an 
average emission measure $<EM>$.

By removing an averaged value of C(T) from the integral:

\beq
I\lo{th} =   A_b(Z) ~ <C(T)> ~ {\int\limits_h  ~N_e N_H dh }
\eeq

a suitably defined  volume {\it line emission measure} $EM_L$ 
can therefore  be defined, for each observed line of intensity
I\lo{ob}:

\beq
 EM_L \equiv  {I\lo{ob} \over  A_b(Z) ~ <C(T)>}  \quad ~{\rm [cm^{-5}]}
\label{eq:em_l}
%Equation~\ref{eq:em_l}
\eeq

For example, Jordan and Wilson (1971) 
assumed that $C(T)$ has a 
constant value over a narrow temperature interval $\Delta log T=0.3$,
to calculate for each observed transition a 
line emission measure  EM(0.3).


Another approximation is to 
define for each observed line an averaged $<DEM>$ (see below).



\subsubsection{The emission measure loci approach}


One direct  approach is to plot the ratio $I\lo{ob} / G(T)$ for each line 
as a function of temperature  and consider the loci of these curves 
to constrain the shape of the emission measure distribution.
In fact, for each line and temperature $T_i$ the value 
$I\lo{ob} / G(T_i)$ represents an upper limit to the  value of the 
{\it line emission measure} $EM_L$ (Equation~\ref{eq:em_l})
 at that temperature, assuming that all the observed emission $I\lo{ob}$ 
is produced by plasma at temperature $T_i$.




\subsection{Ionisation Fractions}

Be aware that large differences between different tabulations
(e.g.  Arnaud \& Raymond, 1992; Arnaud \& Rothenflug, 1985;
Mazzotta et al., 1998)
are present, and that large uncertainties are associated with 
these calculations.


 \begin{figure}[!htbp]
\centerline{\epsfig{file=C_ioneq_10.ps, width=9.0cm,angle=90 }}
\caption{A comparison of various  ionization equilibrium
calculations for carbon.}
\end{figure}

It should be noted that the ionisation equilibrium 
plays a major role not only  in the derivation of
the $DEM$, but also in that one of the  elemental abundances.

\subsubsection{The anomalous ions}

 \begin{figure}[!htbp]
\centerline{\epsfig{file=H3236_12.ps,width=5.0cm,angle=90 }
\epsfig{file=H3236_13.ps,width=5.0cm,angle=90 }}
\centerline{\epsfig{file=H3236_14.ps,width=5.0cm,angle=90 }}
  \caption{ [from Del Zanna et al. 2002]
The emission measures $EM_{\Delta {\rm log} T=0.3}$  values, 
 together with the  $I\lo{ob} / (Ab \times C(T))$ curves, calculated at 
constant pressure $P_{\rm e}= 10^{16}$ cm$^{-3}$ K.
The curves for the allowed lines; 
the curves for the anomalous allowed lines of the Li- and Na-like 
sequences;
the curves for the forbidden lines.
}
  \label{fig:em}
\end{figure}
% Fig.~\ref{fig:em}



It is important to be aware of the fact that
a number of ions, in particular those of the Li and Na 
isoelectronic sequence, present anomalous behaviour 
(see Del Zanna et al., 2002, and references therein for details).


This anomalous behaviour of the ions 
of the Li and  Na isoelectronic sequences 
has been known for over thirty years in solar physics,
but has been largely neglected in the literature.


Del Zanna et al. (2001) have reanalysed 
Skylab data using the Mazzotta et al. (1998)
ionisation fractions and up-to-date atomic data to show 
the extent of this anomalous behavior.
The results are that  lines of the Li-like 
 N~V and C~IV are underestimated by factors of 3 and 10, while those of 
 Ne~VIII and Mg~X  are  overestimated by  factors of 5 and 10,
respectively.   

Del Zanna et al. (2002) have shown for the first time that 
this anomalous behaviour also occur in stellar transition regions
(see Fig.~\ref{fig:em}).
As a consequence, erroneous results in all previous literature
were obtained for: a) the $DEM$ or emission measures;
 b) the elemental abundances;
c) the densities using the emission measure loci method;
d) the radiative losses.




\subsection{Isothermal approximation}


In the isothermal approximation, all plasma is assumed to be at 
a single temperature ($T_o$) and the intensity becomes:

\begin{equation}
{I(\lambda_{ij})}= C(T_o, \lambda_{ij}, N_e) {Ab(X)} EM_h 
\end{equation}

where we have defined the {\bf column emission measure} 
\begin{equation}
EM_h = \int{N_e N_H dh} ~~{\rm \;[cm^{-5}]}
\end{equation}

Within CHIANTI,
one way to obtain a spectrum in the  isothermal approximation is:

\begin{verbatim}
 IDL > isothermal, 150., 200., 1., [1.e6], wvl, spectrum,$
       list_wvl, list_ident, edensity=1.e9,$
      ioneq_name=!xuvtop+'/ioneq/mazzotta_etal.ioneq',$
       abund_name=!xuvtop+'/abundance/cosmic.abund'

 IDL>  synthetic_plot, wvl, spectrum, list_wvl, list_ident, 1.
\end{verbatim}

calculates an isothermal synthetic spectrum 
 with a resolution of 1 \AA\
between 100 and 200 \AA\ for a specified set of abundances and differential
emission measure at a constant density N$_e$ = 10$^9$ cm$^{-3}$.
The output arrays  {\sf wvl, spectrum} contain the wavelengths and the
intensities (in erg~ cm$^{-2}$  s$^{-1}$ sr$^{-1}$  \AA$^{-1}$ by
default).



\section{Filling factors}

An average electron density $N_e$ can be deduced from the total emission measure 
$<EM>$  and an estimate of the dimension $\Delta h$ along the line of sight 
of the 
emitting plasma (or the volume $V = A_s \Delta h$, 
with $A_s$ being the observed projected area), assuming that the elemental abundances are known:
 $<N_e^2> \sim <EM> / \Delta h $.


In most cases, when the  $<N_e^2>$ are compared to the 
 $<N_e>^2$ values that are calculated from direct 
measurements of the average (along the line of sight) density $<N_e>$ 
in the transition region, 
large discrepancies are found. This has been interpreted 
 as due to  the transition region having  a filamentary structure,
so that  most of the plasma 
occupies only a small fraction (the filling factor) of 
the observed volume.
Typical values are of the order of 0.01 (cf. Dere et al. 1987).



\section{Density  diagnostics from line intensities}


The theoretical intensity ratios from individual ion species can 
provide a measurement of electron density which is independent 
of any assumptions about the volume of the emitting region.



Spectral lines  may be grouped into different
categories according to the behaviour of the upper level population:
allowed lines collisionally excited from the ground level;
forbidden  or intersystem lines originating from 
a {\it metastable level - } $m$;
allowed lines excited from a metastable level.

For simplicity we again consider a two level  model.
For forbidden and intersystem transitions
the radiative decay rate  is generally very small
($A_{m,g} \simeq  10^0 - 10^2$ sec$^{-1}$)
collisional de-excitation then becomes an important
depopulating mechanism ($A_{m,g}~\simeq~N_e~ C^e_{m,g}$) and may even be
the dominant mechanism; moreover the population of the metastable level
becomes comparable with the population of the ground level and we have:

\begin{equation}
N_m~=~  {  N_g N_e C^e_{g,m}  \over {N_e   C^e_{m,g}  + A_{m,g}}} \label{n-m}
\end{equation}

For small electron densities, $N_e \rightarrow 0$,
$ A_{m,g} \gg N_e C^e_{m,g}$, then the intensity
has the same dependence on the
density as an allowed line ($I^A$):

\begin{equation}
I_{m,g}~  \simeq N_e^2  \label{i-mg}
\end{equation}

For very large values of electron density,
$N_e\rightarrow \infty$ ,
the collisional de-population dominates,
$ N_e C^e_{m,g} >> A_{m,g}$ ;
the metastable level is in Boltzman equilibrium with the ground level:

\begin{equation}
{N_m \over N_g }~=   ~{ C^e_{g,m} \over C^e_{m,g}}~
= ~{ \omega_m \over \omega_g}~exp\left({-\Delta E_{g,m} \over
kT}\right)  \label{boltz}
\end{equation}

The line intensity has the form:

\begin{equation}
I_{m,g} \simeq  N_e  \label{high-ne}
\end{equation}

For intermediate values of electron density $A_{m,g} \simeq N_e C^e_{m,g}$
 the population of the metastable
level is significant and the intensity varies as:

\begin{equation}
I_{m,g} \simeq N_e^\beta  \quad\quad   1< \beta <2 \label{int-ne}  
\end{equation}

The intensity ratio of a forbidden to an allowed transition
($I^F/I^A$) for different spectral lines from the
same ion can be used to determine an average electron density for the
emitting volume. This value is independent of the elemental abundance,
ionisation ratio and any assumptions about the size of that volume.

 \begin{figure}[!htbp]
\centerline{\epsfig{file= H3236_6.ps,width=7.0cm,angle=90 }}
  \caption{[from Del Zanna et al. 2002]
The $f_{ji}$ curves of the  O~IV lines observed by
HST/GHRS on Capella (Linsky et al. 1995)). 
}
  \label{fig:o_4_capella}
\end{figure}
% Fig.~\ref{fig:o_4_capella}


\subsection{Example of forbidden lines}

Alternatively the intensity ratio of two forbidden lines from the same
ion could be used ($I^F/I^{F'}$). A good example of this 
type of diagnostic ratio occurs in the
transition region ion O~IV. The 2s$^2$2p~$^2$P$_J$ -
2s2p$^2$~$^4$P$_J'$, which fall at around 1400~\AA\  have been used
to determine the electron density in the transition region.





\subsection{Fe XIV}

If the population of metastable level ($m$) is comparable
with the ground level ($g$), then other excited levels ($k$) can
be populated from this metastable level as well as from the ground level
and the dependence of the intensity on electron density becomes:

\begin{equation}
I_{k,m} \simeq N_e^\beta  \quad\quad 2< \beta <3 \label{high-ne}
\end{equation}



Fe XIV is formed at coronal temperatures 
($1.8~10^6$ K), it is a good example 
of the latter diagnostic case. The metastable level is actually the upper
level in the ground configuration (3s$^2$3p~$^2$P$_{1.5}$).
The transition probability to the ground level is 
only 60~sec$^{-1}$. For low electron densities (10$^8$~cm$^{-3}$), 
almost all the population for Fe~XIV is in
the ground level, but as electron density is increased
(10$^{10}$~cm$^{-3}$), the upper
level begins to have a significant population aswell.

 \begin{figure}[htbp]
  \centerline{\epsfig{file=fe14.eps, width=8cm , angle=0 }}
  \centerline{\epsfig{file=fe14_pop.ps, width=8cm , angle=90 }}
  \centerline{\epsfig{file=fe14_ratio.eps, width=6cm , angle=0 }}
\caption{Above: [from Peter Young] Diagram of some of the main levels and 
lines in Fe XIV. 
Below: level populations from CHIANTI.
Bottom: line ratio. }
\end{figure}

The spectral line at 334.2~\AA\ ($^2$P$_{1/2}$ -- $^2$D$_{3/2}$) is excited from the
ground level(3s$^2$3p~$^2$P$_{1/2}$), whereas the line at 
353.8~\AA\ ($^2$P$_{3/2}$ -- $^2$D$_{5/2}$) is excited from the upper level in the 
ground configuration (3s$^2$3p~$^2$P$_{3/2}$).


The intensity ratio of these two lines (Figure~\ref{fe14_ratio})
varies with electron density, reflecting the level population changes
in the ground configuration. 

\subsection{Examples}

Within CHIANTI, 
DENS\_PLOTTER  is a  high-level widget 
for  the analysis of density--sensitive  ratios of
lines from the same  ion. It allows inclusion of 
proton rates and photoexcitation.
The calling sequence is simple:

\begin{verbatim}
 IDL > dens_plotter,'si_9'
\end{verbatim}

 \begin{figure}[htbp]
  \centerline{\epsfig{file=ratios_si9_t.ps, width=7.0cm , angle=90 }}
  \caption{ The density-sensitive Si IX ratio and its variation with temperature.}
  \label{fig:ratios_si9}
\end{figure}
% Figure~\ref{fig:ratios_si9}

 \begin{figure}[!htbp]
  \centerline{\epsfig{file=ratios_ne.ps, width=8.0cm , angle=90 }}
  \caption{Some useful density-sensitive line ratios observed by CDS.}
  \label{fig:ratios_ne}
\end{figure}
% Figure~\ref{fig:ratios_ne}


\begin{table}[!htbp]
\caption{Density sensitive line ratios observed  by CDS, 
ordered by the temperature 
 of maximum of the contribution functions shown in column 4,
 calculated with the 
ionization equilibrium calculations of Arnaud and Rothenflug (1985).
 The ranges for which the ratios can be used are shown in column 5.
The numbers in parentheses indicate the number of transitions that 
compose the self-blends.
The lines indicated with a (!)  have problems in either their  observation 
or in the atomic physics. 
The lines indicated with a (*) are the best selection within 
a wider choice. 
The detectors in parentheses indicate that the lines are also visible
 in second order. 
N means NIS, and G means GIS; 
}


\begin{center}
%

\begin{tabular}{|llllcl|}
\hline
Ion       &Ratio (\AA) &Detector& log T$_{\rm max}$ & log N$_{\rm e}$ &  \\
\hline
\hline

Si IX (*)    & 349.9 (3) / 341.949 & N 1 (G 4) & 6.02 &\hbox{7.5 -- 9.5\hskip 4.5pt} & \\
Si IX     & 345.100 / 341.949 & N 1   (G 4) & 6.02 &\hbox{7.5 -- 9.5\hskip 4.5pt} & \\
Si IX     & 349.9 (3) / 345.100 & N 1 (G 4) & 6.02 &\hbox{7.5 -- 9.5\hskip 4.5pt} &  \\   

Si X      & 356.0 (2) / 347.402 & N 1 (G 4)& 6.12 &8.0 -- 10.0 &  \\

Fe XII    & 338.278 (!) / 364.467  & N 1 (G 4)& 6.16 &7.0 -- 12.0 &  \\

Fe XIII   & 321.4   / 320.80 & N 1 & 6.21 &8 -- 10    &   \\
Fe XIII   & 318.12 / 320.80 & N 1 & 6.21 &8 -- 10    &   \\
Fe XIII   & 359.6 (2) (!) / 348.18 & N 1 (G 4) & 6.21 &8 -- 10 &  \\
Fe XIII (*)  & 320.8  (bl) / 348.18 & N 1 & 6.21 & 8 -- 10 &  \\

Fe XIII (*)   &203.8 (2) / 202.044   & G 1 &6.21 &8.5 -- 10.5   &  \\

Fe XIV    & 353.83  / 334.17 & N 1 (G 4)& 6.25 &9.0 -- 11.0 &   \\ 

\hline

\end{tabular}
\end{center}
\label{tab:dens_pairs}
%Table~\ref{tab:dens_pairs}
\normalsize
\end{table}

Table~\ref{tab:dens_pairs}  presents  a list of 
useful density-sensitive line ratios  available within the   CDS channels.


\begin {enumerate}

\item
Temperature effects should be taken into account.

Figure~\ref{fig:ratios_si9} shows the density-sensitive Si IX ratio
calculated at three temperatures ($T=10^6$ K is the temperature of 
maximum ionization fraction for Si IX), showing  that these temperature 
variations do not appreciably affect  the ratio.

\item
Photoexcitation can be important for some ions.

The radiation that comes from the solar photosphere can excite transitions
between levels in the ground configuration of ions in the corona, mainly 
affecting the level balance calculations for low densities 
(N\lo{e}$ \le 10^8$ cm\up{-3}).

The effect is stronger  close to the photosphere, and tends to die out 
with height because of the decrease of the photospheric radiation field 
with distance. This decrease  can be accounted for by estimating a geometric 
dilution factor that is a function of height above the photosphere. 
Si IX should be affected more than other ions.


\item
Most of the observed diagnostic lines are very weak,
which makes the data analysis difficult.

\item For some ions, the atomic data are yet 
{\bf not reliable}. 


% involve ratios of lines emitted by different elements.

\item
Many  diagnostic ratios are affected by blending 
which varies depending on the type of source observed, 
and which is particularly strong at  moderate resolutions. 

\item Only ions that have peak emissivity at the 
 temperatures where the source emits can be 
expected to give meaningful results. 


\end{enumerate}





\subsection{A better (global) approach}


It is  common in the literature to  use only
a few well-behaved line ratios, without considering all 
the observed lines.

\begin{figure}[!htbp]
\centerline{\epsfig{file=si_9.ps, width=6.0cm , angle=-90 }}
\centerline{
\epsfig{file=keenan02t.ps, width=6.0cm, angle=0}
\epsfig{file=keenan02f4.ps, width=6.5cm, angle=0}
}
 \caption{Top: Emissivity ratios  calculated with CHIANTI;
Below: [from Keenan et al. (2002)] In most literature a large
 number of line ratios are often used.}
\end{figure}

Or consider a large number of ratios.
The fact that with many lines a large number of line ratio 
combinations is possible, and the large number of ratios 
sometimes complicates the interpretation.


A different approach, preferable when more than two lines from an ion
are observed, is to plot the values of 


\begin{equation}
F_{ji}= { I(\lambda_{ij}) N_{\rm e}  \over {h \nu_{ij}}\; N_j(N_{\rm e})  \;A_{ji}}
\end{equation}

as a function of electron density,  calculated 
at a fixed temperature.
All the curves should cross at one point, if 
the plasma is isodensity.
The  $F_{ji}$ curves should be  calculated at the effective temperature,
 i.e. at the temperature where the bulk of the ion emission is
(see Del Zanna et al. 2002 and Del Zanna et al 2004).


\begin{figure}[!htbp]
\centerline{\epsfig{file=H0432f7.ps, width=7cm,angle=90 }}
  \caption{[From Del Zanna et al. 2004] 
The  $F_{ji}$ curves from a whole-Sun grazing incidence 
spectrum.
Note that the intensities of the  257.26 and 182.3 have
  been rescaled taking into account the known blends.  }
  \label{fig:malinovsky}
\end{figure}
% Fig.~\ref{fig:malinovsky}

In some cases, as for ions of the  Be-like sequence,
the method is very sensitive to the temperature,
as  Fig.~\ref{fig:o_5_d} shows.


\subsubsection{Temperature effect}

 \begin{figure}[!htbp]
\centerline{\epsfig{file=H3236_10.ps,width=7.0cm,angle=90 }}
  \caption{ [from Del Zanna et al. 2002]
The $f_{ji}$ curves of the O V lines observed in the 
STIS spectrum of AU Mic, calculated at two temperatures.
Note the large temperature effect.
}
  \label{fig:o_5_d}
\end{figure}
% Fig.~\ref{fig:o_5_d}



%\clearpage


\section{The electron temperature evaluation}


The simplest way to derive the plasma temperature is to
assume ionization equilibrium, and either use an 
emission measure approach (see below) or 
assume the the plasma is isotherm.


\subsection{The isothermal case}


Once the isothermal assumption is made, 
it is straightforward to deduce from a line ratio a temperature $T_*$, 
since  the intensity ratio $I_1/I_2$ is directly equal to the 
ratio of the contribution functions:

\begin{equation}
{I_1 \over I_2} = {{C_1(T_*, N\lo{_e})} \over {C_2(T_*, N\lo{_e})}}
 \end{equation}

Any ratios of lines of ions of close ionization stage can be used for this purpose,
as long as the lines are not  density-sensitive, otherwise 
the derived temperature $T_*$ becomes density-dependent.


Different line ratios are expected to give different temperatures,
if the plasma distribution is not isothermal. 


Aside from the cited possible errors due to density and 
element abundance uncertainties, which can easily be avoided by 
careful choice of lines,
there is one substantial source of error that surprisingly is
normally neglected in the literature.
This is  the validity of the adopted ionization 
equilibrium.  

The use of different ionization 
equilibrium calculations can produce significantly different results
as shown in  Figure~\ref{fig:fe12_10_gt}.

 \begin{figure}[!htbp]
  \centerline{\epsfig{file=fe12_10_gt_comp.ps, width=6.0cm , angle=90 }
\epsfig{file=fe12_10_gt_ratio_comp.ps, width=6.0cm , angle=90 }
}
  \caption{Contribution functions of two iron lines and their
ratio, for different ionization equilibria. Note how the ratio is different.}
  \label{fig:fe12_10_gt}
\end{figure}
% Figure~\ref{fig:fe12_10_gt}


\subsection{A  direct method}

A more direct determination of an isothermal  electron temperature, that 
is not dependent on ionization equilibrium assumptions, can be obtained
from the intensity ratio of two allowed transitions to the ground level $g$
 of the same ion, 
from upper levels $j$ and  $k$ having significantly
different excitation energies  $E_{gj}$ and  $E_{gk}$  
[In general, ratios of allowed lines pertaining to 
different transition arrays are temperature sensitive].

In fact, if 

$$(E_{gk} - E_{gj}) /  kT_e >> 1$$

the intensity ratio is temperature-dependent,
and assuming that  the lines are emitted by the same
isothermal volume with the same electron density, 
an isothermal temperature can be directly deduced from the intensity ratio.

Being allowed, their transition probabilities  $A_{jg} , A_{kg}$ are high,
and the intensities are then proportional to the collisional rates :
$I_{jg}\sim h\nu_{gj} N_e N_g 
C^e_{gj} ~,~ I_{kg}\sim h\nu_{kg} N_e N_g C^e_{gk}$.

\begin{equation}
{I_{jg} \over I_{kg}}~ =
 { \nu_{gj}~ <\Omega_{jg}> \over \nu_{kg} ~ <\Omega_{kg}>}
~exp\left({E_{gk} - E_{gj} \over  kT_e}\right)
\end{equation}

Such spectral lines are far apart in wavelength and are normally
observed by different instruments.
Simulataneous observations with different instruments are 
not common, and instrument calibrations are also difficult.


Good temperature diagnostics in EUV-UV spectral range are the ratios
of O~V [629/172], O~V [1218/629],
O~VI [1032/173].
The latter was used by A.Gabriel and his group 
 to provide one of the few direct measurements
of the electron temperature in off-limb spectra of the 
quiet Sun and the coronal holes (David et al. 1997).


 \begin{figure}[!htbp]
  \centerline{\epsfig{file=david98_1.ps,width=7.cm,angle=0 }
\epsfig{file=david98_2.ps,width=9.cm,angle=0 }
}
\caption{[from David et al. (1998)]}
\end{figure}

Within CHIANTI,
TEMP\_PLOTTER  is a  high-level widget 
for  the analysis of temperature-sensitive  ratios of
lines from the same  ion. It allows inclusion of 
proton rates and photoexcitation.
The calling sequence is simple:

\begin{verbatim}
 IDL > temp_plotter,'o_5'
\end{verbatim}



\subsubsection{The case of multiple line ratios}


As in the case of densities, a better and more global approach is 
to plot the ratios of the observed vs. theoretical line 
intensities for all the observed lines.


\subsection{Temperatures using the emission measure loci approach}


\begin{figure}[!htbp]
\centerline{
\epsfig{file=may_2_trace_171.eps, width=6.0cm,angle=0 }
\epsfig{file=trace_ima_areas.eps, width=7.0cm,angle=0 }}
  \caption{[from Del Zanna \& Mason 2003]
The loop (black),
background (white) areas.
}
  \label{fig:trace_l2_across}
\end{figure}

A quick and useful method to inspect the plasma distribution in 
temperature is the  emission measure loci approach.


 \begin{figure}[!htbp]
\centerline{
\epsfig{file=cds_l2_B_i_gt.ps, width=6cm,angle=90 }
\epsfig{file=cds_l2_back_B_i_gt.ps, width=6cm,angle=90 }
}
  \caption{[from Del Zanna \& Mason 2003]
The emission measure  curves obtained from the 
 background-subtracted line intensities of the loop  (left) and
those of the background (right), for the region B}
\end{figure}




\subsection{Temperatures from imaging instruments such as TRACE and
  SOHO/EIT, YOHKOH/SXT}

 Temperatures are commonly estimated by many authors from  soft X-ray or EUV
broad-band filter images.
 This method uses the intensity  ratios of two or more filters in which  emission 
 comes mainly from plasma at distinct temperatures for the respective
 filters. 

In general,  these
{\it filter ratio techniques should be avoided}, if possible,
 for a variety of reasons. 

\bi
\item
Most passbands are multi-thermal, hence different spectral 
lines can become dominant, depending on the source.


\item
Lines that contribute to the emission 
 observed through one  filter, will not normally 
be formed at the same temperatures, and  hence might not be emitted by the same 
spatial regions: the filter does  not then  sample isothermal plasma.
The ratio with another filter image would therefore be meaningless.


\item
Some atomic data for the entire band might be 
missing or be uncertain.

\item
there is an added uncertainty due to 
the  ionization fractions of the ions.

\item
Filter ratio curves are often multi-valued.


\item
Lines in a  broad-band emission, might 
derive from different elements (as is the case for the YOHKOH filters),
and  therefore  assumptions about  element abundances have to be made, thus 
increasing the uncertainty in what is already only an average temperature.

\ei


\subsubsection{TRACE}

 \begin{figure}[!htbp]
\centerline{\epsfig{file=ch_ss_sp_l2_C_aro_feld_171.ps, width=7.0cm,angle=0}
\epsfig{file=ch_ss_sp_l2_C_aro_feld_195.ps, width=7.0cm,angle=0 }
}
  \caption{[from Del Zanna \& Mason 2003]
Top: simulated spectra for the region C
(background-subtracted) in  the TRACE 
 173 \AA\ and 195 bands (the TRACE effective areas, rescaled, are shown with a 
dashed line). 
Bottom:  simulated spectra folded with the TRACE effective area. }
  \label{fig:ch_ss_sp_aro_171}
\end{figure}
% Fig.~\ref{fig:ch_ss_sp_aro_171}


 \begin{figure}[!htbp]
\centerline{\epsfig{file=compare_trace_resp.ps, width=6.cm,angle=0 }
\epsfig{file=compare_trace_resp3.ps, width=6.cm,angle=0 }}
  \caption{The TRACE responses and 195/173 \AA\ ratio}
\end{figure}
% Fig.~\ref{fig:



 \begin{figure}[!htbp]
\centerline{\epsfig{file=Fe8_ioneq.ps, width=6.0cm,angle=90 }
\epsfig{file=Fe9_ioneq.ps, width=6.0cm,angle=90 }}
  \caption{[from Del Zanna \& Mason 2003]
A comparison of various  ionization equilibrium
calculations for Fe~VIII and Fe~IX.}
  \label{fig:Fe8_ioneq}
\end{figure}
% Fig.~\ref{fig:Fe8_ioneq}

In the particular case of TRACE, the following problems 
have been present:

\bi
\item
No in-flight TRACE calibration.

\item
 Fe~VIII emission can be the dominant contributor to the
 195 \AA\ passband. 

\item
Fe~VIII emissivity are `missing' in the current 
 TRACE responses (CHIANTI v.2 was used).

\item
there is an added uncertainty due to 
the  ionization fractions of 
Fe~VII-IX and the other ions.

\item
Fe~VIII is anomalous 

\item
The filter ratio curve is multi-valued.

\ei


\subsubsection{SOHO/EIT}

Similar problems have been found for the EIT.


 \begin{figure}[!htbp]
  \centerline{
 \epsfig{file=H3924f19.eps,width=10.cm,angle=90 }}
  \caption{[from Del Zanna et al. 2003]
Top:
 GIS 1 spectra  of plume, coronal hole and quiet sun.
Bottom: same as above, but multiplied by the EIT 171 \AA\ filter response.
The EIT is dominated by Fe~IX and Fe~X lines, while the Fe~VIII lines,
very strong in the plume, are not observed by the EIT filter. 
Note, however, that 
any small error in the EIT passband can have a considerable effect.}
  \label{fig:gis_obs_171}
\end{figure}
% Fig.~\ref{fig:gis_obs_171}


 \begin{figure}[!htbp]
  \centerline{\epsfig{file=eit_ch_195.ps,width=4.cm,angle=0 }
\epsfig{file=H3924f20.eps,width=10.0cm,angle=90 }}
  \caption{[from Del Zanna et al. 2003]
Top:  GIS 1 spectra  of plume, coronal hole and quiet sun.
Bottom: same as above, but multiplied by the EIT 195 \AA\ filter response.
Note that while in the quiet Sun the EIT signal is dominated
by Fe~XII lines, in the coronal hole lower temperature lines become 
significant. In the plume, the signal is dominated by Fe~VIII lines.
The 195 \AA\ filter is therefore not isothermal.}
  \label{fig:gis_obs_195}
\end{figure}
% Fig.~\ref{fig:gis_obs_195}


%\clearpage

\section{Abundance determination}


There has been a great deal of controversy in the last ten years
about variations in the elemental abundances in the solar atmosphere. 
It appears that the
element abundances in the slow solar wind differ from those in the
photosphere. 
In fact, it seems that the coronal abundances vary in 
different solar features, and within the same structures with time.

The behaviour seems to depend on the
value for the First Ionization Potential (FIP) - which is the energy
required to ionize the neutral atom. The ions with FIP greater than
10~eV appear to behave differently from those with FIP's less than 10~eV.

Element abundances are usually given relative to the 
hydrogen abundance.




Unfortunately, for both in-situ and remote-sensing cases,
it is difficult to obtain measurements relative to hydrogen.
In principle,
comparison of line intensities with either hydrogen continuum
emission (which is often contaminated by some scattered background intensity), 
or with the  resonantly scattered  hydrogen emission lines observed in
the corona could provide absolute abundance measurements.
In practice, the uncertainties are  large.


Most measurements are therefore relative, between an high-FIP element
such as Neon or Oxigen and a low-FIP one such as Iron or Magnesium.
Neutral Neon,
with a FIP of 21.6~eV, has a
closed shell structure (1s$^2$2s$^2$2p$^6$) which is difficult to
ionize, whereas it is much easier to ionize Magnesium
(1s$^2$2s$^2$2p$^6$3s$^2$), with a FIP of 7.6~eV.

The use of relative measurements has lead to the 
uncertainty as to whether the observed variations are in fact 
due to a depletion of high-FIP elements or an enhancement of low-FIP elements.

Note that photospheric abundances of most elements 
 are relatively well determined (with uncertainties of the order of 15\%),
although values are continuously changing
 (see, e.g. the photospheric C, N, O 
abundances).
The photospheric abundances  of the noble gases (as e.g. Ne and Ar) are not 
directly measured 
(because  absorption lines of these elements are not present in the photospheric 
spectra). Their values are  derived from carbonaceous meteorites, and therefore have  large 
uncertainties.


Many methods have been used to determine abundances 
from remote sensing instruments. These methods
are closely related to emission measure methods.

\begin{figure}[!htbp]
\centerline{\epsfig{file=geiss98.ps, width=7cm,angle=-90 }
\epsfig{file=fludra_99.ps, width=7cm,angle=-90 }}
\caption{FIP effect from Geiss et al (1998) and 
Fludra \& Schmelz (1999).}
\end{figure}

\begin{figure}[!htbp]
\centerline{\epsfig{file=vonsteiger00.ps, width=6cm,angle=0 }}
\caption{Ratios measured from Ulysses [from Von Steiger et al. (2000)]}
\end{figure}


\subsection{The emission measure loci approach}

%\subsection{Obtain emission measure loci curves}


Obtain the G(T) functions from the CHIANTI software, e.g.

\begin{verbatim}
gofnt, 'o_5', 580, 635, t_o_5, g_o_5,  d_o_5, $
press=1e15, abund_name=!xuvtop+'/abundance/sun_coronal.abund', $
ioneq_name=!xuvtop+'/ioneq/mazzotta_etal.ioneq'

; [default units are erg cm^+3 s^-1 sr-1 ]
; Suppose you have an O V 630 A intensity of 1812 [erg cm^-23 s^-1 sr-1]:

F_o_5= 1812./g_o_5 

plot, alog10(t_o_5), alog10(F_o_5),$
 xr=[4.5, 7.], yr=[25, 28], /yst, /xst, $
 xtit='Log T [K]',  ytit='Log F(T) [cm-5]', chars=1.3

\end{verbatim}

\begin{figure}[htpb] 
\centerline{\epsfig{file=ft.ps,width=5.0cm , angle=-90 }}
\end{figure}

\subsection{The EM approximations}

\beq
I\lo{th} = A_b(Z) ~  {\int\limits_T  ~{C(T, N\lo{e})} ~N_e N_H {dh \over dT} dT }
%~~{\rm [ergs \;cm^{-2} \;s^{-1}\; st^{-1}]} $$
\eeq
%

 Many authors (e.g. Pottasch 1963; Jordan and Wilson 1971)
 approximate the above expression
by removing an averaged value of C(T) from the integral:

\beq
I\lo{th} =   A_b(Z) ~ <C(T)> ~ {\int\limits_h  ~N_e N_H dh }
\eeq

\noindent
A suitably defined  volume {\it line emission measure} $EM_L$ 
can therefore  be defined, for each observed line of intensity I\lo{ob}:

\beq
 EM_L \equiv  {I\lo{ob} \over  A_b(Z) ~ <C(T)>}  \quad ~{\rm [cm^{-5}]}
\label{eq:em_l}
%Equation~\ref{eq:em_l}
\eeq

The relative abundances of the elements are derived in order to have all
the {\it line emission measures} of the various ions lie along a 
common smooth curve.


\subsubsection{A different approximation. The Widing and Feldman method}

A different approach was proposed by Widing and Feldman (1989):

 extract  from the integral  
an averaged value of the $DEM$ of the line, that 
here is termed the
{\it line DEM} $DEM_L$:

\beq
DEM_L \equiv \left< N_e N_H {dh \over dT}  \right>  \quad [cm^{-5} K^{-1}]  
\label{eq:obs_dem_l}
%Equation~\ref{eq:obs_dem_l} 
\eeq
%
such that  for each line of observed intensity I\lo{ob}:
\beq
DEM_L \equiv  { I\lo{ob} \over  A_b(Z)  ~  {\int\limits_T  ~{C(T) dT }}}
\eeq
%
A plot of the $A_b(Z) ~ DEM_L= I\lo{ob} / {\int\limits_T  ~{C(T) dT }}$ values 
displayed at the temperatures T\lo{max}  is  used to
deduce relative element abundances, 
 adjusting
them in order to have a  continuous sequence of the  $A_b(Z) ~ DEM_L$ values.


\subsubsection{Various problems}

Only when the two lines have similar $C(T)$ and the DEM
distribution is relatively flat would one  expect that the $DEM$ factors out 
from the integrals:

\begin{equation}
{\int\limits_T~ {C_1(T, N\lo{_e})}  ~DEM (T) ~dT \over \int\limits_T~ {C_2(T, N\lo{_e})}  ~DEM (T) ~dT}
 = 
{\int\limits_T~ {C_1(T, N\lo{_e})} ~dT \over \int\limits_T~ {C_2(T, N\lo{_e})}  ~dT}
\label{eqn:ab12}
%relation~\ref{eqn:ab12}
\end{equation}
%
If the above equality holds, then 
it is possible to  deduce the relative abundances directly from the observed
intensities and the contribution functions, because:
\begin{equation}
{A_b(X_1) \over A_b(X_2)} = { {I_1 \cdot  ~\int\limits_T~ {C_2(T, N\lo{_e})} ~dT }  \over
 {I_2 \cdot ~\int\limits_T~ {C_2(T, N\lo{_e})} ~dT} } = {DEM_L(X_2) \over DEM_L(X_1)}
\label{eqn:ab2}
 \end{equation}
%
i.e. the $DEM$ method and the $DEM_L$ method are equivalent. 

However, this is not always the case.



\subsubsection{AR abundances}


 \begin{figure}[!htbp]
\centerline{
\epsfig{file=loop_B_o_5.ps, width=5.5cm,angle=0 }
\epsfig{file=loop_B_ne_6.ps, width=5.5cm,angle=0 }
\epsfig{file=loop_B_trace_171.ps, width=5.5cm,angle=0 }
}
\caption{[from Del Zanna (2003)] SOHO CDS and TRACE images of 
the base of an active region loop system. }
\end{figure}



%Skylab (Widing \& Feldman 1993)


\begin{figure}[!htbp]
\centerline{\epsfig{file=wf93_3.ps, width=8.cm,angle=-90 }}
\centerline{\epsfig{file=wf93_2r.ps, width=8.cm,angle=0 }
\epsfig{file=wf_93_mazz_fip3_i_gt.ps, width=6.cm,angle=90 }
}
\caption{Left: Widing \& Feldman (1993) method, FIP=14
Right: EM loci results, FIP=3.7, 4 times lower !
}
\end{figure}


Many other effects can significantly affect results.
For example:

- Blending 

- Density effects

- The uncertainty on the ionisation fractions


\subsubsection{Coronal hole plumes}


One of the highest FIP effects was measured by 
Widing \& Feldman (1992) on the bright coronal hole plume 
observed by  Skylab.
A DEM analysis  was performed on the calibrated data tabulated in
Widing \& Feldman, using 
photospheric abundances as a starting point.

 \begin{figure}[!htbp]
\centerline{
\epsfig{file=wf92.ps,width=8cm,angle=0 }
\epsfig{file=H3924f1.eps,width=7cm,angle=90 }}
  \caption{[from Del Zanna et al. 2003]
Left: $DEM_L$ values from  Widing \& Feldman (1992), and FIP=10.
Right: The $DEM_L$ values for the Skylab plume, and photospheric abundances.
The Ne and Mg values  indicate the need
to modify the adopted Ne/Mg photospheric abundance ratio, in order to obtain a 
smooth distribution of $DEM_L$ values. 
The  $DEM(T)$ derived from
  the same data is plotted   for comparison (dashed line). 
}
  \label{fig:wf_pl_deml}
\end{figure}
% Fig.~\ref{fig:wf_pl_deml}

Fig.~\ref{fig:wf_pl_deml} shows the $DEM_L$ values for the Skylab
plume. Following the $DEM_L$ method, the 
 points are displayed at the temperatures $T\lo{max}$,
defined as the temperature where $C(T)$ has a maximum. 
%
First, we note that the use of $T\lo{max}$ is misleading since,
this is quite different from the 
 temperature at which most of the emission occurs.

It is often more informative to use an ``effective temperature" $T\lo{eff}$, 
defined as 

$$  log \;T\lo{eff} = \int C(T)\;DEM(T) log \;T\;dT 
 / (\int C(T)\;DEM(T)\;dT) $$


Fig.~\ref{fig:wf_pl_deml} clearly shows that, in order to align the
$DEM_L$ points on a smooth curve, it is necessary to modify the
adopted Mg/Ne relative abundances by a large factor, consistent with
the FIP effect found by Widing and Feldman.

 \begin{figure}[!htbp]
\centerline{\epsfig{file=H3924f2.eps,width=9.cm,angle=90 }}
  \caption{[from Del Zanna et al. 2003]
The $I\lo{ob} / (A_b * C(T))$ curves for the Skylab plume, assuming
  photospheric abundances. The data indicate an isothermal 
distribution at log $T=5.9$ and are consistent with no FIP effect present. 
The emission measure $EM(0.1)$ values calculated with the  $DEM$ of
Fig.~\ref{fig:wf_pl_deml} and a $\Delta log T=0.1$ are also shown
(filled circles).
}
\label{fig:wf_pl}
\end{figure}
% Fig.~\ref{fig:wf_pl}

A DEM analysis has  been performed on the dataset, and the result
displayed as a dashed line in Fig.~\ref{fig:wf_pl_deml}. It is clear 
that there is a
large difference between the $DEM_L$ points and the DEM values.

The  $I\lo{ob} / (A_b * C(T))$ curves for the plume, calculated with 
photospheric abundances, are displayed in Fig.~\ref{fig:wf_pl}.
They  clearly show that the plasma 
is nearly isothermal, since all the curves  are crossing 
at one point (with the exception of the Ne VII 465.2 \AA\ resonance
line, which clearly departs from this behaviour and requires further
investigation). The figure also shows that the observed Mg VI and Ne VI 
intensities are consistent with photospheric abundances.

\end{document}
