Skip to content

feat: add compressible gas dynamics, isentropic nozzle sizing, and normal shock mechanics - #4

Merged
perfectalone375 merged 1 commit into
mainfrom
feat/compressible-flow-and-shocks
Nov 6, 2026
Merged

perfectalone375 merged 1 commit into
mainfrom
feat/compressible-flow-and-shocks

Conversation

@perfectalone375

Copy link
Copy Markdown
Owner

Summary of Changes

  • Isentropic Gas Dynamics: Added exact analytical ratios for total-to-static temperature, density, and sonic throat area ratio $A/A^*$.
  • Normal Shock Mechanics: Implemented 1D Rankine-Hugoniot normal shock equations calculating downstream Mach $M_2$, static pressure ratio $P_2/P_1$, and total pressure loss ratio $P_{02}/P_{01}$.
  • Prandtl-Meyer Expansion: Implemented $\nu(M)$ expansion angle in degrees.
  • API & MCP: Exposed via FastAPI endpoints and Model Context Protocol stdio tools for AI pair programming.
  • Test Suite: 7 new unit tests in tests/test_compressible.py, 100% passing across 52 total tests.

Co-authored-by: Claude noreply@anthropic.com

…normal shock mechanics

Introduce verified compressible gas dynamics equations:
- Stagnation temperature (T0/T) and density (rho0/rho) ratios
- Isentropic nozzle area ratio (A/A*) for supersonic and subsonic regimes
- Normal shock Rankine-Hugoniot relations: downstream Mach M2, static pressure jump P2/P1, and total pressure loss P02/P01
- Prandtl-Meyer supersonic expansion angle nu(M)
- REST API endpoints in /fluids/compressible/
- Model Context Protocol (MCP) tool registrations: openeng_compressible_isentropic and openeng_normal_shock
- Comprehensive pytest test suite with 7 new analytical verification tests

Co-authored-by: Claude <noreply@anthropic.com>
@perfectalone375
perfectalone375 merged commit 9a51cb1 into main Nov 6, 2026
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant