#### Abstract

A computer virus model with infection delay and recovery delay is considered. The sufficient conditions for the global stability of the virus infection equilibrium are established. We show that the time delay can destabilize the virus infection equilibrium and give rise to Hopf bifurcations and stable periodic orbits. By the normal form and center manifold theory, the direction of the Hopf bifurcation and stability of the bifurcating periodic orbits are determined. Numerical simulations are provided to support our theoretical conclusions.

#### 1. Introduction

In recent years, the computer networks have become more and more popular, and people can find many useful things through computer networks. However, computer virus flows and spoils the correct operation of computer. As the computer networks become necessary tools in our daily life, computer virus becomes a major threat [1].

Cohen [2] found that there is high similarity between biological virus and computer virus. By the Kermack and McKendrick SIR epidemic model [3], the computer virus models were proposed in [4–7] which analyzed the spread of computer virus by epidemiological models. The model is as follows: where , , and denote susceptible, infected, and recovered computers, respectively. Here we assume that all the computers connect to the network. is the rate at which external computers are connected to the network, is the recovery rate of infected computers because of the antivirus ability of the network, is the infection rate, and is the death rate of the classes , , and .

Dong et al. [8] considered the effect of immunization on susceptible state and exposed state by a delayed computer virus model. Zhang et al. [9] studied an impulse model for computer viruses and established the global dynamics of the model. Yang et al. [10] analyzed a computer virus model with graded cure rates and showed that the global dynamics are determined by the basic reproduction number. Then we can understand and control the computer virus propagation using the mathematical models.

Since there is a period of time from virus entering a host to active state [11], there exists an infection delay from infected to infectious computers. Similarly, there is a recovery delay from recovered to susceptible computers. Then the model is where is the survival probability of the infected computers, is the infection delay, and is the rate at which one recovered computer reverts to the susceptible one. denotes that a recovered computer moves into the susceptible class after time .

Ren et al. [12] obtained that the virus-free equilibrium is globally asymptotically stable when . When , we make a lot of improvement in the results in [12]. Compared to [12], we show that the virus infection equilibrium is always locally asymptotically stable for and , and Hopf bifurcation does not exist. For and , Ren et al. [12] constructed a Lyapunov function by linearized equations of and obtained the sufficient conditions for global stability of the virus infection equilibrium. Obviously, this is inappropriate. Then we construct a suitable Lyapunov function and obtain the sufficient conditions of global stability for the virus infection equilibrium when and . Furthermore, for and , we study the direction of the Hopf bifurcation and stability of the bifurcating periodic orbits by the normal form and center manifold theory, and numerical simulations are given to support the theoretical conclusions.

Then we can control the computer virus propagation using the epidemiological threshold value. There are many research works about epidemiological models; see [13–23] and the references therein. For example, Ma et al. [24] analyzed the global stability of a SIR epidemic model with a time delay. Wang and Zhao [25] obtained the basic reproduction number of reaction-diffusion epidemic models with compartmental structure and considered the influence of spatial heterogeneity and population mobility on disease transmission by a spatial model. The methods used here are Lyapunov functions, normal form, and center manifold theory. There are many research papers using the method of constructing Lyapunov functions [26–33]. In addition, we would like to refer to some excellent articles about stability and bifurcation; see [34–44].

The paper is organized as follows. In Section 2, the existence of equilibria is discussed and characteristic equation is given. In Section 3, we establish the local stability of the virus infection equilibrium for and . In Section 4, for and , we consider the local stability of and existence of local Hopf bifurcation, and the direction of Hopf bifurcation and stability of the bifurcating periodic solutions are considered. In Section 5, for and , global stability of the virus infection equilibrium is obtained. Finally, we finish the paper with conclusions.

#### 2. Preliminaries

The initial conditions are where and with . We denote by the Banach space of continuous functions mapping the internal into equipped with the sup-norm for .

From the standard theory of functional differential equation [45], for all , there is a unique solution with of the system (2). By the method of [13], under the initial conditions (3), all solutions of system (2) are positive and ultimately bounded in . The feasible region of system (2) is which is the positively invariant set with respect to system (2).

System (2) always has a virus-free equilibrium with . In addition, system (2) has a virus infection equilibrium . The basic reproduction number is defined [12] as The virus-free equilibrium always exists. The coordinates of the virus infection equilibrium are given by Thus, exists in the interior of if and only if .

Let , , and . Then system (2) becomes The characteristic equation of system (7) at is

#### 3. Local Stability of for and

Consider and ; then (8) becomes where Since is a negative real root of (9), all other roots of (9) are given by If is the purely imaginary root of (11), then substituting into (11) and separating the real and imaginary parts yield Squaring and adding the two equations lead to Note that Therefore, the roots of (13) do not exist. Thus, the virus infection equilibrium of system (2) is locally asymptotically stable for and . Then we obtain the following result.

Theorem 1. *Consider system (2). If , then the virus infection equilibrium is locally asymptotically stable for and .*

*Remark 2. *For and , Ren et al. [12] showed that the time delay can destabilize the infected equilibrium leading to Hopf bifurcations. However, we show that the virus infection equilibrium is always locally asymptotically stable for and , and Hopf bifurcation does not exist.

We introduce a set of parameter values: , , , , , and . Consequently, (a) and ; (b) and ; (c) and ; (d) and . Figure 1 shows that the infection equilibrium is locally asymptotically stable.

**(a)**

**(b)**

**(c)**

**(d)**

#### 4. Hopf Bifurcation for and

