ARTS  2.2.66
m_cia.cc File Reference

Workspace methods for HITRAN CIA data. More...

#include "arts.h"
#include "absorption.h"
#include "file.h"
#include "cia.h"
#include "messages.h"
#include "physics_funcs.h"
#include "auto_md.h"
#include "xml_io.h"
Include dependency graph for m_cia.cc:

Go to the source code of this file.

Functions

void abs_xsec_per_speciesAddCIA (ArrayOfMatrix &abs_xsec_per_species, const ArrayOfArrayOfSpeciesTag &abs_species, const ArrayOfIndex &abs_species_active, const Vector &f_grid, const Vector &abs_p, const Vector &abs_t, const Matrix &abs_vmrs, const ArrayOfCIARecord &abs_cia_data, const Numeric &T_extrapolfac, const Index &robust, const Verbosity &verbosity)
 WORKSPACE METHOD: abs_xsec_per_speciesAddCIA. More...
 
void abs_cia_dataReadFromCIA (ArrayOfCIARecord &abs_cia_data, const ArrayOfArrayOfSpeciesTag &abs_species, const String &catalogpath, const Verbosity &verbosity)
 WORKSPACE METHOD: abs_cia_dataReadFromCIA. More...
 
void abs_cia_dataReadFromXML (ArrayOfCIARecord &abs_cia_data, const ArrayOfArrayOfSpeciesTag &abs_species, const String &filename, const Verbosity &verbosity)
 WORKSPACE METHOD: abs_cia_dataReadFromXML. More...
 
void CIAInfo (const String &catalogpath, const ArrayOfString &cia_tags, const Verbosity &verbosity)
 WORKSPACE METHOD: CIAInfo. More...
 

Variables

const Numeric SPEED_OF_LIGHT
 

Detailed Description

Workspace methods for HITRAN CIA data.

Author
Oliver Lemke olemk.nosp@m.e@co.nosp@m.re-du.nosp@m.mp.i.nosp@m.nfo
Stefan Buehler
Date
2012-12-04

Definition in file m_cia.cc.

Function Documentation

◆ abs_cia_dataReadFromCIA()

void abs_cia_dataReadFromCIA ( ArrayOfCIARecord abs_cia_data,
const ArrayOfArrayOfSpeciesTag abs_species,
const String catalogpath,
const Verbosity verbosity 
)

WORKSPACE METHOD: abs_cia_dataReadFromCIA.

Read data from a CIA data file for all CIA molecules defined in abs_species.

The units in the HITRAN file are: Frequency: cm^(-1) Binary absorption cross-section: cm^5 molec^(-2)

Upon reading we convert this to the ARTS internal SI units of Hz and m^5 molec^(-2).

Author
Oliver Lemke
Parameters
[out]abs_cia_dataWS Output
[in]abs_speciesWS Input
[in]catalogpathGeneric Input

Definition at line 204 of file m_cia.cc.

References cia_get_index(), iso(), list_directory(), Array< base >::nelem(), CIARecord::ReadFromCIA(), CIARecord::SetSpecies(), species_name_from_species_index(), and SpeciesTag::TYPE_CIA.

Referenced by abs_cia_dataReadFromCIA_g(), and CIAInfo().

◆ abs_cia_dataReadFromXML()

void abs_cia_dataReadFromXML ( ArrayOfCIARecord abs_cia_data,
const ArrayOfArrayOfSpeciesTag abs_species,
const String filename,
const Verbosity verbosity 
)

WORKSPACE METHOD: abs_cia_dataReadFromXML.

Read data from a CIA XML file and check that all CIA tags defined in abs_species are present in the file.

The units of the data are described in abs_cia_dataReadFromCIA.

Author
Oliver Lemke
Parameters
[out]abs_cia_dataWS Output
[in]abs_speciesWS Input
[in]filenameGeneric Input (Default: "")

Definition at line 302 of file m_cia.cc.

References cia_get_index(), iso(), Array< base >::nelem(), species_name_from_species_index(), SpeciesTag::TYPE_CIA, and xml_read_from_file().

Referenced by abs_cia_dataReadFromXML_g().

◆ abs_xsec_per_speciesAddCIA()

void abs_xsec_per_speciesAddCIA ( ArrayOfMatrix abs_xsec_per_species,
const ArrayOfArrayOfSpeciesTag abs_species,
const ArrayOfIndex abs_species_active,
const Vector f_grid,
const Vector abs_p,
const Vector abs_t,
const Matrix abs_vmrs,
const ArrayOfCIARecord abs_cia_data,
const Numeric T_extrapolfac,
const Index robust,
const Verbosity verbosity 
)

WORKSPACE METHOD: abs_xsec_per_speciesAddCIA.

Calculate absorption cross sections per tag group for HITRAN CIA continua.

This interpolates the cross sections from abs_cia_data.

The robust option is intended only for testing. Do not use for normal runs, since subsequent functions will not be able to deal with NAN values.

Author
Stefan Buehler
Parameters
[out]abs_xsec_per_speciesWS Output
[in]abs_speciesWS Input
[in]abs_species_activeWS Input
[in]f_gridWS Input
[in]abs_pWS Input
[in]abs_tWS Input
[in]abs_vmrsWS Input
[in]abs_cia_dataWS Input
[in]T_extrapolfacGeneric Input (Default: "0.5")
[in]robustGeneric Input (Default: "0")

Definition at line 42 of file m_cia.cc.

References cia_get_index(), SpeciesTag::CIADataset(), SpeciesTag::CIASecond(), CREATE_OUTS, CIARecord::Extract(), find_first_species_tg(), joker, CIARecord::MoleculeName(), SpeciesTag::Name(), ConstMatrixView::ncols(), Array< base >::nelem(), ConstVectorView::nelem(), ConstMatrixView::nrows(), number_density(), SpeciesTag::Species(), CIARecord::Species(), SpeciesTag::Type(), and SpeciesTag::TYPE_CIA.

Referenced by abs_xsec_per_speciesAddCIA_g().

◆ CIAInfo()

void CIAInfo ( const String catalogpath,
const ArrayOfString cia_tags,
const Verbosity verbosity 
)

WORKSPACE METHOD: CIAInfo.

Display information about the given CIA tags. The CIA tags shown are in the same format as needed by abs_speciesSet.

Author
Oliver Lemke
Parameters
[in]catalogpathGeneric Input
[in]cia_tagsGeneric Input

Definition at line 359 of file m_cia.cc.

References abs_cia_dataReadFromCIA(), CREATE_OUT1, Array< base >::nelem(), and Print().

Referenced by CIAInfo_g().

Variable Documentation

◆ SPEED_OF_LIGHT

const Numeric SPEED_OF_LIGHT