FAILURE MAP
← Case archive

FA-64086 / Medication dosing calculations / Open access

Pharmacokinetic loading and maintenance doses: maintenance bioavailability · case 01

Oral maintenance doses are smaller than the intravenous equivalent.

Verified by executionVariant 1 · 6 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The maintenance dose multiplies by F instead of dividing by it.

THE FAILURE

The maintenance dose multiplies by F instead of dividing by it.

Unsuccessful approach: Dropping F entirely treats an oral dose as if fully absorbed.

Case contract

Input {target, current, vd_l_kg, weight_kg, f, cl_ml_min, tau_h, unit_mg}. Toy one-compartment rule: loading = max(0, (target-current)*Vd*weight/F); maintenance = target*CL*tau/F with CL in L/h = cl_ml_min*60/1000. Both are rounded half-up to a multiple of unit_mg. Return {loading_mg, maintenance_mg}.

Why this case matters

Loading and maintenance calculations chain unit conversions and bioavailability; each factor is an independent defect site.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
    tgt, cur = Fraction(str(x['target'])), Fraction(str(x['current']))
    f = Fraction(str(x['f']))
    u = x['unit_mg']
    vd = Fraction(str(x['vd_l_kg']))
    wt = Fraction(str(x['weight_kg']))
    cl = Fraction(x['cl_ml_min']) * 60 / 1000
    def rnd(v):
        return float(math.floor(v / u + Fraction(1, 2)) * u)
    load = max(Fraction(0), (tgt - cur) * vd * wt / f)
    maint = tgt * cl * x['tau_h'] * f
    return {'loading_mg': rnd(load), 'maintenance_mg': rnd(maint)}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 71,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 750.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 6,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 700.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 13,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.5',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 240.0, 'maintenance_mg': 290.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 65,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 175.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 10,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 14.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 72,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 750.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 7,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 650.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 14,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.8',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 150.0, 'maintenance_mg': 180.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 25,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 75.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 20,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 29.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 73,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 750.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 8,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 600.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 15,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.25',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 480.0, 'maintenance_mg': 575.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 45,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 125.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 30,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 43.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 74,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 800.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 9,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 550.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 16,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.4',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 300.0, 'maintenance_mg': 360.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 85,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 225.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 40,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 58.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 75,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 800.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 10,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 500.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 17,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.6',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 200.0, 'maintenance_mg': 240.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 105,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 275.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 72.0})]]
