star-line

Structure for accelerating line importance sampling
git clone git://git.meso-star.com/star-line.git
Log | Files | Refs | README | LICENSE

sln-slab.1 (6506B)


      1 .\" Copyright (C) 2022, 2026 |Méso|Star> (contact@meso-star.com)
      2 .\" Copyright (C) 2026 Université de Lorraine
      3 .\" Copyright (C) 2022 Centre National de la Recherche Scientifique
      4 .\" Copyright (C) 2022 Université Paul Sabatier
      5 .\"
      6 .\" This file is part of Star-Line.
      7 .\"
      8 .\" This program is free software: you can redistribute it and/or modify
      9 .\" it under the terms of the GNU General Public License as published by
     10 .\" the Free Software Foundation, either version 3 of the License, or
     11 .\" (at your option) any later version.
     12 .\"
     13 .\" This program is distributed in the hope that it will be useful,
     14 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
     15 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
     16 .\" GNU General Public License for more details.
     17 .\"
     18 .\" You should have received a copy of the GNU General Public License
     19 .\" along with this program. If not, see <http://www.gnu.org/licenses/>.
     20 .Dd May 5, 2026
     21 .Dt SLN-SLAB 1
     22 .Os
     23 .\""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
     24 .Sh NAME
     25 .Nm sln-slab
     26 .Nd computations of radiative transfer in a 1D homogeneous slab
     27 .\""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
     28 .Sh SYNOPSIS
     29 .Nm
     30 .Op Fl dhsv
     31 .Op Fl n Ar nrealisations
     32 .Op Fl T Ar thickness
     33 .Op Fl t Ar threads
     34 .Fl S Ar nu_min , Ns Ar nu_max
     35 .Fl a Ar accel_struct
     36 .Fl m Ar molparams
     37 .Fl l Ar lines
     38 .\""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
     39 .Sh DESCRIPTION
     40 .Nm
     41 calculates the transmissivity and the emissivity in a one-dimensional
     42 homogeneous slab of arbitrary thickness using a Monte Carlo algorithm
     43 that samples the spectral lines that make up the gas mixture.
     44 These computations are accelerated by sampling the lines based on the
     45 magnitude of their contribution to the mixture’s spectrum, so that few
     46 Monte Carlo runs are required to estimate the transmissivity with a high
     47 degree of confidence.
     48 The core of the proposal rests on this sampling strategy, made possible
     49 by constructing an acceleration structure from the set of lines in the
     50 mixture.
     51 A structure built using the
     52 .Xr sln-build 1
     53 utility and provided as input to the program.
     54 .Pp
     55 More than just a numerical simulation tool,
     56 .Nm
     57 is primarily designed to validate the aforementioned acceleration
     58 structure in relation to its intended use, namely radiative transfer
     59 computations.
     60 Thus, not only could an error be returned in the event of a problem with
     61 the structure or its use, but the computed value can also contribute to
     62 this validation through its comparison with the result of a computation
     63 of the same quantity performed by another radiative transfer code.
     64 .Pp
     65 The output of
     66 .Nm
     67 displays the estimated transmissivity and emissivity, their standard
     68 deviation, and the number of Monte Carlo realisations rejected due to
     69 issues encountered during the computation, such as numerical
     70 uncertainty.
     71 Each estimate is displayed on a line formatted as follows:
     72 .Bd -literal -offset Ds
     73 "%-16s: %e +/- %e; %lu\en", name, estimate, std_err, rejects_count
     74 .Ed
     75 .Pp
     76 The options are as follows:
     77 .Bl -tag -width Ds
     78 .\""""""""""""""""""""""""""""""""""
     79 .It Fl a Ar accel_struct
     80 An acceleration structure corresponding to the input
     81 .Ar lines ,
     82 used to accelerate their sampling based on their importance.
     83 This structure is generated by the
     84 .Xr sln-build 1
     85 tool.
     86 .\""""""""""""""""""""""""""""""""""
     87 .It Fl d
     88 Disables verification of the correspondence between the lines provided
     89 by the
     90 .Fl l
     91 option and those used to construct
     92 the acceleration structure defined by the
     93 .Fl a
     94 option.
     95 .Pp
     96 Warning!
     97 It is always recommended to verify that the data is correct, even though
     98 this verification can take a significant amount of time when there are a
     99 large number of lines.
    100 Anyway, a user who is
    101 .Em certain
    102 of the data’s consistency may nevertheless use this option
    103 .Pq at their own risk
    104 to disable this verification and thus speed up the execution.
    105 .\""""""""""""""""""""""""""""""""""
    106 .It Fl h
    107 Display short help and exit.
    108 .It Fl l Ar lines
    109 List of lines from which the tree was built.
    110 This list is in binary format as generated by the
    111 .Xr shtr 1
    112 binary, or in plain text HITRAN format, depending on whether the
    113 .Fl s
    114 option is set or not, respectively.
    115 .\""""""""""""""""""""""""""""""""""
    116 .It Fl m Ar molparams
    117 Isotopologue metadata in HITRAN format.
    118 .\""""""""""""""""""""""""""""""""""
    119 .It Fl n Ar nrealisations
    120 Number of Monte Carlo realisations.
    121 By default the number of realisations is 10000.
    122 .\""""""""""""""""""""""""""""""""""
    123 .It Fl S Ar nu_min , Ns Ar nu_max
    124 The spectral range, in cm^-1, over which the computations are performed.
    125 The default spectral range is from 0 to infinity.
    126 .\""""""""""""""""""""""""""""""""""
    127 .It Fl s
    128 Specifies that input lines are formatted according to the binary format
    129 as written by the
    130 .Xr shtr 1
    131 utility, and not according to the HITRAN format.
    132 This format is more compact, allowing for faster loading of line data.
    133 .\""""""""""""""""""""""""""""""""""
    134 .It Fl T Ar thickness
    135 Slab thickness.
    136 The default value is 1.
    137 .\""""""""""""""""""""""""""""""""""
    138 .It Fl t Ar threads
    139 Advice on the number of threads to use.
    140 By default,
    141 .Nm
    142 uses as many threads as processor cores.
    143 .\""""""""""""""""""""""""""""""""""
    144 .It Fl v
    145 Make
    146 .Nm
    147 verbose.
    148 Multiple
    149 .Fl v
    150 options increase the verbosity.
    151 The maximum is 3.
    152 .El
    153 .\""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
    154 .Sh EXIT STATUS
    155 .Ex -std
    156 .\""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
    157 .Sh EXAMPLES
    158 Estimate the transmissivity and emissivity between 100 and 2500 cm^-1
    159 for a slab 2 meters thick.
    160 The slab consists of a homogeneous gas mixture of H2O, CO2 and CO
    161 molecules.
    162 The thermodynamic properties of the mixture, such as its pressure,
    163 temperature and molecular concentrations, correspond to those used to
    164 construct the acceleration structures with sln-build, provided as input
    165 arguments
    166 .Pq option Fl a .
    167 The isotopic metadata
    168 .Pq option Fl m
    169 and the list of lines
    170 .Pq option Fl l
    171 partitioned by the acceleration structure, complete the list of input
    172 data.
    173 The latter is encoded in the format generated by the
    174 .Xr shtr 1
    175 tool
    176 .Pq option Fl s .
    177 The isotopes are in HITRAN format.
    178 Finally, make the program as verbose as possible
    179 .Pq options Fl vvv .
    180 .Bd -literal -offset Ds
    181 sln-slab -S 100,2500 -T2 -a tree_H2O_CO2_CO_1atm_600K.sln \e
    182   -m molparam.txt -sl H2O_CO2_CO_100-2500cm-1.shtr -vvv
    183 .Ed
    184 .\""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
    185 .Sh SEE ALSO
    186 .Xr shtr 1 ,
    187 .Xr sln-build 1