# Optimal Control of HIV Dynamic Using Embedding Method

Authors: H. Zarei; A. V. Kamyad; M. H. Farahi
Journal: Computational and Mathematical Methods in Medicine
 (2011)

---

## Abstract

This present study proposes an optimal control problem, with the final goal of implementing an optimal treatment protocol which could maximize the survival time of patients and minimize the cost of drug utilizing a system of ordinary differential equations which describes the interaction of the immune system with the human immunodeficiency virus (HIV). Optimal control problem transfers into a modified problem in measure space using an embedding method in which the existence of optimal solution is guaranteed by compactness of the space. Then the metamorphosed problem is approximated by a linear programming (LP) problem, and by solving this LP problem a suboptimal piecewise constant control function, which is more practical from the clinical viewpoint, is achieved. The comparison between the immune system dynamics in treated and untreated patients is introduced. Finally, the relationships between the healthy cells and virus are shown.


---

## Body

## 1. Introduction

Human immunodeficiency virus infects CD4+ T-cells, which are an important part of the human immune system, and other target cells. The infected cells produce a large number of viruses. Medical treatments for HIV have greatly improved during the last two decades. Highly active antiretroviral therapy (HAART) allows for the effective suppression of HIV-infected individuals and prolongs the time before the onset of acquired immune deficiency syndrome (AIDS) for years or even decades and increases life expectancy and quality to the patient. But antiretroviral therapy cannot eradicate HIV from infected patients because of the long-lived infected cells and sites within the body where drugs may not achieve effective levels [1–3]. HAART contains two major types of anti-HIV drugs: reverse transcriptase inhibitors (RTI), and protease inhibitors (PI). Reverse transcriptase inhibitors prevent HIV from infecting cells by blocking the integration of the HIV viral code into the host cell genome while protease inhibitors prevent infected cells from replication of infectious virus particles, and can reduce and maintain viral load below the limit of detection in many patients. Moreover, treatment with either type of drugs can also increase the CD4+ T-cell counts that are target cells for HIV.Many of the host-pathogen interaction mechanisms during HIV infection and progression to AIDS are still unknown. Mathematical modeling of HIV infection is of interest to the medical community as no adequate animal models exist to test the efficacy of drug regimes. These models can test different assumptions and provide new insights into questions that are difficult to answer by clinical or experimental studies. A number of mathematical models have been formulated to describe various aspects of the interaction of HIV with healthy cells. Some of these models are addressed in [4]. The basic model of HIV infection is presented by Wodarz and Nowak [5], which contains three state variables: healthy CD4+ T-cells, infected CD4+ T-cells, and concentration of free virus. Their model has been modified to offer important theoretical insights into immune control of the virus, based on treatment strategies, while maintaining a simple structure [6]. Furthermore, this modified model has been developed to guess the natural evolution of HIV infection, as qualitatively described in several clinical studies [7].Some authors have used mathematical models for HIV infection in conjunction with control theory to achieve appropriate goals. For example, these goals may include maximizing the level of healthy CD4+ T-cells and minimizing the cost of treatment [8–11], maximizing the level of healthy CD4+ T-cells while minimizing both the cost of treatment and viral load [12], minimizing both the HIV population and systemic costs to body while maximizing immune response [13, 14], and maximizing both the healthy CD4+ T-cell counts and immune response while minimizing the cost of treatment [15], maximizing the healthy CD4+ T-cell counts and minimizing both the side effects and drug resistance [16].The papers [17–21] consider only RTI medication while the papers [22, 23] consider only PIs. In [24–27], all effects of a HAART medication are combined to one control variable in the model. In  [28–32], dynamical multidrug therapies based on RTIs and PIs are designed.In this paper, a mathematical model of HIV dynamic is considered that includes the effect of antiretroviral therapy, and an analysis of optimal control is performed regarding appropriate goals.The paper is organized as follows: in Section2, the underlying HIV mathematical model is described. Our formulation of the control problem, which attempts to prolong the survival time of patient as long as possible, is described in Section 3. Approximating the obtained optimal control problem by an LP problem is the subject of Section 4. Numerical results obtained from solving the LP problem are presented in Section 5. Finally, Section 6 is assigned to concluding remarks.


## 2. Presentation of a Working Model

In this paper, the pathological behavior of HIV is considered which is modeled with the simplified version of a system of ordinary differential equations (ODEs) as described in [17]. This model, which is consistent with clinical data, is given as follows:(1)dP̅(t)dt=IP̅+β(P0-P(t))-τ̅pP̅(t)-c̅Pa(t)C(t)P̅(t),(2)dP(t)dt=τ̅PP̅(t)-τPP(t)-cPa(t)C(t)P(t),(3)da(t)dt=a(t)(κθ-γC(t)),(4)dC(t)dt=a(t)(εIC+αC(t))(P(t)P0)υ-τCC(t).
Most of the terms in this model have straightforward interpretations. P̅(·) and P(·) denote the amounts of immature CD4+ T-cells and mature ones, respectively. The term a(·) indicates HIV particles, and C(·) designates cytotoxic T-cells specific for HIV (CTLs) as a function of time. Here, IP̅ is the constant rate that P̅ cells are produced, τ̅p is the rate of maturation of P̅ cells into P cells, and τp is the rate of natural death of P cells. Furthermore, β is the amplifying coefficient of the linear feedback effect of P cells decrease on the influx of P̅ cells at time t. Free virus particles a(t) eliminate P̅(·) cells  at a rate proportional to c̅Pa(t)C(t)P̅(t) at time t. Similarly, cPa(t)C(t)P(t) is the rate of elimination of P cells. The term θ characterizes the growth rate of HIV particles, and γ is the rate of inactivation of HIV products mediated by cytotoxic C cells. IC is the influx of C cell precursors, ε is their maturation rate, α is  the proliferation rate of C cells under the antigenic stimulation by HIV products, and τC is their natural death rate. Helper T-cells effect on maturation and proliferation of C cells is expressed by the ratio P(t)/P0, and ν is introduced to characterize the intensity of this helper effect. Chemotherapeutic agent was simulated by decreasing the value κ, that is, the HIV proliferation rate. Lower value for κ corresponds to higher RTI-drug doses.


