Jump to content

Converting ISP and thrust into fuel consumption


kahlzun

Recommended Posts

Hi guys, I've been trying to work out some of the math behind KSP (and rockets in general I guess) and I've gotten stuck on something:

Given an ISP and a thrust value, how does the game calculate fuel consumption?

As the fuel consumption is static independent of those two values, clearly they interact, however Google, Wikipedia, and Wolfram|Alpha have failed me, I throw myself upon your mercy!

Any ideas?

Link to comment
Share on other sites

ISP is a measure of the engine's efficiency. Completely forget you EVER read the word "fuel consumption" in KSP. It's irrelevant and that's why it was replaced. Specific Impulse is what you need to know fuel usage.

It's basically the amount of thrust expended per unit of fuel -- depending on the units you're using. Sometimes it's in seconds, sometimes it's written in meters per second -- in KSP, it's seconds. Look up the Tsiolkovsky Rocket Equation to get an idea of

how to use specific impulse.

Link to comment
Share on other sites

What I mean is:

If you have a NERVA, running in vacuum at full throttle, it will ALWAYS

A: provide 60kN thrust

B: Have an ISP of 800

C: 'use' 1.5L/s fuel.

No matter how hot the rocket gets, or if it's trying to push 200T, or if its landing on an (atmosphere-free) planet, as long as 2 of the 3 above are provided, the third will also be true.

Logically, this means there is some mathmatical relationship between

1.5L/s, 60000N, 800(s) Isp

which I am unable to deduce.

I understand that coding-wise, Isp has replaced FuelConsumption, but I am trying to figure out the logic thereof.

Link to comment
Share on other sites

Isp is a difficult unit to visualize, because it doesn't have a very obvious physical significance. I did find a very nice explanation on wikipedia though:

This Isp in seconds value is somewhat physically meaningful—if an engine's thrust could be adjusted to equal the initial weight of its propellant (measured at one standard gravity), then Isp is the duration the propellant would last

That's the most intuitive explanation of what Isp actually means I've seen so far. :)

Cheers

Link to comment
Share on other sites

As far as I know, the original definition of the specific impulse is the velocity of the exhaust, given in m/s. Think about firing a gun: the higher the velocity of the bullet, the higher the recoil, or, in our case, the thrust you get out of a given mass of fuel.

Now, Americans don't like metric units, so in order to make the specific impulse globally comparable, the rocket scientists did something arbitrary: They divided the specific impulse by the gravitational acceleration g, and got a specific impulse that is now measured in seconds (for which one can also come up with some physical meaning as Harvester showed above). Of course, this only makes sense at the Earth's surface, because g is not a universal constant. But they don't care, they always divide by g, no matter if the rocket is on the Earth's surface or somewhere in outer space.

Now, assuming that the Kerbals have made the same choice to scale with g as we here on Earth, we can extract the density of their fuel from the equation stated by Tamerlane:

Thrust = (fuel rate in kg/s) * g * Isp

which we can convert to

Thrust = (fuel rate in L/s) * density * g * Isp

or

density = Thrust / ((fuel rate in L/s) * g * Isp) = 60,000N / ( 1.5L/s * 10m/s^2 * 800s ) = 60,000kg*m/s^2 / ( 1.5L/s * 10m/s^2 * 800s )

= 5 kg/L

which is five times the density of water. That's a lot, but given the huge density of Kerbin itself, I have no trouble believing that they're able to find some very dense combustibles on their planet.

edit: Would be interesting to check if this is consistent with the rest of the game - firstly of course, the other engines (which it should if ISP is supposed to be meaningful), but also densities taken from the specifications of the fuel tanks. Also, what about SRB's?

Edited by jebbe
Link to comment
Share on other sites

g is a constant, if an arbitrary one. It's the defined Standard Accelleration due to Earth Gravity, which is close, but not the same as the accelleration due to gravity that you would feel at a point on the Earth's Surface.

"Impulse" is a change in momentum. In the SI system, momentum is measured in kilograms*meters/second (or, since a Newton is a kilogram*meter/second, it can also be measured in the equivalent units of Newton * second).

"Specific", in this context means "Per unit of [quantity]". In the case of Specific impulse, there are two common ways to look at it.

1. "Impulse imparted by the engine on the rest of the ship per unit mass of fuel.", also known as Specific Impulse by Fuel Mass. When you do that calculation with SI values, you're dividing kilograms*meters/second by units of kilograms, for units of (kg * m / s)/ (kg) = meters/second. This value is also known as the Effective Exhaust Velocity; If all the exhaust had the same velocity, it's the velocity the exhaust would have to leave the rocket with to satisfy Conservation of Momentum.

