Orbiter-Forum [SDK Question] Control Surface Moments
 User Name Remember Me? Password
 Register Blogs Orbinauts List Social Groups FAQ Projects Mark Forums Read

 Orbiter SDK Orbiter software developers post your questions and answers about the SDK, the API interface, LUA, meshing, etc.

 02-02-2020, 05:29 PM #1 markl316 XR2 Ravenstar Commander Control Surface Moments Hi all, I'm working on an atmospheric autopilot, and I need to be able to somewhat accurately predict the induced moments on a vessel from control surface deflections so I can tune the autopilot. I'm working with the as-included Delta Glider. For sum of forces and moments with no control surface inputs, I'm able to predict the lift, drag, and moment in the vessel body frame with pretty good accuracy. The problem arises when I try to predict the moments from control surface inputs. I would think that the moment from, say, an elevator deflection would be (in the Orbiter left-handed coordinate frame): M = F x R Above, the magnitude of F is (qinf * elevatorArea * cLFull * elevatorPos), per the SDK documentation. For the Delta Glider, this would be (qinf * 1.4 * 1.7 * elevatorPos), from DeltaGlider.cpp line 1026, where elevatorPos is between -1 and 1. The direction of the for F for our elevator example is presumably <0,cos(aoa),sin(aoa)>, such that the elevator lift force acts perpendicular to the freestream (same direction as the lift vector). The vector R is the moment arm for the elevator, <0,0,-7.2> for the Delta Glider, from DeltaGlider.cpp line 1026. However, my calculations aren't matching up what Orbiter is returning for the pitching moment. The mismatch seems to be exacerbated with elevator deflections at higher angles of attack (and rudder deflections at higher sideslip angles), which has me thinking I have the force vector direction wrong. Even at high angles of attack and sideslip, when all control surfaces are at zero, my calculations match what Orbiter returns, so I'm confident my issue has to do with how I'm calculating moment from the control surfaces. The above control surface moment equation & calculation method works quite well for predicting the roll moment from aileron deflections, but it's pitch and yaw that I'm having trouble matching up. Any ideas here would be much appreciated. Last edited by markl316; 02-02-2020 at 07:34 PM.
 02-03-2020, 09:39 AM #2 asbjos tuanibrO Have you taken the pitching moment from the airfoil into account? Remember that it's only non-zero in the vertical lift function. Other than that, it's possibly something with your vectors and their rotations. But that is difficult to diagnose without some source code.
 02-03-2020, 11:47 AM #3 Thorsten Orbinaut Quote: The mismatch seems to be exacerbated with elevator deflections at higher angles of attack (and rudder deflections at higher sideslip angles), which has me thinking I have the force vector direction wrong. Are you by any chance mixing a lift/drag with an axial/normal force coordinate system? They would agree at zero AoA and be quite different at high AoA. Just a wild stab...
 02-03-2020, 02:29 PM #4 markl316 XR2 Ravenstar Commander Thanks for the quick responses guys! Quote: Originally Posted by asbjos  Have you taken the pitching moment from the airfoil into account? Remember that it's only non-zero in the vertical lift function. Yes I have: I'm doing M = qinf * S * c * cM, where S is the wing area (90 m^2 for the DG), and c is the chord (5 meters for the DG). Quote: Originally Posted by Thorsten  Are you by any chance mixing a lift/drag with an axial/normal force coordinate system? They would agree at zero AoA and be quite different at high AoA. I am taking this effect into account; I have all of my aerodynamic forces acting perpendicular/parallel to the freestream, which is only parallel to the Z body axis at zero AOA and sideslip. However, late last night, I did have a breakthrough with my pitch/elevator test case. Apparently, in addition to the vertical (lift) force provided by the elevators, the Orbiter aerodynamic model applies a horizontal (drag) force for the control surface as well, equal to [qinf * S_elevator * elevatorPos], where S_elevator is the elevator (1.4 m^2). I'll post some plots tonight. Quote: Originally Posted by asbjos  But that is difficult to diagnose without some source code. Once I get yaw/roll nailed down I'm happy to post my code, though it's in MATLAB. Last edited by markl316; 02-04-2020 at 01:44 AM.
 Thanked by:

 Thread Tools

 Posting Rules BB code is On Smilies are On [IMG] code is On HTML code is Off You may not post new threads You may not post replies You may not post attachments You may not edit your posts
 Forum Jump User Control Panel Private Messages Subscriptions Who's Online Search Forums Forums Home Orbiter-Forum.com     Announcements     Meets & Greets Orbiter Space Flight Simulator     Orbiter Web Forum         OFMM         Orbiter Forum Space Station         Simpit Forum     General Questions & Help     MFD Questions & Help     Hardware & Software Help     Tutorials & Challenges     Orbiter SDK     Orbiter Visualization Project     Orbiter Beta » Orbiter Project Orbiter Addons     OrbitHangar Addons & Comments     Addons     Addon Development     Addon Requests     Addon Support & Bugs         Addon Developer Forums             Project Apollo - NASSP     Orbiter Lua Scripting Far Side of the Moon     Spaceflight News     Math & Physics     Astronomy & the Night Sky     Backyard Rocketry     Brighton Lounge     International Forum

All times are GMT. The time now is 08:44 AM.

About Us | Rules & Guidelines | TOS Policy | Privacy Policy

Orbiter-Forum is hosted at Orbithangar.com
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright ©2007 - 2017, Orbiter-Forum.com. All rights reserved.