HomeType 1 Diabetes Insulin Pump ManagementExercise-Related Glucose Management Pump Simulator

💉 Exercise-Related Glucose Management Pump Simulator

This simulation helps users manage insulin pump settings during physical exertion in children. It allows for real-time adjustments to ensure optimal glucose levels are maintained, which is crucial for preventing hypoglycemia and hyperglycemia during activities such as sports or physical education.

Type 1 Diabetes Insulin Pump Management2DModerate60 FPS
exercise-glucose-management-pump ↗ Open standalone

Pre-Exercise Glucose Check & Activity Planning

Exercise is one of the most powerful and least predictable variables in pediatric type 1 diabetes management. A CGM check 20-30 minutes before activity — reading both the number and the trend arrow — turns a guess into a plan. Categorizing the upcoming activity as aerobic, anaerobic, or mixed determines whether the child needs a basal reduction, a carb snack, both, or neither.

  • 20-30 min: Recommended pre-check window (before activity starts)
  • ↓ lowering: Aerobic glucose effect (muscles consume glucose for fuel)
  • ↑ transient rise: Anaerobic glucose effect (catecholamines drive glycogenolysis)
  • 126-180: Target pre-exercise range (mg/dL, stable or rising arrow)

Reading the CGM trend arrow before the whistle blows

A single glucose number tells only part of the story; the trend arrow tells you where that number is headed. Before PE class or practice, a child or caregiver checks:

• Steady or single up arrow, glucose 126-180 mg/dL: green light, proceed as planned • Single down arrow: consider 10-15g carbs before starting, or a smaller temp-basal reduction • Double down arrow: treat now with 15-20g fast carbs and recheck before beginning activity • Glucose below 90 mg/dL with any downward trend: treat and delay activity 15 minutes, recheck • Glucose above 250 mg/dL with ketones: exercise is deferred — activity can paradoxically worsen hyperglycemia and ketosis when insulin is critically deficient

This pre-check becomes routine for school-age children: the same five minutes before every gym class, every practice, every game.

Studies of youth with type 1 diabetes show glucose can drop 50-70 mg/dL in the first 20-30 minutes of moderate aerobic exercise. A pre-check that catches a downward trend early prevents a hypoglycemic event before it starts, rather than reacting once symptoms appear mid-activity.

Aerobic versus anaerobic — two very different glucose responses

Not all exercise affects glucose the same way, and pump settings should reflect the specific activity:

Aerobic (sustained, moderate intensity) — running, swimming, soccer, cycling, distance events: • Working muscles increase glucose uptake via insulin-independent GLUT4 translocation, an effect that intensifies with duration • Glucose typically falls steadily throughout the activity and can continue falling afterward • Management: temp basal reduction started before exercise, possible carb snack for longer sessions

Anaerobic (short, high-intensity bursts) — sprinting, weightlifting, hockey shifts, competitive gymnastics: • Adrenaline and cortisol surges trigger hepatic glycogenolysis faster than muscles can consume the released glucose • Glucose can rise 30-80 mg/dL during a short anaerobic burst, sometimes followed by a delayed fall once the surge subsides • Management: little or no basal reduction beforehand; watch for a delayed drop 30-60 minutes later

Mixed sports (soccer, basketball, hockey) combine both patterns unpredictably, which is why real-time CGM monitoring during play matters as much as pre-activity planning.

Building the activity plan into the pump routine

A workable exercise plan is written down once and then reused every time the same activity recurs — Tuesday/Thursday PE class, Saturday morning soccer practice, evening swim team:

• Activity type and typical duration logged (e.g., "PE class, 45 min, mixed running/games") • Standard temp-basal reduction percentage and start time relative to the activity • Carb snack rule if pre-activity glucose is below a set threshold • Emergency fast-carb source kept in a gym bag or with the coach/teacher • School diabetes care plan shared with PE teachers and coaches, including CGM alert thresholds

Over weeks of data, families and clinicians refine this plan using CGM download reports, tightening or loosening the basal reduction based on how glucose actually behaved during past sessions of the same activity.

Temp-Basal Reduction — Dialing Down Background Insulin Before Activity

An insulin pump's temporary basal rate (temp basal) function lets a caregiver override the programmed basal rate for a set duration without changing the underlying pump program. For exercise, a 50-80% reduction started 60-90 minutes before aerobic activity is one of the single most effective tools for preventing exercise-induced hypoglycemia — because it targets the actual cause: too much background insulin relative to how fast the muscles are clearing glucose.

  • 50-80%: Typical reduction range (of programmed basal rate)
  • 60-90 min: Recommended lead time (before aerobic activity starts)
  • ~60-90 min: Rapid-acting insulin half-life (why early start matters)
  • 60-90 min: Typical temp basal duration (can be extended per stage 5)

