PDA

View Full Version : The IL-2 flight engine: food for thought



michapma
08-15-2003, 03:54 PM
Edited due to funny EOL due to copy/paste, please see second post.

Sorry,
Mike

Message Edited on 08/15/0305:12PM by michapma

michapma
08-15-2003, 03:54 PM
Edited due to funny EOL due to copy/paste, please see second post.

Sorry,
Mike

Message Edited on 08/15/0305:12PM by michapma

michapma
08-15-2003, 04:12 PM
Hi all,

Over the months on these forums I have given some thought as to what goes into making the IL-2 flight model engine. A lot of it is guessing, but I hope it is educated guessing. What set my mood to write this long thread? Robi_15_JG52's and Vengeanze's discussion about "I don't understand how the FM's could be changed with EVERY patch so drastically." You can find the original discussion here:
http://forums.ubi.com/messages/message_view-topic.asp?name=us_il2sturmovik_gd&id=zaydb

I have started a new thread in order to not hijack that one any further. /i/smilies/16x16_robot-wink.gif

I'd like to preface everything that I say with the disclaimer that I am not specially informed. These are simply my thoughts, I have no special insider information or experience in aeronautical engineering or flight modeling. I have been studying electrical engineering for several years (about 10 I guess) and that is why I might know anything about modeling phenomena with programs by solving systems of equations.

It's a hard question to answer honestly given what we know. Even to really understand the answer if given directly and in total openness from Oleg and crew (and with no language barrier) I think must be quite difficult. We are not going to get a completely open answer from Oleg. There is a reason his answer usually comes in the form of, "Are you sure?" Most people who are criticizing (and often simply attacking) one or the other aspect of the flight model* either 1) do not know the data well but rather base their statements on their own understanding of what they have read, 2) have no idea of how this data can be implemented into a real-time calculation of flight performance, or 3) both. (* Flight model in this usage is a bit of a misnomer. What is meant is the performance of a specific aircraft, and not the digital mathematical model used to implement the performance.) One of your main points in this thread is that the flight models are not 100% right. Well, I think that you are right, and I think Oleg and crew can agree that even after the patch everything is not perfect. As has been said, flight sims still cannot be "meaningfully compared" to the reality. (I disagree somewhat, but that will do for now.)

So the question is not, "Why isn't everything 100% correct," but rather, "Why is this specific aspect about this specific aircraft not as correct as other specific aspects of the aircraft or of other aircraft?" Counter-arguments to that question that are often brought up are, "So much else is good and the gameplay is already excellent, you are being too picky."; and "You are no expert and have not flown the aircraft, you can't say how they should be." These are both good arguments, but might not satisfy you personally if you are really thirsty for precision. For it to really matter, not only must your knowledge and thirst be great, but your skill must also be very high. You have to consider from the game makers' point of view whether it is really worth it to tune the game to that level. 1C:Maddox already goes a great length to that end. I personally think that most of the arguments brought are either heavily skewed, out of proportion or else non-issues, and this because of the desire to see the performance of a particular aircraft changed according to what boils down to opinion. There are of course notable exceptions (to my perception), such as the rate of energy loss of FWs that has kept them from being good fighters.

Nevertheless, it's an interesting question to think about.

What I suppose is that there are so many aircraft that it is a tremendous challenge to bring each one that much closer to "right" within a given time frame, even for a team of experts, especially when we are talking months and not years. We are talking about approximating real behavior with code, after all. And we are talking about a large number of input variables (data) that have to be dug out of resources that are often inconsistent, and compared with performance results that are even more varied (Ven has pointed this out). Doing that for so many aircraft types while also making all the other changes that go into the sim requires a gargantuan, organized effort, as Ven has again pointed out, as well as Oleg on various occasions. To do it takes time and manpower, which requires money, both of which are of course in limited supply.

As I understand it, the IL-2 engine makes reduced aerodynamic calculations to produce flight-surface and torsional forces, and I have to assume that these forces move the aircraft based on its mass distribution. Reduced, because the complicated systems of differential equations that must be solved numerically for a full flight model is not feasible for PCs to calculate in real time. A good engineer must know what approximations to make. How the model changes at the edges of the flight envelope such as in the stall regime I don't know. The power output of the engine in various conditions must also be calculated correctly in conjunction with the flight model of the airframe in order for the performance to be correct. (I would assume that some effects that we see such as turbulence and buffeting are animations based on flight conditions more than they are results of force calculations. In any case they are very well done and need not be altered for what we are discussing.)

