-
Notifications
You must be signed in to change notification settings - Fork 811
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
Pr liftdrag coefficients #690
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.
Thanks for the contribution!
Would it be possible to have an example of a model that fully utilizes all the newly defined parameters you defined? A good model for this would be the plane
or techpod
this->cmaStall * (this->alpha + this->alphaStall)) | ||
* cosSweepAngle; | ||
cm = this->cm_alpha0 - this->cma * this->alphaStall + | ||
this->cmaStall * (this->alpha + this->alphaStall); | ||
// make sure cm is still less than 0 | ||
cm = std::min(0.0, cm); |
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.
Does this assumption still hold with the defined cm_alpha0
?
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.
Previously, cm behavior was symmetric around zero, while now we start at cm_alpha0. Given the simplified aerodynamics we use in this plugin, assuming now it is symmetric around cm_alpha0 makes sense. I'll add this to the pull request.
Note that for current simulation models, it doesn't matter, since those all set cm to 0 under all conditions.
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.
In fact, what I can find indicates that past stall, cm is typically more negative than cm_alpha0 (positive angle of attack), e.g. this. I'll improve on this too.
I added 3 commits to the pull request that address the feedback about Cm, a bug that slipped in and a docstring that was not up to date (the documentation of Gazebo 9 and later clarify that link.AddForceAtRelativePosition works relative to the CoG of the base link, not the origin). I haven't found the time yet to create or improve an example simulation model. |
@pjdewitte Please do, otherwise we have no way to test the newly introduced parameters |
@pjdewitte Would it be possible to share a timeline when you could add it to the models? It would be great that we could verify this PR by adding it to the models |
I should have thought about a testcase from the start. I'll adjust one of the models by the end of this week (24/01/2021). |
Flight log with plane model, using the committed new parameters: link |
@sfuhrer @RomanBapst FYI |
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.
Looks good!
Thanks for the contribution! This would improve a lot of the flight dynamics performance for fixed-wing / VTOL models
@pjdewitte Have you ever tested this with the techpod? It doesn't seem to be able to takeoff anymore |
This reverts commit 38224fb.
* liftdrag_plugin code cleanup * Add cd_alpha0, cm_alpha0 and cd_delta * Remove sweep correction: already covered by velocity in Lift-Drag plane * Deprecate controlJointRadToCL and a0 * Rename deprecated XML tags * Make cm post-stall behavior symmetric around cm_alpha0 * Fix: post-stall drag (pitch-down stall) not properly accounted for * Correct docstring of cp * Plane: rename elevon to aileron, to align with mixer file. Give elements unique name. * Plane: use new aero parameters Co-authored-by: Pieter-Jan Dewitte <pieterjan.dewitte@atmosuav.com>
This pull request adresses 1, 2, 3 and 5 from #684