Jump to content

Small Change in Jet Engine Behaviour - Big Leap for Kerbalkind!


Recommended Posts

While working on my documentation about space planes in KSP and testing VTOL's I came upon something in the simulation of jet engines which is really bad in terms of flying VTOL's. It would be easy to change, yet not changing the overall behaviour of jet engines.

Some definitions for the coming formulas:

ST = Set Thrust (current thrust input set by user and shown on gauge)

CT = Current Thrust (current engines thrust value)

TL = Thrust Limiter Factor (current thrust limiter setting 0.0-1.0)

TF = Time Factor (constant depending on how long thrust changes are supposed to take and the simulation cycle duration)

MTC = Max Thrust Delta per Simulation Cycle

My guess is that the formula for CT changes per simulation cycle currently is as follows:

CT = CT + (ST*TL-CT)/TF

This causes big changes in thrust setting to take as long as small changes because it takes always the same amount of cycles regardless of the value of change in thrust (actually never gets to finish the change). To reproduce that just launch a jet engine, right click and watch what happens and how long it takes until thrust value is stable after a small or big change of thrust. Keep in mind that especially for small changes the change in thrust at the end is not visible due to 1 digit precision in thrust value when looking at the engines right-click window. This is ok for normal jet operation since tiny changes in speed don't really matter that much.

It's realistic that jet engines take a long time to get from idle RPM to max RPM and this is what the algorithm is supposed to simulate. But small changes should be much quicker and more accurate. Also a thrust limited jet engine should react much quicker. So the thrust delta should be calculated depending on an engine specific RPM/s (delta RPM per second) value.

A better and more realistic algorithm would therefore look like this:

CT = CT + (Sgn(ST*TL-CT)*Min(Abs(ST*TL-CT),MTC)))/TF

It simply makes acceleration linear using a max thrust delta per cycle to limit changes so that small changes are executed quickly and big changes take their time as usual. Also heavily thrust limited engines like the one in the Kopter example would INTENTIONALLY react a lot quicker which would make it a lot easier to fly the VTOL only models while the overall performance of jet engines would stay the same with their slow response to major input.

ex_ssx_kopter_v_1_05_02.jpg

http://www.docmoriarty.com/ksp/mods/ssx_kopter_v_1_06.craft

And without a fix it's practically impossible to fly a model like the Dragonfly precise enough to actually pick something up with the claw.

ex_ssx_dragonfly_v_1_01_01.jpg

http://www.docmoriarty.com/ksp/mods/ssx_dragonfly_v_1_01.craft

Link to comment
Share on other sites

Of course the real formula is likely more complex as it must take framerate into account. But that's not too important.

I guess this assumes drastical reduction of the TF constant, otherwise it would slow down large changes and leave small changes as they were. Apart of that, I think it would be useful. Today when I need a VTOL to increase thrust fast by small amount, I need to "overshoot" the throttle, then return it to desired position. It works somehow but it's very imprecise.

Link to comment
Share on other sites

You could also try clipping little rocket motors into the jets (they don't have to be clipped). Then map the intake cutoff to an action group. that will instantly cut the jets thrust.

Then action group the rockets to a separate key and use both. After some practice they complement each other perfectly.

Watch any 'Cupcake landers' videos. That's what he uses.

Link to comment
Share on other sites

So much for so few, air breathing/jet engines use:

engineAccelerationSpeed = 0.30

engineDecelerationSpeed = 0.50

(here is values for my own mk2 engine which is very slow to respond to throttle on purpose)

stock basic jet engine values are:

engineAccelerationSpeed = 0.12

engineDecelerationSpeed = 0.21

It really makes an engine to be slow or not, easier than your formula.

Feel free to change the part's values to whatever suits your needs, and even create a "VTOL trainer" jet engine, with very small values, just to get a rocket type jet engine.

Link to comment
Share on other sites

Sure i can mod just about anything and could even write a mod that moves my VTOL and anything else by pure magic with unimaginable awesome graphical effects!

This post though is to show that with a little change in stock KSP it would improve the VTOL experience a lot without changing the overall performance of jet engines.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...