Davide-sd / pygasflow

Python functions for Quasi-1D Gasdynamics
https://pygasflow.readthedocs.io
GNU General Public License v3.0
22 stars 8 forks source link
aerothermodynamics compressible-flow flow-dynamics hypersonics ideal-gas supersonic

pygasflow

PyPI version Conda Version Documentation Status Binder

pygasflow is a Python package that provides a few handful functions to quickly perform:

The following charts has been generated with the functions included in this package:

Installation

The repository is avaliable on PyPi:

pip install pygasflow

And also on Conda:

conda install conda-forge::pygasflow

Usage

The easiest way is to call a solver. Let's say you need to solve an isentropic flow:

from pygasflow import isentropic_solver
help(isentropic_solver)
isentropic_solver("m", 2, to_dict=True)
# {'m': 2.0,
#  'pr': 0.12780452546295096,
#  'dr': 0.2300481458333117,
#  'tr': 0.5555555555555556,
#  'prs': 0.24192491286747442,
#  'drs': 0.36288736930121157,
#  'trs': 0.6666666666666667,
#  'urs': 2.3515101530718505,
#  'ars': 1.6875000000000002,
#  'ma': 30.000000000000004,
#  'pm': 26.379760813416457}

Should a solver not be sufficient for your use case, feel free to explore the code implemented inside each flow's type, maybe you'll find a function that suits your needs.

Please: