Creation of the user inputs

The class UserInputs is the main class for defining your inputs. It can be seen as a list storing all the inputs to be used throughout the different operations performed by the script:

UserInputs(input1=value1, ..., inputN=valueN)

These inputs are the specific parameters necessary for the computation of the \(\chi^{2}\) in the LineAnalysis model.

Arguments

The arguments of the class UserInputs are the different parameters necessary for LineAnalysis. They can be defined in any order as long as they respect the notation:

input = value

where input and value are described below. Note that some inputs are mandatory in order to complete the computation successfully. If they are not satisfied an exception will be raised by the script and a message will explain you what you should do.

Mandatory arguments

telescope:

The name of the telescope file if a single telescope is provided or a dictionary of ranges of lines on which different telescopes are applied if there are many telescopes.

  • Default value: None

  • Example 1: For a single telescope:

    telescope = "hifi"
    
  • Example 2: For many telescopes:

    # spire_ssw is applied from line 1 to 4
    # spire_slw is applied on line 5 and 6
    telescope = {"1-4": "spire_ssw", "5,6": "spire_slw"}
    
  • Note: If you want to provide your own telescope you must specify the full path to the your telescope file:

    telescope = "path/to/my/telescope.dat"
    

Warning

If you specify the lines on which the telescopes are applied make sure the lines correspond to the lines you choose for selectedLines, rmsLines and calLines

tuningRange:

The frequency range to be used (in GHz)

  • Default value: None

  • Equivalent in CASSIS: Range min: _ max: _

  • Example:

    tuningRange=[550, 1152]
    
moltags:

The list of molecular tags.

  • Default value: None

  • Equivalent in CASSIS: the selection of the molecule in the list for the given template

  • Example:

    moltags = [28503, 29501]
    
inputFile:

The full path to the input file

  • Default value: None

  • Equivalent in CASSIS: the selection of the data file with the “Load” button

  • Example:

    inputFile = "/Users/username/data/iras16293.dat"
    
selectedLines:

A dictionary defining the indexes of the spectra and the range to be taken into account in the computation of the \(\chi^{2}\).

The index corresponds to the number of the line that appears in the Line analysis panel after you display your spectrum.

  • Example 1: computation of the \(\chi^{2}\) for the first spectrum on the frequency range f1 and for the second spectrum on the frequency range f2:

    selectedLines = {"1": f1, "2": f2}
    
  • Example 2: with many specific regions to be taken into account in a single spectrum:

    selectedLines = {"1": [f1, f2, f3]}
    
  • Example 3: with a range of lines (from line 1 to 3):

    selectedLines = {"1-3": f1}
    

where f1, f2, f3 are ranges of physical units amongst:

  • frequency in GHz
  • velocity in km/s
  • wavelength in micrometer
  • wavenumber in cm-1

(cf section Define ranges for physical magnitudes)

rmsLines:

A dictionary defining the indexes of the spectra and the rms values for these spectra.

The index corresponds to the number of the line that appears in the Line analysis panel after you display your spectrum.

  • Example 1: if the first 3 spectra have a RMS = 0.01 and the last 8 lines have a RMS = 0.04:

    rmsLines = {"1-3": 0.01, "4-8": 0.04}
    
calLines:

A dictionary defining the indexes of the spectra and the calibration values for these spectra.

The index corresponds to the number of the line that appears in the Line analysis panel after you display your spectrum.

  • Example: if the first 3 spectra have a calibration = 0.1 and the last 8 lines have a calibration = 0.4:

    calLines = {"1-3": 0.1, "4-8": 0.4}
    

Note

selectedLines, rmsLines and calLines are interdependent. The spectra specified in these 3 inputs must be exactly the same:

selectedLines = {"1": [f1a, f1b], "2": [f2]}
rmsLines = {"1": [0.05, 0.01], "2": [0.01]}
calLines = {"1": [0.1, 0.4], "2": [0.3]}

Optional arguments

tuningBand:

The width on which the spectra are taken (in km/s)

  • Default value: 60

  • Equivalent in CASSIS: Band: _

  • Example:

    tuningBand = 100
    
aijMin:

The minimum value for the Einstein coefficient, Aij

  • Default value: 0

  • Equivalent in CASSIS: Aij min: _

  • Example:

    aijMin = 0
    
eup:

The minimum and maximum value of the Eup to be used

  • Default value: [0, 150.0]

  • Equivalent in CASSIS: Eup min: _ max: _

  • Example:

    eup = [0.0, 500.0]
    
jup:

The minimum and maximum value of the Jup to be used

  • Equivalent in CASSIS: Jup min: _ max: _

  • Default value: [“*”, “*”]

  • Example:

    jup = [1, 10]
    
kup:

The minimum and maximum value of the Kup to be used

  • Equivalent in CASSIS: Kup min: _ max: _

  • Default value: [“*”, “*”]

  • Example:

    kup=[1, 10]
    
lup:

The minimum and maximum value of the Lup to be used

  • Equivalent in CASSIS: Lup min: _ max: _

  • Default value: [“*”, “*”]

  • Example:

    lup=[1, 10]
    
mup:

The minimum and maximum value of the Mup to be used

  • Equivalent in CASSIS: Mup min: _ max: _

  • Default value: [“*”, “*”]

  • Example:

    mup=[1, 10]
    
template:

The template to be used for the molecules

  • Equivalent in CASSIS: Template

  • Default value: “ISM”

  • Example:

    template="ISM"
    
outputFile:

The path to the file in which the data will be written at the end of the computation

  • Default value: inputFile + ‘.dat’

  • Example:

    output = "/Users/username/data/iras16293_output.dat"
    
plotTitle:

The title of the \(\chi^{2}\) contour plot

  • Default value: the basename of the inputFile

  • Example:

    plotTitle = "Chi2 contour plot of my model"
    
tmb2ta:

Whether the data are in main beam temperature (False) or in antenna temperature (True)

  • Default value: False

  • Example:

    tmb2ta=True
    
isoUnique:

Determine how the isotopic ratios parameters must be taken into account.

  • True: the first iso parameter is taken for all the components
  • False: the union of all the values of the iso parameters of the components

In a more formal way:

let

  • \(m_i\) the number of models for the component i
  • \(p_i\) the number of isotopic values for the component i
  • \(q\) the total number of models
  • isoUnique = False:
\[q = m_{1} m_{2} \dotsm m_{N} = \prod_{i=1}^{N} m_{i}\]
  • isoUnique = True:
\[q = p_{1} \dfrac{m_{1}}{p_{1}} \dfrac{m_{2}}{p_{2}} \dotsm \dfrac{m_{N}}{p_{N}} = p_{1} \prod_{i=1}^{N} (\dfrac{m_{i}}{p_{i}})\]
  • Default value: False

  • Example:

    isoUnique = True
    
warning:

Allow the display of an option pane indicating the number of models to process and asking you whether the script should continue.

  • Default value: True

  • Example:

    warning = False
    

Now you should be ready to create some components for your model.

Table Of Contents

Related Topics

This Page