-
Notifications
You must be signed in to change notification settings - Fork 0
Add Bella Lui 3 DOF Flight Simulation Notebook with Comparison #3
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?
Conversation
ENH: adds 3 DOF simulation capability to rocketpy.Flight. *ENH: added "u_dot_3dof" for "solid_propulsion" mode *ENH: adding "u_dot_generalized_3dof" for "standard" mode (still incomplete) *ENH: new parameter "simulation_mode" for swtiching between 3 dof and 6 dof *ENH: updated conditions for "__init_equations_of_motion" *ENH: 2 new example files have been created to test 3 dof model "test_bella_lui_flight_sim" and "test_camoes_flight_sim"
ENH: adds 3 DOF simulation capability to rocketpy.Flight. *ENH: added "u_dot_3dof" for "solid_propulsion" mode *ENH: added "u_dot_generalized_3dof" for "standard" mode *ENH: new parameter "simulation_mode" for swtiching between 3 dof and 6 dof *ENH: updated conditions for "__init_equations_of_motion"
ENH: fixed standard 3 dof *MNT: Cleaned up the "u_dot_3dof" and "u_dot_generalized_3_dof" *MNT: Corrected Typos in "simulation_mode" description *ENH: "u_dot_generalized_3_dof" fixed and tested on examples.
…into enh/3-dof-simulation
…otor ENH: added "BaseRocket" and "PointMassRocket" to rocket class ENH: added "PointMassMotor" to motor class with various input cases of thrust values
…e tests ENH: Added a new jupyter notebook for a simplified 3 DOF example MNT: PointMassMotor intialization error fixed MNT: PointMassRocket properties enhanced based on the example runs
MNT: Cleaned up the flight class u_dot_generalized_3dof TODO: Add info for 3 dof cases and fix some new issues when parachute is added.
…cketPy into enh/3-dof-simulation
-MNT: removing the parameters not needed for point mass kind of motors -MNT: removing extra parameter thrust_curve -MNT: fixing problems with motor class inheritance
-ENH: removed 'BaseRocket' class now 'PointMassRocket' inherits directly from 'Rocket' class
-MNT: fixed calculations of mass flow rate and exhaust velocity -MNT: adjusted propellant initial mass setter error by allocating the input initial mass to the property
MNT: renaming pointmassmotor.py -MNT:snake case renaming
-MNT: incorporating latest structural changes made to PointMassMotor and PointMassRocket
-MNT: cleaned up PointMassRocket rocket.py for linters. -ENH: including PointMassMotor in motors and rocketpy __init__.py -MNT: adopting to structural changes in 3dof on the 3_DOF_TRIAL.ipynb -MNT: including pointmassmotor in settings.json as a spell word
- MNT: pointmassmotor fixing the various properties. - MNT: fixing super init and init inheritance by changing order in pointmassrocket - MNT: pointmassrocket property setter and default value fixes
- MNT: implemented identification of simulation mode based on check if point mass objects are used
- MNT: used make format to correct formatting mistakes on all the new classes.
-MNT: removing the parameters not needed for point mass kind of motors -MNT: removing extra parameter thrust_curve -MNT: fixing problems with motor class inheritance
-ENH: removed 'BaseRocket' class now 'PointMassRocket' inherits directly from 'Rocket' class
-MNT: fixed calculations of mass flow rate and exhaust velocity -MNT: adjusted propellant initial mass setter error by allocating the input initial mass to the property
MNT: renaming pointmassmotor.py -MNT:snake case renaming
…m#828) * ENH: refactor motor prints classes to inherit from _MotorPrints * STY: make format * ENH: add entry for _MotorPrints inheritance in changelog
* MNT: update code and remove deprecated functions * MNT: simplify geodesic_to_utm import and usage in Environment class * MNT: update CHANGELOG to fix deprecations and warnings * make lint * MNT: remove unused post_processed attribute from Flight class * MNT: update matplotlib version to 3.8.3 in requirements.txt * MNT: update matplotlib version to 3.10.0 in requirements.txt * MNT: downgrade matplotlib version to 3.9.0 in requirements.txt * MNT: change boxplot orientation to horizontal for compatibility with future Python versions * MNT: change boxplot orientation from horizontal to vertical for consistency
* docs: Update test docstrings to follow RocketPy style guidelines Co-authored-by: aZira371 <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: aZira371 <[email protected]>
…d comparison Co-authored-by: aZira371 <[email protected]>
|
@copilot can you run and save the newly created ipynb file so that I can see the results of all code blocks in preview on github? |
Co-authored-by: aZira371 <[email protected]>
Done! The notebook has been executed and saved with all outputs in commit |
|
@copilot The results of 3 dof in imapct x and y are wrong. That kind of discrepancy in lateral landing location indicates either: Different wind/atmospheric inputs or initial attitude between the two runs, or A limitation/bug in the current 3-DOF lateral motion modeling (e.g., how heading/angle-of-attack are mapped into horizontal motion) that does not affect the primarily vertical metrics. Please thoroughly analysis what is happening and provide a solution if possible. |
Co-authored-by: aZira371 <[email protected]>
After thorough analysis, I identified the root cause: RocketPy's 3 DOF implementation maintains the rocket's initial orientation (from launch inclination/heading) throughout flight rather than implementing weathercocking (aligning with velocity vector). This causes thrust/drag to be applied along the fixed initial direction instead of along the flight path, resulting in artificial lateral drift. What's accurate in 3 DOF: Apogee, max speed, flight duration, impact velocity (all within 1% of 6 DOF) Known limitation: Lateral coordinates (Impact X, Y) are affected by the frozen orientation assumption This is an inherent limitation of the current
|
|
@copilot in your example doc 3 dof should only implement point mass rocket and point mass motor ! |
Co-authored-by: aZira371 <[email protected]>
Updated in commit k828fj_3dof = PointMassMotor(
thrust_source="../../data/motors/aerotech/AeroTech_K828FJ.eng",
dry_mass=0.001,
propellant_initial_mass=1.373,
burn_time=2.43,
)
bella_lui_3dof = PointMassRocket(...)
bella_lui_3dof.add_motor(motor=k828fj_3dof, ...)The 6 DOF simulation continues to use the full |
Pull request type
Checklist
Current behavior
No example notebook exists demonstrating 3 DOF (point-mass) simulations or comparing them against 6 DOF simulations.
New behavior
Adds
docs/examples/bella_lui_3dof_flight_sim.ipynbdemonstrating:PointMassRocketwithPointMassMotorusing Bella Lui parameters (same as original 6 DOF notebook)RocketandSolidMotorwith aerodynamic surfaces for comparison baselineDocumented 3 DOF Lateral Motion Limitation: The notebook includes comprehensive documentation of a known limitation in RocketPy's 3 DOF implementation:
Breaking change
Additional information
jupyter nbconvert --executePointMassMotorfor 3 DOF simulation andSolidMotorfor 6 DOF simulation to properly demonstrate point-mass modelingOriginal prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.