Stability analysis of swarming model with time delays

A swarming model is a model that describes the behavior of the social aggregation of a large group of animals or the community of humans. In this work, the swarming model that includes the short-range repulsion and long-range attraction with the presence of time delay is investigated. Moreover, the convergence to a consensus representing dispersion and cohesion properties is proved by using the Lyapunov functional approach. Finally, numerical results are provided to demonstrate the effect of time delay on the motion of the group of agents.


Introduction
The study of the behavior of interacting agents in groups of animals has gained increasing interest in various fields such as biology, engineering, mathematics (see [2,8,12,15,20]). One fascinating feature of such systems is the collective behavior described as formation patterns and can be found in many natural systems such as flocks of birds, schools of fish, chemical compounds, crowd dynamics. From the biological point of view, pattern motion is the consequence of two natural behaviors. On the one hand, agents desire to communicate and stay close to the group. On the other hand, when they stay too close, they try to keep a distance to avoid collision with other agents. Hence, for understanding these behaviors, it is indispensable to take biological phenomena into account. The research on mathematical modeling and simulation of these systems is of increasing interest, starting with the works of Reynolds [19]. Reynolds's model, called the three-zone model, is the first principle model of swarming consisting of three fundamental characteristics of collective motion: cohesion, separation, and alignment rules. Further, this model has been extensively improved by adding many different effects and analyzed for different types of animals. For more details, see, e.g., [1,3,4,10,11,14,16]. In connection with these swarming models, it is essential to mention that the continuous models are developed through partial differential equations (PDEs) that describes the evolution of the particles' density in the systems composed of a large number of interacting agents such as cell, molecular organism, or chemo-taxis with high drift effect; see [13,21].
In the present day, despite a large number of works devoted to studying the stability of the swarm, it is still of paramount interest how agents form the pattern configuration when they are faced with situations where a converging stable state cannot be ensured, especially in the presence of communication with time delay which is a result of traffic congestion or finite speeds of transmission and spread. The stability of swarming concerning time delays is investigated in various models. Firstly, a well-known model is the Cucker-Smale flocking model, which describes agent's motion based on its neighbor agents' positions and velocities. The emergence of the flocking model described by the Cucker-Smale (CS) model with time delay was primarily investigated in [5,6,9,17,18]. In this model, time delays are included in the dynamic of velocities of agents. Besides, the model has been continuously extended by numerous researchers; for example, in [22] the authors consider the CS model by including a time delay in the communication function and velocities of agents, and the authors of [6] study the emergence of flocking where the interaction of agents is based on the CS communication function with a time delay and an attractionrepulsion force.
The contribution to this research effort is investigating the swarming model in which the interaction mechanism consists of attraction and repulsion functions which contain time delays. In particular, the first-and second-order models are studied. In the first-order model, time-delays are included in the agents' position, while in the second-order model, agents adapt their velocity relative to other agents' velocities with communication delay. Furthermore, based on these two models, the emergence of the swarm into the pattern formation is theoretically and numerically investigated. The stability of the swarm is related to parameters of the attraction and repulsion functions.
This work is organized as follows. In the next section, the first-and second-order swarm models with time-delay in the communication function are discussed. Additionally, in the first-order model, the stability of the swarm is analyzed and supplemented with two numerical test cases. In the second-order model, the dispersion and disagreement of the swarms that describe converging to pattern configuration are theoretically and numerically investigated. A conclusion in the last section completes the exposition of this work.

Swarm model and stability of swarm aggregation
In this section, we discuss the swarm model based on an agent-based model in an ndimensional Euclidean space proposed in [7] where the attraction-repulsion function includes a time delay. The evolution of swarming for the first-and second-order models is discussed, and then for both models, its stability properties are theoretically and numerically investigated.

The first-order model
We consider the motion of N interacting individuals where their motion depends only on the position of an individual itself and its observation of other individuals' positions. The equation of motion of the ith agent is given bẏ where x i (t) ∈ R d represents the position of the ith agent and ∇ x i U( x i (t)x j (t) ) denotes the gradient of U with respect to x i . Here x i (t)x j (t) is the Euclidean distance between the ith and jth agents. The function U : (R d ) N → R represents the Morse potential function, which contains attractive and repulsive parts. The Morse potential has the following form: where C r e -r lr and C a e -r la model short-range repulsion and long-range attraction, respectively. Parameters C r , C a represent repulsive and attractive strengths, respectively, whereas l r , l a are repulsive and attractive length scales. The derivative of the Morse potential is expressed as follows: Next, we discuss the swarming system described in (1) with the effect of time-delays on repulsion and attraction. In this system, the time delay is a positive constant and is denoted as τ . Time delays model the situation that agents receive information from other members in the group after a certain time delay. As a consequence, each agent needs time to elaborate its reaction to other agents in the group. The swarming system (1) including the effect of time delay is presented as follows: For simplicity, we define and rewrite the derivative with respect to r ij as Therefore, the swarming system with time delay becomeṡ for i = 1, . . . , N , with given initial data In the following, we consider numerical simulations with the swarming system in the onedimensional case, d = 1, in two test cases: a system without time delay (τ = 0) and a system agents' motion fluctuates during the early time; however, after a certain time, they start self-organizing and then become stationary.

