# Insulin on Board (IOB) - Question 1

I would like to calculate the Insulin on Board (IOB) in our project Glucosurfer.org. This estimate is very useful to prevent the stacking of insulin or to prepare for physical activity. The Glucosurfer is very benefitial for MDI users (Bolus Wizard, Documentation) and the IOB would be a great addition.

As a first step I would like to keep it really simple. It does not need to be perfect. The following chart shows a typical simplification used in pumps. The chart shows the amount of insulin (in percent) present after the injection. In this example it shows 10 units of Apidra and as you can see the insulin is nearly gone at the 3 hour mark. But this is highly individual so it should be possible to tell the system that 10 units of Apidra will last for x hours. The calculation can then be adjusted to this setting. This is easy and I have already a solution for that.

The problem is that the duration of bolus insulin is not fixed. It depends on the dosage. Thus the chart is a simplification for a fixed number of units. In this case for 10 units. I conclude that the function needs to be stretched if the dosage is higher than 10 OR compressed if the dosage is below 10.

Would you agree in general?

More refined: The user will define that 10 units of Apidra will last x hours. He is now injecting 15 units and the system assumes that x = x * 1.5 for his calculation. Do you think it is sufficient to adjust the x accordingly (just to keep it simple)?

Dr. Bernstein states that doses > 7U will have absorption problems due to the fluid dynamics of the larger “bubble” of insulin rather than by the insulin functions themselves? It may be worth it to consider that number? He cited a study but, unfortunately, I don’t have my copy of the book readily at hand.

I did a very short “trial” of this, as I was taking shots of around 20U of N when I reread his book when I was dx’ed and it did seem like I’d get a bit more bang for my buck splitting the shots that way? It may also have perhaps been a way of smoothing out the irregular peakiness of the N? I think that the function might be ok if it were flat up to the 7U “proven” dosage?

But doesn’t a pump used a fixed number? We tell our pumps ‘oh, that insulin lasts 3 hours in me’ and then, from what I can see, for any dosage given, it assumes its duration is 3 hours. If I were to change it to 2 hours it would assume any dosage given lasts 2 hours. Etc.

I think that’s sort of a ‘fudge’ to estimate it? I use 4 hours for mine on the suggestion of my old endo and it seems to work ok? I will test more frequently if I take a larger dose though. I think that there may also be some variance depending on what you are doing, with higher activity levels making it work faster? I don’t have citations though, just a ‘vibe’ I’ve gotten?

If you adjust for dosage this has some implications: you need more calculations and more memory of the shots before. Very likely the pump manufacturers voted for more simplicity. It would be great if we can do that slightly better.

As a very simple model of the bubble you can use the formulas for a sphere:

Volume (V) = 4/3pir^3 (r = radius)
Surface (S) = 4pir^2

Obviously the surface just increases in much smaller increments than the volume. If you double the volume the radius will just increase by 1.259 (for the exact effect on the surface I need to find the formula). The insulin is absorbed at the surface and thus it is logical that greater volumes need more time to absorb. On the other hand it can be argued that the adjustment of time x is indirectly modeling this behavior. The difference is that is does this only proportionally and not with a spherical absorption model in mind. Seems like this should be the next step after the initial IOB is finished. Thanks for the input.

So let me ask you a basic question. Do you believe that insulin activation (how much get’s released into the blood stream) is linearly proportional to the end effect on blood sugar? I don’t.

If you agree with me, then perhaps further refinement of an activation model won’t improve predictions of how remaining insulin will effect your blood sugar by that much, perhaps other factors have a bigger role.

And why would insulin form a spherical bubble, I would suggest instead it is just as likely to branch out filling interstitial pockets more like a branched tree, reflecting a volume that is more proportional to surface. I don’t usually inject to find I have a hard little knot of insulin, do you?

All of the new pumps make the assumption that every food bolus is correct and just tracks correction insulin based on the last BG entry.

Thanks John. This new development is disturbing. The volume of glucose transport per insulin unit depends on the level of physical activity. This is why the bolus IOB is such an important information. Thus the assumption that the bolus for food is correct and can be ignored is a total misinterpretation of the problem at hand. Wow, what a step backward - I hope this result of happy engineering can be deactivated.

