Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Oct 30, 2022. It is now read-only.

RocketPy Hackathon 2022 official repository. Currently archieved due to maintenance reasons.

License

NotificationsYou must be signed in to change notification settings

RocketPy-Team/RocketPy-Hackathon-2022

 
 

Repository files navigation

RocketPy Logo


Open In ColabPyPIDocumentation StatusBuild StatusContributorsChat on DiscordSponsor RocketPyLinkedInDOI

RocketPy

RocketPy is the next-generation trajectory simulation solution for High-Power Rocketry. The code is written as aPython 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 profile, 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

Nonlinear 6 degrees of freedom simulations
  • Rigorous treatment of mass variation effects
  • Solved using LSODA with adjustable error tolerances
  • Highly optimized to run fast
Accurate weather modeling
  • International Standard Atmosphere (1976)
  • Custom atmospheric profiles
  • Soundings (Wyoming, NOAARuc)
  • Weather forecasts and reanalysis
  • Weather ensembles
Aerodynamic models
  • Barrowman equations for lift coefficients (optional)
  • Drag coefficients can be easily imported from other sources (e.g. CFD simulations)
Parachutes with external trigger functions
  • Test the exact code that will fly
  • Sensor data can be augmented with noise
Solid motors models
  • Burn rate and mass variation properties from thrust curve
  • CSV and ENG file support
Monte Carlo simulations
  • Dispersion analysis
  • Global sensitivity analysis
Flexible and modular
  • Straightforward engineering analysis (e.g. apogee and lifting off speed as a function of mass)
  • Non-standard flights (e.g. parachute drop test from helicopter)
  • Multi-stage rockets
  • Custom continuous and discrete control laws
  • Create new classes (e.g. other types of motors)
Integration with MATLAB®
  • Straightforward way to run RocketPy from MATLAB®
  • Convert RocketPy results to MATLAB® variables so that they can be processed by MATLAB®

Validation

RocketPy's features have been validated in our latestresearch article published in the Journal of Aerospace Engineering.

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 byEPFL Rocket Team andNotre Dame Rocket Team.

MissionResult ParameterRocketPyMeasuredRelative Error
Bella Lui KaltbrumnApogee altitude (m)461.03458.970.45 %
Bella Lui KaltbrumnApogee time (s)10.6110.560.47 %
Bella Lui KaltbrumnMaximum velocity (m/s)86.1890.00-4.24 %
NDRT launch vehicleApogee altitude (m)1,310.441,320.37-0.75 %
NDRT launch vehicleApogee time (s)16.7717.10-1.90 %
NDRT launch vehicleMaximum velocity (m/s)172.86168.952.31 %

Documentation

Check out documentation details using the links below:


Join Our Community!

RocketPy is growing fast! Many university groups and rocket hobbyist 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 ourDiscord server today!


Previewing

You can preview RocketPy's main functionalities by browsing through a sample notebook inGoogle Colab. No installation required!

When you are ready to run RocketPy locally, you can read theGetting Started section!


Getting Started

Quick Installation

To install RocketPy's latest stable version from PyPI, just open up your terminal and run:

pip install rocketpy

For other installation options, visit ourInstallation Docs.To learn more about RocketPy's requirements, visit ourRequirements Docs.


Running Your First Simulation

In order to run your first rocket trajectory simulation using RocketPy, you can start a Jupyter Notebook and navigate to thenbks folder. OpenGetting Started - Examples.ipynb and you are ready to go.

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.
  • SolidMotor - Keeps data related to solid motors. Hybrid motor support is coming in the next weeks.
  • 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

A typical workflow starts with importing these classes from RocketPy:

fromrocketpyimportEnvironment,Rocket,SolidMotor,Flight

Then create an Environment object. To learn more about it, you can use:

help(Environment)

A sample code is:

Env=Environment(railLength=5.2,latitude=32.990254,longitude=-106.974998,elevation=1400,date=(2020,3,4,12)# Tomorrow's date in year, month, day, hour UTC format)Env.setAtmosphericModel(type='Forecast',file='GFS')

This can be followed up by starting a Solid Motor object. To get help on it, just use:

help(SolidMotor)

A sample Motor object can be created by the following code:

Pro75M1670=SolidMotor(thrustSource="../data/motors/Cesaroni_M1670.eng",burnOut=3.9,grainNumber=5,grainSeparation=5/1000,grainDensity=1815,grainOuterRadius=33/1000,grainInitialInnerRadius=15/1000,grainInitialHeight=120/1000,nozzleRadius=33/1000,throatRadius=11/1000,interpolationMethod='linear')

With a Solid Motor defined, you are ready to create your Rocket object. As you may have guessed, to get help on it, use:

help(Rocket)

A sample code to create a Rocket is:

Calisto=Rocket(motor=Pro75M1670,radius=127/2000,mass=19.197-2.956,inertiaI=6.60,inertiaZ=0.0351,distanceRocketNozzle=-1.255,distanceRocketPropellant=-0.85704,powerOffDrag='../data/calisto/powerOffDragCurve.csv',powerOnDrag='../data/calisto/powerOnDragCurve.csv')Calisto.setRailButtons([0.2,-0.5])NoseCone=Calisto.addNose(length=0.55829,kind="vonKarman",distanceToCM=0.71971)FinSet=Calisto.addFins(4,span=0.100,rootChord=0.120,tipChord=0.040,distanceToCM=-1.04956)Tail=Calisto.addTail(topRadius=0.0635,bottomRadius=0.0435,length=0.060,distanceToCM=-1.194656)

You may want to add parachutes to your rocket as well:

defdrogueTrigger(p,y):returnTrueify[5]<0elseFalsedefmainTrigger(p,y):returnTrueify[5]<0andy[2]<800elseFalseMain=Calisto.addParachute('Main',CdS=10.0,trigger=mainTrigger,samplingRate=105,lag=1.5,noise=(0,8.3,0.5))Drogue=Calisto.addParachute('Drogue',CdS=1.0,trigger=drogueTrigger,samplingRate=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:

help(Flight)

To actually create a Flight object, use:

TestFlight=Flight(rocket=Calisto,environment=Env,inclination=85,heading=0)

Once the TestFlight object is created, your simulation is done! Use the following code to get a summary of the results:

TestFlight.info()

To seel all available results, use:

TestFlight.allInfo()

Here is just a quick taste of what RocketPy is able to calculate. There are hundred of plots and data points computed by RocketPy to enhance your analyses.

6-DOF Trajectory Plot


Authors and Contributors

This package was originally created byGiovani Ceotto as part of his work atProjeto Jupiter.Rodrigo Schmitt was one of the first contributors.

Later,Guilherme Fernandes andLucas Azevedo joined the team to work on the expansion and sustainability of this project.

Since then, theRocketPy Team has been growing fast and our contributors are what makes us special!

GitHub Contributors Image

See adetailed list of 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!GitHub Repo stars


If you are actively using RocketPy in one of your projects, reaching out to our core team viaDiscord and providing feedback can help improve RocketPy a lot!

And if you are interested in going one step further, please readCONTRIBUTING.md for details on our code of conduct and learn more on how you can contribute with the development of this next-gen trajectory simulation solution for rocketry.


License

This project is licensed under the MIT License - see theLICENSE.md file for details


Release Notes

Want to know which bugs have been fixed and new features of each version? Check out therelease notes.

About

RocketPy Hackathon 2022 official repository. Currently archieved due to maintenance reasons.

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python99.9%
  • Makefile0.1%

[8]ページ先頭

©2009-2025 Movatter.jp