Features β’ Quick Start β’ Documentation β’ Validation β’ Contributing
EnSim is an open-source desktop application for rocket propulsion analysis and flight simulation. It combines NASA-validated thermochemical equilibrium calculations with full 6-DOF trajectory simulation, all within a modern, user-friendly interface.
Whether you're a student learning rocket science, a researcher exploring propulsion concepts, or an engineer performing preliminary design analysis, EnSim provides the tools you need.
Click to expand screenshots
- NASA CEA Methodology: Gordon-McBride equilibrium solver with Gibbs free energy minimization
- Comprehensive Species Database: 35+ species including Hβ, Oβ, CHβ, RP-1, NβOβ, UDMH, MMH
- High-Temperature Dissociation: Full accounting for H, O, OH, NO, and other radicals
- Validated Accuracy: <2% error vs NASA CEA reference data
- Chamber Temperature: Adiabatic flame temperature with dissociation
- Characteristic Velocity (C)*: Key measure of combustion efficiency
- Specific Impulse (Isp): Both vacuum and sea-level values
- Thrust Coefficient (Cf): With nozzle divergence corrections
- Full Rigid Body Dynamics: Quaternion-based orientation (no gimbal lock)
- Adaptive Integration: RK45 Dormand-Prince with automatic step sizing
- Aerodynamic Models: Configurable drag and stability derivatives
- Dense Output: Cubic Hermite interpolation for smooth trajectories
- Landing Dispersion: CEP and 3-sigma confidence ellipses
- Performance Variability: Statistical analysis of Isp, thrust, burn time
- Parallel Processing: Multi-core execution for thousands of runs
- Visualization: Scatter plots, histograms, and probability contours
- Multi-Stage Vehicles: Full staging simulation with preset rockets (Falcon 9, Saturn V)
- Regenerative Cooling: Bartz correlation thermal analysis with channel design
- Trajectory Optimization: Nozzle expansion ratio and stage mass allocation
- Materials Database: 10 aerospace materials with thermal properties
- 17 Propellant Presets: Ready-to-use fuel/oxidizer combinations
- Mission Control Aesthetic: SpaceX-inspired dark theme with cyan/green neon accents
- Real-time KPI Dashboard: Live display of key performance metrics
- Interactive 3D Visualization: PyVista-powered nozzle and trajectory display
- SI/Imperial Units: One-click unit system toggle
- Professional Exports: CSV data, Markdown reports, STL/OBJ/PLY 3D models
- Python 3.10 or higher
- pip package manager
pip install ensim# Clone the repository
git clone https://github.com/SpaceEngineerSS/EnSim.git
cd EnSim
# Create virtual environment (recommended)
python -m venv venv
# Activate virtual environment
# Windows:
venv\Scripts\activate
# Linux/macOS:
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt# Launch the GUI application
python main.py
# Run with validation tests
python main.py --test- Select Propellants: Choose fuel (e.g., Hβ) and oxidizer (e.g., Oβ)
- Set Conditions: Enter O/F ratio, chamber pressure, expansion ratio
- Run Simulation: Click "RUN SIMULATION" to calculate performance
- Analyze Results: View KPIs, graphs, and 3D nozzle visualization
| Document | Description |
|---|---|
| ARCHITECTURE.md | System design and physics overview |
| docs/THEORY.md | Mathematical formulation and equations |
| docs/VALIDATION.md | NASA CEA comparison results |
| CONTRIBUTING.md | Contribution guidelines |
| CHANGELOG.md | Version history |
EnSim is rigorously validated against NASA CEA, the industry standard for rocket propulsion analysis.
| Propellant Combination | T_chamber Error | Isp Error | Status |
|---|---|---|---|
| LOX/LHβ | 1.76% | 1.41% | β Pass |
| LOX/CHβ | 0.48% | 1.07% | β Pass |
| LOX/RP-1 | 0.49% | 0.86% | β Pass |
| NβOβ/UDMH | 0.56% | 0.85% | β Pass |
Overall Accuracy: Average error <1% across all validated cases
See VALIDATION.md for detailed comparison data.
EnSim/
βββ π src/
β βββ π core/ # Physics Engine (Numba JIT)
β β βββ chemistry.py # Gibbs equilibrium solver
β β βββ propulsion.py # Nozzle flow calculations
β β βββ flight_6dof.py # 6-DOF dynamics
β β βββ integrators.py # RK45, Hermite interpolation
β β βββ monte_carlo.py # Dispersion analysis
β β βββ thermodynamics.py # NASA polynomial evaluation
β β
β βββ π ui/ # User Interface (PyQt6)
β β βββ windows/ # Main window, dialogs
β β βββ widgets/ # Custom widgets
β β βββ workers.py # Background threads
β β
β βββ π utils/ # Utilities
β βββ nasa_parser.py # Thermo data parser
β βββ exporters.py # Data export functions
β
βββ π data/ # NASA thermodynamic database
βββ π tests/ # Test suite (pytest)
βββ π docs/ # Documentation
βββ π assets/ # Icons, stylesheets
| Component | Technology | Purpose |
|---|---|---|
| GUI | PyQt6 | Modern cross-platform interface |
| Numerics | NumPy, SciPy | Array operations, optimization |
| Acceleration | Numba | JIT compilation for 10-100x speedup |
| 3D Visualization | PyVista | Interactive nozzle/trajectory display |
| 2D Plots | Matplotlib | Scientific plotting |
| Testing | pytest | Unit and validation tests |
We welcome contributions from the community! Whether it's:
- π Bug Reports: Found an issue? Open a bug report
- β¨ Feature Requests: Have an idea? Suggest a feature
- π¬ Scientific Issues: Validation concerns? Report a scientific issue
- π» Code Contributions: Ready to code? See CONTRIBUTING.md
# Install development dependencies
pip install -e ".[dev]"
# Run tests
pytest tests/ -v
# Run linting
ruff check src/
# Format code
black src/ tests/This project is licensed under the MIT License - see LICENSE for details.
- NASA Glenn Research Center - Thermodynamic polynomial database
- Sutton & Biblarz - "Rocket Propulsion Elements" reference
- The open-source scientific Python community - NumPy, SciPy, Matplotlib
-
Gordon, S. & McBride, B.J. (1994). "Computer Program for Calculation of Complex Chemical Equilibrium Compositions and Applications". NASA Reference Publication 1311.
-
McBride, B.J., Zehe, M.J., & Gordon, S. (2002). "NASA Glenn Coefficients for Calculating Thermodynamic Properties of Individual Species". NASA/TP-2002-211556.
-
Sutton, G.P. & Biblarz, O. (2017). "Rocket Propulsion Elements". 9th Edition, Wiley.
-
Anderson, J.D. (2003). "Modern Compressible Flow". 3rd Edition, McGraw-Hill.
Made with β€οΈ for the aerospace community