for label, args, expected in fixtures[N-1]:
    check(label, solve(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
drug-naive loading{'loading_mg': 750.0, 'maintenance_mg': 1100.0}{'loading_mg': 750.0, 'maintenance_mg': 1100.0}Passed
partial existing level credited{'loading_mg': 700.0, 'maintenance_mg': 625.0}{'loading_mg': 700.0, 'maintenance_mg': 950.0}Failed
level above target gives no load{'loading_mg': 0.0, 'maintenance_mg': 650.0}{'loading_mg': 0.0, 'maintenance_mg': 650.0}Passed
oral bioavailability maintenance{'loading_mg': 240.0, 'maintenance_mg': 70.0}{'loading_mg': 240.0, 'maintenance_mg': 290.0}Failed
half unit rounds up{'loading_mg': 175.0, 'maintenance_mg': 50.0}{'loading_mg': 175.0, 'maintenance_mg': 50.0}Passed
slow clearance long interval{'loading_mg': 10.0, 'maintenance_mg': 14.0}{'loading_mg': 10.0, 'maintenance_mg': 14.0}Passed

SHA-256 / c21e29b2b078bf4080ff396ae7334fbd8190c8218725cc2493b77c67664d4723

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(x):
    tgt, cur = Fraction(str(x['target'])), Fraction(str(x['current']))
    f = Fraction(str(x['f']))
    u = x['unit_mg']
    vd = Fraction(str(x['vd_l_kg']))
    wt = Fraction(str(x['weight_kg']))
    cl = Fraction(x['cl_ml_min']) * 60 / 1000
    def rnd(v):
        return float(math.floor(v / u + Fraction(1, 2)) * u)
    load = max(Fraction(0), (tgt - cur) * vd * wt / f)
    maint = tgt * cl * x['tau_h']
    return {'loading_mg': rnd(load), 'maintenance_mg': rnd(maint)}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 71,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 750.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 6,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 700.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 13,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.5',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 240.0, 'maintenance_mg': 290.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 65,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 175.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 10,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 14.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 72,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 750.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 7,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 650.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 14,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.8',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 150.0, 'maintenance_mg': 180.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 25,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 75.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 20,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 29.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 73,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 750.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 8,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 600.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 15,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.25',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 480.0, 'maintenance_mg': 575.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 45,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 125.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 30,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 43.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 74,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 800.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 9,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 550.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 16,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.4',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 300.0, 'maintenance_mg': 360.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 85,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 225.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 40,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 58.0})],
 [('drug-naive loading',
   {'target': 15,
    'current': 0,
    'vd_l_kg': '0.7',
    'weight_kg': 75,
    'f': 1,
    'cl_ml_min': 100,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 800.0, 'maintenance_mg': 1100.0}),
  ('partial existing level credited',
   {'target': 20,
    'current': 10,
    'vd_l_kg': '0.5',
    'weight_kg': 80,
    'f': '0.8',
    'cl_ml_min': 80,
    'tau_h': 8,
    'unit_mg': 25},
   {'loading_mg': 500.0, 'maintenance_mg': 950.0}),
  ('level above target gives no load',
   {'target': 10,
    'current': 17,
    'vd_l_kg': '0.6',
    'weight_kg': 70,
    'f': 1,
    'cl_ml_min': 90,
    'tau_h': 12,
    'unit_mg': 50},
   {'loading_mg': 0.0, 'maintenance_mg': 650.0}),
  ('oral bioavailability maintenance',
   {'target': 2,
    'current': 0,
    'vd_l_kg': '1.0',
    'weight_kg': 60,
    'f': '0.6',
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 5},
   {'loading_mg': 200.0, 'maintenance_mg': 240.0}),
  ('half unit rounds up',
   {'target': 5,
    'current': 0,
    'vd_l_kg': '0.5',
    'weight_kg': 105,
    'f': 1,
    'cl_ml_min': 25,
    'tau_h': 6,
    'unit_mg': 25},
   {'loading_mg': 275.0, 'maintenance_mg': 50.0}),
  ('slow clearance long interval',
   {'target': 1,
    'current': 0,
    'vd_l_kg': '0.2',
    'weight_kg': 50,
    'f': 1,
    'cl_ml_min': 50,
    'tau_h': 24,
    'unit_mg': 1},
   {'loading_mg': 10.0, 'maintenance_mg': 72.0})]]
for label, args, expected in fixtures[N-1]:
    check(label, solve(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
drug-naive loading{'loading_mg': 750.0, 'maintenance_mg': 1100.0}{'loading_mg': 750.0, 'maintenance_mg': 1100.0}Passed
partial existing level credited{'loading_mg': 700.0, 'maintenance_mg': 775.0}{'loading_mg': 700.0, 'maintenance_mg': 950.0}Failed
level above target gives no load{'loading_mg': 0.0, 'maintenance_mg': 650.0}{'loading_mg': 0.0, 'maintenance_mg': 650.0}Passed
oral bioavailability maintenance{'loading_mg': 240.0, 'maintenance_mg': 145.0}{'loading_mg': 240.0, 'maintenance_mg': 290.0}Failed
half unit rounds up{'loading_mg': 175.0, 'maintenance_mg': 50.0}{'loading_mg': 175.0, 'maintenance_mg': 50.0}Passed
slow clearance long interval{'loading_mg': 10.0, 'maintenance_mg': 14.0}{'loading_mg': 10.0, 'maintenance_mg': 14.0}Passed

SHA-256 / c13036aa7a688e81111840804687b63d990ef891cecff787b3720f8af91271c2

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 6 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.

Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.

Member access is invitation-based. Sign in with your invited account to inspect the repair.

Sign in to the archive ↗

Verification & scope

A deterministic toy software model with explicitly stipulated thresholds and formulas; it is not clinical guidance, not a validated medical calculator, and makes no claim of conformance to any published protocol. Numbered variants vary patient and order inputs. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.

Observations recorded using Python 3.12.14 at 2026-09-29T14:47:21.158131+00:00.

Case digest / 9705666a30306d2cc5a887ce5a586e701e9b74c7d2d6c4e1041d97cad31e1d25