Board index FlightGear Development Aircraft Flight dynamics model

Using VSPAero to build a full FDM

Good sims require good FDMs (the "thing" that makes an aircraft behave like an aircraft).

Using VSPAero to build a full FDM

Postby Richard » Tue Oct 25, 2016 9:47 pm

We seem to be moving through the available methods of computational aerodynamics at quite a pace recently with this, and the work that Victor has been done.

After a fair amount of investigation into the available methods I've settled upon using OpenVSP - which has both a geometrical vehicle modeller, a vortex lattice method solver and (since 3.9.1) a flat panel solver. My results are from the VLM solver.

OpenVSP is really powerful, and there is a lot to understand about how to drive it. The geometrical approach is well suited, and fits well with VSPAero. I started off modelling by trying to get something that was close to the real thing, but now I'm modelling to what works well with VSPAero (i.e. the degenerate geometry).

The approach taken to validate OpenVSP was to build an F-15 aero model and compare that against the wind tunnel data, and to see how close I can get it. This worked reasonable well, although some data is a little different, but probably ok.

After the F-15 I've built a BAe Hawk T2 model which flys quite nicely, but isn't finished.

More recently there is the Beagle Pup project. This is intended to be a comparitive exercise with Simon "bomber"'s Pup model - to see which approach produces the best results.

I've written up my findings (based around the Beagle Pup) in an article on my site http://chateau-logic.com/content/using- ... flightgear

The Beagle Pup took nearly 40hours of CPU at 100% to run, however it seems to fly quite nicely[1]

The FlightGear model can be downloaded from the page listed above, as can the aerodata plots.

I would appreciate testing and feedback

------------------------------------

[1] Usual disclaimer applies; in that I've never flown one in real life so it might turn out to be quite unrealistic.

Image
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Re: Using VSPAero to build a full FDM

Postby Hooray » Tue Oct 25, 2016 9:51 pm

You may want to add this to the newsletter, which will surely make even more peope aware of your work.
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: Using VSPAero to build a full FDM

Postby Richard » Fri Nov 11, 2016 3:35 am

I've just released beta-3 of my Beagle Pup aerodynamics model http://chateau-logic.com/sites/default/ ... 6-11-11.7z

Fixed (or improved) flight handling.

* Elevator response, Pitch moment and stability; it may still be a bit twitchy
* Sideslip due to roll
* Subtle changes to the geometry to reach better stability.
* Removed propeller aerodynamic effects and damage effects - I can put these back in later but they need more work to be useful.

To take off - throttle up whilst controlling the gyroscopic prop effects with the rudder. With no flaps smoothly rotate at 65kts keeping the yaw and roll under control. If you lose control of the yaw then you'll get excessive sideslip which in turn destroys the lift, generates roll and results in an undesired ground interaction. With 38% (one notch) of flaps you should be able to rotate slightly earlier, but the climb out will be slower and you'll need to be careful with the power and not to stall.

Landing I tend to come in at 50-60 kts with one notch of flaps, possibly two notches. Depending on weight you'll stall at around 45 kts.

With my model you do need to keep a watch on the yaw and rudder will be required to control this. I think this is like the aircraft based on comments that I've read - and this is coming out of the aerodynamics - it's not something that I've added.

At this stage let's keep the testing to take off and circuits - to provide comparative results use Fair weather.

Statistics: Posted by Richard — Fri Nov 11, 2016 2:12 am
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Re: Using VSPAero to build a full FDM

Postby Richard » Tue Nov 15, 2016 11:36 pm

Just released another version of this FDM after some feedback and more indepth testing.

To summarise - for all surfaces I've double checked and fixed the geometry (positions), the aerofoils (the wing root was not identical to the tip) and the horizontal tail is still a matter of research to figure out what it is. Also changes is the wing dihedral and. Lots of work on the mass/balance resulting in a 25% MAC Aero reference point and less extreme pitching moments. Also the moments of inertia have been tuned on the basis of what feels right (and therefore these moments of inertia are almost certainly wrong, but they were wrong anyway and this is hopefully less wrong now).

I've tuned and adjusted Cl, Cd and AOA to get closer to Nick Lawson's AIAA paper - but I'm still a way off matching the figures (and I'm not sure why that is). In the interim I've added a fixed amount of 0.012319 to Cd to account for the missing drag - but this is a very blunt method and needs refining.

Uploaded a new release to my site: http://chateau-logic.com/sites/default/ ... 6-11-15.7z

