https://github.com/pandaiscodingcpu/rocket_trajectory
A simple physics-based simulator to model the trajectory of a rocket based on initial conditions like thrust, drag, gravity, and atmospheric resistance.
https://github.com/pandaiscodingcpu/rocket_trajectory
matplotlib-pyplot numpy-library
Last synced: 8 months ago
JSON representation
A simple physics-based simulator to model the trajectory of a rocket based on initial conditions like thrust, drag, gravity, and atmospheric resistance.
- Host: GitHub
- URL: https://github.com/pandaiscodingcpu/rocket_trajectory
- Owner: pandaiscodingcpu
- Created: 2025-02-20T09:15:24.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-02-28T00:57:35.000Z (9 months ago)
- Last Synced: 2025-02-28T09:14:16.133Z (9 months ago)
- Topics: matplotlib-pyplot, numpy-library
- Language: Python
- Homepage:
- Size: 37.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## π Rocket Trajectory Simulator
A simple physics-based simulator that models a rocket's vertical trajectory considering thrust, gravity, drag, and mass reduction due to fuel consumption.
### **Features:**
- β
Simulates **rocket motion** using Newtonian physics.
- β
Takes user inputs for **thrust, mass, fuel burn rate, and flight time**.
- β
Implements **drag force** based on cross-sectional area and air resistance.
- β
Updates **velocity and altitude** iteratively using small time steps.
- β
**Plots altitude vs. time** for visualization.
### **How It Works:**
1. User inputs **rocket parameters** (thrust, mass, fuel burn rate, etc.).
2. The simulation updates velocity and altitude at each time step using **Newton's laws**.
3. **Drag force and fuel consumption** are dynamically adjusted.
4. The altitude vs. time **graph is plotted** using Matplotlib.
### **Tech Stack:**
- **Programming Language:** Python
- **Libraries:** NumPy, Matplotlib
- **Concepts Used:** Kinematics, Newtonβs Laws, Aerodynamic Drag