Stability analysis for the first-order model
In this subsection, theoretical results concerning the formation pattern of the swarm are investigated. We begin by introducing a free agent, a swarm member who does not have any neighbors in its repulsive range.
Definition 1 An agent i is called a "free agent" with respect to time delay if r ij (t, τ ) > δ, ∀j = 1, . . . , N , j = i, and δ is a repulsive range such that U (r ij ) > 0.
where · and ·, · denote the Euclidean norm and inner product, respectively. Since the first agent is free, As a consequence, Therefore R is a decreasing function, that is, all agents move towards the center.
In the following theorem, the stability of swarming corresponding to dispersion and cohesion properties are investigated. These properties are related to attraction and repulsion parameters (C a , C r , l a , l r ) in Morse potential function. We denote C = C r /C a and l = l r /l a .
Proof Without loss of generality, we choose the swarming radius R = x 1 . We consider d dt C a l a e -r 1j la C l e r 1j ( l-1 lr ) -1 .
Further, we prove the second statement when l ≤ min{1, C}. From d dt C a l a e -r 1j la C l e r 1j ( l-1 lr ) -1 , we know that ≥ 0. Let us consider three cases. We get that d dt ( 1 2 x 1 (t) 2 ) = 0. Therefore, the swarming radius is norm-preserving.
It follows that d dt ( 1 2 x 1 (t) 2 ) < 0. Therefore, the swarming radius is decreased. Case III: If r 1j = l r 1-l ln( C 2l ) < l r 1-l ln( C l ), then C a l a e -r 1j la C l e r 1j ( l-1 lr ) -1 = C a l a e -r 1j la C l e ( lr Hence, the swarming radius is increased. From the three cases discussed above, it can be concluded that if the distance between the first agent who has maximum swarming radius and the jth agent is equal to r 1j = l r 1-l ln( C l ), then the swarming radius is bounded. On the other hand, if r 1j is greater than l r 1-l ln( C l ), then the swarming radius is decreased to zero. While, if the distance between the first and jth agent is less than l r 1-l ln( C l ), then swarming radius is increased. It shows that agents get far away from the center.
We present results of experiments to numerically verify Theorem 2.
It can be seen from Fig. 2 that for C ≥ l > 1, when t → ∞, each agent moves far away from the origin, whereas Fig. 3 illustrates that for l ≤ min{1, C} the swarming radius is bounded.

The second-order model
In this section, we focus on the swarming model which includes rules for orientation. In particular, this model contains a mechanism of self-propulsion in which each agent moves with constant speed and adopts the average direction among its neighbors. The secondorder model is given by the following equations: where x i , v i ∈ R d are position and velocity of the ith agent, respectively. The term (αβ v i (t) 2 )v i (t) models self-propulsion and friction forces where parameters α > 0 and β > 0 represent self-propulsion and friction, respectively. The second term is the Morse potential function including interaction with a time delay. In the following, we theoretically and numerically study the stability of the swarm described as converging to the pattern configuration. For investigation of pattern properties, we calculate dispersion X(t) and disagreement V (t) proposed in [17].
Proposition 1 Let (x(t), v(t)) be the solution of system (7). If the solution (x(t), v(t)) converges to consensus, then Proof From the dynamical system (7), we considerv i (t) = 0, for i = 1, . . . , N , that is, We consider (αβ v i (t) 2 )v i (t) = 0 and assume that v i (t) = 0. Then it yields , which can be written as Since ( Consequently, r ij = x i (t)x j (tτ ) = l r 1-l ln( C l ). It can be concluded that when the system (7) tends to consensus, the velocity of each agent converges to value α β and In the sequel, we present results of numerical experiments to validate some aspects of theoretical findings and demonstrate the stability of swarms in two dimensions. For this purpose, we consider the following four test-cases: Case I: C a > C r and l a > l r (see . In Case I, attraction parameters are stronger than those of repulsion. Hence, agents get closer to each other. As a consequence, the swarm is formed as a tight cluster, as showed in Fig. 4. In addition, it can be seen from Fig. 5 that X(t) and V (t) are periodical in amplitude and bounded by some value.
Case II: C a > C r and l a < l r (see Figs. 7-9).
Case III: C a < C r and l a < l r (see Figs. [10][11][12]. In Cases II and III, the repulsive length has a greater magnitude than the attractive one. It means that agents are repelled from others. It follows that the pattern configuration would not be formed, as shown in Figs. 8 and 11.   Case IV : C a < C r and l a > l r (see Figs. [13][14][15]. It can be seen from Figs. 14 and 15 that, when t → ∞, X(t) becomes constant and V (t) tends to zero. This means that the swarm converges to an asymptotic state. Pattern configuration is formed and each agent moves with the same velocity.

Conclusion
This work presented the emergence of swarm with delayed communication. First, the firstand second-order models of the swarm were described, where in the interaction function the time delay was taken into account. Further, the stability of the swarm was analyzed. For both models, agents' movement to a stable state depended on the attractionrepulsion strengths and length scale in the Morse potential function. Finally, numerical results demonstrated the emergence of the swarm and referred that the swarm converges to an asymptotic state. Pattern configuration was formed, and each agent moved with the same velocity.