From my flight testing (of my own model, which is never reliable) it seems still to be too performant even with the revised drag, but more worryingly I can get into quite a strange situation with an excessive amount of sideslip in turns and/or high pitch. I think my aero is still a bit twitchy in the pitch control - but at the moment I'm at a loss as to why.

Given that the point of this experiment was to investigate the possibility of putting together an aero model with little information; at this point I wonder if the airframe chosen actually has far to little basic data to be modelled accurately. I've spent hours reading through search results (ignoring lots of canine pages) to try to get a definitive set of measurements.

The best I've found thus far is probably http://www.pilotfriend.com/aircraft%20p ... %20100.htm - together with some old newsletters from Beagle and old articles from Flight Magazine to fill in the details.
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Re: Using VSPAero to build a full FDM

Postby sanhozay » Wed Nov 16, 2016 12:17 am

Richard wrote in Tue Nov 15, 2016 11:36 pm:I've spent hours reading through search results (ignoring lots of canine pages)

If I see another one of these, I think I'll explode: ;)

Image

Did you get all the numbers from here?

http://www.bobthebeagle.co.uk/specifications/

The 150 is the same airframe, just a couple of inches longer on the engine cowl. A different engine and prop of course.
sanhozay
 
Posts: 1207
Joined: Thu Dec 26, 2013 12:57 pm
Location: EGNM
Callsign: G-SHOZ
Version: Git
OS: Ubuntu 16.04

Re: Using VSPAero to build a full FDM

Postby wlbragg » Wed Nov 16, 2016 1:37 am

I decided to participate and installed the the Pup in fgaddon and then included the most current fdm update pointed to from this thread. What I ended up with is tp Pup line items. The first is is a three variant (100, 150 and 160) and the second is the VSP.

First, does this sound like the correct setup for testing?

Second, does it matter which variant the VSP is tested against?

Results of testing the 160 against the VSP.
Very similar feel. The 160 felt more realistic in controllability. The VSP pitch was funky. Both seemed too easy to lose the flight envelope. Vertical stall was too easy to achieve in both versions.

If there is any specifics you are looking for, please indicate what your looking for and I'll do my best to provide it.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7588
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Using VSPAero to build a full FDM

Postby Richard » Wed Nov 16, 2016 1:56 am

There is also Simon "bomber" Morley's pup - to test; I'll get a link to it.

What I would like testing is the VSP - compared against the other, and any other similar model. The idea of this experiment is to see if a valid, complex, aero model can be created using VSPAERO, or by Simon's method.

The pitch is a bit twitchy; I just made a test file that decreases the pitch due to elevator to 33% of what it was in the computed model. This file is here http://chateau-logic.com/sites/default/ ... up-vsp.xml - just drop it in.

If it turns out to be too much elevator authority then I can investigate that; so give the revised FDM a test.

Testing of the flight model up to and beyond the normal flight envelope; what I'm looking for is general, or detailed comments, flight traces, etc.

1. Taxi and takeoff, with 0 flaps, and takeoff flaps.
2. Cruise performance.
3. Turning, sideslip during turning, overall controllability
4. Landing 0 flaps, 38 flaps, full flaps (watch the pitch moment when flaps are deployed).

Any tests that produce strange results - send me the flightrecorder file. You can turn on JSBSim logging (end of the FDM file - by changing the path to somewhere valid and writable).

All of coefficients in the FDM have come out of VSPAERO; there's little other data apart from geometry and airfoils that go in. If we can make this work then it might be a new future for realistic flight modelling.

Appreciate any testing that is done.
Last edited by Richard on Wed Nov 16, 2016 10:15 pm, edited 1 time in total.
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Re: Using VSPAero to build a full FDM

Postby wlbragg » Wed Nov 16, 2016 3:12 am

Richard wrote in Wed Nov 16, 2016 1:56 am:If it turns out to be too much elevator authority then I can investigate that; so give the revised FDM a test.

Maybe a little better. It doesn't seem to be too much authority, it is more like too little authority on the opposite side. When you make a pitch change it wants to continue in the direction of the pitch and you need to over compensate to get control again. That leads to a vicious cycle that I pretty much always end up loosing. I cant make an approach and flaps seem magnify it.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7588
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Using VSPAero to build a full FDM

Postby sanhozay » Wed Nov 16, 2016 8:06 am

wlbragg wrote in Wed Nov 16, 2016 1:37 am:Second, does it matter which variant the VSP is tested against

