gz-sim icon indicating copy to clipboard operation
gz-sim copied to clipboard

Lighter Than Air Dynamics Systems

Open henrykotze opened this issue 2 years ago β€’ 7 comments

πŸŽ‰ New feature

Summary

This adds the dynamics to simulate a lighter-than-air vehicle such as blimps/airships. The modelling is based on [1] and [2]. Previously we added an airship-dynamics-plugin to Gazebo-Classic for PX4 Gazebo SITL , but we suffered simulation instability similar to that of the underwater-vehicles since Gazebo-Classic could not simulate the Added Mass dynamics.

This PR brings that airship-dynamics-plugin to Gazebo which supports the Added Mass dynamics.

Furthermore, I have extended, the Link class to provide access to the AddedMassMatrix, to allow the lighter-than-air system to easily access this matrix.

The code is somewhat based of the Hydrodynamics system.

I have an STL file which I can contribute, which is an envelope from Wind Reiter, and the coefficients in the integrations test is for this envelope model.

Citations

[1] Li, Y., & Nahon, M. (2007). Modeling and simulation of airship dynamics. Journal of Guidance, Control, and Dynamics, 30(6), 1691–1700. [2] Li, Y., Nahon, M., & Sharf, I. (2011). Airship dynamics modeling: A literature review. Progress in Aerospace Sciences, 47(3), 217–239.

Test it

I have written a small integration test to check whether the lighter-than-air system is loaded correctly and stable.

Checklist

  • [x] Signed all commits for DCO
  • [x] Added tests
  • [x] Added example and/or tutorial
  • [x] Updated documentation (as needed)
  • [ ] Updated migration guide (as needed)
  • [ ] Consider updating Python bindings (if the library has them)
  • [x] codecheck passed (See contributing)
  • [x] All tests passed (See test coverage)
  • [ ] While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by messages.

πŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”ΈπŸ”Έ

henrykotze avatar Nov 11 '23 14:11 henrykotze

Hi, I tried to get this PR as ready as possible for merging (reading the contribution docs and implementing the requirements), and have reached an unproductive state where I need some feedback to take this forward. So any comments, and or further requirements to implement would help alot.

I am still thinking of more tests to add to ensure any future additions will keep the core dynamics of LTA vehicles unchanged (except if some new modelling arises), since the system is unstable when having a velocity.

henrykotze avatar Nov 11 '23 14:11 henrykotze

Can you fix your commit sign-off. Instructions are here

arjo129 avatar Nov 20 '23 23:11 arjo129

Codecov Report

Attention: Patch coverage is 83.05085% with 30 lines in your changes are missing coverage. Please review.

Project coverage is 64.82%. Comparing base (922eea7) to head (bf74047). Report is 3 commits behind head on gz-sim7.

:exclamation: Current head bf74047 differs from pull request most recent head 3705ccd. Consider uploading reports for the commit 3705ccd to get more accurate results

Files Patch % Lines
...ighter_than_air_dynamics/LighterThanAirDynamics.cc 83.04% 29 Missing :warning:
src/Link.cc 83.33% 1 Missing :warning:
Additional details and impacted files
@@             Coverage Diff             @@
##           gz-sim7    #2241      +/-   ##
===========================================
- Coverage    64.88%   64.82%   -0.06%     
===========================================
  Files          360      358       -2     
  Lines        29448    29337     -111     
===========================================
- Hits         19108    19019      -89     
+ Misses       10340    10318      -22     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Nov 21 '23 00:11 codecov[bot]

I hope its okay that I squashed and force pushed, I didnt intent to remove the co-author commits, but rather keep the history much more clearer.

henrykotze avatar Nov 22 '23 05:11 henrykotze

I hope its okay that I squashed and force pushed, I didnt intent to remove the co-author commits, but rather keep the history much more clearer.

No worries. You have to force push for DCO so :shrug:

arjo129 avatar Nov 22 '23 06:11 arjo129

Somehow missed all the other style suggestions. Let me know if there is anything else to do here.

henrykotze avatar Nov 27 '23 14:11 henrykotze

Anything else todo here?

henrykotze avatar Dec 05 '23 05:12 henrykotze

Thanks for iterating on this PR. LGTM!

Thank you for your review and follow ups! Its much appreciated!

henrykotze avatar May 14 '24 07:05 henrykotze

Can you try merging the base branch once it seems the ABI checker is not happy.

arjo129 avatar May 14 '24 07:05 arjo129

Rebased on top of gz-sim7?

henrykotze avatar May 14 '24 07:05 henrykotze

Yep.

arjo129 avatar May 14 '24 07:05 arjo129