The invention
What the device is, and the one thing that makes it different.
PD20 is a continuous-flow regenerative peritoneal dialysis device. Instead of instilling a bag of fresh dialysate, letting it dwell, and draining it, it circulates dialysate continuously through the peritoneal cavity and regenerates the spent fluid by reverse osmosis, returning recovered water and re-dosing the solutes that need replacing.
The clinically important consequence is that ultrafiltration and solute clearance are decoupled from the osmotic agent. In conventional peritoneal dialysis, water removal is bought with dextrose, and sodium leaves the body mainly by being dragged along with that water. If ultrafiltration falls, sodium removal falls with it. A continuous-flow regenerative system removes solute by exchanging a large volume of dialysate across the membrane rather than by concentrating an osmotic gradient, so the two are no longer chained together.
The simulator on this site exists to test whether that claim survives contact with physiology, across a cohort of patients whose behaviour a nephrologist can predict in advance.
Where it is used
A wearable, continuously regenerating device that needs no blood laboratory and no daily clinician oversight fits the settings where conventional dialysis does not.
Travel — hours at a time
The device is body-worn and regenerates its own dialysate, so a patient travels with it rather than around it. No bags of dialysate to carry, no clinic schedule to keep, no power outlet to find for a cycler. The water budget and the clearance floor are held automatically, so a long journey does not mean a missed treatment.
Remote areas — no laboratory
The controller is concentration-blind: it regulates from body weight, bulk conductivity of its own fluid, and its own discard stream, and never needs a blood or serum measurement. A patient weeks from the nearest laboratory still receives regulated therapy, because the device does not depend on a lab result to decide what to do.
Days without clinician control
Therapy is continuous and self-regulating. The water budget, the clearance floor, and the meal-responsive clearance all run on the device, not on a clinician's daily order. A patient can be out of contact for days and the device keeps the same operating point it was prescribed.
Water travel — ships and long passages
At sea there is no dialysis unit and no resupply. A device that regenerates its dialysate and holds its own water budget to a few litres a day is the difference between a voyage and a contraindication. The same concentration-blind control that works without a lab works without a port.
Long-term care travel
Transferring a dialysis patient between facilities usually means re-establishing a prescription and a schedule. A wearable device that carries its own operating point and needs no blood work travels with the patient, so a move between care settings does not interrupt therapy.
Military and austere environments
Forward and austere settings have no dialysis infrastructure, limited water, and no laboratory. A device that regenerates its dialysate, holds a strict water budget, and regulates without blood chemistry is designed for exactly that constraint set.
Hardware — off-the-shelf parts
The device is assembled from reverse-osmosis membranes, pumps, and batteries that are sold today. No part is custom; the invention is the control, not the components.
Reverse-osmosis membranes (commercially available)
| element | class | NaCl rejection | max pressure |
|---|---|---|---|
| Dow FILMTEC BW30 | brackish water | 99.5% | ~41 bar |
| Hydranautics CPA | brackish water | 99.7% | ~41 bar |
| Dow SW30 | seawater | 99.4% | 82.7 bar |
| Dow XUS180808 | ultra-high pressure | 99.5%+ | 120 bar |
The shipped operating point runs 40–120 bar at 0.93 recovery per pass across two passes; the controller commands pressure within that envelope and never asks for what cannot be built.
System components and estimates
| component | estimate | weight | cost |
|---|---|---|---|
| RO membrane element (small spiral-wound) | 1–2 units | ~1–2 kg | ~$50–200 |
| Peristaltic / diaphragm pumps | 2–4 units | ~0.5–1 kg | ~$100–500 |
| Battery (Li-ion, 300–500 Wh) | 1–2 swappable packs | ~1–3 kg | ~$100–300 |
| Mixer, sensors, controller, enclosure | — | ~1–2 kg | ~$200–600 |
| Total (body-worn) | — | ~4–8 kg | ~$500–1600 |
These are engineering estimates for a body-worn prototype, not a quoted bill of materials; the device has not been built. The energy budget is dominated by pumping, not heating — the dialysate is regenerated in-line at body temperature, so no bulk heater is needed.
Consumables per patient per day
| consumable | amount |
|---|---|
| Glucose (dextrose) added by the mixer | ~405 g/day (range 296–521) |
| Glucose absorbed by the patient | ~118 g/day (range 60–202) |
| Sodium added by the mixer | ~100 g/day |
| Chloride added by the mixer | ~125 g/day |
| Device water (RO reject) | ~4.7 L/day (≤ 5.0) |
Glucose is the dominant consumable: the mixer doses it to drive ultrafiltration, and the reverse-osmosis stage rejects ~99% of it, so most of what is bought is recovered and re-infused — the absorbed fraction is what reaches the patient.
The physics engine
Fourteen solutes, ten flux laws, conservation by construction.
Conservation is structural, not checked afterwards
Every physical process in the model moves mass through exactly two primitives: a paired water-plus-carried-solute transfer, and a paired solute-only transfer. Both are atomic and clamped to the source pool, so total water and total per-solute quantity are invariant under any sequence of transfers — mass cannot be created or destroyed by a modelling error, only moved to the wrong place. Measured conservation residuals across a 30-day thirty-patient cohort are of order 10-8, which is floating-point noise rather than physics.
The species, and their transport coefficients
σ is the osmotic reflection coefficient (how strongly the membrane opposes that solute's osmotic pull), S is the convective sieving coefficient (what fraction of the solute is dragged through with ultrafiltrate), and MTAC is the diffusive mass-transfer-area coefficient.
| Solute | Charge | σ | S | MTAC (mL/min) |
|---|---|---|---|---|
| Sodium | +1 | 0.050 | 0.550 | 4.5000 |
| Chloride | -1 | 0.050 | 0.588 | 4.5000 |
| Glucose | 0 | 0.049 | 0.382 | 9.0000 |
| Potassium | +1 | 0.050 | 0.535 | 10.0000 |
| Urea | 0 | 0.020 | 0.688 | 20.0000 |
| Albumin | -18.6 | 0.840 | 0.010 | 0.1000 |
| Globulin | 0 | 0.900 | 0.005 | 0.0500 |
| Icodextrin | 0 | 0.500 | 0.020 | 0.1000 |
| Bicarbonate | -1 | 0.050 | 0.535 | 10.0000 |
| Lactate | -1 | 0.050 | 0.611 | 10.0000 |
| Calcium | +2 | 0.050 | 0.458 | 6.0000 |
| Magnesium | +2 | 0.050 | 0.458 | 6.0000 |
| Phosphate | -1.8 | 0.050 | 0.497 | 10.2000 |
| Sulfate | -2 | 0.050 | 0.458 | 10.2000 |
| Creatinine | 0 | 0.020 | 0.650 | 10.0000 |
Plasma colloid osmotic pressure is not van't Hoff
Plasma protein is strongly non-ideal at physiologic concentration, so the ideal-solution law underestimates the oncotic pressure that opposes ultrafiltration by roughly 40%. The model uses the standard empirical replacement:
COP (mmHg) = 2.1·C + 0.16·C² + 0.009·C³ C = total plasma protein, g/dL
Landis EM & Pappenheimer JR, Handbook of Physiology, Section 2: Circulation, Vol II, American Physiological Society, 1963, p.975.
At a normal total protein of 7.0 g/dL this gives 25.6 mmHg, the textbook plasma value; the ideal law gives 15.8 on the same protein mass. Both albumin and globulin are tracked as separate species, because peritoneal dialysis removes the smaller albumin preferentially and so the albumin fraction of plasma protein falls over a long treatment — a fixed albumin-to-globulin ratio would freeze exactly the quantity that ought to move.
Other laws
- Ultrafiltration — Starling across the peritoneal membrane, driven by the hydrostatic difference between capillary and intraperitoneal pressure plus the summed osmotic terms.
- Intraperitoneal pressure — linear in intraperitoneal volume, anchored to Durand's measurement of 13 cmH2O at 2.82 L supine in 34 CAPD patients (PMID 8105960), with linearity to 5 L from PMID 7999866.
- Diffusion — MTAC-driven, with a Gibbs–Donnan correction: albumin cannot cross, so diffusible ions equilibrate to a ratio set by the impermeant protein charge rather than 1:1.
- Total peritoneal fluid absorption — 1.07 mL/min (Imholz et al., Kidney Int 1993;44:1078-85, PMID 8264138). Note this is total absorption; true lymphatic flow is only 0.2–0.3 mL/min, and the model's variable name should not be read as claiming otherwise.
- Cavity geometry — an ovoid cavity divided into horizontal slabs, with per-slab area-weighted transport and implicit backward-Euler inter-layer diffusion, so a vertical concentration gradient can form and clearance is independent of the slab count.
- Whole-body physiology — intracellular potassium with aldosterone-mediated regulation, a skeletal reservoir for calcium/phosphate/magnesium, hepatic albumin and globulin replacement, endogenous acid production, dietary intake, residual renal function, stool and insensible losses, and osmotic thirst.
Literature calibration
Every constant checked against a published measurement, and the ones that are not measured are labelled as such.
The model carries an automated audit that compares each physical constant against its published range and fails the build if one drifts outside without a recorded justification. The point is not that every number is measured — several genuinely are not — but that the unmeasured ones are named rather than quietly presented as if they were.
| Constant | Model value | Published range | Status | Source |
|---|---|---|---|---|
| MTAC urea | 20.000 mL/min | 15.9-30.0 | verified | Selgas 2005: 22.9 +/- 7.04 mL/min |
| MTAC glucose | 9.000 mL/min | 7.0-11.0 | verified | size-ordered against measured creatinine MTAC 9-11 mL/min (113 Da); glucose at 180 Da must be lower. Calibrated to the Twardowski PET (test_pet_twardowski.py), the direct observable |
| MTAC sodium | 4.500 mL/min | 3.5-6.0 | verified | Oberg & Rippe 2017 (PMC5733752 T1), human: PS for Na+ and anions = 4.5 mL/min (DIRECT) |
| MTAC potassium | 10.000 mL/min | 5.0-15.0 | inferred | INFERRED from the small-monovalent-ion argument — NO measured source exists for potassium |
| lymphatic absorption | 1.070 mL/min | 1.0-1.35 | verified | Imholz 1993 1.07+/-0.18; Monquil 1995 1.01-1.34; Rippe 2001 ~1 |
| reflection sigma glucose | 0.049 | — | not verified | Rippe 2004 (Perit Dial Int 24(1):10-27, PMID 15104333) CONFIRMED as a human CAPD three-pore paper; numeric value NOT yet read from the paywalled full text — physics_core.py:20 |
| reflection sigma Na | 0.05 | — | not verified | Rippe 2004 (Perit Dial Int 24(1):10-27, PMID 15104333) CONFIRMED as a human CAPD three-pore paper; numeric value NOT yet read from the paywalled full text |
| reflection sigma albumin | 0.84 | — | not verified | Rippe 2004 (Perit Dial Int 24(1):10-27, PMID 15104333) CONFIRMED as a human CAPD three-pore paper; numeric value NOT yet read from the paywalled full text |
| sieving Na (convective) | 0.550 - | 0.39-0.71 | verified | derived from Bernardo 2012 FWT 0.45+/-0.16 -> Na sieving 1-FWT = 0.39-0.71 (centre 0.55); Helman 2024 PMC10914194 independently puts free-water transport at a fixed 40-50%% of UF and adopts 50%%, implying 0.50-0.60 — the two agree on ~0.55 |
| cp_beta_ref | 1 | — | not verified | SEARCHED AND NOT FOUND 2026-07-19 — do not repeat these dead ends: PubMed returns a CFD paper that explicitly AVOIDS film theory, and two targeted PubMed queries returned ZERO results (it is a chemical-engineering topic, barely indexed in a biomedical database); MDPI and pubs.acs.org both 403; lenntech and DuPont design-manual URLs 404. The right sources are J. Membrane Science or a manufacturer design manual, neither reachable from the allowed domains. DOES NOT BLOCK ANY DECISION: exp_polarization.py sweeps 1.0-1.4 and the conclusion (2 passes fails, 3 passes holds) is IDENTICAL at every point in that range. |
| Kf | 0.08 mL/min/mmHg | — | not verified | human LpS not located in the 2026-07-18 fetch (the hit was Zakaria & Rippe 1993, a RAT study). Open item — do not cite a human source for this until one is actually read. |
| R*T (van't Hoff) | 19.342 mmHg/(mmol/L) | 19.2-19.5 | verified | R=62.3637 L.mmHg/(mol.K) x T=310.15 K / 1000 — arithmetic, not empirical |
| net endogenous acid | 0.800 mmol/kg/d | 0.7-1.0 | verified | Remer & Manz 1995 PMID 7797810 and Frassetto 1998 PMID 9734733 give 0.7-1.0 mEq/kg/d on a Western diet; dialysis cohorts measure 42.7 +/- 10.1 (HD) and 58.2 +/- 24.3 (CKD) mEq/d (PMID 26508542). 0.80 mmol/kg/d gives 56 mEq/d at 70 kg. |
Results — PD20, twenty-five patients, thirty days
A deliberately varied cohort: typical, high and low transporters, anuric, small and large body size, high-MTAC, and diabetic.
Each patient is simulated minute by minute for 30 days with dietary intake, residual renal function where present, osmotic thirst, endogenous acid production and stool losses all active. The figures below are the pinned published outcomes — an automated test re-runs the whole cohort and fails if any of them moves.
| Patient | Na mmol/L | K mmol/L | HCO₃ mmol/L |
BUN mg/dL | Glucose mmol/L | Cum. UF L/30d |
Glucose abs. g/day | Net Na mmol/day |
|---|---|---|---|---|---|---|---|---|
| P1_typical_M70 | 141.87 | 4.874 | 23.95 | 48.6 | 6.44 | +62.53 | 109.48 | +3.47 |
| P2_high_transporter | 141.48 | 4.779 | 24.67 | 48.1 | 7.06 | +71.21 | 167.20 | +3.28 |
| P3_low_transporter | 142.07 | 4.959 | 22.11 | 55.2 | 5.92 | +58.39 | 71.09 | +3.62 |
| P4_anuric | 141.72 | 5.136 | 23.53 | 59.4 | 6.60 | +78.51 | 125.01 | +3.37 |
| P5_smaller_F50 | 143.06 | 4.946 | 25.50 | 38.0 | 6.88 | +52.10 | 86.23 | +3.27 |
| P6_large_M90 | 141.39 | 4.813 | 22.37 | 62.5 | 6.40 | +76.94 | 136.42 | +3.50 |
| P7_small_M55 | 142.48 | 4.934 | 25.05 | 38.0 | 6.36 | +47.20 | 81.55 | +3.43 |
| P8_anuric_small_F45 | 143.45 | 5.316 | 25.10 | 45.0 | 6.80 | +60.68 | 74.39 | +3.23 |
| P9_HighMTAC_F60 | 141.96 | 5.032 | 25.90 | 41.7 | 8.26 | +72.22 | 177.15 | +2.93 |
| P11_anuric_M95 | 141.29 | 5.069 | 21.23 | 78.4 | 6.35 | +91.19 | 139.23 | +3.46 |
| P12_anuric_F48_low | 143.23 | 5.297 | 24.88 | 46.8 | 6.79 | +62.66 | 78.88 | +3.26 |
| P15_highMTAC_M85 | 141.27 | 4.842 | 24.05 | 57.3 | 7.20 | +83.92 | 201.70 | +3.40 |
| P16_lowMTAC_F55 | 143.04 | 5.009 | 23.57 | 46.2 | 6.19 | +49.96 | 60.19 | +3.49 |
| P17_resid_M65 | 142.05 | 4.882 | 24.54 | 42.5 | 6.43 | +53.69 | 100.99 | +3.48 |
| P18_resid_F70 | 142.33 | 4.890 | 24.36 | 46.4 | 6.87 | +60.25 | 118.94 | +3.67 |
| P19_small_anuric_M50 | 142.44 | 5.189 | 25.78 | 41.0 | 7.04 | +65.63 | 111.57 | +3.17 |
| P20_large_anuric_F88 | 141.50 | 5.038 | 22.78 | 67.3 | 7.03 | +87.13 | 160.92 | +3.28 |
| P21_mid_F62 | 142.57 | 4.929 | 24.74 | 44.8 | 6.91 | +60.31 | 107.95 | +3.52 |
| P22_mid_M78 | 141.86 | 4.961 | 22.56 | 61.8 | 6.29 | +74.36 | 109.80 | +3.81 |
| P24_lowMTAC_anuric_M82 | 141.73 | 5.226 | 20.08 | 82.9 | 5.96 | +83.32 | 86.30 | +3.63 |
| P25_highMTAC_anuric_F52 | 142.29 | 5.053 | 26.51 | 36.2 | 8.52 | +67.30 | 166.70 | +2.85 |
| P26_tiny_F45_resid | 143.36 | 4.942 | 26.27 | 31.4 | 7.01 | +42.92 | 82.99 | +3.20 |
| P27_big_M92_resid | 141.47 | 4.891 | 21.89 | 69.3 | 6.38 | +83.53 | 138.02 | +3.73 |
| P29_mid_anuric_M68 | 141.72 | 5.104 | 24.45 | 52.8 | 6.91 | +76.66 | 140.61 | +3.26 |
| P30_mid_F75_resid | 142.13 | 4.904 | 23.40 | 55.0 | 6.71 | +69.23 | 116.77 | +3.61 |
Body water is held to within a fraction of a litre over the month in every patient, with no restriction placed on what they drink — the cohort drinks 2.9–3.9 L/day (thirst plus water of food and oxidation water).
Per-patient outcomes
Thirty-day trajectories, all ten patients overlaid
Each line is one patient, sampled hourly. Shaded band = reference range. Per-patient detail, every species, is on the patient data pages.
Water, consumables and clearance
The ledger a wearable device is judged on: the water it wastes, the solute it must carry, and the clearance it delivers.
| Patient | Device water L/day | Weekly Kt/V | Fresh supply L/day | Mixer glucose g/day | Mixer Na g/day | Mixer Cl g/day |
|---|---|---|---|---|---|---|
| P11_anuric_M95 | 4.84 | 1.83 | 5.69 | 478 | 97 | 122 |
| P12_anuric_F48_low | 4.66 | 3.86 | 5.51 | 350 | 100 | 126 |
| P15_highMTAC_M85 | 4.79 | 2.59 | 5.84 | 520 | 98 | 123 |
| P16_lowMTAC_F55 | 4.59 | 3.91 | 5.99 | 299 | 102 | 127 |
| P17_resid_M65 | 4.62 | 3.58 | 6.17 | 350 | 101 | 127 |
| P18_resid_F70 | 4.67 | 3.89 | 6.17 | 387 | 101 | 126 |
| P19_small_anuric_M50 | 4.66 | 3.71 | 5.51 | 385 | 100 | 125 |
| P1_typical_M70 | 4.67 | 3.09 | 6.01 | 378 | 100 | 126 |
| P20_large_anuric_F88 | 4.82 | 2.61 | 5.67 | 490 | 98 | 123 |
| P21_mid_F62 | 4.66 | 4.04 | 5.96 | 375 | 101 | 126 |
| P22_mid_M78 | 4.73 | 2.38 | 5.93 | 406 | 99 | 124 |
| P24_lowMTAC_anuric_M82 | 4.78 | 1.71 | 5.62 | 402 | 98 | 123 |
| P25_highMTAC_anuric_F52 | 4.67 | 5.06 | 5.52 | 445 | 100 | 125 |
| P26_tiny_F45_resid | 4.57 | 5.87 | 6.02 | 313 | 102 | 128 |
| P27_big_M92_resid | 4.79 | 2.10 | 5.94 | 459 | 98 | 123 |
| P29_mid_anuric_M68 | 4.73 | 2.83 | 5.58 | 440 | 99 | 124 |
| P2_high_transporter | 4.71 | 3.13 | 5.91 | 456 | 99 | 125 |
| P30_mid_F75_resid | 4.71 | 3.24 | 5.96 | 404 | 100 | 125 |
| P3_low_transporter | 4.63 | 2.70 | 6.08 | 327 | 101 | 126 |
| P4_anuric | 4.75 | 2.49 | 5.60 | 430 | 99 | 124 |
| P5_smaller_F50 | 4.61 | 4.80 | 5.86 | 334 | 101 | 127 |
| P6_large_M90 | 4.75 | 2.35 | 6.00 | 441 | 99 | 124 |
| P7_small_M55 | 4.58 | 4.03 | 6.13 | 315 | 102 | 128 |
| P8_anuric_small_F45 | 4.65 | 4.02 | 5.50 | 342 | 100 | 126 |
| P9_HighMTAC_F60 | 4.71 | 4.36 | 5.55 | 467 | 99 | 125 |
Operating point: PD20_BASE_TOTAL=34, PD20_CIRCUIT=highrec, PD20_DWELL_PEAK_FRAC=0.035, PD20_FLOW_BOOST=0.023, PD20_RECOVERY=0.93, PD20_REGEN=ro, PD20_RESERVOIR_L=0, PD20_RO_PASSES=2, PD20_RO_PRESSURE=120. Product gates: device water ≤ 5.0 L/day (S2 — RO reject, not the sink figure that includes patient urine); weekly Kt/V ≥ 1.70, the ISPD adequacy floor (S3).
Glucose burden, device vs conventional APD
Head-to-head on the same thirty patients: PD20 118 g/day of glucose absorbed by the patient, against 128 g/day absorbed on contemporary automated PD (74–204 g/day), which places 279 g/day (206–352) of glucose in bags. The continuous low-sodium device removes sodium by exchange rather than by concentrating an osmotic gradient, so it pays a lower glucose cost for the same fluid control.
Contemporary peritoneal dialysis, same thirty patients
The comparator arm: a conventional night cycler, five 2-litre exchanges over nine hours, dry day, filling and draining through the bottom lumen as a real catheter does.
The same thirty patients are run on conventional automated peritoneal dialysis, each on the bag strength that suits them best (1.5%, 2.5% or 4.25% dextrose), at three different drinking behaviours. A prescription counts as held only if body water stays within ±1.5 L over 30 days — dehydration counts as failure exactly as overload does.
| Drinking behaviour | Intake | Held | Died |
|---|---|---|---|
| free | thirst-driven | 3/10 | 0/10 |
| moderate | 1.5 L/day | 1/10 | 6/10 |
| low | 1.0 L/day | 0/10 | 10/10 |
Outcome by drinking behaviour
Fluid restriction does not fail gently — it kills by hypernatraemia
This is the result that most deserves attention, and it is not the one we expected. At a restricted intake of 1.0 L/day, every patient dies, and none of them dies of dehydration. Body water at death spans −3.5 to +1.0 L, nowhere near the fatal volume threshold. They die of serum sodium reaching 165 mmol/L.
| Patient | Bag | UF L/day | Δ body water L | Outcome |
|---|---|---|---|---|
| P1_typical_M70 | 2.5% | -0.07 | -2.35 | DIED d8.3 FATAL high Sodium=165.0 (>165) |
| P2_high_transporter | 2.5% | -0.23 | 0.35 | DIED d11.7 FATAL high Sodium=165.0 (>165) |
| P3_low_transporter | 2.5% | 0.07 | -3.49 | DIED d6.7 FATAL high Sodium=165.0 (>165) |
| P4_anuric | 2.5% | 0.06 | 1.04 | DIED d11.2 FATAL high Sodium=165.0 (>165) |
| P5_smaller_F50 | 2.5% | -0.08 | -1.24 | DIED d7.3 FATAL high Sodium=165.0 (>165) |
| P6_large_M90 | 2.5% | -0.04 | -1.89 | DIED d9.0 FATAL high Sodium=165.0 (>165) |
| P7_small_M55 | 2.5% | -0.16 | -2.86 | DIED d7.2 FATAL high Sodium=165.0 (>165) |
| P8_anuric_small_F45 | 2.5% | 0.13 | 0.18 | DIED d8.2 FATAL high Sodium=165.0 (>165) |
| P9_HighMTAC_F60 | 4.25% | 0.82 | -4.25 | DIED d6.3 FATAL high Sodium=165.0 (>165) |
| P10_diabetic_M80 | 2.5% | 0.06 | 1.03 | DIED d11.3 FATAL high Sodium=165.0 (>165) |
The mechanism is visible in the ultrafiltration column. Restricting intake collapses ultrafiltration to zero or below, against 0.72–2.09 L/day when the same patients drink freely. Conventional peritoneal dialysis removes sodium principally by convection — solvent drag with the ultrafiltrate — so when ultrafiltration stops, sodium removal stops with it, whatever the dialysate sodium concentration is. Sodium then accumulates while body water stays normal.
And the process is self-reinforcing: less body water raises serum osmolality, which shrinks the dialysate-to-serum osmotic gradient, which further reduces ultrafiltration, which removes still less sodium. That spiral is what turns six deaths at 1.5 L/day into ten at 1.0 L/day.
Validation — does it behave like the patients we know?
Forty arms: five levels of renal function × two potassium diets × two fluid-compliance behaviours × two phosphate-management behaviours.
A simulator that reproduces its own assumptions proves nothing. The test that matters is whether it reproduces the behaviour of patients whose direction of travel is already known clinically. Each expectation below is asserted in code, and the run exits with an error if the engine contradicts it.
| Verdict | Clinical expectation | Measured |
|---|---|---|
| OK | BUN rises as renal function falls | normal -> anuric: 30 < 61 < 70 < 73 < 75 mg/dL |
| OK | serum K rises with dietary K (anuric) | delta +1.21 mmol/L |
| OK | that rise is STEEPEST when anuric | anuric +1.21 vs normal +0.93 mmol/L — residual renal secretion is the missing buffer |
| OK | fluid non-compliance gains water (anuric) | delta +5.87 L |
| OK | and it hurts the anuric patient more | anuric +5.87 L vs normal +0.90 L |
| OK | serum phosphate rises with intake | delta +1.05 mmol/L |
The phosphate expectation is worth singling out: conventional peritoneal dialysis must fail to control phosphate in a non-compliant anuric patient, because that is precisely why phosphate binders exist. The engine reproduces that failure, which is also what settles an open question about the phosphate transport coefficient — a higher published value would have controlled phosphate without binders, and would therefore have been wrong.
Reproduce every number on this page
The simulator is deterministic. Same inputs, same outputs, bit for bit.
Environment
# Python 3.11+, numpy. Single-threaded execution is required for bit-reproducibility.
export OMP_NUM_THREADS=1 OPENBLAS_NUM_THREADS=1 MKL_NUM_THREADS=1 PARALLEL=1
The full verification sequence, in order
# 1. The automated test suite — 53 enforcing tests covering conservation, every flux law,
# the literature calibration, device blindness, and the pinned published results.
bash run_fullsuite.sh
# 2. Regenerate the controller from the physics (deterministic given unchanged physics).
# Trained to a SEPARATE path so the shipped controller is never overwritten — the trainer
# refuses to overwrite the shipped model by design (it is what every published number was
# produced with).
PD20_MODEL=pretrained_models/physics_nn_repro.json python3 pretrain_robust.py
# 3. Re-run the thirty-patient cohort and regenerate the per-patient report data.
python3 run_cohort.py
python3 gen_report_data.py
# 4. Confirm every published number still reproduces.
python3 test_published_regression.py
# 5. The contemporary-PD comparator arm.
python3 exp_conventional_apd.py
# 6. The forty-arm clinical validation matrix.
python3 exp_validation_matrix.py
Verification state of this build
| Test suite | 53 passed, 0 failed |
|---|---|
| Cohort | 30 of 30 patients survive 30 days; conservation residual ~10-8 |
| Controller build | md5 2c0ac24a96fb2bd01ab79965c516cff5 |
| Solute species | 15 |
| Peritoneal Kf | 8.00e-05 L/min/mmHg per unit area |
| Total peritoneal absorption | 0.00107 L/min |
The controller build hash is stamped because the trained controller is a function of the physics: if a physical constant changes, retraining produces a different controller and every downstream number moves. Quoting a result without the hash of the controller that produced it is not reproducible.
What is withheld, and what is not
Stated plainly so that nobody has to guess where the line is.
Fully disclosed
- The complete physics model — every flux law, every constant, every citation, and every limitation, as set out above.
- All simulation results, for both the device and the contemporary comparator, including the results that are unflattering.
- The full reproduction sequence, so a third party can rebuild every figure independently.
- The device's operating principle: continuous-flow circulation with reverse-osmosis regeneration of spent dialysate.
- The control interface — what the device is permitted to sense (bulk physical properties of the circulating fluid, and patient weight) and what it commands. This is disclosed because it is what makes the results reproducible and because the concentration-blind constraint is itself part of the claimed invention.
Withheld as pending patent matter
- The control algorithm's internal structure, its gains and set-points, and the procedure used to build it from the physics.
This boundary is enforced mechanically, not by good intentions: an automated firewall scans every outward-facing artifact — including this page — for the withheld identifiers, for the numeric set-points, and for descriptions of the control logic written in plain English that a token scan would miss. The build fails if any of them appear.