Calculate infrared pumping rates by solar radiation
Project description
cine is a command-line tool for calculating infrared pumping efficiencies. At large nucleocentric distances, one of the main mechanisms for molecular excitation in comets is the fluorescence by the solar radiation followed by radiative decay to the ground vibrational state. This code calculates the effective pumping rates for rotational levels in the ground vibrational state scaled by the heliocentric distance of the comet. These coefficients are useful for modeling rotational emission lines observed in cometary spectra at sub-millimeter wavelengths.
Code releases are available on PyPI, and development happens in the github project page.
Installation
cine can be installed using pip:
$ pip install cine
or by cloning the github repository:
$ # If you have a github account:
$ git clone git@github.com:migueldvb/cine.git
$ # If you do not:
$ git clone https://github.com/migueldvb/cine.git
$ cd cine
$ python setup.py install
$ # Or if you do not have root privileges:
$ python setup.py install --user
When the package is installed using either method, the cine script will be copied to a directory in the PATH environment variable and will be available for general use.
Requirements
The code requires the standard scientific Python packages (numpy, scipy, and pandas) and astropy’s affiliated package astroquery. to access the HITRAN and Lamda databases. Running the tests requires nose.
Example
cine is a command-line tool that is included in the package to generate pumping rates for several molecules. For example, to obtain the effective pumping rates between the seven lowest rotational levels in the ground vibrational state of HDO you can run the following command once CINE has been installed:
$ cine --mol HDO --nlevels 7
This should create a file named G_HDO.dat which contains the pumping rates G ij in units of s -1 between the rotational levels i and j shown in the first two columns. Note that the levels use zero-based indexing.
0 3 2.568872e-05
0 4 2.570305e-05
0 5 1.552757e-05
1 2 6.253229e-05
1 6 2.987896e-05
2 1 6.196215e-05
2 6 4.410062e-05
3 0 7.547422e-05
3 4 3.103947e-05
3 5 5.048423e-05
4 0 1.253741e-04
4 3 5.128064e-05
4 5 4.679292e-05
5 0 7.481781e-05
5 3 8.287649e-05
5 4 4.643613e-05
6 1 4.820172e-05
6 2 7.201329e-05
To include more levels in the calculation, change the -n/-nlevels command-line option to a larger value. cine has a -h/--help argument that presents an usage explanation describing each optional argument.
These coefficients are useful for deriving molecular production rates from cometary lines observed at sub-millimeter wavelengths combined with a code that solves the radiative transfer equations such as LIME.
Downloading HITRAN data
To download the molecular data cine uses the astroquery.hitran and astroquery.lamda tools. Set the LAMDA_DATA and HITRAN_DATA environment variables (otherwise, the default ~/.astropy/cache/astroquery/Lamda and ~/.astropy/cache/astroquery/hitran will be used),
Tests
If nose is installed the tests can be run from the root of the repository as:
$ python setup.py test
Contributing
Any questions or bug reports can be raised in github’s issue tracker or pull requests.
Project Status
License
Copyright 2017 Miguel de Val-Borro
CINE is free software made available under the MIT License. For details see the LICENSE file.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file cine-0.2.1.tar.gz
.
File metadata
- Download URL: cine-0.2.1.tar.gz
- Upload date:
- Size: 13.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c9f81c2e5a93af83fb9d3c14a638ded9e73621f191546c4cd15c324ae041bb69 |
|
MD5 | 624b0d708f0a6c6e12e7ca4a2c856f8a |
|
BLAKE2b-256 | f2846b3a90c18a863caf3089e4e0d178fcba0199d244f8afb77a83cd08a2fb1c |