## 3. Optimal Control Formulation

In this section, we  formulate an optimal control problem that identifies the inhibition parameterκ in (3), with a function of the control variable. In particular, we will replace the parameter κ with the function 1-u(t). This choice then identifies the control variable u(t) with the rate of inhibition of virus reproduction, which is modeled as a  simple function of drug dosage.In clinical practice, the following guidelines are used typically.(i)
Antiretroviral therapy is initiated att0, the time at which the CD4+ T-cell count falls below 350 cells/μL.(ii)
The transition from HIV to AIDS is marked by a CD4+ T-cell count below 200 cells/μL.(iii)
A person is said to have full-blown AIDS when his/her CD4+ T-cell count falls belowCD4crit+, typically around of 50 cells/μL.This paper aims to propose a drug regimen that delays the onset of full-blown AIDS and prolongs survival as much as possible, while one is going to minimize the drug costs. This can be modeled as follows.Assume that the onset of full-blown AIDS occurs after timetf. Hence, we should have(5)P(t)≥CD4crit+,t∈[t0,tf],P(tf)=CD4crit+.
A problem arising from the use of most chemotherapies is the multiple and sometimes harmful side effects, as well as the ineffectiveness of treatment after a certain time due to the capability of the virus to mutate and become resistant to the treatment. Global effects of these phenomena can be considered by imposing limited treatment interval [22], that is, treatment lasting for a given period from time t0 to t0+η. Therefore, the support of the control function u(·) must be in the treatment interval (6)supp⁡⁡u⊆[t0,t0+η].
Here, we follow [8, 22] in assuming that the costs of the treatment is proportional to u2(t) at time t. Therefore, the overall cost of the treatment is ∫t0tfu2(t)dt. So, the following functional should be maximized:(7)σ(tf,u)=tf-λ∫t0tfu2(t)dt.
Parameter λ is used to set the relative importance between maximizing the survival time tf and minimizing the systemic cost to the body. Setting P̅=x1, P=x2, a=x3, and C=x4, the system of differential equations (1)–(4) can be represented in a generalized form as(8)ẋ(t)=g(t,x(t),u(t))=(IP+β(x20-x2)-τ̅Px1-c̅Px3x4x1τ̅Px1-τPx2-cPx3x4x2x3((1-u)θ-γx4)(εIC+αx4)x3(x2x20)υ-τCx4),x(0)=x0.
Assume that K denotes the set of all measurable control functions u(·)∈[0,1], where u(·) satisfies (6), and the corresponding solution of (8) at final time tf satisfies (5). Therefore, we are seeking for u*(·)∈K such that (9)σ(tf,u)≤σ(tf*,u*),∀u∈K.
Setting f0(t,x(t),u(t))=1-λu2(t), then the optimal drug regimen problem, while ignoring t0, can be represented as:(10)max⁡tf,u∈K⁡∫t0tff0(t,x(t),u(t))dt
subject to(11)ẋ=g(t,x(t),u(t)),(12)x(t0)=xt0,x2(tf)=CD4crit+,(13)x2(t)≥CD4crit+,t∈[t0,tf].This optimal control problem is referred to as OCP. Some problems may arise in the quest of solving OCP. The setK may be empty. If K is not empty, the functional measuring the performance of the system may not achieve its maximum in the set K. In order to overcome these difficulties, in the next section we transfer the OCP into a modified problem in measure space.


## 4. Approximation of OCP by Linear Programming Problem

Using measure theory for solving optimal control problems based on the idea of Young [33], which was applied for the first time by Wilson and Rubio [34], has been theoretically established by Rubio in [35]. Then, the method has been extended for approximating the time optimal problems by an LP model [36]. Here, this approach is used.


### 4.1. Functional Space

