Professional Documents
Culture Documents
A Performance Comparison Between Standard and Impulsive ZMPC On Type 1 Diabetic Patients
A Performance Comparison Between Standard and Impulsive ZMPC On Type 1 Diabetic Patients
Abstract—Type 1 diabetes mellitus is a worldwide chronic This technique was also adapted to impulsive controls systems
and autoimmune disease affecting almost 25 million individual (ICS) in [11], and a first attempt to control T1DM patients was
around the world. Particularly, in Colombia, it has an annual rate made in [12].
of growth of 3% - 5%. Current research in the treatment of this
illness is aimed at the implementation of the so-called Artificial The formulation proposed in [12] takes advantage of two
Pancreas, a device that allows the regulation of blood glucose underlying discrete-time systems (computed at the time in-
levels automatically. Recently, several model predictive control stants when the impulses are applied), to produce the so-called
strategies has been developed to accomplish that. In this work, a impulsive MPC (iZMPC); a controller that control the plant
performance comparison between a standard model predictive by impulses instead of continuous input actions.
control (MPC) and a novel impulsive zone MPC scheme is
made based on a novel long-term glucose insulin model. The In this work, both techniques, the standard ZMPC and the
proposed control strategies ensure the stability under moderate- iZMPC, are tested and compared here throughout 20 virtual
to-severe disturbances. A long-term scenario - including meals patients (but coming from real life data provided by the
- are simulated and tested in 20 virtual patients. The results ‘Centre Hospitalier de Nantes’, in Nantes-France, and the
appear to be satisfactory as long as every hyperglycemia and ‘Clı́nica Integral de Diabetes’ of Medellı́n, Colombia) and
hypoglycemia episodes are suitably controlled. The performance
comparison also shows that the standard MPC is 70% of the using a new T1DM model detailed in [13]. This model is
time in the target zone, while the iZMPC is 92.5%. based on the functional insulin therapy and has the advantage
of representing the patient realistically, which mainly means
I. I NTRODUCTION that it has a critically stable equilibrium manifold (instead of
Type 1 diabetes mellitus (T1DM) is a chronic and au- a stable one), and predicts the patient behavior for a long term
toimmune disease that cause progressive destruction of the (approximately 2 days). The model’s equilibrium corresponds
pancreatic β-cells. As a consequence, the natural endogenous to a basal insulin injection level, and small disturbances desta-
production of insulin disappears, thus resulting in a dysfunc- bilize the system producing both, hyper and hypoglycemia
tional glycemic regulation. In Latin America is estimated that episodes, if no actions are taken.
the prevalence of T1DM will increase by 250% over the next The iZMPC has the following interesting features: i) im-
20 years and its cost in health budget will be three times pulsive input due to the nature of the problem ii) artificial
higher. The inclusion of insulin pump therapy have had a variables, which give an enlarged domain of attraction (this
good acceptance due to the positive clinical results on diabetes allows use a shorter prediction horizon), and in consequence
control (quality of life and costs), but its performance in a reduced computational effort.
Colombia and Latin America is still not very well studied, The control-variability grid analysis (CVGA) [6] is used for
especially in outpatient routine [1]. measuring the quality of this closed-loop glucose control for
The idea of an artificial pancreas was envisioned more than the cohort of patients. This method is for the visualization of
50 years ago; it is a device that closes the loop between the extreme glucose excursions caused by a control algorithm
the measurements of continuous glucose monitoring system in a group of subjects, with each subject represented by one
(CGM) and insulin pump injection/infusion. Nowadays, model data point for any given observation period. This analysis
predictive control (MPC) has been the most developed control shows that the iZMPC controller has a better performance than
strategy for the artificial pancreas [2]–[6]. The standard zone the standard ZMPC because presents less hyper- and hypo-
MPC (ZMPC) is a type of model predictive control algorithm glycemia episodes with less time outside to the normoglycemia
that computes the optimal future inputs to maintain the pre- levels. Furthermore, it has a less pronounced peaks due to the
dicted output within a desired zone rather than at a single set- meals perturbations. The performance comparison shows that
point [7], [8]. An improved version of ZMPC is the one that the standard MPC is 70% of the time in the target zone, and
uses intermediary variables - additional variables forced to lie in contrast, the iZMPC is 92.5%.
in the system equilibrium subspace - and permits a significant This paper is organized as follows: Section 2 presents
enlargement of the controller domain of attraction [9], [10]. the T1DM patient model. Sections 3 describes the discrete
and impulsive schemes, and the MPC formulation for both above this safety range), and hyperglycemia is dangerous long
strategies. In Section 4, numerical results are presented and term. Constraints for both, states and inputs are considered, in
the comparison developed. Finally, the conclusions and per- such a way that u ∈ U, x ∈ X and r ∈ R, where U, X and
spectives are discussed. R are assumed to be polyhedrons.
Furthermore, the insulin infusion u is considered as the
II. T YPE 1 DIABETES MODEL
control variable, while the carbohydrate (CHO) in meals r
According to [13], the following affine continuous time is considered as a disturbance. This disturbance, however,
model is considered: is neither a completely known nor a completely unknown
ẋ(t) = Ax(t) + Bu u(t) + Br r(t) + E, x(0) = x0 , (1) disturbance. In fact, in this work that disturbance is assumed
unknown, which avoids the alternative to predict or anticipate
where the state x(t) = [G(t) I(t) I(t)˙ D(t) Ḋ(t)]0 , being G the disturbance effect. A completely different problem arises -
the glycemia (mg/dl), I the plasma insulin (insulinemia) (U/l) mainly in the context of predictive control - if disturbances
and D the digestion of CHO (g/dl). Furthermore, u(t) the (meals) are assumed to be (even partially) anticipated by
control input, is the insulin infusion rate (U), and the variable means of a signal entering the controller. This issue is not in
r(t) is the food intake (g) and also is taken as the disturbance. the scope of this paper, but a perspective for future research.
The corresponding model matrices are given by:
0 −ksi 0 1 0
III. C ONTROL ALGORITHM DESCRIPTION
0 0 1 0 0
1 2
− − A. Discrete time scheme
A = 0 Tu2 Tu 0 0 , (2)
0 0 0 0 1 The zero-order hold (ZOH) discretization is a standard
0 0 0 − T12 − T2r method used in ZMPC to obtain its necessary discrete-time
r
0 0 θ system [15]. Starting with the continuous model (1), the input
0 0 0 u(t) is taken constant as
ku
Bu = Vi Tu2 , Br = 0 , E = 0 ,
0 0 0 u(t) = u(kTs ), kTs 6 t < (k + 1)Ts (3)
kr
0 VB Tr2 0
where (kTs ) corresponds to the actual sampling instant, (k +
where ksi represents the sensitivity to insulin, Tu and kVui 1)Ts is the next one, and k ∈ N. An analytical solution to
are respectively the time constant and static gain of the the continuous state-space model (1) considering this input is
relationship between the input u(t) (insulin rate) and the given by:
insulinemia I(t), with Vi being the insulin distributed volume,
and Tr and VkBr are respectively the time constant and static t
Z
A(t−kTs )
gain of the relationship between the CHO in meal r(t) and the x(t) = e x(kTs ) + eA(t−τ ) Bu u(τ )dτ (4)
kTs
digestion of CHO, D(t), with VB being the blood volume. Z t Z t
A(t1 −τ )
Furthermore, the parameter θ = k1 − kb is the difference + e Br r(τ )dτ + E eA(t1 −τ ) dτ.
between the liver endogenous glucose production k1 and the kTs kTs
glucose absorption rate by the brain kb .
If the latter equation is evaluated at t = (k+1)Ts , the discrete-
The main advantages of this model is that it is an integrating
time system is obtained, namely
model (A has an eigenvalue at zero, which means that it is not
stable) and so it better represents the evolution of the variable
in real life diabetic patients. For instance, any equilibrium x(k + 1) = Ad x(k) + Bud u(k) + Brd r(k) + Ed , (5)
point corresponding to the fasting state (rs = 0) is given
by an arbitrary value of G, fixed values for the other states, where the
R Tscorresponding discrete matrices are Ad = eATs and
A(Ts −τ )
∆ Bud = 0 e B dτ = A−1 (eATs −I)Bu , if A−1 exists,
and a fixed (and unique) value of insulin, us = ub , which R Ts A(T −τ ) u
is known as the basal insulin rate. These characteristics, that Brd = 0 e s Br dτ and Ed = E.
make the model essentially different from other models used
in the literature (mainly the Bergman model, [14]), allow us to B. Impulsive scheme
make long term predictions. This way, it is argued that every
undesirable episode can be better anticipated and corrected. If the insulin infusion u is assumed to be injected to the
∆
The general control objective is to maintain the glycemia system only at certain time instants given by τk = kT , where
in a safety range, X T ar , while keeping the other variables T is the fixed period, and k ∈ N, then it is possible to work
fulfilling the constraints, which are mainly positive values. under the impulsive system framework.
An interesting point is that the hypoglycemia episodes (when Formally, assume that the input is given by
glycemia is below this safety range) are more dangerous in
short time than hyperglycemia episodes (when the glycemia is u(t) = u(kT )δ(t − kT ), t ∈ [kT, (k + 1)T ], k ∈ N, (6)
where δ(t) is a generalized function (or distribution) Dirac 1) Underlying discrete time subsystems: According to the
delta1 , that fulfills δ(t) = ∞ for t = 0, δ(t) = 0 for t 6= 0, impulsive scheme developed in [11], two underlying discrete-
and time subsystems associated to (12) can be defined to charac-
terize the states x(τk ) and x(τk+ ) evolution2 :
Z ∞
g(ζ)δ(ζ)dζ = g(0), (7) x• (k+1) = A• x• (k)+Bu• u• (k)+Br• r• (k)+E • , x• (0) = x(τ0 ),
−∞
x◦ (k+1) = A◦ x◦ (k)+Bu◦ u◦ (k)+Br◦ r◦ (k)+E ◦ , x◦ (0) = x(τ0+ ),
for all continuous, compactly supported, function g. This way, ∆
the solution of (1) at each periods T can be divided into where A• = A◦ = Ad = eAT , Bu• = eAT Bu , Bu◦ = Bu .
two parts, the first one, describing the system in the period Furthermore, the input and disturbance are related by u◦ (k +
∆
[kT, kT + ∆T ], and the second one describing the system in 1) = u• (k) = u(τk ), r◦ (k) = r• (k) = r(k), and E • = E ◦ =
R T Aζ ∆ T
e dζE, Br• = Br◦ = 0 eAζ dζBr .
R
the period (kT + ∆T, (k + 1)T ), for a positive and arbitrary 0
small ∆: 2) Extended equilibrium for the impulsive representation:
The extended equilibrium points of the impulsive representa-
ϕ(t; x(kT ), u, r) = eA(t−kT ) x(kT ) (8) tion are characterized by the equilibrium points of the Under-
Z kT +∆T lying Subsystems, (x•s , u•s , rs• ) and (x◦s , u◦s , rs◦ ), respectively,
+ eA(t−ζ) Bu u(ζ)δ(ζ − kT )dζ in such a way that they must fulfill the conditions:
kT
Z kT +∆T
+ eA(t−ζ) Br r(ζ)dζ x•s = A• x•s + Bu• u•s + Br• rs• + E • ,
kT
Z kT +∆T x◦s = A◦ x◦s + Bu◦ u◦s + Br◦ rs◦ + E ◦ .
+ eA(t−ζ) dζE, So, the equilibrium sets corresponding to the two subsystems
kT
are given by
for t ∈ [kT, kT + ∆], and
∆
Xs• = {x•s ∈ X : ∃u•s ∈ U, rs• = 0 (13)
A(t−kT )
ϕ(t; x(kT + ∆T ), u, r) = e x(kT + ∆T ) (9) such that A• x•s + Bu• u•s + Br• rs• + E • = 0} ,
Z (k+1)T ∆
+ eA(t−ζ) Br r(ζ)dζ Xs◦ = {x◦s ∈ X : ∃u◦s ∈ U, rs◦ = 0 (14)
kT +∆T
Z (k+1)T such that A◦ x◦s + Bu◦ u◦s + Br◦ rs◦ + E ◦ = 0} ,
∆ ∆
+ eA(t−ζ) dζE, Us• = {u•s } = {u•b } , Us◦ = {u◦s } = {u◦b } . (15)
kT +∆T
Furthermore, given that u◦ (k + 1) = u• (k) and r◦ (k) =
for t ∈ (kT + ∆, (k + 1)T ). r (k) by definition (and E ◦ = E • ), we have that at steady
•
Now, if we consider the limits of this solution for ∆ → 0, state it is u•s = u◦s and rs• = rs◦ . For simplicity, the equilibrium
it follows that input and disturbance of both subsystems are denoted as u• (k)
and rs• , respectively. This means that it is necessary to find
∆
x(kT + ) = lim ϕ(t; x(kT ), u, r) = x(kT ) + Bu u(kT ), (10) variables (x•s , x◦s , u•s , rs• ) fulfilling
∆→0
BG [mg/dL] % time
< 80 0.67 13.96
< 70 0.11 6.11
<110
>110 90 70 <50 < 60 0.00 4.08
< 50 0.00 3.41
Minimum BG > 180 5.37 10.30
> 250 3.35 6.66
Fig. 1. CVGA for patients controlled by discrete ZMPC (dots) and impulsive > 300 2.80 5.69
ZMPC (open circles). > 350 2.42 2.80
> 450 1.81 0.45
< 80 6 1
# Events BG [mg/dL]
< 70 4 0
scenarios, since the patients are assumed hospitalized, regular < 60 1 0
meals are considered: the breakfast, the launch, the dinner, and < 50 0 0
< 40 0 0
some snacks between meals. > 180 50 77
The state and input constraints are given by X = {x : > 250 11 19
[0 0 − 0.1 0 − 0.1]T x [500 .5 0.1 1 0.1]T } and > 300 5 14
> 350 1 10
U = {u : 0 ≤ u ≤ 30}, respectively. The state target window > 450 0 4
should be decided by the treating physician. In the simulation BG [mg/dL]: Mean 121.89 152.9297
below it is defined by X T = {x : [80 0 − 0.1 0 − 0.1]T BG [mg/dL]: Min 66.00 9.5135
BG [mg/dL]: Max 390 470.8716
x [100 0.2 0.05 0.5 0.05]T }. It is clear that, if the glycemia
remains most of the time within the boundaries of X T , then
the insulin therapy is satisfactory. the performances of the discrete and impulsive ZMPC, the
The therapeutic windows (target zone) for the glycemia summary outcome presented in Table I for iZMPC shows an
values is selected to be [80 − 100], which is a zone strictly accurate control in the 60% cases and a benign control for the
inside the normoglycemia zone of [60 − 140]. This is so 92.5% and also, only have two cases in over-correction and
to improve the performance, since the controller makes no one case in failure to deal with hyperglycemia, and zero cases
distinction between points inside the zone, and so, it tends in the zone of hypoglycemia. The summary outcome I for the
to maintain the glycemia at the boundary of the therapeutic discrete ZMPC shows a regular accurate control 17.5% and
window (not at a middle point) that is closer to the current a benign control for the 70%; however, this strategy shows a
value. If a disturbance pushes the system above the zone, the 20% over-corrections of hyper- and hypoglycemia and a 7.5%
controller only steers the system back to the upper bound of of failure to deal with hypoglycemia and one case of erroneous
the zone. As a result, any disturbance in the same direction control. See also Table 2. Figures 2-5 shows the evolution of
will produce a transitory evolution that can take the glycemia glycemia and the control effort for paciente IF2 (see [13]).
far from the upper bound. So selecting the bounds of the target
zone inside the normoglycemia zone could be a good practice. V. C ONCLUSIONS
For the iZMPC, the control/prediction horizon N should be A comparison of the performance between discrete and
large enough to account for the entire insulin effect (given impulsive form on the design of ZMPC for the regulating
that overdoses are hard to compensate, because of its posi- glycemia in type I diabetic patients has been tackled in this
tiveness). So, according to the insulin response settling time, paper. The main differences between this ZMPC controllers
the control/prediction horizon (which is the number of periods are: i) the iZMPC controller do not need a permanent insulin
considered for the predictions) is selected in these simulations injection in contrast to the discrete ZMPC, and the insulin
to be N ≈ STuT×60 , which is only a practical rule. Note is delivered by boluses, preventing insulin overdoses, ii) both
however that, as it is usual in MPC, the use of larger horizons controllers can maintains the glycemia levels in the normal
N needs a high computational effort. The iZMPC parameters range (70 ∼ 140mg/dl) but the iZMPC obtain a better
are selected to be: Q = 500; R = 1; p = 500000. A detailed regulation of the glycemic in the accurate zone (see Fig 1)
analysis for the selection of these parameters, according to the thanks to the artificial variables.
patient parameters, still needs to be done. In general, the CVGA analysis showed that the iZMPC
In the Fig 1, the CVGA method is applied to compare controller had a better performance to maintain the glucose
150
[3] B. Grosman et al., “Zone model predictive control: a strategy to
240 150 minimize hyper-and hypoglycemic events,” Journal of diabetes science
CHO count
220 Impulsive ZMPC
and technology, vol. 4, no. 4, pp. 961–975, 2010.
128
Discrete ZMPC 125 [4] R. Hovorka et al., “Nonlinear model predictive control of glucose con-
200 centration in subjects with type 1 diabetes,” Physiological measurement,
180
vol. 25, no. 4, p. 905, 2004.
100
Glycemia (mg/dl)
CHO (g)
Hyperglycemia Diabetes Science and Technology, vol. 7, no. 6, pp. 1446–1460, 2013.
140
[6] L. Magni et al., “Model predictive control of glucose concentration in
120 type i diabetic patients: An in silico trial,” Biomedical Signal Processing
Normoglycemia and Control, vol. 4, no. 4, pp. 338–346, 2009.
50
100
[7] E. Camacho and C. Alba, Model Predictive Control, ser. Advanced
80 Textbooks in Control and Signal Processing. Springer London, 2013.
Hypoglycemia 15 15
20 [8] J. J. Lee et al., “Design and in silico evaluation of an intraperitoneal-
60 subcutaneous (ip–sc) artificial pancreas,” Computers and Chemical En-
7.5
40 0 gineering, vol. 70, pp. 180 – 188, 2014, manfred Morari Special Issue.
0 5 10 15 20 25 30 35 40 45 50 [9] A. Ferramosca, D. Limon, A. H. González, D. Odloak, and E. F.
Camacho, “MPC for tracking zone regions,” Journal of Process Control,
vol. 20, no. 4, pp. 506–516, 2010.
Fig. 2. Glycemia regulation, IF2 patient. [10] A. H. Gonzalez and D. Odloak, “A stable MPC with zone control,”
Journal of Process Control, vol. 19, no. 1, pp. 110–122, 2009.
[11] P. S. Rivadeneira, A. Ferramosca, and A. H. Gonzalez, “Mpc with
state window target control in linear impulsive systems,” in 5th IFAC
18 Impulsive ZMPC Conference on Nonlinear Model Predictive Control (NMPC’15), 2015,
Discrete ZMPC pp. 508–513.
16 [12] ——, “Impulsive zone model predictive control with application to type
I diabetic patients,” in Proceedings of the 2016 IEEE Multi-Conference
insulin injection (U/h)
14
on Systems and Control, Buenos Aires, 2016, pp. 544–549.
12 [13] N. Magdelaine et al., “A long-term model of the glucose–insulin dynam-
ics of type 1 diabetes,” IEEE Transactions on Biomedical Engineering,
10 vol. 62, no. 6, pp. 1546–1552, 2015.
8
[14] R. Bergman, P. L.S., and C. C., “Physiologic evaluation of factors con-
trolling glucose tolerance in man: measurement of insulin sensitivity and
6 beta-cell glucose sensitivity from the response to intravenous glucose,”
J Clin Invest, vol. 68, no. 6, pp. 456–67, 1981.
4
[15] V. Yaramasu and B. Wu, Model Predictive Control of Wind Energy
2 Conversion Systems. John Wiley & Sons, 2016.
[16] R. Gondhalekar, E. Dassau, H. C. Zisser, and F. J. Doyle III, “Periodic-
0 zone model predictive control for diurnal closed-loop operation of an
0 5 10 15 20 25 30 35 40 45
Tiempo (h) artificial pancreas,” Journal of Diabetes Science and Technology, vol. 7,
no. 6, pp. 1446–1460, 2014.
[17] B. Grosman, E. Dassau, H. C. Zisser, L. Jovanovic, and F. J. Doyle
Fig. 3. Administered insulin, IF2 patient. III, “Zone model predictive control: a strategy to minimize hyper- and
hypoglycemic events,” Journal of Diabetes Science and Technology,
vol. 4, no. 4, pp. 961–975, 2010.
levels in the accurate zone of control (90 mg/dl−180 mg/dl). [18] F. J. Doyle III, “Zone model predictive control of an artificial pancreas,”
The discrete ZMPC shows a good control of glucose in a in Proceedings of the 10th World Congress on Intelligent Control and
Automation,Beijing, China, July 6-8 2012.
less strict zone (70 mg/dl − 300 mg/dl), and with a risk of
hypoglycemic/hyperglycemic episodes.
The main drawback of ZMPC is the tuning of its parameters,
whose task may be not trivial. This set-up allows it a variety of
closed-loop behaviors, and several studies can be done to find
a method to tune the controller according to the significant
model parameters of the patient, that will be pursued in a
future work.
The simulations has good results in these small cohort of
virtual patients; however, for future studies it is important to
perform a validation with a larger cohort of patients, especially
those brought by the FDA (Food and Drug Administration)
accepted ‘UVA/Padova’ simulator of diabetic patients.
R EFERENCES
[1] A. E. Gómez et al., “Numerical and clinical precision of continuous
glucose monitoring in Colombian patients treated with insulin infusion
pump with automated suspension in hypoglycemia,” Endocrinologı́a y
Nutrición (English Edition), vol. 62, no. 10, pp. 485–492, 2015.
[2] F. J. Doyle et al., “Closed-loop artificial pancreas systems: engineering
the algorithms,” Diabetes care, vol. 37, no. 5, pp. 1191–1197, 2014.