Convert CSG geometry into different formats
Project description
csg2csg
A tool to translate common Monte Carlo geometry formats between each other.
How to use
Right now the code is petty rough.
Install using pip
pip3 install csg2csg --user
Run from the terminal with csg2csg -i filename -f format
where filename is the input filename and format is the file format of the input file. Options for the file format include several neutronics codes [mcnp, serpent, openmc, phits, fluka] each is at a different level of completeness.
The default is to attempt to translate the input file into all neutronics codes but users can specify which codes with the -o
flag.
To see all the run options type csg2csg -h
in the terminal
Caveats
Several! Right now only MCNP can be read, and then written to MCNP Serpent and OpenMC. When the file can be read only a subset of MCNP surfaces can be read
MCNP Surfaces Supported
- P,PX,PY,PZ
- S SO SX SY SZ
- CX CY CZ C/X C/Y C/Z
- SQ
- GQ
- KX, KY, KZ
- TX TY TZ
- Macrobodies - RPP, SPH and RCC
- X, Y, Z - one and two coefficent only
MCNP Surfaces Not Yet Supported
- X, Y, Z - three coefficient
- Macrobodies - BOX, RHP, HEX, REC, TRC, ELL, WEB, ARB
Tranforms
- Are read and interpretted, but nothing is done with them, in the future codes that support cell transformations will use it, but right now MCNP is the only code that does surface transformations
Project details
Release history Release notifications | RSS feed
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 csg2csg-0.0.30.tar.gz
.
File metadata
- Download URL: csg2csg-0.0.30.tar.gz
- Upload date:
- Size: 68.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ce05e33a9734a6acd578aa8c0aa3cf0997b68c1297a8f34f2f9d807864e62b05 |
|
MD5 | 2dbf7dee171201fe8e0cb3143d0a5480 |
|
BLAKE2b-256 | f5b13bcc2227bed85c02d2eedb46d9b6069e906ae8e71b210d5989924a394263 |