We assume that the state variablesx(·) and the control input u(·), respectively, get their values in the compact sets A=A1×A2×A3×A4⊂ℜ4 and U⊂ℜ. Set J=[t0,tf]. Here, we are going to derive weak forms for (11)–(13).Definition 1.
A triplep=[tf,x,u] is said to be admissible if the following conditions hold.(i)
The vector functionx(·) is absolutely continuous and belongs to A for all t∈J.(ii)
The functionu(·) takes its values in the set U and is Lebesgue measurable on J.(iii)
p satisfies in (11)–(13), on J0, that is, the interior set of J.It is assumed that the set of all admissible triples is nonempty and denotes it by W. Let p be an admissible triple, B be an open ball in ℜ5 containing J×A, and let C′(B) be the space of all real-valued continuous differentiable functions on it. Let φ∈C′(B), and define φg as follows:
(14)φg(t,x(t),u(t))=φx(t,x(t))⋅g(t,x(t),u(t))+φt(t,x(t))
for each [t,x(t),u(t)]∈Ω, where Ω=J×A×U. The function φg is in the space C(Ω), the set of all continuous functions on the compact set Ω. Since p=[tf,x,u] is an admissible triple, we have
(15)∫t0tfφg(t,ξ(t),u(t))dt=∫t0tfφx(t,x(t))⋅ẋ(t)+φt(t,x(t))dt=φ(tf,x(tf))-φ(t0,x(t0))=Δφ,
for all φ∈C′(B). Let D(J0) be the space of all infinitely differentiable real-valued functions with compact support in J0. Define
(16)ψn(t,x(t),u(t))=xn(t)ψ′(t)+gn(t,x(t),u(t))ψ(t),n=1,2,3,4,∀ψ∈D(J0).
Assume p=[tf,x,u] be an admissible triple. Since the function ψ(·) has compact support in J0, ψ(t0)=ψ(tf)=0. Thus, for n=1,2,3,4, and for all ψ∈D(J0), from (16) and using integration by parts, we have
(17)∫t0tfψn(t,x(t),u(t))dt=∫t0tfxn(t)ψ′(t)dt+∫t0tfgn(t,x(t),u(t))ψ(t)dt=0.
Also, by choosing the functions which are dependent only on time, we have
(18)∫t0tfϑ(t,x(t),u(t))dt=aϑ,∀ϑ∈C1(Ω),
where C1(Ω) is the space of all functions in C(Ω) that depend only on time and aϑ is the integral of ϑ(·) on J.
Equations (15), (17), and (18) are the weak forms of (11)–(13). Note that the constraints (12) are considered on the right-hand side of (15) by choosing suitable functions φ∈C′(B) which are monomials of x2. Furthermore, the constraint (13) is considered, by choosing an appropriate set A. Now, we consider the following positive linear functional on C(Ω):
(19)Γp:F⟶∫JF(t,x(t),u(t))dt,∀F∈C(Ω).Proposition 1.
Transformationp→Γp of admissible triples in W into the linear mappings Γp defined in (19) is an injection.Proof.
We must show that ifp1≠p2, then Γp1≠Γp2. Let pj=[tfj,xj,uj],j=1,2 be different admissible triples. If tf1=tf2, then there is a subinterval of [t0,tf1], say J1, where x1(t)≠x2(t) for each t∈J1. A continuous function F can be constructed on Ω so that the right-hand sides of (19) corresponding to p1 and p1 are not equal. For instance, one can make F independent of u, equal zero for all t outside J1, and such that it is positive on the appropriate portion of x1(·), and zero on the x2(·), then the linear functionals are not equal. In other words, if tf1≠tf2, then Γp1 and Γp2 have different domains and are not equal.Thus, from (15), (17), and (18), one can conclude that maximizing the functional (10) over admissible space W, changes to the following optimization problem in functional space:(20)max⁡p∈W⁡Γp(f0)
subject to(21)Γp(φg)=Δφ,φ∈C′(B),(22)Γp(ψn)=0,n=1,2,3,4,ψ∈D(J0),(23)Γp(ϑ)=aϑ,ϑ∈C1(Ω).


### 4.2. Measure Space

LetM+(Ω) denote the space of all positive Radon measures on Ω. By the Riesz representation theorem [35], there exists a unique positive Radon measure μ on Ω such that(24)Γp(F)=∫JF(t,x(t),u(t))dt=∫ΩF(t,x,u)dμ≡μ(F),F∈C(Ω).
So, we may change the functional space of the optimization problem to measure space. In other words, the optimization problem (20)–(23) can be converted to the following optimization problem in measure space:(25)Maximizeμ∈M+(Ω)⁡μ(f0)
subject to(26)μ(φg)=Δφ,φ∈C′(B),(27)μ(ψn)=0,n=1,2,3,4,ψ∈D(J0),(28)μ(ϑ)=aϑ,ϑ∈C1(Ω).We will consider maximization of (25) over the set Q of all positive Radon measures on Ω, satisfying (26)–(28). The main advantages of considering this measure theoretic form of the problem is the existence of optimal measure in the set Q where this point can be studied in a straightforward manner without having to impose conditions such as convexity which may be artificial.Define functionI:Q→R as I(μ)=μ(f0). The following theorem guarantees the existence of an optimal solution.Theorem 1.
The measure theoretical problem of maximizing (25) with constraints (26)–(28) has an optimal solution, say μ*, where μ*∈Q.Proof.
The so-called constraints (27) and (28) are special cases of (26) [35]. So, the set Qcan be written as
(29)Q=⋂φ∈C′(B){μ∈M+(Ω):μ(φg)=Δφ}.
Assume that p=[tf,x,u] is an admissible triple. It is well known that the set {μ∈M+(Ω):μ(1)=tf-t0} is compact in the weak* topology. Furthermore, the set Q as intersection of inverse image of closed singleton sets {Δφ} under the continuous functions μ→μ(φg) is also closed. Thus, Q is a closed subset of a compact set. This proves the compactness of the set Q. Since the functional I, mapping the compact set Q on the real line, is continuous and thus takes its maximum on the compact set Q.Next, based on analysis in [35], the problem (25)–(28) is approximated by an LP problem, and a triple p* which approximates the action of μ*∈Q is achieved.


### 4.3. Approximation

