1. Introduction
Diabetes (Diabetes mellitus) is a chronic disease that affects millions of persons worldwide (see, for instance, [
1,
2,
3], and [
4]). This disease is characterized by inadequate control of the blood glucose concentration in the body, leading to complications such as limb loss, blindness, ischemic heart disease, and end-stage renal disease [
3]. Besides, for diabetic patients with insulin-dependent diabetes, the glucose/insulin regulatory system can be viewed as a feedback-control example where the blood glucose levels are frequently measured to control it (see, for instance, [
2,
5,
6,
8] and [
9]). Additionally, and according to the Diabetes Control and Complications Trial (DCCT), the blood glucose concentration should be within the range of 50-120 mg/dL [
4]. In [
10], the range from 60 mg/dL to 110 mg/dL is considered as the normal blood glucose concentration level in humans. Therefore, by correctly applying insulin, this glucose level can be correctly (healthy) manipulated. As reference values, above 120mg/dL the state of the patient is known as
hyperglycemia, and below of 50mg/dL, the state is known as
hypoglycemia. Both states are harmful to the diabetic patient [
4].
Exogenous factors that can affect glucose include food intake, rate of digestion, exercise, and reproductive state, among others ([
2,
4]). Hence, for control performance evaluation, it is also important that the designed controller be robust in front of any real kind of internal or external perturbations.
Figure 1 shows the block diagram of a closed-loop controlled system of diabetic patients using insulin pumps ([
4,
6]). In this scheme, the glucose sensor can be embedded under the skin, and the insulin pump can be implanted in the abdomen. So, the control objective consists to keep regulating the glucose level in the body. In this scenario, the patient is said to be under
metabolic control. The pump injects insulin through a catheter. The system shown in
Figure 1 can be referred to as
artificial pancreas due to this closed-loop system replaces, in some way, the pancreas activity in controlling the glucose level of the body of a healthy person [
2].
In literature, several approaches have been used to design artificial pancreas. For instance, a robust controller using higher-order sliding mode control is studied in [
6]. Using optimal H
control theory, an insulin injection control is analyzed in [
5]. And employing a parametric programming approach for the control design is considered in [
4]. On the other hand, in [
11], control algorithms using standard linear control techniques, like the proportional-derivative controller, are studied, as in [
12,
13,
14]. In this paper, the feedback measurement signal is assumed available at discrete-time moments which results in an interesting and useful technological fact for an artificial pancreas design. In contrast, we claim that no significant benefit is obtained in using a nonlinear model-based control design strategy. For instance, in [
15], an impulsive model predictive control is presented, but the mathematical model has to be linear, and in [
16], miss undertaken internal dynamics. On the other hand, PID controllers in the artificial pancreas has been studied in [
17], but only for hyperglycemic condition, and in [
18] a PID robust control is presented for the hypoglycemic situation, but both conditions are not studied simultaneously, as in the present work. However, the nonlinear techniques can offer new ways of control implementation that can face some nonlinearities ignored in by the linear controller tools. Some of these nonlinear control design strategies involve sliding mode control [
6,
7], delay control [
19], optimal control [
20], switched LPV control [
21], sub-optimal control [
22], model predictive control [
23], fuzzy control [
24], reinforcement learning [
25], etc. Therefore, the use of these control design tools allows us to innovate new developments for artificial pancreas approaches. Our proposal aims to act upon the control part of an insulin-dependent diabetic system to develop an effective and simple solution to avoid non-desired clinical problems.
The main objective of the present work is to design a robust control for an artificial pancreas to minimize the effect of extreme situation as hyperglycemia or hypoglycemia. Additionally, we evaluate our artificial pancreas performance under different scenarios. Our control strategy uses a novel switched strategy: when a peak value on glucose blood concentration is detected, then the controller tries to minimize its level by injecting insulin to the system; and when the glucose blood concentration is minor than healthy level, then glucose ingestion is administrated by the controller. The objective is to maintain a healthy level of glucose. The control strategy is based on a Proportional-Derivative (PD) theory, where the input signal is the detected peak value of the glucose blood concentration. The PD controller format is considered due to its simple and easy realization [
12], as pointed out by [
13,
20]. We avoid using the PID controller because its integral action may be useless [
14]. This is also evidenced, in our numerical experiments, when we noticed that strong hypoglycemia occurs during a long period of time when the integral part is considered. But in order to complete the study of the proposed switched strategy, a reset integral part is considered, defining a commuted Proportional Integral Derivative (PID) controller. This approach is based on Clegg integrator [
26], where a reset signal is introduced to face the overshoots produced by the integral part of the controller as suggested in [
27] and [
28].
The rest of the paper is organized as follows. First, the nonlinear mathematical model and the proposed controller are presented in
Section 2. Then,
Section 3 shows the performance of the combined PD controller in different scenarios: with decaying disturbance; with external additive perturbation; and in the presence of dynamical plant changes. Also, in this section, a resetting-PID is evaluated to see the undesired chattering effect due to the integral part of the control architecture. Finally,
Section 4 discusses the obtained results.
3. Results
Simulation experiments of our controlled pancreatic model are carried out here, and for different patients shown in
Table 1 [
6] (the value
in Patient 3 denotes a modified value to obtain a notable hyperglycemia case). The total simulation time is over 800 minutes, and the sample time is set to 2s. The control parameter values are stated as
and
[
12]. Note that these values verify the stability conditions, as shown in Appendix A. In [
30], algorithms to tune PD control parameters are presented. Our purpose is to test the switched strategy, not to find the best PD control parameters.
To test the effectiveness of our switched control strategy, different scenarios are considered: commuted controller (
9)-(
10) is compared to the uncontrolled situation, and to system (
1)-() with the classic PD controller
defined in [
12] and [
14]:
where the control is defined by:
Decaying exponential disturbance
(
4): open-loop and closed-loop with commuted PD controller (
Figure 2,
Figure 3 and
Figure 4).
Change on the dynamic equation (
5), proving the efficiency of our control algorithm against slight modification on glucose assimilation (
Figure 7).
Finally, a reset-PID controller is implemented, showing that despite the rise time being reduced, the control law presents chattering, a non-desired effect for a pancreatic system (
Figure 8 and
Figure 9).
Figure 2.
From (a), we notice that Patient 2 presents strong hypoglycemia (reaching 30 mg/dl), and Patient 3 hyperglycemia (reaching 120 mg/dl). From closed-loop system (b), only Patient 3 presents hypoglycemia for one hour approximately, reaching the lowest glucose level 52mg/dl (considered healthy in [
4]).
Figure 2.
From (a), we notice that Patient 2 presents strong hypoglycemia (reaching 30 mg/dl), and Patient 3 hyperglycemia (reaching 120 mg/dl). From closed-loop system (b), only Patient 3 presents hypoglycemia for one hour approximately, reaching the lowest glucose level 52mg/dl (considered healthy in [
4]).
Figure 3.
Closed-loop simulations. Classic model (
16)-() with
(
19) from [
12], is compared to proposed system ()-(
5) with commuted PD controller (
9)-(
10). It shows how under the commuted PD controller (
9)-(
10) the glucose blood concentration is stabilized at
.
Figure 3.
Closed-loop simulations. Classic model (
16)-() with
(
19) from [
12], is compared to proposed system ()-(
5) with commuted PD controller (
9)-(
10). It shows how under the commuted PD controller (
9)-(
10) the glucose blood concentration is stabilized at
.
Figure 4.
Control input
(
9) and
(
10), with
defined in (
4), for each Patient under study. To prevent hypoglycemia, after a few minutes of the end of its injection, glucose ingestion is needed.
Figure 4.
Control input
(
9) and
(
10), with
defined in (
4), for each Patient under study. To prevent hypoglycemia, after a few minutes of the end of its injection, glucose ingestion is needed.
Figure 5.
Simulations of closed-loop system with external perturbation (
20). The proposed control strategy performs better than PD control
[
12], noticing that glucose ingestion is needed to prevent hypoglycemia episodes.
Figure 5.
Simulations of closed-loop system with external perturbation (
20). The proposed control strategy performs better than PD control
[
12], noticing that glucose ingestion is needed to prevent hypoglycemia episodes.
Figure 6.
Commuted PD controller (
9)-(
10), under external perturbation (
20). Notice that the glucose ingestion suggested is small compared with the glucose blood concentration.
Figure 6.
Commuted PD controller (
9)-(
10), under external perturbation (
20). Notice that the glucose ingestion suggested is small compared with the glucose blood concentration.
Figure 7.
Simulations of closed-loop system with commuted PD controller (
9)-(
10) when dynamical changes on the glucose assimilation are considered (
27)-(). Two comparative situations: (a) with
and (b) under external perturbation (
20). The behavior is similar to commuted model (
5), as
Figure 2 and
Figure 5 show.
Figure 7.
Simulations of closed-loop system with commuted PD controller (
9)-(
10) when dynamical changes on the glucose assimilation are considered (
27)-(). Two comparative situations: (a) with
and (b) under external perturbation (
20). The behavior is similar to commuted model (
5), as
Figure 2 and
Figure 5 show.
Figure 8.
Matlab Simulink diagram block model used to study the behavior of the proposed control strategy to our pancreatic plant, considering reset integrator (
29). When
, we obtain the commuted PD controller (
9)-(
10). As a resetting signal, we use a sinusoidal function
, and zero initial condition.
Figure 8.
Matlab Simulink diagram block model used to study the behavior of the proposed control strategy to our pancreatic plant, considering reset integrator (
29). When
, we obtain the commuted PD controller (
9)-(
10). As a resetting signal, we use a sinusoidal function
, and zero initial condition.
Figure 9.
Simulations of closed-loop system with external perturbation (
20), using PID with reset integrator (
29). The rise time is reduced in 10 minutes approximately compared to
Figure 5, but the control laws present chattering.
Figure 9.
Simulations of closed-loop system with external perturbation (
20), using PID with reset integrator (
29). The rise time is reduced in 10 minutes approximately compared to
Figure 5, but the control laws present chattering.
Each figure of glucose blood concentration displays the healthy range 60-110 [
10] to measure the duration of hypo- and hyperglycemia episodes. For each patient, we compute the glucose and insulin blood concentration
and
respectively, and the control action
and
(verifying in this case that they are both positive). The simulation results of patients are obtained using the data in
Table 1, with
[
7]. Note that in [
6],
is used. We decided to use a different value of it to be more realistic taking the exogenous factor into account. Also, the pump dynamics have been ignored (for a justification, see [
6]).
3.1. Decaying Exponential Disturbance Simulations
Figure 2 pictures the open-loop system response (
1)-(
4) with
.
Figure 2 presents the signal output of the closed-loop system ()-(
5) with the commuted PD control (
9)-(
10) showing the effectiveness of the proposed commuted PD controller. Also, a comparison is presented in
Figure 3, where the behavior of classic PD control [
12] does not perform better than the proposed control strategy. Furthermore, the commuted PD controller stabilizes the glucose blood concentration at the basal value
in the three cases. As
Figure 3 shows, no hypoglycemia is attained when commuted PD control (
9)-(
10) is chosen. That is not the case when
(
10) is not considered, as
behavior shows. In
Figure 3, considering commuted controller, in just a few minutes, hypoglycemia occurs. Then, the glucose blood concentration is normalized, but the basal glucose concentration is not reached.
Analysing
Figure 4, we see how commuted PD controller works. We comment on the Patient 1 case. During the first minutes after meal ingestion, when
is biggest, the system needs insulin injection to reduce the glucose concentration (graphic of
in
Figure 4). To normalize its level, glucose ingestion is needed an hour after (graphic of
in
Figure 4). This is a common situation difficult to deal with. This due to the insulin administration could be too strong for a pancreatic system. To mitigate this effect, we suggest ingesting some controlled quantity of glucose. This is done by
(
10) action. The same can be seen for Patients 2 and 3 given in
Figure 4 and
Figure 4, respectively.
3.2. External Noise Perturbation
We consider now an intake meal after 230 minutes after the controller is activated. It corresponds to the case of additive perturbation on (
1) or (
5), and defined as:
where the function
is the well-known Heaviside expression:
Due to the additional glucose ingestion, an additional rate of glucose absorption has to be considered (exponential function in (
20)). Hence, the classic mathematical model of the pancreatic system is given by [
12]:
Which modified to our controlled system, results:
with
defined in (
9) and
in (
10).
Figure 5Figure 6 present the simulations of Patients 1, 2, and 3 under the commuted PD controller action. In these cases, the commuted PD controller has a good performance, because no hypoglycemia range is attained. Hyperglycemia is attained only during ingestion, as expected.
3.3. Changes on Glucose Assimilation
Consider a more general case to system in (
5), where the dynamic of
is modified using an auxiliary variable
with an stable dynamic (
27)-():
We set
.
Figure 7 presents the simulations, where it can be noticed that its behavior is similar to (
5). So, we can conclude that our control algorithm is robust against to changes in patient dynamics for glucose assimilation.
3.4. PID Using Reset Integrator
As was mentioned in the introduction, we noticed from simulations that strong hypoglycemia occurs during a long period of time when the integral part in the PD controller is considered. In order to complete the study of the proposed switched strategy, we consider now a reset integral part. Hence, defining a commuted PID controller as:
The limitations of the linear integrator can be faced using a reset integrator, also named as Clegg integrator [
26]. This integrator resets its output to zero whenever its input and output have different signs [
27,
28]. Due to this resetting condition, the transient response of the controller can be arranged.
Figure 8 captures the Matlab Simulink model used to compute the numerical simulation experiments. Based on Clegg integrator [
26], we define a reset integrator block by taking into account that we need to integrate the error and to vanishing it. Then, from
Figure 8, we set:
Clegg integrator Input. The error between glucose blood concentration and the nominal value .
Clegg integrator Initial condition. After each reset to the Clegg integrator, an initial condition is needed to integrate at each resetting action. We use the zero initial condition setting.
Clegg integrator Resetting actions. The block can reset its state to the specified initial condition based on an external signal. We choose to reset the integrator when the sinus function changes its sign.
Clegg integrator gain. The parameter was found by the trial and error method.
Figure 9 shows the behavior of the commuted PID controller (
29), where the rise time is reduced to 10 minutes approximately. But the controller presents chattering in all cases (we picture Patient 1 in
Figure 9 as an example), and the insulin injection is increased.
4. Discussion of Results
This paper proposes a new strategy to control the glucose blood concentration in a pancreatic system, and with the control objective to reduce the error between this concentration with respect to the basal one. As it is well-known, the main idea is to administrate insulin to prevent hyperglycemia. But this insulin dose could be too strong, falling into the hypoglycemia region. To mitigate this effect, we suggest ingesting some controlled quantity of glucose. The method used to define the controllers is the Proportional-Derivative one, which is able to stabilize the glucose concentration around its basal value. The key feature is to avoid an unhealthy glucose concentration range, combining insulin injection with glucose administration. Then, two control actions are defined: one to modify the insulin dynamic (and prevent hyperglycemia), and the other one to to improve the perform the glucose dynamic (and prevent hypoglycemia).
The simulations test the closed-loop performance on four different human behaviors. Moreover, external perturbations are considered, as meal ingestion. The results are comparable or improved with respect to other works. The purpose of this work is to study the behavior of this novel strategy, and opens the possibility of testing this switched strategy on another type of controller.
Finally, two complementary studies are presented. One is based on modifying the glucose absorption dynamic, to test the robustness of the commuted PD controller. The other study was to include an integral part to our controller approach, defining a PID with a resetting integrator action, showing that despite the rise-time of closed-loop dynamics is reduced, chattering on the controller appears inevitably.