Opacity data¶
BeAR uses mainly tabulated absorption cross-sections for its radiative transfer calculations. The cross-sections have to be given in units of \(\mathrm{cm^{2}}\) or in cross-sections per species mass \(\mathrm{cm^{2}/g}\). BeAR is primarily designed to be used with the output files from the HELIOS-k opacity calculator. HELIOS-k is an open-source code that can be found here.
Pre-calculated opacity data for a broad range of species that have been curated by Simon Grimm
can be found on the DACE platform under Opacity
.
This data is already in a format that BeAR can use directly.
While BeAR is designed to work primarily with the opacity data format of the HELIOS-k opacity calculator, one can of course also use other opacities. In that case, they have to be converted to the format described below.
Besides the tabulated opacities, BeAR offers a variety of built-in opacities, namely Rayleigh scattering and continuum absorption. The available data is discussed here.
Global wavenumber grid¶
Cross-sections are required to be tabulated as a function of wavenumber. All cross-sections have to be given on the same wavenumber grid to avoid having to constantly interpolating them in wavenumber space when reading them in. By default, BeAR will use the HELIOS-k opacities. In that case, the opacity data is calculated on a wavenumber grid with a constant step of 0.01 \(\mathrm{cm^{-1}}\), starting from 0 \(\mathrm{cm^{-1}}\). Unless indicated otherwise, BeAR will implicitely assume that this standard HELIOS-k grid is used and no further configuration is needed.
However, if other opacity data is used, the wavenumber grid has to be provided as well. In that case,
BeAR expects to find this global wavenumber grid in a special file. The location of the opacity
data and the wavenumber file are handled by the retrieval.config
configuration file.
Within the root opacity folder indicated in the retrieval.config
file, BeAR expects to find a file
called wavenumbers_full.dat
.
This file has the following, simple structure.
5000001
0.0000000000e+00
1.0000000000e-02
2.0000000000e-02
3.0000000000e-02
4.0000000000e-02
5.0000000000e-02
6.0000000000e-02
7.0000000000e-02
8.0000000000e-02
9.0000000000e-02
1.0000000000e-01
1.1000000000e-01
1.2000000000e-01
The file starts with an integer value that is equal to the total number of wavenumbers in the file. After that, the single wavenumbers are tabulated in ascending order.
Opacity data for a specific species¶
Opacity data for a specific species have to be located in a folder that is usually
specified in the opacity species list within the forward_model.config
. Inside
this folder, BeAR expects to find a summary file filelist.dat
that contains
a list of pressures and temperatures as well as filenames the opacities have
been tabulated at.
In general it has the following structure:
18.01528
1.00000e-08 2.00000e+02 Out_00000_42000_00200_n800.bin
4.64159e-04 4.00000e+02 Out_00000_42000_00400_n333.bin
2.15443e+00 3.00000e+02 Out_00000_42000_00300_p033.bin
1.00000e-03 2.50000e+03 Out_00000_42000_02500_n300.bin
2.15443e-04 4.30000e+03 Out_00000_42000_04300_n366.bin
2.15443e-05 5.00000e+01 Out_00000_42000_00050_n466.bin
1.00000e-01 3.50000e+02 Out_00000_42000_00350_n100.bin
The first line is a header with important information. Internally, BeAR uses cross-sections in units of \(\mathrm{cm^{2}}\), while the the standard HELIOS-k data is usually given in \(\mathrm{cm^{2}/g}\), that means cross-sections per species mass.
For the conversion between the two, the molecular weight of the species is
required, which has to be placed within the header as the first value. In
the above example, this corresponds to the molecular weight of water.
In case the actual opacity data is already given in \(\mathrm{cm^{2}}\),
a value of 0
needs to be used here, instead.
Below the header is a list of all available opacity files together with the pressure in bar and temperature in Kelvin. The first column refers to the pressure, the second column to the temperature, while the third one is the file name where the corresponding, tabulated opacity data can be found.
All individual opacity files are saved in binary format to decrease the time
it requires to read them in. They have to be tabulated at exactly the same
wavenumbers that are listed in wavenumber_full.dat
file.
However, not all chemical species have absorption lines that cover the entire, global wavenumber range. Some, for example, might only absorb in the infrared but not in the UV. Therefore, the cross-sections don’t need to be tabulated over the entire global wavenumber range. Instead, they may stop once no absorption lines are present any more. Internally, the missing cross-sections are set to zero. Note, however, that there must be no holes in the data files. If a molecule has holes in its absorption data, the corresponding cross-sections have to be stored as zeros in the binary file.
Inside the binary file itself, the data has to be stored as single-precision values, not the usual double-precision ones. This is already the case for the standard HELIOS-k opacity files that can be found on DACE, for example.
Special cases¶
Sometimes, opacity data can be too small to be represented by a single-precision float value. This is often the case with collision-induced absorption (CIA). In this case, the opacities can also be saved and read in in log10 space.
In order to signal BeAR that the opacities are stored in log space, the header of the
summary file filelist.dat
has to be adjusted slightly as shown in the example below.
0 log
1.00000e-08 2.00000e+02 Out_H2-H2_200_n800.dat
1.00000e-08 2.25000e+02 Out_H2-H2_225_n800.dat
1.00000e-08 2.50000e+02 Out_H2-H2_250_n800.dat
1.00000e-08 2.75000e+02 Out_H2-H2_275_n800.dat
1.00000e-08 3.00000e+02 Out_H2-H2_300_n800.dat
1.00000e-08 3.25000e+02 Out_H2-H2_325_n800.dat
1.00000e-08 3.50000e+02 Out_H2-H2_350_n800.dat
1.00000e-08 3.75000e+02 Out_H2-H2_375_n800.dat
In this example, cross-sections in \(\mathrm{cm^{2}}\) are stored in log10 space.
Thus, the molecular weight is set to 0, and the parameter log
is used afterwards.
If the data is stored in linear space, lin
can be used. Since, however, this is
standard behaviour for HELIOS-k data, it can be omitted as shown in the first example.
Another special case for opacities is pressure broadening by a specific species. Usually, BeAR
treats the pressure the opacities are tabulated at as the total gas pressure. However,
sometimes absorption cross-sections have been calculated for a specific background perturber
species. This can also be taken into account in the header of the filelist.dat
file as
shown in the following example.
39.0983 lin H2
1.00000e-08 1.00000e+02 Out_00000_36000_00100_n800.bin
1.00000e-08 2.00000e+02 Out_00000_36000_00200_n800.bin
1.00000e-08 3.00000e+02 Out_00000_36000_00300_n800.bin
1.00000e-08 4.00000e+02 Out_00000_36000_00400_n800.bin
1.00000e-08 5.00000e+02 Out_00000_36000_00500_n800.bin
1.00000e-08 6.00000e+02 Out_00000_36000_00600_n800.bin
1.00000e-08 7.00000e+02 Out_00000_36000_00700_n800.bin
1.00000e-08 8.00000e+02 Out_00000_36000_00800_n800.bin
Here, cross-sections per mass for potassium are stored in linear space with molecular hydrogen as the perturber species. Thus, instead of the total gas pressure, BeAR will use the partial pressure of H2 for these opacities. The perturber species is listed in the third column of the header. Note, that when this option is used, the second column with the storage format of the opacities has to be present as well.
Opacities included in BeAR¶
BeAR includes a selection of different opacity sources that can be calculated on-the-fly and do not need to be read in as tabulated data. This currently includes Rayleigh scattering by
molecular hydrogen, H2
atomic hydrogen, H
atomic helium, He
water, H2O
carbon monoxide, CO
carbon dioxide, CO2
methane, CH4
Additionally, BeAR can calculate the bound-free and free-free continuum absorption for the hydrogen anion H-. This, however, is only relevant for very hot scenarios as otherwise the abundance of H- would not be high enough to have a strong impact on the overall opacity.
If additional Rayleigh scattering or more continuum absorbers are needed, they can be either added to the code or simply be pre-tabulated and then used as the regular opacity data discussed above.
Choosing opacity sources in forward models¶
Most forward models in BeAR require the user to specify the opacity sources that should be used. The general format for this is as follows:
#Opacity species&folders
H2O Molecules/1H2-16O__POKAZATEL_e2b
CH4 Molecules/12C-1H4__YT34to10_e2b
NH3 Molecules/14N-1H3__CoYuTe_e2b
H2S Molecules/1H2-32S__AYT2_e2b
CO2 Molecules/12C-16O2__CDSD_4000_e2b
The first column refers to the species’ chemical formulas. These need to be listed in the internal
chemical species list of BeAR as discussed here. The second column
indicates the folder where the opacity data, or more specifically the summary file filelist.dat
,
for the species can be found. The folders here are relative to the root opacity folder that is set
as a config parameter in the file retrieval.config
. The species do not have to appear in any
specific order.
For the Rayleigh-scattering species mentioned above, the folder name is replaced by the keyword
Rayleigh
as shown in the following example, where Rayleigh scattering for H2 and He is added.
#Opacity species&folders
H2 Rayleigh
He Rayleigh
H2O Molecules/1H2-16O__POKAZATEL_e2b
CH4 Molecules/12C-1H4__YT34to10_e2b
Special cases are the bound-free and free-free continuum absorptions for H- and collision-induced
absorption (CIA). These are added by using the keywords H-
and CIA
, respectively, as shown
below:
#Opacity species&folders
CIA-H2-H2 CIA/H2-H2
CIA-H2-He CIA/H2-He
H- none
H2 Rayleigh
He Rayleigh
H2O Molecules/1H2-16O__POKAZATEL_e2b
TiO Molecules/48Ti-16O__Toto_e2b
VO Molecules/51V-16O__VOMYT_e2b
BeAR currently can add the following CIA sources:
CIA-H2-H2
- CIA by H2 and H2
CIA-H2-He
- CIA by H2 and He
CIA-H-He
- CIA by atomic H and He
The opacity for the hydrogen anion H- is calculated by BeAR on-the-fly and does not need a folder
to be specified. Thus, the keyword none
is used here instead.