The problem (25)–(28) is an infinite-dimensional linear programming problem, and we are mainly interested in approximating it. First, the maximization of I is considered not over the set Q,but over a subset of it denoted by requiring that only a finite number of constraints (26)–(28) be satisfied. Let {φi:i=1,2,…}, {ψj:j=1,2,…}, and {ϑs:s=1,2,…} be the sets of total functions, respectively, in C′(B), D(J0), and C1(Ω). The first approximation is completed by choosing finite number of functions φis,  ψjs, and ϑss. Now we have the following propositions.Proposition 2.
Consider the linear program problem consisting of maximizing the functionI over the set QM of measures in M+(Ω) satisfying:
(30)μ(φig)=Δφi,i=1,…,M.
Then, JM≡maxQMI tends to J=maxQI as M→∞.Proof.
We haveQ1⊇Q2⊇⋯⊇QM⊇⋯⊇Q and hence, J1≥J2≥⋯≥JM≥⋯≥J. The sequence {Jj}j=1∞ is nonincreasing and bounded, so, it converges to a number ζ such that ζ≥J. We show that ζ=J. Set R≡⋂M=1∞QM. Then, R⊇Q and ζ≡maxRI. It is sufficient to show R⊆Q. Assume μ∈R and φ∈C′(B). Since the linear combinations of the functions {φj,j=1,2,…} are uniformly dense in C′(B), there is a sequence {φ̃k}∈span{φj,j=1,2,…}, such that φ̃k tends to φ uniformly as k→∞. Hence, S1, S2, and S3 tend to zero as k→∞ where S1=sup|φx-φ̃kx|, S2=sup|φt-φ̃kt|, and S3=sup|φ-φ̃k|. Since μ∈R and the functional f→μ(f) is linear, μ(φ̃kg)=Δφ̃k and
(31)|μ(φg)-Δφ|=|μ(φg)-Δφ-μ(φ̃kg)+Δφ̃k|=|∫Ω{[φx(t,x)-φ̃kx(t,x)]g(t,x,u)+[φt(t,x)-φ̃kt(t,x)]}dμ-(Δφ-Δφ̃k)∫Ω{g(t,x,u)|≤S1∫Ω|g(t,x,u)|dμ+S2∫Ωdμ+2S3.
The right-hand side of the above inequality tends to zero as k→∞, and the left-hand side is independent of k; therefore μ(φg)=Δφ. Thus, R⊆Q and ζ≤J, which implies ζ=J.Proposition 3.
The measureμ* in the set QM at which the functional I attains its maximum has the form
(32)μ*=∑j=1Mα*jδ(zj*),
where αj*≥0, zj*∈Ω, and δ(z) is unitary atomic measure with the support being the singleton set {zj*}, characterized by δ(z)(F)=F(z), z∈Ω.Proof .
See [35].Therefore, our attention is restricted to finding a measure in the form of (32), which maximizes the functional I and satisfies in M number of the constraints (26)–(28). Thus, by choosing the functions φi, i=1,2,…,M1, ψk, k=1,…,M2, and ϑs, s=1,…,S, the infinite dimensional problem (25)–(28) is approximated by the following finite dimensional nonlinear programming (NLP) problem: (33)Maximizeαj≥0,zj∈Ω⁡∑j=1Mαjf0(zj)
subject to(34)∑j=1Mαjφig(zj)=Δφi,i=1,…,M1,(35)∑j=1Mαjψkn(zj)=0,k=1,…,M2,n=1,2,3,4,(36)∑j=1Mαjϑs(zj)=aϑs,s=1,…,S,
where M=M1+4M2+S. Clearly, (33)–(36) is an NLP problem with 2 M unknowns: αj and zj, j=1,…,M. One is interested in LP problem. The following proposition enables us to approximate the NLP problem (33)–(36) by a finite dimensional LP problem.Proposition 4.
LetΩN={y1,y2,…,yN} be a countable dense subset of Ω. Given ε>0, a measure v∈M+(Ω) can be found such that:
(37)|v(f0)-μ*(f0)|≤ε,|v(φig)-μ*(φig)|≤ε,i=1,…,M1,|v(ψkn)-μ*(ψkn)|≤ε,k=1,…,M2,n=1,2,3,4,|v(ϑs)-μ*(ϑs)|≤ε,s=1,…,S,
where the measure v has the form
(38)v=∑j=1Mαj*δ(yj),
and the coefficients αj*, j=1,…,M, are the same as optimal measure (32), and yj∈ΩN, j=1,…,M.Proof.
We rename the functionsf0, φig’s, ψkn’s, and ϑs’s sequentially as hj,  j=1,2,…,M+1. Then, for  j=1,…,M+1,
(39)|(μ*-v)hj|=|∑i=1Mαi*[hj(zi*)-hj(yi)]|≤(∑i=1Mαi*)max⁡i,j⁡|hj(zi*)-hj(yi)|.hjs are continuous. Therefore, maxi,j can be made less than ε/∑j=1Mαj* by choosing yi, i=1,2,…,M, sufficiently near zi*.For constructing a suitable setΩN, which preserves the relation (6), J is divided to S subintervals as follows:(40)Js=[t0+(s-1)ΔTS-1,t0+sΔTS-1),s=1,2,…,S-1,JS=[tl,tf),
where tl is a lower bound for optimal time tf, which can be obtained by using a search algorithm based on golden section [36] or Fibonnaci search method [37]. Let S̅ be the largest number such that JS̅⊆[t0,t0+η]. Set J1=⋃s=1S̅Js, J2=⋃s=S̅+1SJs, Ω1=J1×A×U,  and  Ω2=J2×A×{0}. Moreover, the intervals Ai (i=1,2,3,4) and U are divided, respectively, into ni and m subintervals. So, the sets Ωi, i=1,2, are partitioned into N1=S̅n1n2n3n4m and N2=(S-S̅)n1n2n3n4 cells, respectively. One point is chosen from each cell. In this way, we will have a grid of points, which are numbered sequentially as yj=(tj,x1j,…,x4j,uj), j=1,…,N, where  N=N1+N2.Therefore, according to (38), the NLP problem (33)–(36) is converted to the following  LP problem:(41)Maximizeαj≥0⁡∑j=1Mαjf0(yj)
subject to(42)∑j=1Nαjφig(yj)=Δφi,i=1,…,M1,(43)∑j=1Nαjψkn(yj)=0,k=1,…,M2,n=1,2,3,4,(44)∑j=1Nαjϑs(yj)=aϑs,s=1,…,S.Here, we discuss suitable total functionsφis, ψks, and ϑss. The functions φis can be taken to be monomials of t and the components of the vector x as follows:(45)tix2j,x2jxhi,i∈{0,1},j∈{1,2,…},h∈{1,3,4}.
In addition, we choose some functions with compact support in the following form [36, 37]: (46)ψ2r-1(t)={sin⁡(2πr(t-t0)ΔT)t≤tl0otherwise,ψ2r(t)={1-cos⁡⁡(2πr(t-t0)ΔT)t≤tl0otherwise,
where r=1,2,… and ΔT=tl-t0. Finally, the following functions are considered that are dependent on t only:(47)ϑs(t)={1t∈Js0otherwise,
where Js, s=1,…,S, are given by (40). These functions are used to construct the approximate piecewise constant control [35–37]. By the above definition of ϑs, we consider tf as an unknown variable in the constraints (44) which can be written as(48)∑j=1lαj=ΔTS-1⋮∑j=(S-2)l+1(S-1)lαj=ΔTS-1∑j=(S-1)l+1Slαj=tf-tl,
where ℓ=N/S. Of course, we need only to construct the control function u(·), since x(·) can be obtained by solving the ODEs (8). By using simplex method, a nonzero optimal solution αi1*,αi2*,…,αik*, i1<i2<⋯<ik of  the LP problem (41)–(44) can be found where k cannot exceed the number of constraints, that is, k≤M1+M2+S. Setting αi0*=t0, a piecewise control function u(·) approximating the optimal control is constructed based on these nonzero coefficients as follows [35, 36]:(49)u(t)={uijt∈[∑h=0j-1αih*,∑h=0jαih*)0otherwise,j=1,2,…,k,
where uijis the 6th  component of yij.To start the proposed method, one needs to havetl. Here, a bisection method is proposed to find the desired lower bound tl for optimal time tf*. This algorithm has a simple structure and is started with a given upper bound tu, where it is assumed that the lower bound starts with tl=0. Assuming that tf*(tl) denotes the solution of LP problem  (41)–(44) corresponding to the given lower bound tl, the bisection method is outlined as follows.Algorithm 1 (estimation of the lower boundtl).
First, letτ=[tl,tu], where tl=0 and tu is an upper bound for tf*.
Step 1.
Leta=(tl+tu)/2 and solve the corresponding LP problem to find tf*(a). If no feasible solution is found for the corresponding LP problem or tf*(a)=a, set tu=a; else set tl=a.
Step 2.
If the length of the intervalτ=[tl,tu] is small enough, then choose tl as a good estimation for lower bound tf* else, go to Step 1.


## 4.1. Functional Space

We assume that the state variablesx(·) and the control input u(·), respectively, get their values in the compact sets A=A1×A2×A3×A4⊂ℜ4 and U⊂ℜ. Set J=[t0,tf]. Here, we are going to derive weak forms for (11)–(13).Definition 1.
A triplep=[tf,x,u] is said to be admissible if the following conditions hold.(i)
The vector functionx(·) is absolutely continuous and belongs to A for all t∈J.(ii)
The functionu(·) takes its values in the set U and is Lebesgue measurable on J.(iii)
p satisfies in (11)–(13), on J0, that is, the interior set of J.It is assumed that the set of all admissible triples is nonempty and denotes it by W. Let p be an admissible triple, B be an open ball in ℜ5 containing J×A, and let C′(B) be the space of all real-valued continuous differentiable functions on it. Let φ∈C′(B), and define φg as follows:
(14)φg(t,x(t),u(t))=φx(t,x(t))⋅g(t,x(t),u(t))+φt(t,x(t))
for each [t,x(t),u(t)]∈Ω, where Ω=J×A×U. The function φg is in the space C(Ω), the set of all continuous functions on the compact set Ω. Since p=[tf,x,u] is an admissible triple, we have
(15)∫t0tfφg(t,ξ(t),u(t))dt=∫t0tfφx(t,x(t))⋅ẋ(t)+φt(t,x(t))dt=φ(tf,x(tf))-φ(t0,x(t0))=Δφ,
for all φ∈C′(B). Let D(J0) be the space of all infinitely differentiable real-valued functions with compact support in J0. Define
(16)ψn(t,x(t),u(t))=xn(t)ψ′(t)+gn(t,x(t),u(t))ψ(t),n=1,2,3,4,∀ψ∈D(J0).
Assume p=[tf,x,u] be an admissible triple. Since the function ψ(·) has compact support in J0, ψ(t0)=ψ(tf)=0. Thus, for n=1,2,3,4, and for all ψ∈D(J0), from (16) and using integration by parts, we have
(17)∫t0tfψn(t,x(t),u(t))dt=∫t0tfxn(t)ψ′(t)dt+∫t0tfgn(t,x(t),u(t))ψ(t)dt=0.
Also, by choosing the functions which are dependent only on time, we have
(18)∫t0tfϑ(t,x(t),u(t))dt=aϑ,∀ϑ∈C1(Ω),
where C1(Ω) is the space of all functions in C(Ω) that depend only on time and aϑ is the integral of ϑ(·) on J.
Equations (15), (17), and (18) are the weak forms of (11)–(13). Note that the constraints (12) are considered on the right-hand side of (15) by choosing suitable functions φ∈C′(B) which are monomials of x2. Furthermore, the constraint (13) is considered, by choosing an appropriate set A. Now, we consider the following positive linear functional on C(Ω):
(19)Γp:F⟶∫JF(t,x(t),u(t))dt,∀F∈C(Ω).Proposition 1.
Transformationp→Γp of admissible triples in W into the linear mappings Γp defined in (19) is an injection.Proof.
We must show that ifp1≠p2, then Γp1≠Γp2. Let pj=[tfj,xj,uj],j=1,2 be different admissible triples. If tf1=tf2, then there is a subinterval of [t0,tf1], say J1, where x1(t)≠x2(t) for each t∈J1. A continuous function F can be constructed on Ω so that the right-hand sides of (19) corresponding to p1 and p1 are not equal. For instance, one can make F independent of u, equal zero for all t outside J1, and such that it is positive on the appropriate portion of x1(·), and zero on the x2(·), then the linear functionals are not equal. In other words, if tf1≠tf2, then Γp1 and Γp2 have different domains and are not equal.Thus, from (15), (17), and (18), one can conclude that maximizing the functional (10) over admissible space W, changes to the following optimization problem in functional space:(20)max⁡p∈W⁡Γp(f0)
subject to(21)Γp(φg)=Δφ,φ∈C′(B),(22)Γp(ψn)=0,n=1,2,3,4,ψ∈D(J0),(23)Γp(ϑ)=aϑ,ϑ∈C1(Ω).


## 4.2. Measure Space

LetM+(Ω) denote the space of all positive Radon measures on Ω. By the Riesz representation theorem [35], there exists a unique positive Radon measure μ on Ω such that(24)Γp(F)=∫JF(t,x(t),u(t))dt=∫ΩF(t,x,u)dμ≡μ(F),F∈C(Ω).
So, we may change the functional space of the optimization problem to measure space. In other words, the optimization problem (20)–(23) can be converted to the following optimization problem in measure space:(25)Maximizeμ∈M+(Ω)⁡μ(f0)
subject to(26)μ(φg)=Δφ,φ∈C′(B),(27)μ(ψn)=0,n=1,2,3,4,ψ∈D(J0),(28)μ(ϑ)=aϑ,ϑ∈C1(Ω).We will consider maximization of (25) over the set Q of all positive Radon measures on Ω, satisfying (26)–(28). The main advantages of considering this measure theoretic form of the problem is the existence of optimal measure in the set Q where this point can be studied in a straightforward manner without having to impose conditions such as convexity which may be artificial.Define functionI:Q→R as I(μ)=μ(f0). The following theorem guarantees the existence of an optimal solution.Theorem 1.
The measure theoretical problem of maximizing (25) with constraints (26)–(28) has an optimal solution, say μ*, where μ*∈Q.Proof.
The so-called constraints (27) and (28) are special cases of (26) [35]. So, the set Qcan be written as
(29)Q=⋂φ∈C′(B){μ∈M+(Ω):μ(φg)=Δφ}.
Assume that p=[tf,x,u] is an admissible triple. It is well known that the set {μ∈M+(Ω):μ(1)=tf-t0} is compact in the weak* topology. Furthermore, the set Q as intersection of inverse image of closed singleton sets {Δφ} under the continuous functions μ→μ(φg) is also closed. Thus, Q is a closed subset of a compact set. This proves the compactness of the set Q. Since the functional I, mapping the compact set Q on the real line, is continuous and thus takes its maximum on the compact set Q.Next, based on analysis in [35], the problem (25)–(28) is approximated by an LP problem, and a triple p* which approximates the action of μ*∈Q is achieved.


## 4.3. Approximation

The problem (25)–(28) is an infinite-dimensional linear programming problem, and we are mainly interested in approximating it. First, the maximization of I is considered not over the set Q,but over a subset of it denoted by requiring that only a finite number of constraints (26)–(28) be satisfied. Let {φi:i=1,2,…}, {ψj:j=1,2,…}, and {ϑs:s=1,2,…} be the sets of total functions, respectively, in C′(B), D(J0), and C1(Ω). The first approximation is completed by choosing finite number of functions φis,  ψjs, and ϑss. Now we have the following propositions.Proposition 2.
Consider the linear program problem consisting of maximizing the functionI over the set QM of measures in M+(Ω) satisfying:
(30)μ(φig)=Δφi,i=1,…,M.
Then, JM≡maxQMI tends to J=maxQI as M→∞.Proof.
We haveQ1⊇Q2⊇⋯⊇QM⊇⋯⊇Q and hence, J1≥J2≥⋯≥JM≥⋯≥J. The sequence {Jj}j=1∞ is nonincreasing and bounded, so, it converges to a number ζ such that ζ≥J. We show that ζ=J. Set R≡⋂M=1∞QM. Then, R⊇Q and ζ≡maxRI. It is sufficient to show R⊆Q. Assume μ∈R and φ∈C′(B). Since the linear combinations of the functions {φj,j=1,2,…} are uniformly dense in C′(B), there is a sequence {φ̃k}∈span{φj,j=1,2,…}, such that φ̃k tends to φ uniformly as k→∞. Hence, S1, S2, and S3 tend to zero as k→∞ where S1=sup|φx-φ̃kx|, S2=sup|φt-φ̃kt|, and S3=sup|φ-φ̃k|. Since μ∈R and the functional f→μ(f) is linear, μ(φ̃kg)=Δφ̃k and
(31)|μ(φg)-Δφ|=|μ(φg)-Δφ-μ(φ̃kg)+Δφ̃k|=|∫Ω{[φx(t,x)-φ̃kx(t,x)]g(t,x,u)+[φt(t,x)-φ̃kt(t,x)]}dμ-(Δφ-Δφ̃k)∫Ω{g(t,x,u)|≤S1∫Ω|g(t,x,u)|dμ+S2∫Ωdμ+2S3.
The right-hand side of the above inequality tends to zero as k→∞, and the left-hand side is independent of k; therefore μ(φg)=Δφ. Thus, R⊆Q and ζ≤J, which implies ζ=J.Proposition 3.
The measureμ* in the set QM at which the functional I attains its maximum has the form
(32)μ*=∑j=1Mα*jδ(zj*),
where αj*≥0, zj*∈Ω, and δ(z) is unitary atomic measure with the support being the singleton set {zj*}, characterized by δ(z)(F)=F(z), z∈Ω.Proof .
See [35].Therefore, our attention is restricted to finding a measure in the form of (32), which maximizes the functional I and satisfies in M number of the constraints (26)–(28). Thus, by choosing the functions φi, i=1,2,…,M1, ψk, k=1,…,M2, and ϑs, s=1,…,S, the infinite dimensional problem (25)–(28) is approximated by the following finite dimensional nonlinear programming (NLP) problem: (33)Maximizeαj≥0,zj∈Ω⁡∑j=1Mαjf0(zj)
subject to(34)∑j=1Mαjφig(zj)=Δφi,i=1,…,M1,(35)∑j=1Mαjψkn(zj)=0,k=1,…,M2,n=1,2,3,4,(36)∑j=1Mαjϑs(zj)=aϑs,s=1,…,S,
where M=M1+4M2+S. Clearly, (33)–(36) is an NLP problem with 2 M unknowns: αj and zj, j=1,…,M. One is interested in LP problem. The following proposition enables us to approximate the NLP problem (33)–(36) by a finite dimensional LP problem.Proposition 4.
LetΩN={y1,y2,…,yN} be a countable dense subset of Ω. Given ε>0, a measure v∈M+(Ω) can be found such that:
(37)|v(f0)-μ*(f0)|≤ε,|v(φig)-μ*(φig)|≤ε,i=1,…,M1,|v(ψkn)-μ*(ψkn)|≤ε,k=1,…,M2,n=1,2,3,4,|v(ϑs)-μ*(ϑs)|≤ε,s=1,…,S,
where the measure v has the form
(38)v=∑j=1Mαj*δ(yj),
and the coefficients αj*, j=1,…,M, are the same as optimal measure (32), and yj∈ΩN, j=1,…,M.Proof.
We rename the functionsf0, φig’s, ψkn’s, and ϑs’s sequentially as hj,  j=1,2,…,M+1. Then, for  j=1,…,M+1,
(39)|(μ*-v)hj|=|∑i=1Mαi*[hj(zi*)-hj(yi)]|≤(∑i=1Mαi*)max⁡i,j⁡|hj(zi*)-hj(yi)|.hjs are continuous. Therefore, maxi,j can be made less than ε/∑j=1Mαj* by choosing yi, i=1,2,…,M, sufficiently near zi*.For constructing a suitable setΩN, which preserves the relation (6), J is divided to S subintervals as follows:(40)Js=[t0+(s-1)ΔTS-1,t0+sΔTS-1),s=1,2,…,S-1,JS=[tl,tf),
where tl is a lower bound for optimal time tf, which can be obtained by using a search algorithm based on golden section [36] or Fibonnaci search method [37]. Let S̅ be the largest number such that JS̅⊆[t0,t0+η]. Set J1=⋃s=1S̅Js, J2=⋃s=S̅+1SJs, Ω1=J1×A×U,  and  Ω2=J2×A×{0}. Moreover, the intervals Ai (i=1,2,3,4) and U are divided, respectively, into ni and m subintervals. So, the sets Ωi, i=1,2, are partitioned into N1=S̅n1n2n3n4m and N2=(S-S̅)n1n2n3n4 cells, respectively. One point is chosen from each cell. In this way, we will have a grid of points, which are numbered sequentially as yj=(tj,x1j,…,x4j,uj), j=1,…,N, where  N=N1+N2.Therefore, according to (38), the NLP problem (33)–(36) is converted to the following  LP problem:(41)Maximizeαj≥0⁡∑j=1Mαjf0(yj)
subject to(42)∑j=1Nαjφig(yj)=Δφi,i=1,…,M1,(43)∑j=1Nαjψkn(yj)=0,k=1,…,M2,n=1,2,3,4,(44)∑j=1Nαjϑs(yj)=aϑs,s=1,…,S.Here, we discuss suitable total functionsφis, ψks, and ϑss. The functions φis can be taken to be monomials of t and the components of the vector x as follows:(45)tix2j,x2jxhi,i∈{0,1},j∈{1,2,…},h∈{1,3,4}.
In addition, we choose some functions with compact support in the following form [36, 37]: (46)ψ2r-1(t)={sin⁡(2πr(t-t0)ΔT)t≤tl0otherwise,ψ2r(t)={1-cos⁡⁡(2πr(t-t0)ΔT)t≤tl0otherwise,
where r=1,2,… and ΔT=tl-t0. Finally, the following functions are considered that are dependent on t only:(47)ϑs(t)={1t∈Js0otherwise,
where Js, s=1,…,S, are given by (40). These functions are used to construct the approximate piecewise constant control [35–37]. By the above definition of ϑs, we consider tf as an unknown variable in the constraints (44) which can be written as(48)∑j=1lαj=ΔTS-1⋮∑j=(S-2)l+1(S-1)lαj=ΔTS-1∑j=(S-1)l+1Slαj=tf-tl,
where ℓ=N/S. Of course, we need only to construct the control function u(·), since x(·) can be obtained by solving the ODEs (8). By using simplex method, a nonzero optimal solution αi1*,αi2*,…,αik*, i1<i2<⋯<ik of  the LP problem (41)–(44) can be found where k cannot exceed the number of constraints, that is, k≤M1+M2+S. Setting αi0*=t0, a piecewise control function u(·) approximating the optimal control is constructed based on these nonzero coefficients as follows [35, 36]:(49)u(t)={uijt∈[∑h=0j-1αih*,∑h=0jαih*)0otherwise,j=1,2,…,k,
where uijis the 6th  component of yij.To start the proposed method, one needs to havetl. Here, a bisection method is proposed to find the desired lower bound tl for optimal time tf*. This algorithm has a simple structure and is started with a given upper bound tu, where it is assumed that the lower bound starts with tl=0. Assuming that tf*(tl) denotes the solution of LP problem  (41)–(44) corresponding to the given lower bound tl, the bisection method is outlined as follows.Algorithm 1 (estimation of the lower boundtl).
First, letτ=[tl,tu], where tl=0 and tu is an upper bound for tf*.
Step 1.
Leta=(tl+tu)/2 and solve the corresponding LP problem to find tf*(a). If no feasible solution is found for the corresponding LP problem or tf*(a)=a, set tu=a; else set tl=a.
Step 2.
If the length of the intervalτ=[tl,tu] is small enough, then choose tl as a good estimation for lower bound tf* else, go to Step 1.


## 5. Numerical Results

In this implementation, we setM1=10 and choose functions φi, i=1,2,…,M1, from C′(B) as follows:(50)x1,x2,x3,x4,x22,x23,x1x2,x3x2,x4x2,tx2.
Furthermore, we set S=13 and M2=6. Setting u=0 in (8), we find that at t0=1642, x(t0)=(8.19,35,0.05,0.04). Model parameters are chosen as follows [17]:(51)IP̅=1.0,β=0.01,τ̅p=0.2,c̅p=0,τp=0.001,cp=20,θ=0.02,γ=0.8,ε=0.154,IC=0.2,α=0.3,v=3,
and the following initial condition is used:(52)x(0)=(5,100,0.0005,0).
Besides, λ is set to λ=10, and the length of treatment is set to η=500 (days). By using controllability on the dynamical control system, one can assume A1=[7,10], A2=[5,85], A3=[0,5], A4=[0,0.1], and U=[0,1]. Furthermore, the number of partitions in the construction of the set ΩN are n1=4, n2=10, n3=4, n4=4, and m1=4. Initially, an upper bound for optimal time tf* is set to tu=5297.45. The results of implementing Algorithm 1 are summarized in Table 1. Setting tl=3642, we have an LP problem with 16000 unknowns and 47 constraints which is solved by the linprogcode of the optimization toolbox in MATLAB. The total CPU time required on a laptop with CPU 2.20 GHz and 0.99 GB of RAM was 17.23 minutes. The suboptimal time has been found tf*=3943.2. The resulting suboptimal control and the response of the system to the obtained control function are depicted in Figures 1 and 2, respectively. Moreover, we found P(tf*)=4.9360, which is close to the exact value, that is, 5 (CD4crit+%).  Note that the normal level of mature CD4+ T-cells is about 1000 cells/μL. The relationships between the CD4+ T-cells, CTLs, and virus during the different stages of the disease are shown in Figure 3 as a phase space diagram.Table 1
Results of implementing Algorithm1.
tltuatf*(a)05297.452648.723370.062648.725297.453973.08Infeasible2648.723973.083310.903595.253310.903973.083641.993709.733641.993973.08Figure 1
The approximate suboptimal piecewise constant controlu.Dynamic behavior of the state variablesP̅, P, a and C versus time  in  the case of untreated (dashed line) and treated infected patients (solid line).
(a)(b)(c)(d)Phase space diagram for CD4+  T-cells (P), and CTLs (C).
(a)(b)


## 6. Conclusion

In this paper, we considered a dynamical system which describes the various aspects of the interaction of HIV with the immune system, to construct an optimal control problem which maximizes survival time of patients. A measure theoretical method is used to solve such kind of problems. The method is not iterative, and it does not need any initial guess of the solution, and numerical results confirmed the effectiveness of this approach.Numerical results show that in presence of treatment, the survival time of patients can be considerably prolonged. From Figures2(b) and 2(c), it is concluded that in presence of treatment (solid lines), the virus is controlled to very low levels and CD4+ T-cells are maintained at high levels for relatively long time. From Figure 2(d), an increase in CTL’s occurs in response to therapy.Figure3(a) shows an inverse correlation between CD4+ T-cells and virus particles. Furthermore, Figure 3(b) shows a clear correlation between the level of CTLs in the blood and HIV progression. As the virus increases upon initial infection, CTLs increase in order to decrease the virus. But this situation changes after about 1000th day due to destruction of CD4+ T-cells. Because these cells play an essential role in stimulation of immune response and signal other immune cells to eliminate infection by killing infected cells. After the 1642nd  day, an increase in immune response can be observed which is due to recovery of CD4+ T-cells in response to treatment. Immune response increases for a while after discontinuation of therapy but ultimately becomes extinct.



---

*Source: 674318-2011-04-18.xml*