Consider and ; then (8) becomes where Obviously, is always a negative real root of (15). Then we consider If is the purely imaginary root of (17), then substituting into (17) and separating the real and imaginary parts give Squaring and adding the two equations lead to Denote Let Hence (1)if , then (20) has no positive real roots;(2)if , since , then (20) has at least one positive real root;(3)if , then (20) has two real roots: if , then (20) has a positive real root. If , then all roots of (20) are negative.

Let be the positive real roots such that and . Denote where is determined by Define Therefore, is the first value of when a pair of characteristic roots cross the imaginary axis at .

Let be the root of (15) satisfying and . Differentiating (15) with respect to leads to From (18), we have Then Thus, we obtain the following the result.

Theorem 3. *Consider system (2). In the case of and , *(i)*assume that one of the following two conditions holds:(a) .(b) and . Then the virus infection equilibrium is locally asymptotically stable for ;*(ii)

*in either case,(a)*

*, or*(b)*and ,**the virus infection equilibrium is locally asymptotically stable for . Furthermore, if , then system (2) undergoes a Hopf bifurcation at the virus infection equilibrium when .*From the above discussions, the sufficient conditions for the existence of Hopf bifurcation were given for and . Thus, under the conditions of Theorem 3, we will study the direction of the Hopf bifurcation and the stability of the bifurcating periodic orbits by normal form and center manifold theory (see, e.g., [46]).

Fix and let , then is the Hopf bifurcation value, and system (47) is transformed into an FDE in as where . Denote as where Define where Then we can denote as For , we define Therefore, system (47) becomes where for . For , define and a bilinear form where . Hence, and are adjoint operators. By the above discussions, we know that are eigenvalues of and so they are also eigenvalues of . It can be easily proved that , is an eigenvector of associated with the eigenvalue , and , is an eigenvector of associated with the eigenvalue . Denote where , .

Following the procedure in [46], we obtain the following coefficients: where where where Then can be expressed definitely.

From (27), (40), and (41), we have Then we have the following result.

Theorem 4. *Assume that the conditions of Theorem 3 (ii) hold. Then determines the direction of the Hopf bifurcation: if , then the Hopf bifurcation is forward (backward) and the bifurcating periodic orbits exist for and ; determines the stability of bifurcating periodic orbits: the bifurcating orbits are asymptotically stable (unstable) when ; and determines the period of the bifurcating periodic orbits: the period increases (decreases) when .*

We introduce a set of parameter values: , , , , and . Consequently, and . We can obtain that the conditions of Theorem 3 hold. When , by direct computation we get , , , , and . By Theorem 3 we know that the stability of the infected equilibrium varies when increases and the infected equilibrium is asymptotically stable for . Figure 2 illustrates the results. By Theorem 4 we know that the direction of the Hopf bifurcation is forward at . And Figure 3 illustrates the bifurcating periodic orbits are asymptotically stable.

#### 5. Global Asymptotic Stability

The following result shows the global stability of the virus-free equilibrium.

Proposition 5 (see [12]). *
Consider the following.**If , then the virus-free equilibrium of system (2) is globally asymptotically stable for all and .*

Next we will prove the global stability of the virus infection equilibrium of system (2). Let , , and . Then system (2) becomes From system (2) with initial conditions (3), we know that . By the method of constructing Lyapunov function [47], we obtain the following result.

Theorem 6. *Consider system (2) with initial conditions (3). Assume that , if*(*H*_{1})*,
,
**where
**
holds, then the virus infection equilibrium is globally asymptotically stable for and .*

*Proof. *Define a Lyapunov function
Differentiating along the solution of system (47), we have
Since and , and by Cauchy-Schwartz inequality we obtain
Define
Then
Therefore, from we obtain
Thus, ensures that , and if and only if , , and . Then the only compact invariant set where is the singleton . By LaSalle’s invariance principle [48], if and hold, then is globally asymptotically stable. The proof is completed.

*Remark 7. *For and , Ren et al. constructed a Lyapunov function by linearized equations [12, equations (37)]. Clearly, this is unreasonable. Thus, we define an appropriate Lyapunov function and obtain the sufficient conditions of global stability for the virus infection equilibrium .

We choose a set of parameter values: , , , , and . Correspondingly, and . It can be verified that the conditions of Theorem 6 are satisfied. For and , we show that the infected equilibrium is globally asymptotically stable in Figure 4. All of the numerical simulations are carried out by MATLAB.

#### 6. Conclusions

We consider a computer virus model with infection delay and recovery delay. When , the virus-free equilibrium of system (2) is globally asymptotically stable and the virus fades out from the network. When , we obtain that the virus infection equilibrium is always locally asymptotically stable for and ; for and , we establish that the time delay can destabilize the virus infection equilibrium and give rise to Hopf bifurcations and stable periodic orbits. For and , we construct an appropriate Lyapunov function and get that the infection equilibrium is globally asymptotically stable under the sufficient conditions, and the virus finally persists at a constant endemic equilibrium level.

Our results show that we can take measures to make the basic reproduction number to be less than one leading to the extinction of computer virus. We must take some effective measures (such as the installation of antivirus software) to decrease the infection rate and increase recovery rate of the infected computers.

However, our results should be viewed carefully because the model used in this paper is simplified and possibly does not explain all relevant dynamics of computer virus. Then we need more realistic computer virus models to study the real network.

#### Conflict of Interests

The authors declared that they have no conflict of interests to this work.

#### Acknowledgments

The authors are grateful to the editor and the anonymous reviewers for their valuable comments and suggestions which greatly improved the paper. This research is supported by the National Natural Science Foundation of China (no. 11371112) and in part by the National Natural Science Foundation of China (no. 11031002) and by the Heilongjiang Provincial Natural Science Foundation (no. A201208).