zcross


Namezcross JSON
Version 0.0.21 PyPI version JSON
download
home_pagehttps://gitlab.com/micrenda/zcross-python
SummaryAn utility to read low-pressure gaseous cross sections data
upload_time2023-09-24 06:35:04
maintainer
docs_urlNone
authorMichele Renda
requires_python>=3.0
license
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # ZCross

ZCross is a python library used to read low pressure gas sections from various sources like [LXCat](https://lxcat.net/home/).

## Installation

To install this package just use pip:
``` shell
pip install zcross
```

Cross section databases are not provided by `ZCross`: however, it is possible to download the cross section tables of interest from the [download section](https://nl.lxcat.net/data/download.php) of [LXCat](https:://www.lxcat.net).
Once you download the cross sections in `XML` format, you can save it somewhere (we suggest under `/opt/zcross_data`) and to define an enviroment variable pointing to that path:
``` bash
export ZCROSS_DATA=/opt/zcross_data
```
(you can add it to your `.profile` file)

## Examples

List the database availables:
``` python
import zcross

zs = zcross.load_all()
# be patient, it will take a while ...

for z in zs:
	print(z.database)
```
		
Show the groups and references of a speficic database:
``` python
import zcross

z = zcross.load_by_name('ccc')

for group in z.database:
	print(group)

for reference in z.database.references:
	print('[{}]:'.format(reference.type))
	for k,v in reference.items():
	   print('  {:<10} : {}'.format(k,v))
```
		
Show the process of a specific group:
``` python
import zcross

z = zcross.load_by_name('itikawa')

group      = z.database[0]

for process in group:
	print("Process {}: {}".format(process.id, process.get_simple_type()))
	print("Comment: {}\n".format(process.comment))
```
	
Show the cross section table of a specific process:
``` python
import zcross

z = zcross.load_by_name('phelps')

process    = z.database['H2O'][5]

print('Reaction:')
print(process.get_reaction())

print('Energy [{}],\tArea [{}]'.format(process.energy_units, process.cross_section_units))

for energy, area in process:
	print('{:8.2f}\t{:e}'.format(energy, area))
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://gitlab.com/micrenda/zcross-python",
    "name": "zcross",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.0",
    "maintainer_email": "",
    "keywords": "",
    "author": "Michele Renda",
    "author_email": "michele.renda@cern.ch",
    "download_url": "https://files.pythonhosted.org/packages/d3/11/d3d2ef4143e4ca5ecb1d9fd4ef6f78bf6859604567048421a9e48812ce12/zcross-0.0.21.tar.gz",
    "platform": null,
    "description": "# ZCross\n\nZCross is a python library used to read low pressure gas sections from various sources like [LXCat](https://lxcat.net/home/).\n\n## Installation\n\nTo install this package just use pip:\n``` shell\npip install zcross\n```\n\nCross section databases are not provided by `ZCross`: however, it is possible to download the cross section tables of interest from the [download section](https://nl.lxcat.net/data/download.php) of [LXCat](https:://www.lxcat.net).\nOnce you download the cross sections in `XML` format, you can save it somewhere (we suggest under `/opt/zcross_data`) and to define an enviroment variable pointing to that path:\n``` bash\nexport ZCROSS_DATA=/opt/zcross_data\n```\n(you can add it to your `.profile` file)\n\n## Examples\n\nList the database availables:\n``` python\nimport zcross\n\nzs = zcross.load_all()\n# be patient, it will take a while ...\n\nfor z in zs:\n\tprint(z.database)\n```\n\t\t\nShow the groups and references of a speficic database:\n``` python\nimport zcross\n\nz = zcross.load_by_name('ccc')\n\nfor group in z.database:\n\tprint(group)\n\nfor reference in z.database.references:\n\tprint('[{}]:'.format(reference.type))\n\tfor k,v in reference.items():\n\t   print('  {:<10} : {}'.format(k,v))\n```\n\t\t\nShow the process of a specific group:\n``` python\nimport zcross\n\nz = zcross.load_by_name('itikawa')\n\ngroup      = z.database[0]\n\nfor process in group:\n\tprint(\"Process {}: {}\".format(process.id, process.get_simple_type()))\n\tprint(\"Comment: {}\\n\".format(process.comment))\n```\n\t\nShow the cross section table of a specific process:\n``` python\nimport zcross\n\nz = zcross.load_by_name('phelps')\n\nprocess    = z.database['H2O'][5]\n\nprint('Reaction:')\nprint(process.get_reaction())\n\nprint('Energy [{}],\\tArea [{}]'.format(process.energy_units, process.cross_section_units))\n\nfor energy, area in process:\n\tprint('{:8.2f}\\t{:e}'.format(energy, area))\n```\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "An utility to read low-pressure gaseous cross sections data",
    "version": "0.0.21",
    "project_urls": {
        "Homepage": "https://gitlab.com/micrenda/zcross-python"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d311d3d2ef4143e4ca5ecb1d9fd4ef6f78bf6859604567048421a9e48812ce12",
                "md5": "76e9d1a7cdb498b5be9384e8e7dd8311",
                "sha256": "07ec240adc72cc7825ac0543d89ecaec72464513063039e5cbf45f27d2bd3de2"
            },
            "downloads": -1,
            "filename": "zcross-0.0.21.tar.gz",
            "has_sig": false,
            "md5_digest": "76e9d1a7cdb498b5be9384e8e7dd8311",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.0",
            "size": 26277,
            "upload_time": "2023-09-24T06:35:04",
            "upload_time_iso_8601": "2023-09-24T06:35:04.819564Z",
            "url": "https://files.pythonhosted.org/packages/d3/11/d3d2ef4143e4ca5ecb1d9fd4ef6f78bf6859604567048421a9e48812ce12/zcross-0.0.21.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-09-24 06:35:04",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "micrenda",
    "gitlab_project": "zcross-python",
    "lcname": "zcross"
}
        
Elapsed time: 0.13448s