Richard's FDM and Bomber's FDM are using Bomber's engine and prop for the Pup 100, so to compare eggs with eggs, you should fly the Pup 100 from FGADDON.
sanhozay
 
Posts: 1207
Joined: Thu Dec 26, 2013 12:57 pm
Location: EGNM
Callsign: G-SHOZ
Version: Git
OS: Ubuntu 16.04

Re: Using VSPAero to build a full FDM

Postby Alant » Wed Nov 16, 2016 10:16 am

Prof Lawson has published several papers about his CFD work on the Bulldog in the RAes Aeronautical Journal. I no longer have access as I stopped paying my RAeS subs when I retired. Perhaps you can access them. He is also a Bulldog instructor/pilot. You could try contacting him at Cranfield.
From his CV I see that he teaches in-flight measurement of aircraft performance and handling. They must have a lot data there.
Alant
 
Posts: 1219
Joined: Wed Jun 23, 2010 6:58 am
Location: Portugal
Callsign: Tarnish99
Version: latest Git
OS: Windows 10/11

Re: Using VSPAero to build a full FDM

Postby Richard » Wed Nov 16, 2016 10:19 pm

Alan - I've already been in contact with him a very nice and helpful chap.

Based on feedback from Wayne and Vincent I've been tuning the inertias and also the CoG and control surface moments - this is to see if I can get a model that we think flies correctly and then figure out if it's right or not.

The moments of inertia that VSPAERO calculates should be more accurate; except that I don't understand what it is doing which makes it difficult. More research for me in this area. Also the control surface moments could well be wrong based on how VSPAERO calculates them (by deflecting the normals on the affected segments of the degenerate geometry).

Revised FDM is here if anyone's got time to test it. http://chateau-logic.com/sites/default/ ... -11-16.zip
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Re: Using VSPAero to build a full FDM

Postby wlbragg » Wed Nov 16, 2016 11:19 pm

Latest revision may be a little better. I think I have a better description of what I feel is going on. I think everything is exaggerated
1) The flight envelope is really tight, especially in the pitch. Yaw seems better but can be exaggerated under certain conditions.
2) Flaps cause excessive lift, may cause excessive drag. I can only deploy flaps at an exaggerated speed or it stalls even with the increased lift. If you deploy them with full thrust then you get the exaggerated lift.
3) Elevator causes exaggerated pitch change even though it appears to be normalized (for lack of a better term) to the control device. In other words really loose in action but not in ability to control. Slow to react but only on when trying to come back to the center.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7588
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Using VSPAero to build a full FDM

Postby Richard » Sat Nov 26, 2016 1:03 am

After another 10 days of development I think I've finally got to the root of my stability problems; it appears that most of the problems with the uncontrollable response were being caused by a combination of factors, but mainly that the stability derivatives side force due to yaw (CFYR) , Yaw moment due to roll (CMNP), and pitch moment due to pitch (CMMQ) had the wrong sign, along with Yaw due to Aileron (CMNDAD).