2. "Impulse imparted by the engine on the rest of the ship per unit of fuel weight measured under a standard Earth Gravity", also known as Specific Impulse by Fuel weight. That's where the 9.81 m/s^2 comes from. The amount of fuel denoted a specific weight when measured under a standard gravity that doesn't change, regardless of where you're doing the burning be it on an alien planet or in interstellar space.

Do the calculation in SI units, and you're dividing Newtons * second by Newtons to get a value in seconds. Furthermore, if you're measuring force and weight in pounds or short tons instead of Newtons, you still get a value in seconds, and it's the same value of seconds. So if you're selling your rockets to clients who use SI or the Imperial system, you can tell them how efficient your rockets are using the same statistic.

When the value is reported in seconds, it means "The amount of time for which the amount of fuel that weighs 1 Newton (or pound or short ton or whatever) under a standard gravity can be used by this engine design to produce 1 Newton(or pound, or short ton, or whatever) of thrust."

Link to comment
Share on other sites

To calculate the fuel consumption in tons, use this formula:

fuel consumption(ton/s) = Thrust/10 SI

That's the thrust of the engine divided by ten times the specific impulse. This will give you a number in tons per second of fuel used. There is 200 fuel units per ton I believe and assuming a "unit" is a liter, you can use:

fuel consumption(L/s) = 20L*Thrust/SI

to get the useage in L/s. It works out with your example of the NERVA engine. The thrust number is the number you see in game, so 200 or 300 or 60 or whatever.

Link to comment
Share on other sites

Fuel consumption (L/s) = ( thrust (kN) / Isp ) * 20,4

where 20,4 is somekind of conversion factor for KSP

Yep, that sounds right: The 20.4 is basically 1000 / ( g * fuel_density ). The 1000 comes in because you are using kN instead of N.

Link to comment
Share on other sites

Yep, that sounds right: The 20.4 is basically 1000 / ( g * fuel_density ). The 1000 comes in because you are using kN instead of N.

Thanks Jebbe I was just about to tell him to do some unit analyses and find out what the units must be to provide a clue where the number comes from obviously it is (density*g)^-1 here is the really question. I am fairly new to the game so not sure how much the developers have revealed about the mechanics of the game and how much peeps have figured out. My question is has any one bothered to figure out the differential equation governing the following three factors? Air resistance in atmosphere, Rocket mass change due to fuel consumption which causes a change in effective thrust, and change in g as altitude increases. Since this is a computer sim I must assume all these factors are discreet as apposed to a continuous curve. I wonder what are the scales heights for air resistance and gravity and delta kg for change in mass?

Link to comment
Share on other sites

Thrust is independent of fuel consumption. If you wish to know how much acceleration you can get at a particular thrust, it's just the standard Newtonian equation of motion: a = F/m.

Gravitational accelleration also uses the standard equations; if you know the Standard Gravitational Parameter of the body in question (μ) and its radius ® and your altitude (h) in the appropriate units... then accelleration due to gravity ag = (μ)/(r+h)2

Link to comment
Share on other sites

Thrust is independent of fuel consumption. If you wish to know how much acceleration you can get at a particular thrust, it's just the standard Newtonian equation of motion: a = F/m.

Gravitational accelleration also uses the standard equations; if you know the Standard Gravitational Parameter of the body in question (μ) and its radius ® and your altitude (h) in the appropriate units... then accelleration due to gravity ag = (μ)/(r+h)2

Indeed your right about thrust for any instantaneous time. Though the equation I had in mind from classical mechanics was Fext=d/dt*(mv) where m=mass and v=radial velocity and Fext= -mg.

As far a gravity goes I assumed they where using Newtonian mechanics but a computer can not create a "real" smooth continuous curve so the program must use some [DELTA]h for every [DELTA] ag i was just wonder what that was and the same goes for air resistance.

Link to comment
Share on other sites

I do wish they had solved the n-body problem but I can see how that would very much complicate the program and probably destabilize it. Since they chose a grafics engine that does not support muli-prepossessing using the solution to the n-body problem is out of the question.

Link to comment
Share on other sites

Thrust is independent of fuel consumption. If you wish to know how much acceleration you can get at a particular thrust, it's just the standard Newtonian equation of motion: a = F/m.

