**2.1. The equations of statistical equilibrium**

In order to calculate the level populations of a given atom or ion, we make two basic assumptions :

- The rates of processes involving ionization stages other than the atom or ion being considered (such as direct photoionization or recombination, charge exchange reactions, collisional ionization, etc.) are slow compared to bound-bound rates.
- All transitions considered are optically thin.

To calculate the population of some level *i*, we must take into
account all possible processes that will (de)populate it:

where *n*_{i} is the volume density of atoms or ions in
level *i*.

Therefore, in steady state regime the sum over all processes that
populate level *i* will
be balanced by the sum over all processes that depopulate level
*i*. Assuming that the two
conditions listed above are met, this can be written
(see, for instance, Rybicki and Lightman
[3]):

where we have considered all possible bound-bound processes, i.e.,
spontaneous,
radiation-induced and collisionally-induced.
The lefthand side of eq. (2) is the sum over all processes that populate
level *i*
from the other levels *j*, whereas the righthand side is the sum
over all processes that depopulate level *i* to levels *j*.

*A*_{ij} is the transition probability of spontaneous decay
from level *i* to level *j*. For
*i* *j*,
*A*_{ij} = 0.

*B*_{ij} are Einstein coefficients, related to the
transition probabilities by:

for *i* > *j*, and *B*_{ii} = 0; *h* is
Plank's constant, *E*_{i} is the energy of level
*i* (expressed in cm^{-1}) and *g*_{i} is the
statistical weight of level *i*.

*u*_{ij} is the spectral energy density of the radiation
field integrated along the line profile
_{} of the transition from level *i* to level *j*:

with *u*_{ii} = 0;
_{ij} is the frequency of the
transition and we have assumed that the radiation field
does not vary significantly along the line profile.

In eq. (2) we have also considered the effect of collisions;
*n*^{k} is the volume
density of the particle inducing the transition, the main collision
partners usually being
*k* = *e*^{-}, *p*^{+},
*H*^{0}, *He*^{0}, *H*_{2},... ,
depending whether the medium is primarily ionized or neutral.

*q*^{k}_{ij} is the collision rate for the
transition from level *i* to level *j* induced by
the collision partner *k* .
These coefficients are the cross-sections for the related process
_{ij}
convolved with a Maxwellian distribution of velocities
*f*(*v*), making
these quantities suitable for astrophysical applications
(see, for instance, Osterbrock
[4]):

for the deexcitation rates (*i* > *j*); *k* is
Boltzmann's constant, *T* is the kinetic temperature,
*µ* is the reduced mass of the system and
is the collision partner's
kinetic energy.

Excitation and deexcitation rates are related by the principle of detailed balance:

with *q*_{ii} = 0.
When the interaction is coulombian, as in collisions with electrons, it
is convenient
to express the cross-section in terms of the *collision stregth*
_{ij},
defined by:

where m is the electron's mass. Substituting this in eq. (5) yields:

with *T* expressed in K and
_{ij} is
defined by the integral in eq. (8)
and is called *Maxwellian-averaged collision stregth*. Typically
_{ij} is a slowly
varying function of T, of order unity. However, for neutral atoms it may
vary for several orders of magnitude.

These are the basic parameters needed to solve eq. (2). If we consider
our model ion
to be composed of *n* levels, then we must solve a linear system of
*n* - 1 equations in order to calculate the relative population ratios.