Why timing the reduction before exercise matters

Rapid-acting insulin analogs (lispro, aspart, glulisine) have a pharmacokinetic profile that peaks 45-90 minutes after subcutaneous delivery and remains active for 3-5 hours. A temp basal reduction switched on at the moment exercise starts does nothing about the insulin already circulating from the last hour of basal delivery — it only affects insulin delivered from that point forward.

Starting the reduction 60-90 minutes ahead of time allows circulating insulin levels to actually fall before the muscles start pulling glucose out of the blood, so the two effects do not stack. This lead time is the single most common adjustment families miss when a temp basal "doesn't seem to work" — the reduction was started at kickoff, not before it.

Choosing a reduction percentage

The right percentage depends on exercise intensity, duration, and how a child has responded in the past:

• Light activity (walking, easy bike ride, 20-30 min): 20-30% reduction • Moderate PE class or team practice (30-60 min): 50% reduction • Vigorous, sustained aerobic activity (60-90 min, cross country, swim practice): 70-80% reduction • Competitive endurance events: reduction may be combined with carbohydrate intake during activity rather than relying on basal reduction alone, since suspending too much basal risks rebound hyperglycemia afterward

Automated insulin delivery (AID) systems — hybrid closed-loop pumps like Control-IQ, Omnipod 5, and CamAPS FX — offer a built-in "Exercise Mode" or "Activity Mode" that raises the algorithm's target glucose and suppresses automatic correction boluses, functioning as a smarter, semi-automated version of a manual temp basal reduction.

A too-aggressive reduction for too short a duration can backfire: if temp basal ends while the child is still moving, or if 80% reduction is used for a light 20-minute walk, unopposed counter-regulatory hormones can push glucose upward once activity intensity exceeds what the reduced basal accounts for. Matching percentage and duration to actual activity is the core skill.

Manual pumps versus automated insulin delivery systems

On a standard (non-automated) pump, temp basal is a manual override: caregiver or child enters a percentage and duration, and the pump delivers that adjusted rate until the timer expires or is cancelled.

On hybrid closed-loop systems, the algorithm is already adjusting basal delivery every few minutes based on CGM readings and trend. Exercise Mode changes the algorithm's internal target (for example, raising the target from 110 mg/dL to 150-160 mg/dL) and often disables auto-correction boluses, so the system naturally backs off insulin delivery in response to falling glucose rather than requiring a fixed percentage to be estimated in advance. Because the algorithm is reactive, Exercise Mode is often turned on well before activity and left on for a while afterward to cover the post-exercise sensitivity window described in Stage 5.

Active Insulin (IOB) — When a Recent Bolus Compounds Exercise Risk

Insulin on board (IOB) is the estimated amount of a previous bolus still active in the body, decaying over the insulin action duration typically set at 3-5 hours on the pump. High IOB combined with exercise is one of the most common preventable causes of severe hypoglycemia in youth with type 1 diabetes, because active bolus insulin and exercise-driven glucose uptake pull glucose down through two separate, additive mechanisms at the same time.

  • 3-5 hr: Typical insulin action duration (pump-configured DIA setting)
  • ~35-45%: IOB remaining at 2 hr post-bolus (of original bolus, exponential decay curve)
  • 2+ hours: Recommended gap before exercise (after a full meal bolus, when feasible)
  • high: Combined risk multiplier (bolus insulin + exercise uptake stack additively)

How insulin-on-board is calculated and why it matters mid-activity

Pumps estimate IOB using an insulin action curve — commonly a bilinear or exponential decay model — parameterized by the insulin action duration (often called Duration of Insulin Action, DIA) set in pump settings, typically 3-5 hours for rapid-acting analogs.

IOB(t) = bolus_amount × decay_fraction_remaining(t)

Immediately after a meal bolus, nearly 100% of the dose is "on board." By roughly 2 hours later, 35-45% typically remains, and by 3-4 hours it approaches zero. Because exercise increases insulin sensitivity and accelerates glucose clearance independent of insulin action, any IOB still present during activity effectively acts stronger than it would at rest — the same units of active insulin drive a larger glucose drop when muscles are also pulling glucose from the blood.

Clinical guidance from pediatric diabetes exercise consensus statements generally recommends postponing or modifying moderate-to-vigorous aerobic exercise when IOB exceeds roughly 50% of the total daily bolus dose typical for that meal, or when a correction bolus was given within the last 90 minutes — the combined effect can precipitate hypoglycemia within 20-30 minutes of starting activity.

