Repository navigation
Conversation
Put the fourth initial-state value in the yaw coordinate so a requested heading does not tilt the rotor thrust. Cover constructor and parameter paths with physical hover checks and real bdsim diagrams. Co-Authored-By: ChatGPT (GPT-6 Astra Pro) <noreply@openai.com>
Rotate world translational velocity into body axes before combining it with rotor hub velocity. Verify world-yaw covariance and closed-form thrust and pitching moments. Co-Authored-By: ChatGPT (GPT-6 Astra Pro) <noreply@openai.com>
Allocate thrust, drag and moment arrays from the configured rotor count. Validate balanced flight and individual rotor moments for two, four, six and eight rotors. Co-Authored-By: ChatGPT (GPT-6 Astra Pro) <noreply@openai.com>
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 13 |
| Duplication | 0 |
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
Combine the related fixes from PRs petercorke#971, petercorke#972 and petercorke#973 for one MultiRotor review. Preserve each original commit as a parent and all component regressions. Retain yaw in four-value initial states, express rotor inflow in body coordinates, and size thrust and torque arrays for the configured rotor count. Validation: 69 targeted tests passed and 2 existing graphics tests were skipped; mypy passed for all 166 source files. Regression-test Ruff lint/format and git diff --check passed. The wider blocks run timed out in the existing arm FDyn repeat-run test under the Python dynamics fallback; it is not claimed as passing. Compiled/platform CI was not run locally. Co-Authored-By: ChatGPT (GPT-6 Astra Pro) <noreply@openai.com>
Integrate upstream main bceb42c without changing the contribution files. Revalidate the related regression suites and mypy against Python 3.11 configuration while retaining the existing commit history. Co-Authored-By: ChatGPT (GPT-6 Astra Pro) <noreply@openai.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Batch the related MultiRotor fixes from #971, #972 and #973 in response to the request to consolidate fixes within the same module. The original commits remain parents of the integration commit, and all component regressions are retained.
A four-value initial state currently turns requested yaw into roll; inflow combines world-frame translation with body-frame rotation; and load arrays assume four rotors even when the configured model has more. These defects change simulated accelerations or raise
IndexErrorfor supported rotor counts.Changes and numerical behavior
[x, y, z, yaw]into the existing yaw/pitch/roll state order in the constructor and parameter update path. Six-value poses and twelve-value states retain their existing layout.self.nrotors, matching the existing geometry, input validation and rotor loop.Public numerical behavior changes for short-state initialization and moving, rotated multirotors. Six- and eight-rotor models can evaluate their dynamics without the previous four-column indexing error. The existing force and moment equations are retained.
Validation
Revalidated after merging upstream
mainatbceb42c18877840280037539dac036f21d4fefe5in commitfae5e497aa400b239645aae1c952cf3e974546c7. The contribution source and regression files are unchanged by this update.Result: 69 targeted tests passed, 2 existing graphics tests skipped. Coverage includes hover initialization, heading-rotation invariance and larger rotor configurations.
An earlier wider run of
tests/test_blocks.pytimed out after 50 seconds in the existing arm testRobotBlockTest::test_fdyn_runs_twicewhile using the Python dynamics fallback. The full blocks module is not claimed as passing, and that arm test was not changed.Validation used Linux, Python 3.12.14, NumPy 2.5.5, SciPy 1.18.1 and Matplotlib 3.11.2, with the source tree on
PYTHONPATH=src. The Python kinematics/dynamics fallbacks were used. The compiled extension, other operating systems and the complete repository/platform matrix were not run locally.python -m mypypassed for all 166 source files using upstream main's Python 3.11 target.git diff --checkpassed. The regression files are unchanged from the integration revision, where Ruff lint and format checks passed.Contribution
Primary contributor: @Afloat16.
Prepared with ChatGPT (GPT-6 Astra Pro) assistance.