From b07a5d7551b826409be08b4b695896d1c42887a5 Mon Sep 17 00:00:00 2001 From: edger-asiimwe Date: Sat, 16 Mar 2024 14:05:56 +0300 Subject: [PATCH] Refactored kgut parameters --- simglucose/patient/t1dpatient.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/simglucose/patient/t1dpatient.py b/simglucose/patient/t1dpatient.py index fefa39a8..3f233556 100644 --- a/simglucose/patient/t1dpatient.py +++ b/simglucose/patient/t1dpatient.py @@ -133,8 +133,8 @@ def model(t, x, action, params, last_Qsto, last_foodtaken): dxdt[0] = -params.kmax * x[0] + d if Dbar > 0: - aa = 5 / 2 / (1 - params.b) / Dbar - cc = 5 / 2 / params.d / Dbar + aa = 5 / (2 * Dbar * (1 - params.b)) + cc = 5 / (2 * Dbar * params.d) kgut = params.kmin + (params.kmax - params.kmin) / 2 * ( np.tanh(aa * (qsto - params.b * Dbar)) - np.tanh(cc * (qsto - params.d * Dbar)) + 2)