paper on type 1 diabetes
TRANSCRIPT
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 1/9
Model predictive control of glucose concentration in type I diabetic patients:
An in silico trial
L. Magni a,*, D.M. Raimondo a, C. Dalla Man b, G. De Nicolao a, B. Kovatchev c, C. Cobelli b
a Dipartimento di Informatica e Sistemistica, University of Pavia, via Ferrata 1, I-27100 Pavia, Italyb Department of Information Engineering, University of Padova, Via Gradenigo 6/B, I-35131 Padova, Italyc University of Virginia Health System, Box 800137, Charlottesville, VA 22908, USA
1. Introduction
Diabetes (medically known as diabetes mellitus) is the name
given to disorders in which the body has trouble regulating its
blood glucose, or blood sugar, levels. There are two major types of
diabetes: type I diabetes and type II diabetes. Type I diabetes, also
called juvenile diabetes or insulin-dependent diabetes, occurs
when the body’s immune system attacks and destroys beta cells of
the pancreas. Beta cells normally produce insulin, a hormone that
regulates, together with glucagon (another hormone produced by
alpha cells of the pancreas), the blood glucose concentration in the
body, i.e. while insulin lowers it, glucagon increases it. The food
intake in the body results in an increase in the glucose
concentration. Insulin enables most of the body’s cells to take
up glucose from the blood and use it as energy. When the beta cells
aredestroyed, since no insulin can be produced,glucose remains in
the blood causing serious damage to several organs. For this
reason, people with type I diabetes must take insulin in order to
stay alive. This means undergoing multiple injections daily
(normally coinciding with the meal times), and testing blood
sugar by pricking their fingers for blood several times a day [8].
This method is just an open-loop control with intermittently
monitored glucose levels resulting in intermittently administered
insulin doses that are manually administered by a patient using awritten algorithm. The current open-loop therapy can be
contrasted to glucose management by a closed-loop system
controlling blood glucose in diabetic patients also known as an
artificial pancreas.
The automated control of normoglycemia in subjects with type
I diabetes has been subject of extensive research since the 1970s
[1,7]. However, the first devices, e.g. the Biostator TM [4], which
used intravenous (i.v.) BG sampling and i.v. insulin and glucose
delivery, were cumbersome and unsuited for outpatient use. A
minimally invasive closed-loop system using subcutaneous (s.c.)
continuous glucose monitoring and s.c. insulin pump delivery was
needed. To date, several s:c :– s:c : systems, have been tested [7,9].
From a control viewpoint, the main challenges are time delays,
constraints, meal disturbances, and nonlinear dynamics. Most of
the control schemes proposed in literature are based on either PID
(proportional integral derivative) or MPC (model predictive
control) control laws, see e.g. [16,7,6]. Due to the presence of
significant delays in the glucose metabolism model, a well-
designed feedforward action able to consider in advance a meal
announcement signal is essential in order to guarantee satisfactory
performances. Within MPC , feedforward and feedback control
actions are jointly designed and constraints are taken into account
in a very natural way. The recent advancements in nonlinear MPC ,
see e.g. [15], and the development of a new generationof models of
glucose metabolism make this control technique even more
promising.
Biomedical Signal Processing and Control 4 (2009) 338–346
A R T I C L E I N F O
Article history:Received 10 November 2008
Received in revised form 6 April 2009
Accepted 15 April 2009
Available online 22 May 2009
Keywords:
Diabetes
Virtual patients generation
Model predictive control
Control-Variability Grid Analysis
Blood Glucose Index
A B S T R A C T
In this paper, the feedback control of glucose concentration in type I diabetic patients usingsubcutaneous insulin delivery and subcutaneous continuous glucose monitoring is considered. A
recently developed in silico model of glucose metabolism is employed to generate virtual patients on
which control algorithms can be validated against interindividual variability. An in silico trial consisting
of 100 patients is used to assess the performances of a linear output feedback and a nonlinear state-
feedback model predictive controller, designed on thebasis of thein silico model.More than satisfactory
results areobtainedin thegreatmajority of virtual patients.The experiments highlight thecrucialrole of
the anticipative feedforward action driven by the meal announcement information. Preliminary results
indicate that further improvements may be achieved by means of a nonlinear model predictive control
scheme.
2009 Elsevier Ltd. All rights reserved.
* Corresponding author.
E-mail address: [email protected] (L. Magni).
Contents lists available at ScienceDirect
Biomedical Signal Processing and Control
j o u r n a l h o m e p a g e : w w w . e l s e v i e r . c o m / l o c a t e / b s p c
1746-8094/$ – see front matter 2009 Elsevier Ltd. All rights reserved.
doi:10.1016/j.bspc.2009.04.003
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 2/9
The need of guaranteeing parameter identificability from easily
measurable experimental data motivated the development of
parsimonious models of glucose metabolism (see e.g. the classical
minimal model [2]). By contrast, in silico large-scale simulation
models aim to describe the glucose–insulin system in as much
detail as possible. The major limitation of most in silico models is
that they were validated on few subjects and only by means of
plasma concentration measurements. Recently, a new-generation
in silico model has been developed taking advantage of the
availability of a unique-meal data set of 204 nondiabetic
individuals [5]. The subjects underwent a triple tracer meal
protocol, making it possible to obtain in a virtually model-
independent fashion thetime courseof all therelevant glucose and
insulin fluxes during a meal. Thus, by using a ‘‘concentration and
flux’’ portrait, it was possible to model the glucose–insulin system
by resorting to a subsystem forcing function strategy which
minimizes structural uncertainties in modeling the various unit
processes.
In this paper, the above model is used to randomly generate
virtual diabetic patients. Suitable modifications (see [12]) are
introduced to reflect the absence of endogenous insulin secretion,
while the parameter variability in the original data set is used to
model interindividual variability of the diabetic population.
Validating algorithms on a whole set of different patients (insilico trial) is the only realistic way of addressing robustness of the
artificial pancreas in the face of interindividual variability so as to
maximize success chances in the subsequent clinical trials
conducted on real patients.
In the present work, the in silico model is used todesign a linear
output feedback MPC scheme which is then tested on an in silico
trial consisting of 100 synthetic type I diabetic subjects ‘‘followed’’
for a day, receiving dinner and breakfast. The overall results, as
measured by several established performance indices, are more
than satisfactory for the great majority of virtual patients. An
important role is played by the feedforward action that takes
advantage of the meal announcement information. Moreover, the
controller performances are shown to be robust with respect to
errors in the meal announcement signal. Finally, in order to furtherimprove the glucose concentration regulation, a preliminary test is
carried out by using a nonlinear state-feedback MPC scheme. A
definite improvement of glucose and insulin profiles is observed,
indicating that nonlinear MPC has the potential for achieving very
effective glycemic control.
2. Virtual patients
In order to synthesize and test the controller, we used the meal
glucose–insulin model [5,12] summarized in the following
subsections.
2.1. Glucose intestinal absorption
Glucose intestinal absorption is modeled by a three-compart-
ment model
˙ Q sto1ðt Þ ¼ k griQ sto1ðt Þ þ dðt Þ
˙ Q sto2ðt Þ ¼ kempt ðt ;Q stoðt ÞÞQ sto2ðt Þ þ k griQ sto1ðt Þ
˙ Q gut ðt Þ ¼ kabsQ gut ðt Þ þ kempt ðt ;Q stoðt ÞÞQ sto2ðt Þ
Q stoðt Þ ¼ Q sto1ðt Þ þ Q sto2ðt Þ
Raðt Þ ¼ fkabsQ gut ðt Þ=BW
8>>>>>><>>>>>>:where Q sto (mg) is the amount of glucose in the stomach (solid,
Q sto1, and liquid phase, Q sto2
), Q gut (mg) is the glucose mass in the
intestine, k gri is the rate of grinding, kabs is the rate constant of
intestinal absorption, f is the fraction of intestinal absorption
which actually appears in plasma, d (mg/min) is the amount of
ingested glucose, BW (kg)is thebody weight, Ra (mg/kg/min) is the
glucose rate of appearance in plasma and kempt is the rate constant
of gastric emptying which is a time-varying nonlinear function of
Q sto
kempt ðt ; Q stoðt ÞÞ ¼ kmax þkmax kmin
2 ftan h½aðQ stoðt Þ bDðt ÞÞ
tan h½bðQ stoðt Þ dDðt ÞÞg
where
a ¼ 5
2Dðt Þð1 bÞ; b ¼
5
2Dðt Þd; Dðt Þ ¼
Z t f
t i
dðt Þ dt
with t i and t f , respectively, start time andend time of thelast meal,
b, d , kmax and kmin model parameters.
2.2. Glucose subsystem
A two-compartment model is used to describe glucose kinetics
˙ G pðt Þ ¼ k1G pðt Þ þ k2Gt ðt Þ þ EGP ðt Þ þ Raðt Þ U ii E ðt Þ
˙ Gt ðt Þ ¼ k1G pðt Þ k2Gt U idðt Þ
Gðt Þ ¼ G pðt Þ
V G
8>>><
>>>:where V G (dl/kg) is the distribution volume of glucose, G (mg/dl) is
the glycemia, G p (mg/kg) and Gt (mg/kg) are glucose in plasma and
rapidly equilibrating tissues, and in slowly equilibrating tissues,
respectively, EGP is the endogenous glucose production (mg/kg/
min), E (mg/kg/min) is the renal excretion, U ii and U id are the
insulin-independent and -dependent glucose utilizations, respec-
tively (mg/kg/min), and k1 and k2 are the rate parameters. The
insulin-independent glucose utilizations U ii is assumed constant.
Basal steady state, i.e. constant glycemia Gb (mg/dl), is character-
ized by the following equations:
k1G pb þ k2Gtb þ EGP b þ Rab U ii E b ¼ 0k1G pb k2Gtb U idb ¼ 0
so that, noting that at basal equilibrium Rab ¼ 0,
EGP b ¼ U ii þ U idb þ E b
2.3. Glucose renal excretion
Renal extraction represents the glucose flow which is elimi-
nated by thekidney, when glycemia exceeds a certain threshold ke2
E ðt Þ ¼ max f0; ke1ðG pðt Þ ke2Þg
The parameter ke1 (1/min) represents renal glomerular filtration
rate.
2.4. Endogenous glucose production
EGP comes from the liver, where a glucose reserve exists
(glycogen). EGP is inhibited by high levels of glucose and insulin
EGP ðt Þ ¼ max ð0; EGP b k p2ðG pðt Þ G pbÞ k p3ðI dðt Þ I bÞÞ
where k p2 and k p3 are model parameters and I d (pmol/l) is a
delayed insulin signal, coming from the following dynamic
system:
˙ I 1ðt Þ ¼ kiI ðt Þ kiI 1ðt Þ˙ I dðt Þ ¼ kiI 1ðt Þ kiI dðt Þ
( (1)
where I (pmol/l) is plasma insulin concentration or insulinemia
and k i (1/min) is a model parameter.
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 339
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 3/9
2.5. Glucose utilization
Glucose utilization is made up of two components: the insulin-
independent one U ii, which represents the glucose uptake by the
brain and erythrocytes, and the insulin-dependent component U id,
which depends nonlinearly on glucose in the tissues
U idðt Þ ¼ V mð X ðt ÞÞ Gt ðt Þ
K m þ Gt ðt Þ
where V m (1/min) is a linear function of interstitial fluid insulin X (pmol/l)
V mð X ðt ÞÞ ¼ V m0 þ V mx X ðt Þ
which depends from insulinemia in the following way:
˙ X ðt Þ ¼ p2U X ðt Þ þ p2U ðI ðt Þ I bÞ
where K m, V m0, V mx are model parameters, I b (pmol/l) is the basal
insulin level and p2U (1/min) is called rate of insulin action on
peripheral glucose. Considering the basal steady state, one has
U idb ¼ V m0Gtb
K m þ Gtb
and
Gtb ¼ U ii EGP b þ k1G pb þ E bk2
V m0 ¼ ðEGP b U ii E bÞðK m þ GtbÞ
Gtb
2.6. Insulin subsystem
Insulin flow s, coming from the subcutaneous compartments,
enters the bloodstream and is degradated in the liver and in the
periphery:
˙ I pðt Þ ¼ ðm2 þ m4ÞI pðt Þ þ m1I lðt Þ þ sðt Þ
˙ I lðt Þ ¼ ðm1 þ m3ÞI lðt Þ þ m2I pðt Þ
I ðt Þ ¼ I pðt Þ=V I
8><
>:where V I (l/kg) is thedistribution volumeof insulin and m1, m2, m3,m4 (1/min) are model parameters.
At basal one has
0 ¼ ðm2 þ m4ÞI pb þ m1I lb þ sb
0 ¼ ðm1 þ m3ÞI lb þ m2I pb
so that
I lb ¼ m2
m1 þ m3I pb
sb ¼ ðm2 þ m4ÞI pb m1I lb
8<:where I pb ¼ I bV I .
2.7. s.c. insulin subsystem
In diabetic patients, insulin is usually administered by
subcutaneous injection. Insulin takes some time to reach the
circulatory apparatus, unlike in the healthy subject in which the
pancreas secretes directly into the portal vein. This delay is
modeled here with two compartments, S 1 and S 2 (pmol/kg) (which
is a variation of the model described in [17]), which represent,
respectively, polymeric and monomeric insulin in the subcuta-
neous tissue
˙ S 1ðt Þ ¼ ðka1 þ kdÞS 1ðt Þ þ uðt Þ˙ S 2ðt Þ ¼ kdS 1ðt Þ ka2S 2ðt Þ
sðt Þ ¼ ka1S 1ðt Þ þ ka2S 2ðt Þ
8><>:where uðt Þ (pmol/kg/min) represents injected insulin flow, kd is
called degradation constant, ka1 and ka2 are absorption constants.
At basal one has
0 ¼ ðka1 þ kdÞS 1b þ ub
0 ¼ kdS 1b ka2S 2b
sb ¼ ka1S 1b þ ka2S 2b
8><>:and solving the system
S 1b ¼ sb
kd þ ka1
S 2b ¼ kd
ka1S 1b
ub ¼ sb
8>>>><>>>>:The quantity ub (pmol/min) represents insulin infusion to maintain
diabetic patient at basal steady state.
2.8. s.c. glucose subsystem
Subcutaneous glucose GM (mg/dl) is, at steady state, highly
correlated with plasma glucose; dynamically, instead, it follows
the changes in plasma glucose with some delay. This dynamic was
modeled with a system of first order
˙ GM ðt Þ ¼ ks:c :GM ðt Þ þ ks:c :Gðt Þ
2.9. Virtual patient generation
In order to obtain parameter joint distributions in type 1
diabetes, the parameter identified in 204 subjects in health were
used as starting point [5]. Some modification was needed to
realistically describe a type 1 diabetic subject: basal glucose
concentration was assumed to be on average 50 mg/dl higher
than in subjects in health; steady-state insulin concentration
(due to an external insulin pump) was assumed to be on average
four times higher than in subjects in health; basal endogenous
glucose production was assumed to be 35% higher than in
subjects in health, and steady-state insulin clearance was
assumed to be one third lower than in subjects in health;
parameters relating to insulin action on both glucose productionand utilization were assumed to be one-third lower than in
subjects in health. For all these parameters/variables the same
inter-subject variability found in subjects in health was
maintained. The parameters were assumed to be log-normal
distributed to guarantee that they were always positive, so the
covariance matrix (26 26) was calculated using the log-
transformed parameters. Then, 100 subjects were generated
using the joint distribution, i.e. 100 realizations of the log-
transformed parameter vector were randomly extracted from
the multivariate normal distribution with mean equal to mean
of the log-transformed parameters and 26 26 covariance
matrix. Finally, the parameters in the 100 in silico subjects
were obtained by antitransformation.
3. Metrics to assess control performance
In evaluating the performance of a control algorithm one has
to remember that its basic function is to mimic as best as
possible the feature of the beta cells, which is to maintain
glucose levels between 80 and 120 mg/dl in the face of
disturbances such as meals or physical activity. A good
algorithm should be able to maintain blood sugar low enough,
as this reduces the long-term complications related to diabetes,
but must also avoid even isolated hypoglycemic episodes. To be
useful, a metric has to take into account these features. The
HbA1c cannot be considered in this context because in the first
closed-loop clinical trial patients are controlled only for a short
period.
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 340
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 4/9
3.1. Blood Glucose Index (BGI)
Blood Glucose Index is a metric proposed by Kovatchev et al.
[10], to evaluate the clinical risk related to a particular glycemic
value
BGI ðÞ ¼ 10ð g ½lna
ðÞ bÞ2
(2)
where a, b and g are fixed equal to 1.084, 5.3811 and 1.509,
respectively. The BGI function is asymmetric, because hypoglyce-mia is considered more dangerous than hyperglycemia (see Fig. 1).
Starting from the BGI, two synthetic indices for sequences of n
measurements of blood glucose can be defined.
3.1.1. LBGI (low BGI)
Measures hypoglycemic risk
LBGI ¼ 10
n
Xn
i¼1
rl2
ðGiÞ
where rlðÞ ¼ min ð0; g ½lna
ðÞ lna
ðG0ÞÞ.
3.1.2. HBGI (high BGI)
Measures hyperglycemic risk
HBGI ¼ 10
n
Xn
i¼1
rh2
ðGiÞ
where rhðÞ ¼ max ð0; g ½ln aðÞ ln aðG0ÞÞ.
LBGI index captures the tendency of the algorithm to overshoot
the target and eventually trigger hypoglycemia. Directly linked
with LBGI, HBGI captures the tendency of the algorithm to stay
above the target range.
3.2. Control-Variability Grid Analysis (CVGA)
The Control-VariabilityGrid Analysis (CVGA) [13] is a graphical
representation of min/max glucose values in a population of
patients either real or virtual. The CVGA provides a simultaneous
assessment of thequalityof glycemic regulation in all patients. Assuch, it hasthe potential to play an important role in thetuning of
closed-loopglucosecontrol algorithms andalso in thecomparison
of their performances. Assumingthat foreach subject a timeseries
of measured blood glucose (BG) values over a specified time
period (e.g.1 day) is available, theCVGAis obtainedas follows:for
each subject, a point is plotted whose X -coordinate is the
minimum BG andwhose Y -coordinate is the maximum BG within
the considered time period (see Fig. 2). Note that the X -axis is
reversed as it goes from 110 (left) to 50 (right) so that optimal
regulation is located in lower left corner. The appearance of the
overall plot is a cloud of points located in various regions of the
plane. Different regions on the plane can be associated with
different qualities of glycemic regulation. In order to classify
subjects into categories, nine rectangular zones are defined as
follows:
Zone A(Gmax < 180, Gmin > 90)]: Accurate control.
Zone B high (180 <Gmax < 300, Gmin > 90)]: Benign trend
towards hyperglycemia.
Zone B low (Gmax <180, 70<Gmin < 90)]: Benign trend towards
hypoglycemia.
Zone B (180<Gmax < 300, 70 <Gmin < 90)]: Benign control.Zone C high (Gmax > 300, Gmin > 90)]: overCorrection of
hypoglycemia.
Zone C low (Gmax < 180, Gmin < 70)]: overCorrection of hyper-
glycemia
Zone D high (Gmax > 300, 70<Gmin < 90)]: Failure to deal with
hyperglycemia.
Zone D low (180 <Gmax < 300, Gmin < 70)]: Failure to deal with
hypoglycemia.
Zone E (Gmax >300, Gmin < 70)]: Erroneous control.
4. Model predictive control
The glucose metabolism model can be rewritten in the
following compact way:˙ xðt Þ ¼ f ðt ; xðt Þ;uðt Þ;dðt ÞÞ
yðt Þ ¼ GM ðt Þ
where x ¼ ½Q sto1; Q sto2
;Q gut ;G p;Gt ; I p; X ; I 1; I d; I l; S 1; S 2; GM , and
f ð; ; ; Þ is derived from the model equations reported in Section
2. The system is subject to the following constraints:
xmin x xmax (3)
umin u umax (4)
where xmin, xmax, umin and umax denote lower and upper bounds on
the state and input, respectively. Typically, they represent limits on
the glucose concentration and on the insulin delivery rate. In theFig. 1. Blood Glucose Index.
Fig. 2. Control-Variability Grid Analysis with summary.
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 341
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 5/9
following, it is assumed that meal announcement is available, i.e.
the disturbance signal (the meal) is known in advance.
The MPC control law ([15,3,11]) is based on the solution of a
Finite Horizon Optimal Control Problem (FHOCP ), where a cost
function J ð ¯ x;uÞ is minimized with respect to the input u subject to
the state dynamics of a model of the system, and to state- and
input-constraints. Letting uo be the solution of the FHOCP ,
according to the Receding Horizon paradigm, the feedback control
law u ¼ kMPC ð xÞ is obtained by applying to the system only the first
part of the optimal solution. In this way, a closed-loop control
strategy is obtained solving an open-loop optimization problem.
MPC control laws can be formulated for both discrete- and
continuous-time systems. In this paper, a discrete-time linear MPC
(LMPC ) is derived from an input–output linearized approximation
of the full model. Moreover, a state-feedback nonlinear MPC
(NMPC ) scheme is derived that exploits the full nonlinear model.
4.1. Unconstrained linear model predictive control
In order to obtain a time-invariant model, the rate constant
of gastric emptying kempt has been fixed to kempt ðt ;Q stoÞ ¼ kmean ¼
ðkmin þ kmaxÞ=2. The system is linearized around the basal steady-
state point of each patient and discretized with sampling time T s
yielding
xðk þ 1Þ ¼ AD xðkÞ þ BDuuðkÞ þ BDddðkÞ yðkÞ ¼ C D xðkÞ
After a model order reduction step the following transfer function
representation is obtained
Y ð z Þ ¼ N U ð z Þ
DE ð z ÞU ð z Þ þ
N Dð z Þ
DE ð z ÞDð z Þ (5)
with
N U ð z Þ ¼ b2 z 2 þ b1 z þ b0
DE ð z Þ ¼ z 3 þ a2 z 2 þ a1 þ a0
N Dð z Þ ¼ bD2 z 2 þ bD1 z þ bD0
Since the two transfer functions have the same denominator, the
following input–output representation is obtained
yðk þ 1Þ ¼ a2 yðkÞ a1 yðk 1Þ a0 yðk 2Þ þ b2uðkÞ þ b1uðk 1Þ
þ b0uðk 2Þ þ bD2dðkÞ þ bD1dðk 1Þ þ bD0dðk 2Þ
Finally, system (5) can be given the following state-space
(nonminimal) representation
xIOðk þ 1Þ ¼ AIO xIOðkÞ þ BIOuðkÞ þ M IOdðkÞ yðkÞ ¼ C IO xIOðkÞ
where xIOðk þ 1Þ ¼ ½ yðk þ 1Þ0; . . . ; yðk n þ 2Þ
0;uðkÞ
0; . . . ;uðk n
þ2Þ0;dðkÞ0; . . . ; dðk n þ 2Þ
00 and the matrices A IO;BIO;M IO;C IO are
defined accordingly.
In order to derive the LMPC control law the following quadraticdiscrete-time cost function is considered
J ð xIOðkÞ; uðÞÞ ¼XN 1
i¼0
ðk yoðk þ iÞ yðk þ iÞk2Q D
þ kuðk þ iÞk2RD
Þ
þ k yoðk þ N Þ yðk þ N Þk2S D
where N is the prediction horizon, yoðkÞ the desired output at time
k and Q D ¼ Q 0D 0, RD ¼ R0D > 0, S D ¼ S 0D 0 areweighting matrices.
The evolution of the system can be rewritten in a compact way
as follows:
Y ðkÞ ¼ A c xIOðkÞ þ B c U ðkÞ þ Mc DðkÞ
where Y ðkÞ ¼ ½ yðk þ 1Þ; yðk þ 2Þ; . . . ; yðk þ N 1Þ; yðk þ N Þ;DðkÞ ¼
½dðkÞ
0
; dðk þ 1Þ
0
;. . .
;dðk þ N 1Þ
0
; dðk þ N Þ
0
0
; U ðkÞ ¼ ½uðkÞ
0
; uðk þ 1Þ
0
;
. . . ; uðk þ N 1Þ0;uðk þ N Þ
00 and A c ; B c ;Mc , are derived using the
discrete-time Lagrange formula:
xIOðk þ iÞ ¼ AiIO xIOðkÞ þ
Xi1
j¼0
Ai j1IO ðBIOuðk þ jÞ þ M IOdðk þ jÞÞ
In this way, letting Y oðkÞ ¼ ½ yoðk þ 1Þ0; yoðk þ 2Þ
0; . . . ; yoðk þ N 1Þ
0;
yoðk þ N Þ00 the cost function becomes
¯ J ð xðkÞ; uðÞÞ ¼ ðY oðkÞ Y ðkÞÞ0QðY oðkÞ Y ðkÞÞ þ U 0ðkÞRU ðkÞ
¼ ðY oðkÞ A c xIOðkÞ B c U ðkÞ Mc DðkÞÞ0Q ðY oðkÞ
A c xIOðkÞ B c U ðkÞ Mc DðkÞÞ þ U 0ðkÞRU ðkÞ
where Q and R are block-diagonal matrices that contain the
matrices Q , R and S . In the unconstrained case, the solution of the
optimization problem is
U oðkÞ ¼ ðB 0c QB 0c þ RÞ1
B 0c QðY oðkÞ A c xIOðkÞ Mc DðkÞÞ
where the future values of the set point and the disturbance signal
(meal) are considered. Finally, following the Receding Horizon
approach the control law is given by
uoðkÞ ¼ ½ I 0 . . . 0 U oðkÞ
In view of the input constraints (4), only a saturated value will be
applied to the system. The satisfaction of the state constraints, on
the contrary, cannot be guaranteed; it is only possible to tune
parameters Q , R , S and N to improve the regulation performance.
The major advantages of this input–output LMPC scheme are that
an observer is not required ( xIO includes past input and output
values only), and that it is very easily implementable because on-
line optimization is avoided.
4.2. Constrained linear model predictive control
Witha relatively small increaseof the computational burden it is
possible to consider explicitly both input and state constraints by
solving a constrained linear quadratic optimization problem. This
can be doneby solving on-line a quadratic programmingproblem or
by using an explicit solution derived through a multiparametric
approach. In this paper the results obtained with constrained LMPC are not reported because they did not show any significant
improvement. In fact, the explicit consideration of input constraints
alone does not improve the performance of the unconstrained
saturated control law, while the fully constrained problem, i.e. also
with state constraints, introduces nontrivial problems due to the
approximation error caused by linearization and model reduction.
Further work is required to explore this approach.
4.3. Nonlinear model predictive control
Unconstrained LMPC with a quadratic cost function provides an
explicit control law. The simplicity of this solution is a great
advantage in order to implement the controller on real patients.
In the following, a nonlinear model predictive control isproposed. The goal is to evaluate the (upper) performance limit
of a predictive control algorithm in the blood glucose control
problem. In order to do this, we consider the ideal albeit
unrealistic, situation:
1. the nonlinear model used in the synthesis of the NMPC exactly
describes the system;
2. all the states of the systems are measurable. A state-feedback
NMPC is proposed (no observer is used).
The model used in the synthesis of the NMPC is the full
nonlinear continuous-time model previously described.
Since nonlinear predictive control allows for the use of
nonlinear cost functions, the adopted cost function incorporates
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 342
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 6/9
the kind of nonlinearity entering the LBGI and HBGI indexes
previously described. In order to minimize the control energy
spent within the optimization horizon, the cost function includes
also a term depending on the control action.
The Finite Horizon Optimal Control Problem consists in
minimizing, with respect to control sequence u1ðt kÞ; . . . ;uN ðt kÞ
(t k ¼ kT S with T S sampling time period), the following nonlinear
cost function with horizon N
J ð xt k ;u1ðt kÞ; . . . ; uN ðt kÞÞ ¼
Z t kþN
t k
f10qð g ððln ðG pðt ÞÞÞa bÞÞ2
þ ruðt Þ2g dt (6)
Note that a full hybrid solution is developed, i.e. the control inputs
uiðt kÞ are constrained to be piecewise constants, uðt Þ ¼
uiðt kÞ;t 2 ½t kþi1; t kþiÞ; i 2 ½1; . . . ; N (see [14]).
The values of g , a and b adopted in this case are g ¼ 0:75,
a ¼ 1:44, and b ¼ 9:02.
5. Virtual protocol
The performance of closed-loop glucose controllers was testedon a 1-day virtual protocol (see Fig. 3):
1. Patient enters at 17.00 of Day 1. At that time, data gathering for
warm-up phase starts. Microinfusor is programmed to inject
basal insulin for the specific patient.
2. At 18.00 of Day 1 patient takes a meal lasting about 15 min. The
meal contains 85 g of carbohydrates. At the same time, patient
receives an insulin bolus d according to his personal insulin/
carbohydrate ratio (CHO ratio or CR), that is
d ¼ 85 CR
3. Control loop is closed at 21.30 of Day 1. At this time, the
switching phase starts. In this phase the metrics for evaluationare not calculated.
4. At 23.00 of Day 1 regulation phase starts.
5. At 7.30 of Day 2, patient has breakfast containing 50 g of CHO.
Meal duration is about 2 min.
6. Experiment finishes at 12.00 of Day 2. Patient is discharged and
restarts his normal insulinic therapy.
6. In silico trial
In order to test the proposed control algorithm several in
silico trials have been based on the protocol described in Section
5. The main objectives are to verify: (a) the effect of a change in
the parameter q that is the only tuning parameter that is
individualized; (b) the impact of meal announcement; (c) therobustness with respect to errors in the meal announcement
information (e.g. time and amount); (d) the benefit of an explicit
consideration of the nonlinear dynamics by means of a NMPC.
The CVGA matrix, used to compare population performances, is
computed only during the regulation period in order to reduce
Fig. 5. CVGA: Experiment L1 (white) versus Experiment L3 (blue). (For
interpretation of the references to color in this figure legend, the reader is
referred to the web version of the article.)
Fig. 3. Nominal scenario for adult patient.
Fig. 4. CVGA: Experiment L1 (white) versus Experiment L2 (blue). (For
interpretation of the references to color in this figure legend, the reader is
referred to the web version of the article.)
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 343
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 7/9
the influence of the open-loop regulation on the closed-loop
indexes:
Experiment L1. 100 subjects are simulated using an LMPC
control law synthesized with T s ¼ 15 min, n ¼ 3, N ¼ 16, RD ¼ 1
and Q D ¼ S D ¼ qn, where qn has been individualized for each
subject and the set point is taken equal to 112 mg/dl.
Experiment L2. It is equal to Experiment 1 with q ¼ 2qn.
Experiment L3. It is equal to Experiment 1, but the LMPC
control law is applied without meal announcement.
Experiment L4. The ingested amount of glucose is 125% of the
nominal value forall 100 patients.The LMPC control lawhas the
same parameters as those used for Experiment 1 and relies on
the nominal glucose dose to decide the feedforward action.
Experiment L5. The ingested amount of glucose is 75% of thenominal value forall 100 patients.The LMPC control lawhas the
same parameters as those used for Experiment 1 and relies on
the nominal glucose dose to decide the feedforward action.
Experiment L6. The ingested amount of glucose is delayed of
30 min with respect to the nominal value for all 100 patients.
The LMPC control law has the same parameters as those used
for Experiment 1 and relies on the nominal glucose profile to
decide the feedforward action.
Experiment L7. The ingested amount of glucose is 30 min in
advance with respect to the nominal value for all 100 patients.
The LMPC control law has the same parameters as those used
for Experiment 1 and relies on the nominal glucose profile to
decide the feedforward action.
Experiment N8. In order to explore the potentiality of NMPC,
some virtual patients undergoing Experiment 1 were also
controlled by means of NMPC.
7. Results
The performances obtained in Experiment L1, as shown in Fig. 4,are clearly satisfactory: in factno hypo phenomenon occurs and also
themaximum values arevery well regulated.In particular, 59 virtual
patients are in the A-zone and41 are in the B-zone. The comparison
between Experiment L1 and L2 (see Fig. 4) shows the effect of a
variation of the q parameter, the only parameter to be tuned. In
Fig. 8. CVGA: Experiment L1 (white) versus Experiment L6 (blue). (For
interpretation of the references to color in this figure legend, the reader is
referred to the web version of the article.)
Fig. 6. CVGA: Experiment L1 (white) versus Experiment L4 (blue). (For
interpretation of the references to color in this figure legend, the reader is
referred to the web version of the article.)
Fig. 7. CVGA: Experiment L1 (white) versus Experiment L5 (blue). (For
interpretation of the references to color in this figure legend, the reader is
referred to the web version of the article.)
Fig. 9. CVGA: Experiment L1 (white) versus Experiment L7 (blue). (For
interpretation of the references to color in this figure legend, the reader is
referred to the web version of the article.)
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 344
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 8/9
Fig. 10. Experiments L1 and L4–L7 for patient 9.
Fig. 11. Experiment L1 (LMPC) versus Experiment N8 (NMPC) for patient 35.
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 345
8/12/2019 paper on type 1 diabetes
http://slidepdf.com/reader/full/paper-on-type-1-diabetes 9/9
particular, increasing the aggressiveness, i.e. using a larger q, all the
points in the CVGA move towards the Lower B region reducing the
maximum BG value butalso theminimum one.2 patients move even
in the lower D-zone and 2 in thelower C-zone. The CVGA reported in
Fig. 5 for ExperimentsL1, L3 shows that in Experiment L3, 9 patients
move from A-zone to B-zone. The difference in regulation
performance with and without meal announcement information
demonstrates the benefit of an anticipative action in the insulin
injection exploiting knowledge of the meal profile. The robustness
analysis of the proposed control algorithm against wrong informa-
tion on meal amount or time is performed through Experiments L4–
L7andis shown in Figs. 6–9 . Inall cases, all the patients are in the A-
and B-zones so that. Robustness with respect to this kind of
uncertainties is apparent. An example of the time evolution of the
glucoseand external insulinare reported in Fig.10 forpatient #9.The
vertical black lines in Figs. 10 and 11 indicate the beginning of the
closed-loop, the beginning of the regulation period and the breakfast
nominal time. Finally, in Fig. 11 the glucose and insulin profiles
obtained in the Experiment L1 with the LMPC andin Experiment N8
with NMPC are reported for patient #35. As shown in Fig. 11, the
adoption of an NMPC scheme, in place of an LMPC one, may bring
substantial improvement. In particular the range of glucose
concentration variability is reduced and a much smoother insulin
profileis achieved. Theadvantage of the nonlinear predictivecontrolscheme is twofold: constraints on glycemia areexplicitly allowedfor
and knowledge of the nonlinear dynamics is exploited.
8. Conclusions
This paper presents an engineering view of the control of
diabetes based on three fundamental clinical perspectives: (1)
recent studies have documented thebenefits andthe technological
reliability of continuous glucose monitoring (CGM ); (2) intensive
insulin treatment attempting to approximate near-normal levels
of glycemia markedly reduces chronic complications, but may risk
potentially life-threatening severe hypoglycemia; (3) in silico
modeling could produce credible pre-clinical information and
could substitute the traditional animal trials yielding results in afraction of the time. Hence, the future development of the artificial
pancreas will be greatly accelerated by employing mathematical
modeling and computer simulation.
The best way to utilize CGM data would be to devise automated
procedures for the interpretation and processing of the continuous
data flow,which take intoaccountglucoseutilizationand the delays
related to subcutaneous insulin administration. Automated control
algorithms would be needed,which should be based on engineering
understanding of the glucose–insulin system in diabetes, e.g. on
predictive models. Risk analysis and analysis of temporal glucose
variability, including methods such as the BGI and the CVGA
presented in this paper, will be fundamental to both the design of
open- and closed-loop control algorithms and to the evaluation of
the results from their in silico and in vivo testing. A simulator of T 1DM , as the oneconsidered in this paper, shouldbe equipped with a
cohort of i n silico subjects that span the observed interindividual
variability of key metabolic parameters in the T 1DM population.
The in silico trial has demonstrated that linear output-feedback
MPC achieves satisfactory glycemic regulation in a virtual
population of 100 type I diabetic patients. The proposed scheme
is also robust with respect to errors in the meal announcement
signal. Robustness in the face of sensor errors may also be
investigated by complementing the simulator with a probabilistic
model of sensor noise. Moreover, the benefit brought by
individualization of the control parameter q has been demon-
strated. For virtual patients, this parameter can be tuned via a trial
and error procedure based on in silico experiments. For the real
patients it is necessary to find a safe value that can be refined via a
day-to-day iterative learning algorithm.
Preliminary tests conducted on virtual patients have shown
that state-feedback nonlinear MPC has the potential to introduce
further improvements. In fact, although linear MPC yields well-
regulated glucose profiles with reasonable insulin administrations,
the adoption of the nonlinear controller further reduces glucose
variability using a smoother insulin profile. However, for nonlinear
MPC to be usable in practice the development of state observers
would be required.
References
[1] B.W. Bequette, A critical assessment of algorithms and challanges in the devel-opment of a closed-loop artificialpancreas,Diabetes Technology & Therapeutics 7(1998) 28–47.
[2] R.N. Bergmann, Y.Z. Ider, C.R. Bowden, C. Cobelli, Quantitative estimation of insulin sensitivity, American Journal of Physiology 236 (1979) E667–E677.
[3] E.F. Camacho, C. Bordons, Model Predictive Control, Springer, 2004.[4] A.H. Clemens, P.H. Chang, R.W. Myers, The development of Biostator, a glucose
controlled insulin infusion system (GCIIS), Hormone and Metabolic Research 7(1977) 23–33.
[5] C. Dalla Man, R.A. Rizza, C. Cobelli, Meal simulation model of the glucose-insulinsystem, IEEE Trans. Biomed. Eng. 54 (2007) 1740–1749.
[6] P. Dua, F.J. Doyle, E.N. Pistikopoulos III, Model-based blood glucose control fortype 1 diabetes via parametric programming, IEEE Transactions on BiomedicalEngineering 53 (2006) 1478–1491.
[7] R. Hovorka, Continuous glucose monitoring and closed-loop systems, DiabeticMedicine 23 (2005) 1–12.
[8] JDRF website: http://www.jdrf.org/index.cfm?page_id=101982.[9] D.C. Klonoff, The artificial pancreas: how sweet engineering will solve bitter
problems, Journal of Diabetes Science and Technology 1 (2007) 72–81.[10] B.P. Kovatchev, W.L. Clarke, M. Breton, K. Brayman, A. McCall, Quantifying
temporal glucose variability in diabetes via continuous glucose monitoring:mathematical methods and clinical application, Diabetes Technology & Thera-peutics 7 (6) (2005) 849–862.
[11] J. Maciejowski, Predictive Control with Constraints, Prentice-Hall, 2001.[12] L. Magni, D.M. Raimondo, L. Bossi, C. Dalla Man, G. De Nicolao, B. Kovatchev, C.
Cobelli, Model predictive control of type 1 diabetes: An in silico trial, Journal of Diabetes Science and Technology 1 (6) (2007) 804–812.
[13] L. Magni, D.M. Raimondo, C. Dalla Man, M. Breton, S. Patek, G. de Nicolao, C.Cobelli,B. Kovatchev,Evaluating the efficacy of closed-loop glucose regulationviacontrol-variability grid analysis (cvga), Journal of Diabetes Science and Technol-ogy 2 (4) (2008) 630–635.
[14] L. Magni, R. Scattolini, Model predictive control of continuous-time nonlinearsystems withpiecewiseconstant control,IEEE Transactionson AutomaticControl49 (2004) 900–906.
[15] D.Q. Mayne, J.B.Rawlings, C.V.Rao, P.O.M. Scokaert, Constrained model predictivecontrol: stability and optimality, Automatica 36 (2000) 789–814.
[16] A.E. Panteleon, M. Loutseiko, G.M. Steil, K. Rebrin, Evaluation of the effect of gain
on the meal response of an automated closed-loop insulin delivery system,Diabetes 55 (2006) 1995–2000.
[17] C.A. Verdonk, R.A. Rizza, J.E. Gerich, Effects of plasma glucose concentration onglucose utilization and glucose clearance in normal man,Diabetes30 (1981) 535–537.
L. Magni et al./ Biomedical Signal Processing and Control 4 (2009) 338–346 346