jxx123 / simglucose

A Type-1 Diabetes simulator implemented in Python for Reinforcement Learning purpose
MIT License
232 stars 111 forks source link

Subcutaneous glucose computation: Use plasma glucose concentration (G) instead of plasma glucose mass (Gp) #20

Closed monal closed 3 years ago

monal commented 3 years ago

As per equation A17 in the paper: Man, Chiara Dalla, et al. "The UVA/PADOVA type 1 diabetes simulator: new features." Journal of diabetes science and technology 8.1 (2014): 26-34.

dGs(t)/dt = - ksc Gs(t) + ksc G(t)

Hence, in t1dpatient.py, line195,

wouldn't the computation be: dxdt[12] = (-params.ksc x[12] + params.ksc x[3]/params.Vg) instead of dxdt[12] = (-params.ksc x[12] + params.ksc x[3])?

Thanks!

monal commented 3 years ago

Looks like it might be a typo in the original paper. The correct equations can be found in the following paper: Messori, Mirko, et al. "Individualized model predictive control for the artificial pancreas: In silico evaluation of closed-loop glucose control." IEEE Control Systems Magazine 38.1 (2018): 86-104.