Oleg talks of tweaking and improving the flight model for this and that aircraft. I don't think he means that he is changing systems of equations, but rather altering the parameters put into the system based on that aircraft's data and how the performance matches up to what is expected. As an engineer, if I put data into a calculational model and what it gives me isn't consistent with the performance I expect to see, then I know that either the input data is wrong, the calculational model is wrong, the expected results are wrong, or some combination thereof. Remember that it is not just a question of matching up numbers here, we are talking about, it is the rather complex evaluation of the dynamic response of an object about three axes of motion, plus its acceleration curves, velocity, behavior in extremes, all the stuff that actually goes into flight performance. Most of Oleg's critics cannot even understand the performance, much less make a qualified evaluation. No wonder that most of us are content if the performance "feels right." Nevertheless, gross errors can and will be found if they get past the testing process. Back to the three possible sources of error: which could be wrong, input, model, or output? We are sure none of the three are perfect.

First I'll have a go at the mathematical model, which I might also loosely refer to as the physics engine. This is something we have no specifics on, we can only make educated guesses at how it works. First I will assume that, aside from the aforementioned animations, the model is not gotten around. What I mean is that I assume that some effects such as turbulence are not really part of the flight model in the sense that they are the direct result of calculated forces, but rather that they are animated at the right time based on flight conditions, as I mentioned already. Other than this, I assume that no tweaking of the model involves bypassing the physics engine. As an example, if a Spitfire is being modeled (chosen to be neutral since it isn't in the game yet) and no matter what the input the output does not meet expectations, let's say it rolls too slowly, I am assuming that the results are not hard-coded to make the Spit roll at the right rate. Instead, the input or model must be changed. This is an important consideration. Secondly, there are a lot of choices to be made in the model used. I mentioned earlier that an engineer must know what assumptions can be made. It is quite probable that there is no single system of equations that is used to model all of the aircraft. Simplifications that work for one wing may not work for another, same goes I think for flap types and drag. I don't know specifics but I think aeronautical engineers will back me up on this one. I imagine that different models with different simplifications and even different solvers for the system. (A solver is a numerical method used to solve a system of equations.) There are some aspects of aircraft performance in IL-2 and FB that are widely regarded as short-comings, such as linkage between the roll and yaw axes (pardon my poor terminology). I expect that these could be the result of a simplification in the model, i.e., in the choice of the detail of the model. My idea is that the equations required to properly govern that behavior would require too many calculations to be practicable, and so it was simplified and thus reduced. No matter what data is put in, the performance can't be made to reflect the reality. It's just an idea, not meant to be taken seriously but to illustrate the kinds of issues involved in the model itself aside from the input data. (This coupling is present, it is also quite possible that Oleg made the decision to reduce the magnitude of yaw effects so as to make the performance more playable as a game.)

Next let's think about the output, although I've already mentioned most of what I can say about it. This is what we see the most of: when people try to make intelligent arguments about why they think a specific aircraft is not doing something just right, say the roll rate of a given P-47 or the energy retention of one of the FW-190 types in a turn, they present historical data that they feel is relevant to their argument. Even this single aspect is so far outside the field of my (professional) knowledge that just trying to understand the arguments being presented can make me give up. I don't have a good background in aeronautical engineering or experience flying airplanes, and that's why I stay out of most flight model arguments. However, I can again emphasize the point that understanding the quality of a modeled aircraft performance is no trivial matter, and that most of us are content to either compare the aircraft to another aircraft (but not to all 100+ other aircraft) or to go by the "feel" of the performance.

The last point is the ever mysterious "input" to the system. Most people often mistake the ouput for the input. That means that if I have historically recorded data for say again the roll rate of a given P-47 type, that is not input that can be used in the flight model. It is something that the output of the flight model can be compared to (if it is deemed to actually be relevant). Input are such things as the coefficient of lift of a wing surface, the mass and its distribution, drag variables, and all kinds of other stuff that I don't know enough about, for the engine and propeller system as well as the airframe. Indeed the data is "out there" and Oleg probably has it about as well as it can be had. He surely doesn't just pull it out of a magic hat, but input parameters can be adjusted to see how they affect the output.

