Feature/cluster motor structure#924
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a new ClusterMotor implementation to RocketPy, intended to model a symmetric cluster of identical motors by aggregating thrust, mass, and inertia (including parallel-axis/Steiner corrections), with accompanying integration tests.
Changes:
- Introduces
rocketpy.motors.cluster_motor.ClusterMotor(new motor type built on top ofMotor). - Implements cluster-scaled thrust/mass/inertia behavior plus a simple cluster layout plotting helper.
- Adds integration tests validating basic scaling and Steiner-theorem inertia expectations.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
rocketpy/motors/cluster_motor.py |
New ClusterMotor class that aggregates an underlying motor’s properties for clustered configurations. |
tests/integration/motors/test_cluster_motor.py |
New integration tests for cluster initialization, scaling, and inertia calculations. |
You can also share your feedback on Copilot code review. Take the survey.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #924 +/- ##
===========================================
+ Coverage 80.27% 81.20% +0.92%
===========================================
Files 104 114 +10
Lines 12769 14735 +1966
===========================================
+ Hits 10250 11965 +1715
- Misses 2519 2770 +251 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
MateusStano
left a comment
There was a problem hiding this comment.
This is really good! Just requested a few changes and it should be good to merge
|
Hi @MateusStano, thanks for the great feedback! You were spot on about the inertia calculations.I've renamed the class to RingClusterMotor and updated the docstrings to make it clear that this specifically models an annular configuration without a central motor.To fix the issue with the |
Add unreleased changelog entry for PR RocketPy-Team#924 (RingClusterMotor annular cluster feature). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Implemented one pending merge-readiness item on this PR:\n\n- updated CHANGELOG.md with an Unreleased entry for RingClusterMotor (#924).\n\nCommit: �d10a942\n\n@MateusStano could you please take a final look so we can move this to merge? |
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
… appeared through th merge
Add unreleased changelog entry for PR RocketPy-Team#924 (RingClusterMotor annular cluster feature). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Restore required aero surface and motor imports in rocket plots and fix Fin type dispatch to keep cluster motor plotting code valid after rebase. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
ad10a94 to
378ec7c
Compare
|
Update: I rebased eature/cluster-motor-structure onto current develop and resolved conflicts to keep the PR merge-ready.\n\nAdditional adjustments included in this update:\n- added CHANGELOG.md Unreleased entry for RingClusterMotor (#924)\n- fixed post-rebase plotting imports/type dispatch in |
Pull request type
Checklist
black rocketpy/ tests/) has passed locallypytest tests/integration/motors/test_cluster_motor.py) have passed locallyCHANGELOG.mdhas been updated (if relevant)Current behavior
Currently, RocketPy does not have native support for clustered motor configurations.
Users attempting to simulate a cluster (e.g., 3x or 4x motors) must manually create a "custom" single motor with scaled thrust curves and manually calculate the complex inertia changes caused by the off-axis mass distribution using external tools. This process is error-prone and does not dynamically update the inertia tensor correctly as propellant is consumed.
New behavior
This PR introduces a new
ClusterMotorclass inrocketpy.motors.SolidMotorobject, preserving all its internal ballistics.Breaking change
To do
Once implementation has been validated, we will still need to improve the draw() function to enable the drawing of grouped projects. For now, I have only implemented a rear view, so that the placement of the engines is visible.
This feature was developed by the French rocket science association IPSA SPACE SYSTEMS. Come say hello to us on Instagram!
https://www.instagram.com/ipsa_space_systems/