Skip to content

Commit 96ff97b

Browse files
authored
Merge pull request #282 from RocketPy-Team/enh/distances-vs-positons-v2
ENH: Distances vs Positons v2
2 parents 52bd7b4 + 7c14e54 commit 96ff97b

35 files changed

+2424
-3847
lines changed

README.md

+29-17
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
# RocketPy
1818

19-
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 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.
19+
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.
2020

2121
<br>
2222

@@ -78,7 +78,7 @@ RocketPy is the next-generation trajectory simulation solution for High-Power Ro
7878
<summary>Flexible and modular</summary>
7979
<ul>
8080
<li>Straightforward engineering analysis (e.g. apogee and lifting off speed as a function of mass)</li>
81-
<li>Non-standard flights (e.g. parachute drop test from helicopter)</li>
81+
<li>Non-standard flights (e.g. parachute drop test from a helicopter)</li>
8282
<li>Multi-stage rockets</li>
8383
<li>Custom continuous and discrete control laws</li>
8484
<li>Create new classes (e.g. other types of motors)</li>
@@ -125,15 +125,15 @@ Check out documentation details using the links below:
125125

126126
# Join Our Community!
127127

128-
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.
128+
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.
129129

130130
If you want to be a part of this and make RocketPy your own, join our [Discord](https://discord.gg/b6xYnNh) server today!
131131

132132
<br>
133133

134134
# Previewing
135135

136-
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 required!
136+
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!
137137

138138
When you are ready to run RocketPy locally, you can read the *Getting Started* section!
139139

@@ -229,24 +229,36 @@ A sample code to create a Rocket is:
229229

230230
```python
231231
Calisto = Rocket(
232-
motor=Pro75M1670,
233-
radius=127/2000,
234-
mass=19.197-2.956,
232+
radius=127 / 2000,
233+
mass=19.197 - 2.956,
235234
inertiaI=6.60,
236235
inertiaZ=0.0351,
237-
distanceRocketNozzle=-1.255,
238-
distanceRocketPropellant=-0.85704,
239-
powerOffDrag='../data/calisto/powerOffDragCurve.csv',
240-
powerOnDrag='../data/calisto/powerOnDragCurve.csv'
236+
powerOffDrag="../../data/calisto/powerOffDragCurve.csv",
237+
powerOnDrag="../../data/calisto/powerOnDragCurve.csv",
238+
centerOfDryMassPosition=0,
239+
coordinateSystemOrientation="tailToNose",
241240
)
242241

243242
Calisto.setRailButtons([0.2, -0.5])
244243

245-
NoseCone = Calisto.addNose(length=0.55829, kind="vonKarman", distanceToCM=0.71971)
244+
Calisto.addMotor(Pro75M1670, position=-1.255)
246245

247-
FinSet = Calisto.addTrapezoildalFins(4, span=0.100, rootChord=0.120, tipChord=0.040, distanceToCM=-1.04956)
246+
NoseCone = Calisto.addNose(length=0.55829, kind="vonKarman", position=0.71971 + 0.55829)
248247

249-
Tail = Calisto.addTail(topRadius=0.0635, bottomRadius=0.0435, length=0.060, distanceToCM=-1.194656)
248+
FinSet = Calisto.addTrapezoidalFins(
249+
n=4,
250+
rootChord=0.120,
251+
tipChord=0.040,
252+
span=0.100,
253+
position=-1.04956,
254+
cantAngle=0,
255+
radius=None,
256+
airfoil=None,
257+
)
258+
259+
Tail = Calisto.addTail(
260+
topRadius=0.0635, bottomRadius=0.0435, length=0.060, position=-1.194656
261+
)
250262
```
251263

252264
You may want to add parachutes to your rocket as well:
@@ -297,7 +309,7 @@ To see all available results, use:
297309
TestFlight.allInfo()
298310
```
299311

300-
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.
312+
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.
301313

302314
![6-DOF Trajectory Plot](docs/static/rocketpy_example_trajectory.svg)
303315

@@ -323,7 +335,7 @@ The easiest way to help RocketPy is to demonstrate your support by starring our
323335

324336
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!
325337

326-
And if you are interested in going one step further, please read [CONTRIBUTING.md](https://github.com/RocketPy-Team/RocketPy/blob/master/CONTRIBUTING.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.
338+
And if you are interested in going one step further, please read [CONTRIBUTING.md](https://github.com/RocketPy-Team/RocketPy/blob/master/CONTRIBUTING.md) for details on our code of conduct and learn more about how you can contribute to the development of this next-gen trajectory simulation solution for rocketry.
327339

328340
<br>
329341

@@ -335,4 +347,4 @@ This project is licensed under the MIT License - see the [LICENSE.md](https://gi
335347

336348
## Release Notes
337349

338-
Want to know which bugs have been fixed and new features of each version? Check out the [release notes](https://github.com/RocketPy-Team/RocketPy/releases).
350+
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).

docs/development/rocketpy_as_developer.rst

+21-9
Original file line numberDiff line numberDiff line change
@@ -151,17 +151,18 @@ The first step is to initialize the class with the vital data:
151151
.. code-block:: python
152152
153153
Calisto = Rocket(
154-
motor=Pro75M1670,
155154
radius=127 / 2000,
156155
mass=19.197 - 2.956,
157156
inertiaI=6.60,
158157
inertiaZ=0.0351,
159-
distanceRocketNozzle=-1.255,
160-
distanceRocketPropellant=-0.85704,
161-
powerOffDrag="../../data/calisto/powerOffDragCurve.csv", #copy here the path to the drag curve file
162-
powerOnDrag="../../data/calisto/powerOnDragCurve.csv", #copy here the path to the drag curve file
158+
powerOffDrag="../../data/calisto/powerOffDragCurve.csv",
159+
powerOnDrag="../../data/calisto/powerOnDragCurve.csv",
160+
centerOfDryMassPosition=0,
161+
coordinateSystemOrientation="tailToNose",
163162
)
164163
164+
Calisto.addMotor(Pro75M1670, position=-1.255)
165+
165166
Then the rail buttons must be set:
166167

167168
.. code-block:: python
@@ -174,11 +175,22 @@ In the example, a nosecone, one fin set and one tail were added, but each case c
174175

175176
.. code-block:: python
176177
177-
NoseCone = Calisto.addNose(length=0.55829, kind="vonKarman", distanceToCM=0.71971)
178-
179-
FinSet = Calisto.addFins(4, span=0.100, rootChord=0.120, tipChord=0.040, distanceToCM=-1.04956)
178+
NoseCone = Calisto.addNose(length=0.55829, kind="vonKarman", position=0.71971 + 0.55829)
179+
180+
FinSet = Calisto.addTrapezoidalFins(
181+
n=4,
182+
rootChord=0.120,
183+
tipChord=0.040,
184+
span=0.100,
185+
position=-1.04956,
186+
cantAngle=0,
187+
radius=None,
188+
airfoil=None,
189+
)
180190
181-
Tail = Calisto.addTail(topRadius=0.0635, bottomRadius=0.0435, length=0.060, distanceToCM=-1.194656)
191+
Tail = Calisto.addTail(
192+
topRadius=0.0635, bottomRadius=0.0435, length=0.060, position=-1.194656
193+
)
182194
183195
If you are considering the parachutes in the simulation, they also have to be added to the rocket object.
184196
A trigger function must be supplied to trigger the parachutes.

0 commit comments

Comments
 (0)