<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/RocketPy_Logo_white.png">
<source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/RocketPy_Logo_black.png">
<img alt="RocketPy Logo" src="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/RocketPy_Logo_black.png">
</picture>
<br>
[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/RocketPy-Team/rocketpy/blob/master/docs/notebooks/getting_started_colab.ipynb)
[![Documentation Status](https://readthedocs.org/projects/rocketpyalpha/badge/?version=latest)](https://docs.rocketpy.org/en/latest/?badge=latest)
[![PyPI](https://img.shields.io/pypi/v/rocketpy?color=g)](https://pypi.org/project/rocketpy/)
![Conda Version](https://img.shields.io/conda/v/conda-forge/rocketpy?color=g)
[![codecov](https://codecov.io/gh/RocketPy-Team/RocketPy/graph/badge.svg?token=Ecc3bsHFeP)](https://codecov.io/gh/RocketPy-Team/RocketPy)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
[![Contributors](https://img.shields.io/github/contributors/RocketPy-Team/rocketpy)](https://github.com/RocketPy-Team/RocketPy/graphs/contributors)
[![Sponsor RocketPy](https://img.shields.io/static/v1?label=Sponsor&message=%E2%9D%A4&logo=GitHub&color=%23fe8e86)](https://github.com/sponsors/RocketPy-Team)
[![Chat on Discord](https://img.shields.io/discord/765037887016140840?logo=discord)](https://discord.gg/b6xYnNh)
[![Instagram](https://img.shields.io/badge/Instagram-E4405F?style=flat&logo=instagram&logoColor=white)](https://www.instagram.com/rocketpyteam)
[![LinkedIn](https://img.shields.io/badge/LinkedIn-0077B5?style=flat&logo=linkedin&logoColor=white)](https://www.linkedin.com/company/rocketpy)
[![DOI](https://img.shields.io/badge/DOI-10.1061%2F%28ASCE%29AS.1943--5525.0001331-blue.svg)](http://dx.doi.org/10.1061/%28ASCE%29AS.1943-5525.0001331)
# RocketPy
RocketPy is the next-generation trajectory simulation solution for High-Power Rocketry. The code is written as a [Python](http://www.python.org) library and allows for a complete 6 degrees of freedom simulation of a rocket's flight trajectory, including high-fidelity variable mass effects as well as descent under parachutes. Weather conditions, such as wind profiles, can be imported from sophisticated datasets, allowing for realistic scenarios. Furthermore, the implementation facilitates complex simulations, such as multi-stage rockets, design and trajectory optimization and dispersion analysis.
## Main features
1. **Nonlinear 6 Degrees of Freedom Simulations**
- Rigorous treatment of mass variation effects
- Efficiently solved using LSODA with adjustable error tolerances
- Highly optimized for fast performance
2. **Accurate Weather Modeling**
- Supports International Standard Atmosphere (1976)
- Custom atmospheric profiles and Soundings (Wyoming)
- Weather forecasts, reanalysis, and ensembles for realistic scenarios
3. **Aerodynamic Models**
- Optional Barrowman equations for lift coefficients
- Easy import of drag coefficients from other sources (e.g., CFD simulations)
4. **Parachutes with External Trigger Functions**
- Test the exact code that will fly
- Sensor data augmentation with noise for comprehensive parachute simulations
5. **Solid, Hybrid, and Liquid Motors Models**
- Burn rate and mass variation properties from the thrust curve
- Define custom rocket tanks based on flux data
- Support for CSV and ENG file formats
6. **Monte Carlo Simulations**
- Conduct dispersion analysis and global sensitivity analysis
7. **Flexible and Modular**
- Perform straightforward engineering analysis (e.g., apogee and lift-off speed as a function of mass)
- Handle non-standard flights (e.g., parachute drop test from a helicopter)
- Support multi-stage rockets and custom continuous/discrete control laws
- Easily create new classes, such as other types of motors
8. **Integration with MATLAB®**
- Effortlessly run RocketPy from MATLAB®
- Convert RocketPy results to MATLAB® variables for further processing
These powerful features make RocketPy an indispensable tool for high-power rocket trajectory simulation, catering to enthusiasts, researchers, and engineers in the field of rocketry.
## Validation
RocketPy's features have been validated in our latest [research article published in the Journal of Aerospace Engineering](http://dx.doi.org/10.1061/%28ASCE%29AS.1943-5525.0001331).
The table below shows a comparison between experimental data and the output from RocketPy.
Flight data and rocket parameters used in this comparison were kindly provided by [EPFL Rocket Team](https://github.com/EPFLRocketTeam) and [Notre Dame Rocket Team](https://ndrocketry.weebly.com/).
| Mission | Result Parameter | RocketPy | Measured | Relative Error |
|:-----------------------:|:-----------------------|:---------:|:---------:|:---------------:|
| Bella Lui Kaltbrumn | Apogee altitude (m) | 461.03 | 458.97 | **0.45 %** |
| Bella Lui Kaltbrumn | Apogee time (s) | 10.61 | 10.56 | **0.47 %** |
| Bella Lui Kaltbrumn | Maximum velocity (m/s) | 86.18 | 90.00 | **-4.24 %** |
| NDRT launch vehicle | Apogee altitude (m) | 1,310.44 | 1,320.37 | **-0.75 %** |
| NDRT launch vehicle | Apogee time (s) | 16.77 | 17.10 | **-1.90 %** |
| NDRT launch vehicle | Maximum velocity (m/s) | 172.86 | 168.95 | **2.31 %** |
Over years of development and testing, RocketPy has been validated across an expanding range of flight scenarios.
For more information on these validated flights, visit our [Flight Examples](https://docs.rocketpy.org/en/latest/examples/index.html) page in the documentation.
# Documentation
Check out documentation details using the links below:
- [User Guide](https://docs.rocketpy.org/en/latest/user/index.html)
- [Code Documentation](https://docs.rocketpy.org/en/latest/reference/index.html)
- [Development Guide](https://docs.rocketpy.org/en/latest/development/index.html)
- [Technical Documentation](https://docs.rocketpy.org/en/latest/technical/index.html)
- [Flight Examples](https://docs.rocketpy.org/en/latest/examples/index.html)
<br>
# Join Our Community!
RocketPy is growing fast! Many university groups and rocket hobbyists have already started using it. The number of stars and forks for this repository is skyrocketing. And this is all thanks to a great community of users, engineers, developers, marketing specialists, and everyone interested in helping.
If you want to be a part of this and make RocketPy your own, join our [Discord](https://discord.gg/b6xYnNh) server today!
<br>
# Previewing
You can preview RocketPy's main functionalities by browsing through a sample notebook in [Google Colab](https://colab.research.google.com/github/RocketPy-Team/rocketpy/blob/master/docs/notebooks/getting_started_colab.ipynb). No installation is required!
When you are ready to run RocketPy locally, you can read the *Getting Started* section!
<br>
# Getting Started
## Quick Installation
To install RocketPy's latest stable version from PyPI, just open up your terminal and run:
```shell
pip install rocketpy
```
For other installation options, visit our [Installation Docs](https://docs.rocketpy.org/en/latest/user/installation.html).
To learn more about RocketPy's requirements, visit our [Requirements Docs](https://docs.rocketpy.org/en/latest/user/requirements.html).
## Running Your First Simulation
In order to run your first rocket trajectory simulation using RocketPy, you can start a Jupyter Notebook and navigate to the `docs/notebooks` folder. Open `getting_started.ipynb` and you are ready to go. We recommend that you read the [First Simulation](https://docs.rocketpy.org/en/latest/user/first_simulation.html) page to get a complete description.
Otherwise, you may want to create your own script or your own notebook using RocketPy. To do this, let's see how to use RocketPy's four main classes:
- `Environment` - Keeps data related to weather.
- `Motor` - Subdivided into `SolidMotor`, `HybridMotor` and `LiquidMotor`. Keeps data related to rocket motors.
- `Rocket` - Keeps data related to a rocket.
- `Flight` - Runs the simulation and keeps the results.
The following image shows how the four main classes interact with each other:
![Diagram](https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/Fluxogram-Page-2.svg)
A typical workflow starts with importing these classes from RocketPy:
```python
from rocketpy import Environment, Rocket, SolidMotor, Flight
```
An optional step is to import datetime, which is used to define the date of the simulation:
```python
import datetime
```
Then create an Environment object. To learn more about it, you can use:
```python
help(Environment)
```
A sample code is:
```python
env = Environment(
latitude=32.990254,
longitude=-106.974998,
elevation=1400,
)
tomorrow = datetime.date.today() + datetime.timedelta(days=1)
env.set_date(
(tomorrow.year, tomorrow.month, tomorrow.day, 12), timezone="America/Denver"
) # Tomorrow's date in year, month, day, hour UTC format
env.set_atmospheric_model(type='Forecast', file='GFS')
```
This can be followed up by starting a Solid Motor object. To get help on it, just use:
```python
help(SolidMotor)
```
A sample Motor object can be created by the following code:
```python
Pro75M1670 = SolidMotor(
thrust_source="data/motors/cesaroni/Cesaroni_M1670.eng",
dry_mass=1.815,
dry_inertia=(0.125, 0.125, 0.002),
center_of_dry_mass_position=0.317,
grains_center_of_mass_position=0.397,
burn_time=3.9,
grain_number=5,
grain_separation=0.005,
grain_density=1815,
grain_outer_radius=0.033,
grain_initial_inner_radius=0.015,
grain_initial_height=0.12,
nozzle_radius=0.033,
throat_radius=0.011,
interpolation_method="linear",
nozzle_position=0,
coordinate_system_orientation="nozzle_to_combustion_chamber",
)
```
With a Solid Motor defined, you are ready to create your Rocket object. As you may have guessed, to get help on it, use:
```python
help(Rocket)
```
A sample code to create a Rocket is:
```python
calisto = Rocket(
radius=0.0635,
mass=14.426, # without motor
inertia=(6.321, 6.321, 0.034),
power_off_drag="data/rockets/calisto/powerOffDragCurve.csv",
power_on_drag="data/rockets/calisto/powerOnDragCurve.csv",
center_of_mass_without_motor=0,
coordinate_system_orientation="tail_to_nose",
)
buttons = calisto.set_rail_buttons(
upper_button_position=0.0818,
lower_button_position=-0.6182,
angular_position=45,
)
calisto.add_motor(Pro75M1670, position=-1.255)
nose = calisto.add_nose(
length=0.55829, kind="vonKarman", position=1.278
)
fins = calisto.add_trapezoidal_fins(
n=4,
root_chord=0.120,
tip_chord=0.040,
span=0.100,
sweep_length=None,
cant_angle=0,
position=-1.04956,
)
tail = calisto.add_tail(
top_radius=0.0635, bottom_radius=0.0435, length=0.060, position=-1.194656
)
```
You may want to add parachutes to your rocket as well:
```python
main = calisto.add_parachute(
name="main",
cd_s=10.0,
trigger=800, # ejection altitude in meters
sampling_rate=105,
lag=1.5,
noise=(0, 8.3, 0.5),
)
drogue = calisto.add_parachute(
name="drogue",
cd_s=1.0,
trigger="apogee", # ejection at apogee
sampling_rate=105,
lag=1.5,
noise=(0, 8.3, 0.5),
)
```
Finally, you can create a Flight object to simulate your trajectory. To get help on the Flight class, use:
```python
help(Flight)
```
To actually create a Flight object, use:
```python
test_flight = Flight(
rocket=calisto, environment=env, rail_length=5.2, inclination=85, heading=0
)
```
Once the Flight object is created, your simulation is done! Use the following code to get a summary of the results:
```python
test_flight.info()
```
To see all available results, use:
```python
test_flight.all_info()
```
Here is just a quick taste of what RocketPy is able to calculate. There are hundreds of plots and data points computed by RocketPy to enhance your analyses.
![6-DOF Trajectory Plot](https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/rocketpy_example_trajectory.svg)
If you want to see the trajectory on Google Earth, RocketPy acn easily export a KML file for you:
```python
test_flight.export_kml(file_name="test_flight.kml")
```
<img alt="6-DOF Trajectory Plot" src="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/trajectory-earth.png" width="501">
# Authors and Contributors
This package was originally created by [Giovani Ceotto](https://github.com/giovaniceotto/) as part of his work at [Projeto Jupiter](https://github.com/Projeto-Jupiter/). [Rodrigo Schmitt](https://github.com/rodrigo-schmitt/) was one of the first contributors. Later, [Guilherme Fernandes](https://github.com/Gui-FernandesBR/) and [Lucas Azevedo](https://github.com/lucasfourier/) joined the team to work on the expansion and sustainability of this project.
Since then, the [RocketPy Team](https://github.com/orgs/RocketPy-Team/teams/rocketpy-team) has been growing fast and our contributors are what makes us special!
## Institutional Contributors
RocketPy extends its gratitude to the following institutions for their support and contributions:
<div>
<a href="https://github.com/Projeto-Jupiter">
<picture align=top>
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/projeto_jupiter_dark.png" height="150px">
<source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/projeto_jupiter_light.jpg" height="150px">
<img align=top id="projeto-jupiter-image" alt="Projeto Jupiter Logo" src="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/projeto_jupiter_light.jpg" height="150px">
</picture>
</a>
<a href="https://github.com/Space-Enterprise-at-Berkeley">
<img align=top alt="Space Enterprise at Berkeley Logo" src="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/space_enterprise_at_berkeley.jpeg" height="150px">
</a>
<a href="https://www.instagram.com/faradayupv">
<img align=top alt="Faraday Rocketry UPV Logo" src="https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/faraday_team_logo.jpg" height="150px">
</a>
</div>
## Individual Contributors
RocketPy is also indebted to a growing list of individual contributors who actively participate in its development. These include:
[![GitHub Contributors Image](https://contrib.rocks/image?repo=RocketPy-Team/RocketPy)](https://github.com/RocketPy-Team/RocketPy/contributors)
See a [detailed list of contributors](https://github.com/RocketPy-Team/RocketPy/contributors) who are actively working on RocketPy.
## Supporting RocketPy and Contributing
The easiest way to help RocketPy is to demonstrate your support by starring our repository!
[![starcharts stargazers over time](https://starchart.cc/rocketpy-team/rocketpy.svg)](https://starchart.cc/rocketpy-team/rocketpy)
You can also become a [sponsor](https://github.com/sponsors/RocketPy-Team) and help us financially to keep the project going.
If you are actively using RocketPy in one of your projects, reaching out to our core team via [Discord](https://discord.gg/b6xYnNh) and providing feedback can help improve RocketPy a lot!
And if you are interested in going one step further, please read the [development documentation](https://docs.rocketpy.org/en/latest/development/index.html) to learn more about how you can contribute to the development of this next-gen trajectory simulation solution for rocketry.
## License
This project is licensed under the MIT License - see the [LICENSE.md](https://github.com/RocketPy-Team/RocketPy/blob/master/LICENSE) file for details
## Release Notes
Want to know which bugs have been fixed and the new features of each version? Check out the [release notes](https://github.com/RocketPy-Team/RocketPy/releases).
Raw data
{
"_id": null,
"home_page": null,
"name": "rocketpy",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": null,
"author": null,
"author_email": "Giovani Hidalgo Ceotto <ghceotto@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/9b/8e/b916548c487d553530e9231d3bd9dbd4608826a35cf55d082fdfd835302f/rocketpy-1.7.1.tar.gz",
"platform": null,
"description": "<picture>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/RocketPy_Logo_white.png\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/RocketPy_Logo_black.png\">\n <img alt=\"RocketPy Logo\" src=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/RocketPy_Logo_black.png\">\n</picture>\n\n<br>\n\n[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/RocketPy-Team/rocketpy/blob/master/docs/notebooks/getting_started_colab.ipynb)\n[![Documentation Status](https://readthedocs.org/projects/rocketpyalpha/badge/?version=latest)](https://docs.rocketpy.org/en/latest/?badge=latest)\n[![PyPI](https://img.shields.io/pypi/v/rocketpy?color=g)](https://pypi.org/project/rocketpy/)\n![Conda Version](https://img.shields.io/conda/v/conda-forge/rocketpy?color=g)\n[![codecov](https://codecov.io/gh/RocketPy-Team/RocketPy/graph/badge.svg?token=Ecc3bsHFeP)](https://codecov.io/gh/RocketPy-Team/RocketPy)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![Contributors](https://img.shields.io/github/contributors/RocketPy-Team/rocketpy)](https://github.com/RocketPy-Team/RocketPy/graphs/contributors)\n[![Sponsor RocketPy](https://img.shields.io/static/v1?label=Sponsor&message=%E2%9D%A4&logo=GitHub&color=%23fe8e86)](https://github.com/sponsors/RocketPy-Team)\n[![Chat on Discord](https://img.shields.io/discord/765037887016140840?logo=discord)](https://discord.gg/b6xYnNh)\n[![Instagram](https://img.shields.io/badge/Instagram-E4405F?style=flat&logo=instagram&logoColor=white)](https://www.instagram.com/rocketpyteam)\n[![LinkedIn](https://img.shields.io/badge/LinkedIn-0077B5?style=flat&logo=linkedin&logoColor=white)](https://www.linkedin.com/company/rocketpy)\n[![DOI](https://img.shields.io/badge/DOI-10.1061%2F%28ASCE%29AS.1943--5525.0001331-blue.svg)](http://dx.doi.org/10.1061/%28ASCE%29AS.1943-5525.0001331)\n\n# RocketPy\n\nRocketPy is the next-generation trajectory simulation solution for High-Power Rocketry. The code is written as a [Python](http://www.python.org) library and allows for a complete 6 degrees of freedom simulation of a rocket's flight trajectory, including high-fidelity variable mass effects as well as descent under parachutes. Weather conditions, such as wind profiles, can be imported from sophisticated datasets, allowing for realistic scenarios. Furthermore, the implementation facilitates complex simulations, such as multi-stage rockets, design and trajectory optimization and dispersion analysis.\n\n\n## Main features\n\n1. **Nonlinear 6 Degrees of Freedom Simulations**\n - Rigorous treatment of mass variation effects\n - Efficiently solved using LSODA with adjustable error tolerances\n - Highly optimized for fast performance\n\n2. **Accurate Weather Modeling**\n - Supports International Standard Atmosphere (1976)\n - Custom atmospheric profiles and Soundings (Wyoming)\n - Weather forecasts, reanalysis, and ensembles for realistic scenarios\n\n3. **Aerodynamic Models**\n - Optional Barrowman equations for lift coefficients\n - Easy import of drag coefficients from other sources (e.g., CFD simulations)\n\n4. **Parachutes with External Trigger Functions**\n - Test the exact code that will fly\n - Sensor data augmentation with noise for comprehensive parachute simulations\n\n5. **Solid, Hybrid, and Liquid Motors Models**\n - Burn rate and mass variation properties from the thrust curve\n - Define custom rocket tanks based on flux data\n - Support for CSV and ENG file formats\n\n6. **Monte Carlo Simulations**\n - Conduct dispersion analysis and global sensitivity analysis\n\n7. **Flexible and Modular**\n - Perform straightforward engineering analysis (e.g., apogee and lift-off speed as a function of mass)\n - Handle non-standard flights (e.g., parachute drop test from a helicopter)\n - Support multi-stage rockets and custom continuous/discrete control laws\n - Easily create new classes, such as other types of motors\n\n8. **Integration with MATLAB\u00ae**\n - Effortlessly run RocketPy from MATLAB\u00ae\n - Convert RocketPy results to MATLAB\u00ae variables for further processing\n\nThese powerful features make RocketPy an indispensable tool for high-power rocket trajectory simulation, catering to enthusiasts, researchers, and engineers in the field of rocketry.\n\n## Validation\n\nRocketPy's features have been validated in our latest [research article published in the Journal of Aerospace Engineering](http://dx.doi.org/10.1061/%28ASCE%29AS.1943-5525.0001331).\n\nThe table below shows a comparison between experimental data and the output from RocketPy.\nFlight data and rocket parameters used in this comparison were kindly provided by [EPFL Rocket Team](https://github.com/EPFLRocketTeam) and [Notre Dame Rocket Team](https://ndrocketry.weebly.com/).\n\n| Mission | Result Parameter | RocketPy | Measured | Relative Error |\n|:-----------------------:|:-----------------------|:---------:|:---------:|:---------------:|\n| Bella Lui Kaltbrumn | Apogee altitude (m) | 461.03 | 458.97 | **0.45 %** |\n| Bella Lui Kaltbrumn | Apogee time (s) | 10.61 | 10.56 | **0.47 %** |\n| Bella Lui Kaltbrumn | Maximum velocity (m/s) | 86.18 | 90.00 | **-4.24 %** |\n| NDRT launch vehicle | Apogee altitude (m) | 1,310.44 | 1,320.37 | **-0.75 %** |\n| NDRT launch vehicle | Apogee time (s) | 16.77 | 17.10 | **-1.90 %** |\n| NDRT launch vehicle | Maximum velocity (m/s) | 172.86 | 168.95 | **2.31 %** |\n\nOver years of development and testing, RocketPy has been validated across an expanding range of flight scenarios.\nFor more information on these validated flights, visit our [Flight Examples](https://docs.rocketpy.org/en/latest/examples/index.html) page in the documentation.\n\n# Documentation\n\nCheck out documentation details using the links below:\n\n- [User Guide](https://docs.rocketpy.org/en/latest/user/index.html)\n- [Code Documentation](https://docs.rocketpy.org/en/latest/reference/index.html)\n- [Development Guide](https://docs.rocketpy.org/en/latest/development/index.html)\n- [Technical Documentation](https://docs.rocketpy.org/en/latest/technical/index.html)\n- [Flight Examples](https://docs.rocketpy.org/en/latest/examples/index.html)\n\n<br>\n\n# Join Our Community!\n\nRocketPy is growing fast! Many university groups and rocket hobbyists have already started using it. The number of stars and forks for this repository is skyrocketing. And this is all thanks to a great community of users, engineers, developers, marketing specialists, and everyone interested in helping.\n\nIf you want to be a part of this and make RocketPy your own, join our [Discord](https://discord.gg/b6xYnNh) server today!\n\n<br>\n\n# Previewing\n\nYou can preview RocketPy's main functionalities by browsing through a sample notebook in [Google Colab](https://colab.research.google.com/github/RocketPy-Team/rocketpy/blob/master/docs/notebooks/getting_started_colab.ipynb). No installation is required!\n\nWhen you are ready to run RocketPy locally, you can read the *Getting Started* section!\n\n<br>\n\n# Getting Started\n\n## Quick Installation\n\nTo install RocketPy's latest stable version from PyPI, just open up your terminal and run:\n\n```shell\npip install rocketpy\n```\n\nFor other installation options, visit our [Installation Docs](https://docs.rocketpy.org/en/latest/user/installation.html).\nTo learn more about RocketPy's requirements, visit our [Requirements Docs](https://docs.rocketpy.org/en/latest/user/requirements.html).\n\n## Running Your First Simulation\n\nIn order to run your first rocket trajectory simulation using RocketPy, you can start a Jupyter Notebook and navigate to the `docs/notebooks` folder. Open `getting_started.ipynb` and you are ready to go. We recommend that you read the [First Simulation](https://docs.rocketpy.org/en/latest/user/first_simulation.html) page to get a complete description.\n\nOtherwise, you may want to create your own script or your own notebook using RocketPy. To do this, let's see how to use RocketPy's four main classes:\n\n- `Environment` - Keeps data related to weather.\n- `Motor` - Subdivided into `SolidMotor`, `HybridMotor` and `LiquidMotor`. Keeps data related to rocket motors.\n- `Rocket` - Keeps data related to a rocket.\n- `Flight` - Runs the simulation and keeps the results.\n\nThe following image shows how the four main classes interact with each other:\n\n![Diagram](https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/Fluxogram-Page-2.svg)\n\nA typical workflow starts with importing these classes from RocketPy:\n\n```python\nfrom rocketpy import Environment, Rocket, SolidMotor, Flight\n```\n\nAn optional step is to import datetime, which is used to define the date of the simulation:\n\n```python\nimport datetime\n```\n\nThen create an Environment object. To learn more about it, you can use:\n\n```python\nhelp(Environment)\n```\n\nA sample code is:\n\n```python\nenv = Environment(\n latitude=32.990254,\n longitude=-106.974998,\n elevation=1400,\n)\n\ntomorrow = datetime.date.today() + datetime.timedelta(days=1)\n\nenv.set_date(\n (tomorrow.year, tomorrow.month, tomorrow.day, 12), timezone=\"America/Denver\"\n) # Tomorrow's date in year, month, day, hour UTC format\n\nenv.set_atmospheric_model(type='Forecast', file='GFS')\n```\n\nThis can be followed up by starting a Solid Motor object. To get help on it, just use:\n\n```python\nhelp(SolidMotor)\n```\n\nA sample Motor object can be created by the following code:\n\n```python\nPro75M1670 = SolidMotor(\n thrust_source=\"data/motors/cesaroni/Cesaroni_M1670.eng\",\n dry_mass=1.815,\n dry_inertia=(0.125, 0.125, 0.002),\n center_of_dry_mass_position=0.317,\n grains_center_of_mass_position=0.397,\n burn_time=3.9,\n grain_number=5,\n grain_separation=0.005,\n grain_density=1815,\n grain_outer_radius=0.033,\n grain_initial_inner_radius=0.015,\n grain_initial_height=0.12,\n nozzle_radius=0.033,\n throat_radius=0.011,\n interpolation_method=\"linear\",\n nozzle_position=0,\n coordinate_system_orientation=\"nozzle_to_combustion_chamber\",\n)\n```\n\nWith a Solid Motor defined, you are ready to create your Rocket object. As you may have guessed, to get help on it, use:\n\n```python\nhelp(Rocket)\n```\n\nA sample code to create a Rocket is:\n\n```python\ncalisto = Rocket(\n radius=0.0635,\n mass=14.426, # without motor\n inertia=(6.321, 6.321, 0.034),\n power_off_drag=\"data/rockets/calisto/powerOffDragCurve.csv\",\n power_on_drag=\"data/rockets/calisto/powerOnDragCurve.csv\",\n center_of_mass_without_motor=0,\n coordinate_system_orientation=\"tail_to_nose\",\n)\n\nbuttons = calisto.set_rail_buttons(\n upper_button_position=0.0818,\n lower_button_position=-0.6182,\n angular_position=45,\n)\n\ncalisto.add_motor(Pro75M1670, position=-1.255)\n\nnose = calisto.add_nose(\n length=0.55829, kind=\"vonKarman\", position=1.278\n)\n\nfins = calisto.add_trapezoidal_fins(\n n=4,\n root_chord=0.120,\n tip_chord=0.040,\n span=0.100,\n sweep_length=None,\n cant_angle=0,\n position=-1.04956,\n)\n\ntail = calisto.add_tail(\n top_radius=0.0635, bottom_radius=0.0435, length=0.060, position=-1.194656\n)\n```\n\nYou may want to add parachutes to your rocket as well:\n\n```python\nmain = calisto.add_parachute(\n name=\"main\",\n cd_s=10.0,\n trigger=800, # ejection altitude in meters\n sampling_rate=105,\n lag=1.5,\n noise=(0, 8.3, 0.5),\n)\n\ndrogue = calisto.add_parachute(\n name=\"drogue\",\n cd_s=1.0,\n trigger=\"apogee\", # ejection at apogee\n sampling_rate=105,\n lag=1.5,\n noise=(0, 8.3, 0.5),\n)\n```\n\nFinally, you can create a Flight object to simulate your trajectory. To get help on the Flight class, use:\n\n```python\nhelp(Flight)\n```\n\nTo actually create a Flight object, use:\n\n```python\ntest_flight = Flight(\n rocket=calisto, environment=env, rail_length=5.2, inclination=85, heading=0\n)\n```\n\nOnce the Flight object is created, your simulation is done! Use the following code to get a summary of the results:\n\n```python\ntest_flight.info()\n```\n\nTo see all available results, use:\n\n```python\ntest_flight.all_info()\n```\n\nHere is just a quick taste of what RocketPy is able to calculate. There are hundreds of plots and data points computed by RocketPy to enhance your analyses.\n\n![6-DOF Trajectory Plot](https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/rocketpy_example_trajectory.svg)\n\nIf you want to see the trajectory on Google Earth, RocketPy acn easily export a KML file for you:\n\n```python\ntest_flight.export_kml(file_name=\"test_flight.kml\")\n```\n\n<img alt=\"6-DOF Trajectory Plot\" src=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/trajectory-earth.png\" width=\"501\">\n\n# Authors and Contributors\n\nThis package was originally created by [Giovani Ceotto](https://github.com/giovaniceotto/) as part of his work at [Projeto Jupiter](https://github.com/Projeto-Jupiter/). [Rodrigo Schmitt](https://github.com/rodrigo-schmitt/) was one of the first contributors. Later, [Guilherme Fernandes](https://github.com/Gui-FernandesBR/) and [Lucas Azevedo](https://github.com/lucasfourier/) joined the team to work on the expansion and sustainability of this project.\n\nSince then, the [RocketPy Team](https://github.com/orgs/RocketPy-Team/teams/rocketpy-team) has been growing fast and our contributors are what makes us special!\n\n## Institutional Contributors\n\nRocketPy extends its gratitude to the following institutions for their support and contributions:\n\n<div>\n <a href=\"https://github.com/Projeto-Jupiter\">\n <picture align=top>\n <source media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/projeto_jupiter_dark.png\" height=\"150px\">\n <source media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/projeto_jupiter_light.jpg\" height=\"150px\">\n <img align=top id=\"projeto-jupiter-image\" alt=\"Projeto Jupiter Logo\" src=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/projeto_jupiter_light.jpg\" height=\"150px\">\n </picture>\n </a>\n <a href=\"https://github.com/Space-Enterprise-at-Berkeley\">\n <img align=top alt=\"Space Enterprise at Berkeley Logo\" src=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/space_enterprise_at_berkeley.jpeg\" height=\"150px\">\n </a>\n <a href=\"https://www.instagram.com/faradayupv\">\n <img align=top alt=\"Faraday Rocketry UPV Logo\" src=\"https://raw.githubusercontent.com/RocketPy-Team/RocketPy/master/docs/static/institutional/faraday_team_logo.jpg\" height=\"150px\">\n </a>\n</div>\n\n## Individual Contributors\n\nRocketPy is also indebted to a growing list of individual contributors who actively participate in its development. These include:\n\n[![GitHub Contributors Image](https://contrib.rocks/image?repo=RocketPy-Team/RocketPy)](https://github.com/RocketPy-Team/RocketPy/contributors)\n\nSee a [detailed list of contributors](https://github.com/RocketPy-Team/RocketPy/contributors) who are actively working on RocketPy.\n\n## Supporting RocketPy and Contributing\n\nThe easiest way to help RocketPy is to demonstrate your support by starring our repository!\n\n[![starcharts stargazers over time](https://starchart.cc/rocketpy-team/rocketpy.svg)](https://starchart.cc/rocketpy-team/rocketpy)\n\nYou can also become a [sponsor](https://github.com/sponsors/RocketPy-Team) and help us financially to keep the project going.\n\nIf you are actively using RocketPy in one of your projects, reaching out to our core team via [Discord](https://discord.gg/b6xYnNh) and providing feedback can help improve RocketPy a lot!\n\nAnd if you are interested in going one step further, please read the [development documentation](https://docs.rocketpy.org/en/latest/development/index.html) to learn more about how you can contribute to the development of this next-gen trajectory simulation solution for rocketry.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE.md](https://github.com/RocketPy-Team/RocketPy/blob/master/LICENSE) file for details\n\n## Release Notes\n\nWant to know which bugs have been fixed and the new features of each version? Check out the [release notes](https://github.com/RocketPy-Team/RocketPy/releases).\n",
"bugtrack_url": null,
"license": null,
"summary": "Advanced 6-DOF trajectory simulation for High-Power Rocketry.",
"version": "1.7.1",
"project_urls": {
"documentation": "https://docs.rocketpy.org/",
"homepage": "https://rocketpy.org/",
"repository": "https://github.com/RocketPy-Team/RocketPy"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "0009b2bee9786e7de880b866026c4afbdc8feb10275958e552cc3b90992147d1",
"md5": "c86e1e54ad5ade23840869062b0ba9c8",
"sha256": "35022af7e58adf9de52b2113aa9b53f0593c235269019efdc4ed91a60744375d"
},
"downloads": -1,
"filename": "rocketpy-1.7.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "c86e1e54ad5ade23840869062b0ba9c8",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 346564,
"upload_time": "2024-12-07T10:24:37",
"upload_time_iso_8601": "2024-12-07T10:24:37.069733Z",
"url": "https://files.pythonhosted.org/packages/00/09/b2bee9786e7de880b866026c4afbdc8feb10275958e552cc3b90992147d1/rocketpy-1.7.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9b8eb916548c487d553530e9231d3bd9dbd4608826a35cf55d082fdfd835302f",
"md5": "ae3d5e6644a51ec60196fae95afca32d",
"sha256": "d6dfe02a5e1b8beed2aa4609c9d9a6bae31b07e62a453c066ca57d233707518e"
},
"downloads": -1,
"filename": "rocketpy-1.7.1.tar.gz",
"has_sig": false,
"md5_digest": "ae3d5e6644a51ec60196fae95afca32d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 292371,
"upload_time": "2024-12-07T10:24:39",
"upload_time_iso_8601": "2024-12-07T10:24:39.275236Z",
"url": "https://files.pythonhosted.org/packages/9b/8e/b916548c487d553530e9231d3bd9dbd4608826a35cf55d082fdfd835302f/rocketpy-1.7.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-12-07 10:24:39",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "RocketPy-Team",
"github_project": "RocketPy",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [
{
"name": "numpy",
"specs": [
[
">=",
"1.13"
]
]
},
{
"name": "scipy",
"specs": [
[
">=",
"1.0"
]
]
},
{
"name": "matplotlib",
"specs": [
[
">=",
"3.0"
]
]
},
{
"name": "netCDF4",
"specs": [
[
">=",
"1.6.4"
]
]
},
{
"name": "requests",
"specs": []
},
{
"name": "pytz",
"specs": []
},
{
"name": "simplekml",
"specs": []
}
],
"lcname": "rocketpy"
}