Timing meals, boluses, and activity around each other

Because IOB cannot be instantly reduced once delivered, the most reliable strategy is scheduling:

• Where practical, schedule vigorous exercise 2+ hours after a meal bolus, once IOB has fallen substantially • If exercise must follow soon after a meal (a common reality with school schedules — lunch period into afternoon PE), consider a reduced bolus for that meal, anticipating the exercise • A correction bolus for a high reading shortly before activity is treated cautiously — better to allow a modest reduction in temp basal and permit glucose to come down gradually during exercise than to add fresh IOB right before muscles start consuming glucose • After activity, IOB from a pre-exercise bolus continues decaying into a period of heightened insulin sensitivity (Stage 5), so even "normal" IOB levels need extra caution in the following hours

Real-world scheduling constraints for young athletes

Unlike adults with flexible schedules, children and teens rarely control when PE class or practice falls relative to meals. A few practical adaptations are used across pediatric endocrinology clinics:

• Lunch-into-PE scenario: a smaller lunch bolus with a planned snack immediately before or during activity • After-school practice: an afternoon snack bolus is reduced or timed with the temp basal reduction already in place • Two-a-day practices (preseason sports): the plan is reviewed for each session separately since IOB and glycogen stores differ between a morning and an evening session • CGM data reviewed weekly by families and care teams to see whether the current IOB/timing plan is producing lows, and adjustments made incrementally rather than reactively after a single bad session

During-Exercise Monitoring — Trend Arrows, Carb Rules, and Pump Suspension

Once activity begins, the plan meets reality. Continuous glucose monitors provide a live trend arrow every few minutes, turning mid-activity decisions into a simple rule set rather than a guess. For contact sports where the pump itself could be damaged or dislodged, temporary suspend or full disconnect protocols keep the device safe without abandoning glucose management for the duration of play.

  • 1-5 min: CGM update interval (depending on sensor platform)
  • 10-15 g: Fast-carb dose (single down arrow) (glucose tablets, juice, gel)
  • 15-20 g: Fast-carb dose (double down arrow) (plus pause / reassess in 15 min)
  • ~1 hr: Max pump disconnect time (contact sports, then reconnect and check)

Trend-arrow-based carbohydrate rules during activity

CGM trend arrows during exercise translate directly into action, and most pediatric diabetes teams give families a written version of this rule set to keep in a gym bag or hand to a coach:

• Steady or single up arrow, glucose above 100 mg/dL: continue activity, recheck in 15-20 minutes • Single down arrow: take 10-15g fast-acting carbs, continue activity, recheck in 15 minutes • Double down arrow, or glucose below 80 mg/dL: take 15-20g fast carbs immediately, pause vigorous activity, recheck in 15 minutes before resuming • Glucose below 70 mg/dL at any trend: treat as hypoglycemia per standard rule-of-15 protocol, stop activity, recheck every 15 minutes until above 80 mg/dL and rising

These thresholds are deliberately simple so a coach, athletic trainer, or the child themselves can apply them without needing to interpret a chart mid-game.

Pump suspend and disconnect for contact and water sports

Insulin pumps are not designed to withstand direct impact, and some sports create genuine risk of device damage or dislodgement:

• Suspend delivery: pauses all insulin delivery (basal and any bolus) while the pump stays attached — used for brief high-risk moments or when hypoglycemia treatment requires no further insulin • Full disconnect: the infusion set is detached from the pump entirely, commonly done for football, hockey, wrestling, or swimming/diving where the pump cannot be safely worn • Because no basal insulin is delivered during a disconnect, glucose can rise gradually — most guidance limits disconnect time to roughly one hour for moderate-length activities, with reconnection and a glucose check immediately afterward • Longer disconnects (extended swim practice, an all-day tournament) may need a small manual correction upon reconnection if glucose has drifted upward, calculated conservatively given recent activity and continuing insulin sensitivity

For collision sports in particular, many pediatric sports medicine and endocrinology programs recommend a hybrid approach: reduce temp basal significantly beforehand (Stage 2) so that even a full disconnect during play does not leave the athlete without any insulin coverage for too long, then reconnect and reassess at the first break in play.

CGM trend-arrow action rules during activity