Gravitational accelleration also uses the standard equations; if you know the Standard Gravitational Parameter of the body in question (μ) and its radius ® and your altitude (h) in the appropriate units... then accelleration due to gravity ag = (μ)/(r+h)2

Indeed your right about thrust for any instantaneous time. Though the equation I had in mind from classical mechanics was Fext=d/dt*(mv) where m=mass and v=radial velocity and Fext= -mg.

As far a gravity goes I assumed they where using Newtonian mechanics but a computer can not create a "real" smooth continuous curve so the program must use some [DELTA]h for every [DELTA] ag i was just wonder what that was and the same goes for air resistance.

Link to comment
Share on other sites

My question is has any one bothered to figure out the differential equation governing the following three factors? Air resistance in atmosphere, Rocket mass change due to fuel consumption which causes a change in effective thrust, and change in g as altitude increases. Since this is a computer sim I must assume all these factors are discreet as apposed to a continuous curve. I wonder what are the scales heights for air resistance and gravity and delta kg for change in mass?

There has been a challenge that resulted in quite sophisticated physical models for the Kerbal universe; some of the results found their way into MechJeb. It covers what you were asking for in great depth, including several numerical codes to solve the equations:

http://kerbalspaceprogram.com/forum/showthread.php/6664-Mini-challenge-max-altitude-with-this-supplied-spacecraft

In there we had a lot of references to this thread about drag - unfortunately, the links don't work anymore in the new Forum, so here you go:

http://kerbalspaceprogram.com/forum/showthread.php/5235-Atmospheric-drag

I do wish they had solved the n-body problem but I can see how that would very much complicate the program and probably destabilize it. Since they chose a grafics engine that does not support muli-prepossessing using the solution to the n-body problem is out of the question.

The problem with this is not computational power; all you'd have to do is add a number for each celestial body. The issue is the prediction of the trajectories, which are useful in itself, but become essential for time warp: For the patched conics, there are analytical solutions you can apply, while with the n-body problem you'd have to run a complete numerical simulation over the whole trajectory at each frame to keep the trajectories up to date. And that is not an option even if you had a super computer.

Edited by jebbe
Link to comment
Share on other sites

These equations are the exact thing I was looking for a few days ago, because I have a few mods installed that have engines that use the old "fuel consumption" system and I wanted to update them to use the new Isp system via a .cfg edit, but I gave up because I kept going cross-eyed when I attempted to re-solve the equations I found so they would spit out an Isp number when given the values for Fuel Consumption, Thrust, Fuel Mass, and Fuel Volume. This way, mods that are well balanced and have at least one engine that uses the old "fuelConsumption" system and one fuel tank could be easily converted to the new "Isp and vacIsp" system.

So, the equation I have so far is complete, but it is solved for fuel consumption. (tell me how I'm wrong, if I am, please)

Fc=(Thr / Isp) * g * (Mfuel / Vfuel)

Variable legend:

Fc = Fuel consumption (Liters/second)

Thr = Thrust (kN)

Isp = Specific Impulse (Seconds)

g = Earth's sea-level acceleration due to gravity (9.80665 m/s2)

Mfuel = Mass of fuel (Kg)

Vfuel = Volume of fuel (Liters)

I tried re-solving that equation for Isp, can anyone tell me if my math is right?

Isp = g * Thr * Fc * (Mfuel/Vfuel)

Example run-thru using data from the .cfgs of the engine and fuel tank of DishyCourier's SPHERE ball-pod mod

engine:

Thrust = 8.9

Fuel Consumption = 0.29

Fuel tank:

Full Mass =

Empty mass =

(calculated total mass of fuel = 0.24)

Fuel = 92

Plugging those values into the re-solved equation, I get:

9.80665 * 8.9 * 0.29 * (0.24 / 92) = 785.12 seconds, which agrees nicely with the performance of the engine and fuel tank, they can take the little ship (SAS+pod+fuel tank+engine) from Kerbin to the Mun and back, and still have enough fuel left over for a powered landing

Link to comment
Share on other sites

Nope, first equation is wrong already - see my earlier post:

Thrust = (fuel rate in L/s) * density * g * Isp

so you get

Isp = Thrust / ((fuel rate in L/s) * density * g)

where density = (Mfuel/Vfuel).

Plugged in you have

Isp = Thrust * Vfuel / ((fuel rate in L/s) * Mfuel * g)

Edited by jebbe
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...