In fact, the input and the model have to be so chosen that the output works as expected. This must be rigourously tested, tweaked, retested and so on. Any major change to the system requires all models to have to be put through this process again. I can very well understand, for instance, that when the damage (distribution of mass, effect of damage on lift produced, etc.) and engine models (prop pitch/RPM, more complex WEP, radiator, supercharger and mixture) were significantly upgraded that their effect on the flight envelope caused some reassessments of how to model the flight characteristics. The atmospheric conditions have an effect on both the engine and flight equations, since the air density affects the model at various altitudes even if we don't include weather effects.

I hope my ideas are not too far off base.

Of course, some changes are simply a question of deciding what performance is correct, and as I and others have mentioned, this alone is a logistical nightmare. You have to factor in new sources that may be discovered, you may in fact change your mind about other sources, and you may decide to make some changes based on user feedback. This is what most of us are aware of.

This has been a bit of a serious and long post, and I hope it hasn't been too dry. However, to me the most absolutely relevant point that can be made is what Ven has pointed out in the other thread: 98% of the time the aircraft are not being flown in a historical way. Until they are, does it really matter whether they perform 100% historically correct?


There you have it,
Mike

NB: Reposted due to funny format of EOL in copy/paste.

<table width="100%" border="0" cellspacing="0" cellpadding="10"><tr valign="middle" bgcolor="#3e463b"><td height="40" colspan="3" align="center">The ongoing IL-2 User's Guide project (http://people.ee.ethz.ch/~chapman/il2guide/)</a></td></tr><tr bgcolor="#515e2f"><td width="40%">FB engine management:
Manifold Pressure sucks (http://www.avweb.com/news/columns/182081-1.html)
Those Marvelous Props (http://www.avweb.com/news/columns/182082-1.html)
Mixture Magic (http://www.avweb.com/news/columns/182084-1.html)
Putting It All Together (http://www.avweb.com/news/columns/182085-1.html)
Those Fire-Breathing Turbos (Part 1 of 6) (http://www.avweb.com/news/columns/182102-1.html)</td><td align="center">

‚ =69.GIAP=Chap‚

69.GIAP (http://www.baseclass.modulweb.dk/giap/)</p></td><td width="40%" align="right" valign="top">Hardware:
Flight Simulation Performance Analyzed (http://www.simhq.com/_air/air_062a.html)
Building a home-made throttle quadrant step by step (http://forums.ubi.com/messages/message_view-topic.asp?name=us_il2sturmovik_gd&id=zkavv)
Sound Can Be Hazardous for Games (http://www6.tomshardware.com/game/20030405/index.html)</td></tr></table>

XyZspineZyX
08-15-2003, 04:17 PM
Wow, great post 8-) . I think this really expanded my understanding of how FB works and why getting it all correct is sooo difficult. I had some similar thoughts before, but I didn't go as as far as you in collecting them and bringing them into a scheme. So, much thanks for this effort.

I highly recommend reading carefully the complete post - at least if you are the kind of guy, that likes to take part in flight model discussions!

Uffz. chamel http://www.jagdgruppe-ost.de/image/abzeichen/chamel.gif
Schwarm II - 2. Staffel / I. Gruppe EJGr.Ost
Rote 5
<a

XyZspineZyX
08-15-2003, 04:25 PM
Wow, long post.
Sorry, didn't read it.
Now, who's for co-op?

DogTailRed2

michapma
08-15-2003, 04:31 PM
LOL

<table width="100%" border="0" cellspacing="0" cellpadding="10"><tr valign="middle" bgcolor="#3e463b"><td height="40" colspan="3" align="center">The ongoing IL-2 User's Guide project (http://people.ee.ethz.ch/~chapman/il2guide/)</a></td></tr><tr bgcolor="#515e2f"><td width="40%">FB engine management:
Manifold Pressure sucks (http://www.avweb.com/news/columns/182081-1.html)
Those Marvelous Props (http://www.avweb.com/news/columns/182082-1.html)
Mixture Magic (http://www.avweb.com/news/columns/182084-1.html)
Putting It All Together (http://www.avweb.com/news/columns/182085-1.html)
Those Fire-Breathing Turbos (Part 1 of 6) (http://www.avweb.com/news/columns/182102-1.html)</td><td align="center">

‚ =69.GIAP=Chap‚

69.GIAP (http://www.baseclass.modulweb.dk/giap/)</p></td><td width="40%" align="right" valign="top">Hardware:
Flight Simulation Performance Analyzed (http://www.simhq.com/_air/air_062a.html)
Building a home-made throttle quadrant step by step (http://forums.ubi.com/messages/message_view-topic.asp?name=us_il2sturmovik_gd&id=zkavv)
Sound Can Be Hazardous for Games (http://www6.tomshardware.com/game/20030405/index.html)</td></tr></table>

XyZspineZyX
08-15-2003, 04:32 PM
That is 1 long gawddamn post ..... I bet it would be very impressive if I read it.

"We make war that we may live in peace."

Aristotle

XyZspineZyX
08-15-2003, 05:01 PM
Thanks for a very well thought out post.

As frustrating as it is to feel that some aircraft 'just aren't right', people really do need to bear in mind just how hard it is to attempt to replicate a high fidelity style flightsim on an ordinary PC, with the associated eye candy. Considering the amount of individual forces / interactions that Oleg says Il-2 is trying to simulate, things are pretty good. As you say, there have to be shortcuts, and some of these shortcuts are going to produce oddities at certain extremes of input. Professional training sims do that too. And they don't have hundreds of thousands of users attempting quite silly things in them at the edge of the envelope all day long.

There are some limitations to this approach though. Games that 'animate' forces like compressability, or read roll/climb data from a table based model, are always going to be able to simulate more effects 'by the book' than you can do by calculating them the hard way. The difference is more something that's felt than seen though - planes in Il-2 feel like a body travelling through air. Planes in most other sims [with some notable exceptions like X-Plane] just don't feel like you're in a body of mass travelling through the air. They're calculated directly from hard numbers and ratios, and they feel like it. Sure the P-47 in CFS3 rolls according to the chart, but there's little feeling of slip or inertia there as there is in IL-2.

XyZspineZyX
08-15-2003, 05:58 PM
Very good post Michampa.

Too bad Oleg didn't do something like this a long time ago, it would resolve a LOt of arguments around here.

As Clint-ruin says:

"They're calculated directly from hard numbers and ratios, and they feel like it. Sure the P-47 in CFS3 rolls according to the chart, but there's little feeling of slip or inertia there as there is in IL-2."

Good point, but I have to say that some aspect of inertia are wrong in the FB as it is now. Example: Planes loose very little energy by throttling back and maintain their speed. I have flown in (not piloted) in some prop aircraft and I can tell you first hand that that is not correct.
Planes DO glide, but loose speed and alt quite significantly, depending on the environment-a plane gliding above the forest will glide a lot longer then the one gliding above the plains, since the forest relases an air flow. That is why gliders gain alt abopve forests.
As it is now, it is extremely diffficult to land a plane, since it is quite hard to bleed of his speed/energy on approach.

And that was modelled quite more realistically before the patch. Of course it wasn't 100% perfect (nothing cannot be 100% perfect) but 1C has gone from a good "output" to a bad one, similar with the early planes (reffering to the previous topics).

So, I still cannot understand how this dramatic changes could be overlooked by the beta testers, moreover that significant number of them are real pilots?

However, I am glad that at least Oleg had the wisdom to make this an "open beta" patch and that these pionts will be corrected in the add-on.

XyZspineZyX
08-15-2003, 06:02 PM
In addition, I will speak to a friend of mine who is an active military pilot, flying the Mi-8 and Mi-24.
Through him, I will contact pilots flying the Pilatus props which, although quite different then the WW2 aircraft still must obey the same priniplec of air flight as all prop planes.
Maybe one of them would be willing to comment about it here.

XyZspineZyX
08-15-2003, 06:02 PM
Chap, are u getting your PhD in Flight Sims?



[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]

54LUT3!

"Fighter Aces don't win wars" -- el Zed

michapma
08-15-2003, 09:07 PM
No way, LZ. Not from the College of General Discussion. /i/smilies/16x16_robot-happy.gif


Robi, I am always interested in hearing from the input of real pilots who fly these or similar aircraft. There was a thread a while back that I unfortunately lost track of, in which a poster provided some feedback from a Luftwaffe veteran who flew the Me-262. The comments were very interesting. I also find it a good sign that FB can really only be compared with the real thing. I have heard a lot of praise about X-plane, I wonder how its flight model is built.

Mike

<table width="100%" border="0" cellspacing="0" cellpadding="10"><tr valign="middle" bgcolor="#3e463b"><td height="40" colspan="3" align="center">The ongoing IL-2 User's Guide project (http://people.ee.ethz.ch/~chapman/il2guide/)</a></td></tr><tr bgcolor="#515e2f"><td width="40%">FB engine management:
Manifold Pressure sucks (http://www.avweb.com/news/columns/182081-1.html)
Those Marvelous Props (http://www.avweb.com/news/columns/182082-1.html)
Mixture Magic (http://www.avweb.com/news/columns/182084-1.html)
Putting It All Together (http://www.avweb.com/news/columns/182085-1.html)
Those Fire-Breathing Turbos (Part 1 of 6) (http://www.avweb.com/news/columns/182102-1.html)</td><td align="center">

‚ =69.GIAP=Chap‚

69.GIAP (http://www.baseclass.modulweb.dk/giap/)</p></td><td width="40%" align="right" valign="top">Hardware:
Flight Simulation Performance Analyzed (http://www.simhq.com/_air/air_062a.html)
Building a home-made throttle quadrant step by step (http://forums.ubi.com/messages/message_view-topic.asp?name=us_il2sturmovik_gd&id=zkavv)
Sound Can Be Hazardous for Games (http://www6.tomshardware.com/game/20030405/index.html)</td></tr></table>

XyZspineZyX
08-15-2003, 10:41 PM
Mike, very good post. I like the point you bring up about the physics model of FB, and how historical performance numbers are useful for comparison, but not as direct input to the sim. Previous sims could have used numerical data, as you mentioned, being tab based. That the FM in FB is calculation based means that the coefficients and equations used for these calculations need to be massaged to affect FM performance. Simply plugging in a new climb rate isn't possible. That being said, I'm pleasantly surprised by the top speeds of various aircraft in 1.1b that were posted by another simmer more dedicated than me. They were all within about 5 kph of the viewer data. Argue with the viewer data if you wish, but I'm assuming this is the performance target the programmers are shooting for, and it appears their aim is very, very good. Hitting a performance target that closely by plugging numbers (often educated guesses I'm sure, given the scarcity of engineering data that has survived) into equations is some impressive programming and engineering.
I don't know much about X-plane either, but I believe it is also calculation based. It has the provision for including new aircraft into the sim, by providing that aircraft's aerodynamic parameters (I don't know to what detail.) It has been used as a test program for some homebuilt aircraft before they were actually flown, I believe.
One last dig directed at the whiners. If you're bummed that your favorite ride from 1.0 was "immasculated" by the 1.1b patch, before you question Oleg's parents' marital status, do a little reading about the plane, and not just from fanboy web sites. Pick up a few books, with dimension and performance data as well as pilot anecdotes. Read not just about your favorite, but about the planes it fought with and against. And read about some basic aerodynamic performance (there are lots of "aero for pilots" type books out there that avoid all the nasty differential equations I still have nightmares about.) Then, before you start typing "the ME-109K sux!!!" on the forums, ask yourself how that airplane really performed in combat, how it achieved that performance, and how pilots fought with it, and against it. I'm not saying that FB is 100% accurate (it never will be), but if you've done your research, you'll find that the sim is a lot more accurate than you originally gave it credit for. At the very least, if you aren't convinced, you'll have some data to back up you position, which may help improve the sim, and will keep you from sounding like such a whiner.

Blotto

"Only the spirit of attack, born in a brave heart, will bring success to any fighter craft, no matter how technically advanced." - A. Galland

"Look, do you want the jets, or would you rather I slap the props back on?" - W. Messerschmitt