Do you believe that insulin activation (how much get's released into the blood stream) is linearly proportional to the end effect on blood sugar?
I have no problem to believe that. It would be hard to verify that because of the race between absorbtion and insulin activation. In a static state experiment people get injections of insulin and their blood glucose is kept steady with glucose infusions. The amount of glucose needed shows the activity of insulin. Do these experiments disagree with a proportional relation between insulin activity and end effect on blood glucose?

...why would insulin form a spherical bubble...
These are all baby steps and I just like the idea because I know the effect that Acidrock is refering to. Of course it does not form a spherical bubble and I have rarely knots under my skin. But still there is some sort of reservoir effect with huge dosages. It is as if the insulin needs more time to become active. This can be related to absorbtion problems or the insulin does not unfold with normal speed. It just lasts longer and the tail is also longer. It would be nice to have that represented in a refined model.

Do you believe that insulin activation (how much get’s released into the blood stream) is linearly proportional to the end effect on blood sugar? I don’t.

For example, we cannot assume that insulin is more effective after exercise simply because of improved blood flow, it is more effective because of improved peripheral glucose uptake, numerous studies have shown that. Other things that can effect uptake include blood sugar levels, history of elevated insulin levels. And beyond the uptake effects, I think there are effects that have to do with threshold responses where above a certain level insulin will inhibit glucose being produced by your liver and your liver also performs ongoing insulin clearance with a spike in clearance activity at night.

Here is an interesting paper on modeling you may already have encountered. There is a great deal of work on these problems in the activities focused on trying to get closed loop control to work. What you have done is pull out one part of that system. I am actually still confused about what question you are asking, is it about plasma levels of insulin or is it about net resulting effects on glucose levels.

Ok, so I gave you all this criticism, but offered nothing helpful. Sorry.

Why don’t you use a diffusion model. If you derived a diffusion model based on a three dimensional sphere, you would end up with a first order differential equation with just some constants. Similar efforts on a tree volume would result in the same net effect. An example of its use is in the paper. If you solve it you will get an exponential. So my suggestion, for whatever it is worth, is to use an exponential equation.

Everything you guys said are way above my head. I do know that in the Using Insulin by John Walsh he uses a straight calculation for IOB - example 25% for each hour for Humalog.

However, Gary Scheiner states on page 133 of the THINK LIKE A PANCREAS that the most precise method of determining the unused insulin goes like this for each half hour: 90%, 70%, 50%, 30%, 20%, 10%, 5%, 0% of insulin remaining.

I do not know if this is helpful at all??

Good luck with your project. We need something like this for the MDIers. I use my old Ping pump without anything in the cartridge to track my carbs, BG and IOB.

This is not true.
I can say with 100% certainy that Animas continues to calculate and track IOB as they always have- for food and correction. I am fairly certain that MM has not changed their calculations on the Revel but I could be wrong on that. Up until the Revel (and again I do not think this has changed) MM has also tracked IOB for carbs and correction.
Omni has NEVER tracked for food- only for correction. This has been a major issue of this system from the very beginning. Unfortunately the rep in my area insists that that is the way they want it and will not admit it is a flaw.

The first version should be simple. The next iteration can be more sophisticated.

First IOB formula

The formula is simple but more advanced than the linear models the first pumps have used.
From different papers I derived the swinging curve seen at the beginning of this discussion.
This curve is a simplification and its progression should be comparable to what Gary Scheiner
states in "Think like a Pancreas":

f(x)=(x^3-20*x)*x+100=(x^2-10)^2 = percent of active insulin per minute x

This function will reach 0 at x = √10 ≈ 3. In this context it is valid for x between 0 and 3.
So the function will be 0 at the third minute?! Well, we have to compensate for that and adjust
with the valid duration for the user as follows:

The system will have settings. There the user can define how long 5 units of his bolus insulin will be active. This parameter k will be in minutes. Let us assume the aswer is that 5 units will last 240 minutes (4 hours): k = 240.

Scale factor c:

k*c = √10 <=> c = √10/k <=> c = √10/240 <=> c = 0.013176156

If you like to use the formula f(x) with minutes you will use f(x*c) to adjust for the scale.

Examples

5 units of Apidra will last 240 minutes.
The injected dosage was 5 units.
k = 240 => c = 0.0125

User wants to know his IOB after 30 minutes:

f(30*c) = f(0.39) = 96.90 => 5 units * (96.90/100) = 4.85 IOB

IOB after 60 minutes:

f(60*c) = f(0.79) = 87.91 => 5 units * (87.91/100) = 4.40 IOB

IOB after 120 minutes:

f(120*c) = f(1.5) = 56.25 => 5 units * (56.25/100) = 2.81 IOB

IOB after 180 minutes:

f(180*c) = f(1.5) = 19.14 => 5 units * (19.14/100) = 0.96 IOB

IOB after 240 minutes:

f(240*c) = f(3.16) = 0 => 5 units * (0/100) = 0 IOB

Experimental: Adjustment for higher or lower dosages than 5

Further refinement is necessary to express that the actual dosage defines the length of activity. The user has defined that 5 units will last for k minutes. Now his actual dosage d is different from 5 and this should be considered with the following factor. Let us assume the injected dosage is 10 units (d=10). Like before 5 units of Apidra will last 240 minutes (k=240).

Dosage factor p:

5*p = d <=> 5*p = 10 <=> p = 2

This factor p will be applied to the duration k that is valid for 5 units:

k' = k*p <=> k' = 480 (use k' instead of k in the formula for c)

Examples

The injected dosage was 10 units.
p = 2
k' = 240*2 => c = √10/k' <=> c = 0.0066

User wants to know his IOB after 30 minutes:

f(30*c) = f(0.20) = 99.22 => 10 units * (99.22/100) = 9.92 IOB

IOB after 60 minutes (1 hour):

f(60*c) = f(0.39) = 96.90 => 10 units * (96.90/100) = 9.69 IOB

IOB after 120 minutes (2 hours):

f(120*c) = f(0.79) = 87.89 => 10 units * (87.89/100) = 8.78 IOB

IOB after 180 minutes (3 hours):

f(180*c) = f(1.19) = 73.85 => 10 units * (73.85/100) = 7.38 IOB

IOB after 240 minutes (4 hours):

f(240*c) = f(1.58) = 56.25 => 10 units * (56.25/100) = 5.625 IOB

Obviously the linear scaling of the duration k is a weakness. It seems not very likely that more than 50% percent of the 10 units is present after 4 hours. On the other hand it is a clear warning that unplanned physical activity has a high risk of causing a low blood glucose. So far the users of Glucosurfer have no IOB at hand so this is still valuable information despite the simplicity.

I hope I have not made major mistakes here.

I will agree with you that it does not take active insulin into consideration when bolusing for carbs. It will however tell you how much IOB is left using both IOB for the last bolus AND the last time you took in carbs.
Perhaps I am missing something but unless you are hypoglycemic why would you want the pump to take out it’s current IOB based on carbs you are about to eat? Regardless of how much is still there if you are consuming more Carbohydrate you will need insulin to cover that additional influx of sugar. What if your blood glucose was 100 1 hour after you ate. The reason you have such a good blood sugar is because you bolused 15 minutes before hand so you never got a “spike”. Let’s say you decide that you now want to eat more. How much IOB should not matter as you are now consuming more. There are simply too many variables at play to have a pump accurately determine what needs to happen based on IOB and how many carbs you want to eat at any one particular time.
On the other hand the Omni does not track the insulin given for carbs eaten. So 2 hours after you eat it will show very little IOB (depending on how much you had to give for correction) so it is more than likely going to suggest a correction where the MM and Animas pump more than likely wouldn’t or it would likely only be a very small amount if they did.

I understand Animas is currently conducting a study looking at the way all of the different pumps calculate IOB.

“All of the new pumps make the assumption that every food bolus is correct and just tracks correction insulin based on the last BG entry”

That is not a true statement. I have only had my Ping since June (and it was actually replaced in Jan and the replacement was not a refurbished one). If it calculated IOB based on correction insulin & BG entries, I would rarely have IOB. It calculates the IOB based on food.

Gary Scheiner wrote an article how different pumps calculate the IOB.

+1! Interesting though!

Sorry John, I misread what you were saying! I was thinking that you meant that any bolus for food would not be included in the IOB. I apoligize - I read that wrong!

@John: thanks for the clarification.