ProductIndicationTrial DesignKey Result
Steady / single upGlucose > 100 mg/dLNo action needed; recheck in 15-20 minutesContinue activity as planned
Single down arrowAny glucose level10-15g fast carbs, recheck in 15 minutesPrevents further drop mid-activity
Double down arrowAny glucose level15-20g fast carbs, pause vigorous play, recheck in 15 minutesStops rapid descent before symptoms
Below 70 mg/dLAny trend arrowRule-of-15 hypoglycemia treatment, stop activity entirelyTreats confirmed hypoglycemia safely

Post-Exercise Delayed Hypoglycemia — Managing the Hours After Activity Ends

The most dangerous window in exercise-related glucose management is not during activity — it is hours later, often overnight. Muscles continue drawing glucose from the blood to replenish glycogen stores well after activity stops, and insulin sensitivity stays elevated for up to 24 hours. This "lag effect" causes delayed hypoglycemia that can strike while a child is asleep, unaware and unable to self-treat, making it the leading exercise-related safety concern for families and clinicians alike.

  • up to 24 hr: Lag-effect duration (elevated insulin sensitivity post-exercise)
  • 6-15 hr: Peak delayed-hypo window (after activity ends, often overnight)
  • often continued: Extended temp basal reduction (several hours past activity end)
  • markedly elevated risk: Overnight lows after evening sport (vs. daytime-only activity)

The physiology of delayed post-exercise hypoglycemia

During exercise, muscle and liver glycogen stores are drawn down to fuel activity. In the hours that follow, the body prioritizes glycogen resynthesis — pulling glucose out of the bloodstream and into muscle cells at an accelerated rate, largely through insulin-independent GLUT4 transporter activity that remains upregulated well after the activity itself has ended.

At the same time, whole-body insulin sensitivity increases: the same unit of insulin has a larger glucose-lowering effect than it would have before exercise. This combination — ongoing glycogen-driven glucose uptake plus heightened insulin sensitivity — can persist for 6 to 24 hours, meaning a temp basal rate that was appropriately reduced during a 5pm practice can still be too aggressive for an unadjusted evening dose given at 9pm, or conversely, a return to 100% basal too soon after practice ends can precipitate a low at 2am.

Multiple pediatric studies have identified overnight hypoglycemia as significantly more common on nights following daytime or evening exercise compared to non-exercise days, with a substantial share of these lows occurring between roughly midnight and 6am — precisely when a sleeping child is least likely to notice symptoms without a CGM low alarm.

Extending the temp basal reduction beyond activity end

Rather than returning basal to 100% the moment activity stops, many pediatric diabetes care plans call for continuing a smaller reduction — commonly 10-20% below normal — for several hours afterward, tapering back to full basal gradually rather than abruptly:

• Immediately post-exercise (0-2 hr): reduction may stay closer to the during-exercise level as glycogen replenishment is most active • Mid recovery (2-6 hr): reduction is tapered, e.g., from 50% down to 20-30% • Extended window (6-24 hr, especially overnight): a modest reduction (10-20%) or a raised overnight CGM low-alert threshold is often maintained, particularly after longer or more vigorous sessions

Automated insulin delivery systems handle much of this automatically by keeping Exercise/Activity Mode engaged for several hours after activity, letting the algorithm's reactive dosing manage the tapering rather than requiring a caregiver to calculate and reset multiple manual temp basal segments through the evening.

Evening sports practice and the overnight low-risk warning

Evening practices and games are especially high-risk because the lag effect's peak window (roughly 6-15 hours post-exercise) overlaps directly with overnight sleep — exactly when hypoglycemia is hardest to detect and treat quickly:

• A bedtime CGM check with a target above the usual threshold (for example, requiring 150+ mg/dL with a flat or rising trend before sleep, rather than the usual 120+ mg/dL) is commonly recommended after evening exercise • A bedtime snack with some protein and complex carbohydrate is often added even if glucose looks adequate at bedtime, to blunt the overnight drawdown • CGM low-alarm thresholds may be raised for that night (for example, from 70 to 80 mg/dL) so that caregivers are alerted with more lead time to act before glucose reaches a dangerous level • Families are advised to check on a sleeping child at least once overnight after a particularly long or vigorous evening session, in addition to relying on CGM alarms

This extended vigilance — spanning temp basal tapering, elevated bedtime targets, and overnight monitoring — is what closes the loop opened by the very first pre-exercise check in Stage 1, treating exercise as a single continuous physiological event rather than a discrete hour on a field or in a gym.

⚙ Under the hood

This simulation helps users manage insulin pump settings during physical exertion in children. It allows for real-time adjustments to ensure optimal glucose levels are maintained, which is crucial for preventing hypoglycemia and hyperglycemia during activities such as sports or physical education.

CanvasBiomedicine

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)