  Transmission spectroscopy at UV wavelengths is a rich and largely unexplored
source of information about the upper atmospheres of extrasolar planets. So
far, UV transit observations have led to the detection of atomic hydrogen,
oxygen and ionized carbon in the upper atmosphere of HD209458b. The
interpretation of these observations is controversial - it is not clear if the
absorption arises from an escaping atmosphere interacting with the stellar
radiation and stellar wind, or the thermosphere inside the Roche lobe. Here we
introduce an empirical model that can be used to analyze UV transit depths of
extrasolar planets and use it to interpret the transits of HD209458b in the H
Ly alpha and the OI triplet emission lines. The results indicate that the mean
temperature of the thermosphere is 8,000-11,000 K and that the H2/H
dissociation front is located at pressures between 0.1-1 microbar, which
correspond to an altitude of 1.1 Rp. The upper boundary of the model
thermosphere is located at altitudes between 2.7-3 Rp, above which the
atmosphere is mostly ionized. We find that the HI transit depth reflects the
optical depth of the thermosphere in the wings of the H Ly alpha line but that
the atmosphere also overflows the Roche lobe. By assuming a solar mixing ratio
of oxygen, we obtain an OI transit depth that is statistically consistent with
the observations. An OI transit depth comparable to or slightly larger than the
HI transit depth is possible if the atmosphere is undergoing fast hydrodynamic
escape, the O/H ratio is supersolar, or if a significant quantity of neutral
oxygen is found outside the Roche lobe. Due to the large uncertainty in the
data, repeated observations are necessary to better constrain the OI transit
depths and thus the composition of the thermosphere.