Also I've spent a good few evenings understand how OpenVSP mass properties work (I've explained this with changes to my original VSP Aero article, but basically I had to adjust the density of each component of the OpenVSP model to result in a mass in slugs that was correct, and then the calculated moments of inertia were much better (my original MOI were 3000,14000,16000 and the new ones are 549, 636, 1145 (Ixx,Iyy,Izz).

Beta 5 of my VSPAERO generated Beagle Pup flight model

Things that I know are probably still wrong

* flaps (in terms of lift and moments)
* Wing incidence I'm pretty sure should be 2.5 degrees, however what I'm not sure about is the relationship between the alpha of the fuselage and the wing, and how this relates to the alpha that comes from VSP. So for now I've adjusted the tail incidence by -1.90 degrees (leading edge down) to get the right sort of pitching moment (CMM1)
* AERORP (or Centre of Gravity used for calculation). I'm using 6.8, 0, 0. I haven't found much in the way of data that tells me where this should be, except for an excerpt from the Beagle magazine that states that the aft CoG limit is 27.5 SMC, which is helpful as that comes out at 6.83; but I'm still not 100% sure that my wing root is in the right place. So more tuning may be required here.
* I'm not even totally certain where z=0 is on the fuselage- I'm assuming the centre of the propeller; but that could be wrong. So the Z axis CoG may well still be wrong.
* I figured ou the wing dihedral based on photographs - so this may also be wrong. Other values seem worse.

Overall I'm much happier with Beta5 - I can reposition in air at 10k feet, with 0 kts, and it will eventually come to a stable nose down glide (of about 7 degrees). I've also tested lots strange orientations and stalls to ensure that the craft has the expected positive stability and no matter what I do to it I can't get the FDM to become numerically unstable - all of the preceding improvements make me believe that this is good progress.

As always feedback and testing is appreciated.
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Re: Using VSPAero to build a full FDM

Postby wlbragg » Sat Nov 26, 2016 6:53 am

The flight envelope is really small, especially pitch up and stalling. But, within the envelope, it feels really sweet. Once I got used to the sensitivity of the controls, the feel of the FDM was actually some of the best I think I have ever felt. Funny how even though you can loose it and fall out of the sky quite easily, when you are in control it feels really good. I'm was impressed!

I was able to get full flaps and a reasonable glide slope all the way down to idle, but again the sensitivity of the controls made it hard to flare without stalling (only using a mouse for control). When I was able to keep control of the pitch to remain in the envelope, it behaved realistically in my opinion.
Kansas and Ohio/Midwest scenery development.
KEQA, 3AU, KRCP Airport Layout
Intel i7/GeForce RTX 2070/Max-Q
User avatar
wlbragg
 
Posts: 7588
Joined: Sun Aug 26, 2012 12:31 am
Location: Kansas (Tornado Alley), USA
Callsign: WC2020
Version: next
OS: Win10/Linux/RTX 2070

Re: Using VSPAero to build a full FDM

Postby Richard » Wed Nov 30, 2016 1:04 am

Thanks for the testing and the feedback. After a bit of investigation over the weekend I think I'm getting to a more consistent geometric model.

I've had to go back to basics to work out where my aero reference point should be; as this is something that is usually stated. My first versions used the CG calculation feature of OpenVSP, but instinctively this seemed to place the CG to far aft for a propeller plane.

So I've had to pull out the textbooks and work out how the aero reference should be calculated. The figure of 25% MAC is quite commonly used, except that I could not find any manufacturer documentation that details the mean aerodynamic chord for the Beagle Pup. Beagle however do mention in their documentation that the aft CG limit is 27.5% SMC; which is good as SMC is easily calculated and this gives me an aft limit of

So my first step in finding out what AERORP should be was to calculate MAC. I've always understood MAC to be the chord at the wing average center - the following diagram illustrates this

Image

Along with this there is a formula that I found in this paper http://www.dept.aoe.vt.edu/~lutze/AOE31 ... lwings.pdf

* rc = Root Chord
* t = Taper Ratio = (Tip Chord ÷ Root Chord)
* MAC = rc x 2/3 x (( 1 + t + t*t ) ÷ ( 1 + t ))

I'm not completely certain I've got the right figures for any of the above (apart from some probably inaccurate measuring of the only crude line drawings that I coud find); however the resulting MAC this formula gives is 6.96.

The next part based on the above paper is to find the X location of the aerorp where the wing pitching moment is constant throughout all angles of attack. VSPAero makes it easy to do this, and after only a couple of hours I ended up with an aero reference point of (7.257, 0, -0.288). This new aero reference point gives a much better and less extreme CM basic for the entire airframe.

Together with this I've revised the moments of interia. These are calculated by OpenVSP as 618, 1092, 1277, 18 - however I'm still not convinced that these fly right, the controls seem very underdamped, I've adjusted the kinematic rates on the surfaces to see if that helps but it doesn't, so I've manually tuned these to 1235, 2183, 2553,37 which feels more like an aircraft - I don't like this sort of tuning as it's very easy to tune to the pilot preconceptions - much preferring an analytical approach - however I think I need more detailed information about the mass distribution on the aircraft to get the right sort of results out of OpenVSP. I'm certain that given the right input.

The rest of the geometry has been aligned again to match my measured photograph, it looks close, but this doesn't take into account any possible optical distortions.

Image

Revised FDM (Beta 5) is available here: http://chateau-logic.com/sites/default/ ... 6-11-30.7z - I would appreciate testing and feeback on the model or on anything that is wrong in my approach.
Last edited by Richard on Wed Nov 30, 2016 6:37 am, edited 1 time in total.
Richard
 
Posts: 810
Joined: Sun Nov 02, 2014 11:17 pm
Version: Git
OS: Win10

Next

Return to Flight dynamics model

Who is online

Users browsing this forum: No registered users and 1 guest