-
-
Notifications
You must be signed in to change notification settings - Fork 195
ENH: Improve parachute geometric parametrization #835
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
ENH: Improve parachute geometric parametrization #835
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR improves the parachute geometric parametrization by introducing new parameters (radius, height, and porosity) to provide a more flexible and accurate simulation. Key changes include:
- Adding lambda callbacks to update parachute_radius, parachute_height, and parachute_porosity in the simulation.
- Updating the added mass computation in flight dynamics to use parachute_radius and parachute_height.
- Extending the Parachute class to support the new parameters, with appropriate defaults and serialization.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
File | Description |
---|---|
rocketpy/simulation/flight.py | Updated simulation callbacks and mass computation with new parameters. |
rocketpy/rocket/parachute.py | Extended the Parachute class to include and serialize new parameters. |
Comments suppressed due to low confidence (2)
rocketpy/simulation/flight.py:2002
- [nitpick] Consider adding a comment to explain the rationale behind the modified added mass formula using parachute_radius squared times parachute_height, clarifying the geometrical model or assumptions used.
ma = ka * rho * (4 / 3) * np.pi * parachute_radius**2 * parachute_height
rocketpy/simulation/flight.py:2018
- Ensure that the variable 'z' is defined in this scope (for example, by extracting altitude from the state vector) to avoid potential runtime errors.
az = (Dz - mp * self.env.gravity.get_value_opt(z)) / (mp + ma)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.
porosity : float, optional | ||
Porosity of the parachute material, which is a measure of how much air can | ||
pass through the parachute material. | ||
Default value is 0.0432 (for consistency with previous versions). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you define more precisely what porosity is? Something like: "The ratio of the area of the porous structure to the total area of the canopy" (I don't know if this is the correct definition in our case, just an example)
Pull request type
Checklist
black rocketpy/ tests/
) has passed locallypytest tests -m slow --runslow
) have passed locallyCHANGELOG.md
has been updated (if relevant)Current behavior
Parachute radius is assumed to be fixed (=1.5m)
New behavior
Other than adding a radius parameter, there is also additional height and porosity parameters.
The default is still set to the current behavior.
Breaking change