Skip to main content

flow_state

Compressible flow state calculations for Python.

Test codecov DOI PyPI Docs Webapp License Python Ruff

Install

pip install flow-state-calculator

Quick Start

API:

from flow_state import solve

# From Mach and altitude
state = solve(mach=2.0, altitude=10000)

# From Mach and stagnation conditions (wind tunnel)
state = solve(mach=6, pres_stag=(140, "psi"), temp_stag=420)

# From Mach and target unit Reynolds number
state = solve(mach=5.3, re1=12.8e6)

print(state)  # Full summary
print(state.pres, state.temp, state.re1)

CLI:

flow-state init    # Create a config template
flow-state solve   # Solve from flow_config.toml

Documentation

Full documentation: https://uahypersonics.github.io/flow-state

Citation

If you use flow_state in your research, please cite it:

@software{flow_state,
  author = {Hader, Christoph},
  title = {flow\_state: Compressible Flow State Calculations},
  url = {https://github.com/uahypersonics/flow-state},
  year = {2026}
}

Code Style

This project follows established Python community conventions so that contributors can focus on the physics rather than inventing formatting rules.

Convention What it covers Reference
PEP 8 Code formatting, naming, whitespace Python standard style guide
PEP 257 Docstring structure (triple-quoted, imperative mood) Python standard docstring conventions
numpydoc Docstring sections (Parameters, Returns, Attributes) NumPy/SciPy docstring standard — the norm for scientific Python
Ruff Automated linting and formatting Enforces PEP 8 compliance automatically
typing / TYPE_CHECKING Type hints for IDE support and static analysis Python standard library

Releasing

This project uses Semantic Versioning (vMAJOR.MINOR.PATCH):

  • MAJOR (v1.0.0, v2.0.0): Breaking API changes
  • MINOR (v0.3.0, v0.4.0): New features, backward-compatible
  • PATCH (v0.3.1, v0.3.2): Bug fixes, minor corrections

To publish a new version to PyPI:

  1. Regenerate the API architecture diagram:
    pydeps src/flow_state --noshow --max-bacon=4 --cluster -o docs/assets/architecture.svg
    
  2. Commit and push to main
  3. Tag and push:
    git tag -a vMAJOR.MINOR.PATCH -m "Release vMAJOR.MINOR.PATCH"
    git push origin vMAJOR.MINOR.PATCH
    

The GitHub Actions workflow will automatically build and publish to PyPI via Trusted Publishing.

License

BSD-3-Clause. See LICENSE for details.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

flowstate-0.5.5.tar.gz (1.6 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

flowstate-0.5.5-py3-none-any.whl (56.9 kB view details)

Uploaded Python 3

File details

Details for the file flowstate-0.5.5.tar.gz.

File metadata

  • Download URL: flowstate-0.5.5.tar.gz
  • Upload date:
  • Size: 1.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for flowstate-0.5.5.tar.gz
Algorithm Hash digest
SHA256 bb9c1de36e064063fe57bed984bd10c83dc47b2121f3d3e87b1ac40676123767
MD5 845025909c1eaf2cdfeea3f9d68587dd
BLAKE2b-256 220b4d7d2174e994976b9c4a95b44d3374a6800403342edba02bee62b238eeb3

See more details on using hashes here.

Provenance

The following attestation bundles were made for flowstate-0.5.5.tar.gz:

Publisher: publish.yml on uahypersonics/flow-state

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file flowstate-0.5.5-py3-none-any.whl.

File metadata

  • Download URL: flowstate-0.5.5-py3-none-any.whl
  • Upload date:
  • Size: 56.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for flowstate-0.5.5-py3-none-any.whl
Algorithm Hash digest
SHA256 e8a0ae99d3ccbb62b7ac3c7e27d1a1c6355fe494530738a4b7bdec89d15d4542
MD5 6eb2ea5832bc299a622270a871a53f49
BLAKE2b-256 f2af2515adc3bba7701bca2ef181b52fd9fed335a9299d6039c9bcc3aeeb1f3c

See more details on using hashes here.

Provenance

The following attestation bundles were made for flowstate-0.5.5-py3-none-any.whl:

Publisher: publish.yml on uahypersonics/flow-state

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.6.0

2 files

This release

0.5.5 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page