## 3 Methodology
### Consensus Scoring System  
In the distributed architecture, each agent's behavior depends not only on its own decision but also on the behaviors of other teammates and the environment. However, Equation (8) shows that the visual scope of each agent is limited by its sensor, in which we define a set of neighbors as virtual committee members for each agent. Let \(A_{i}\) denote the sensing area of \(i\)-th agent with radius \(r_{i}\in\mathbb{N}\), where \(r_{i}\) should always be greater than its safety distance \(d_{i}\in\mathbb{N}\). \(d_{nearest}\) is the distance of agent \(i\) and its neighbor \(k\), \(N_{i}\) is the set of the neighbors of \  
We propose a scoring system to find the minimum-cost trajectory among the candidate trajectories predicted in the time window. The cost function of a candidate trajectory \(j\) of \(i\)-th agent can be denoted in Equations (9):  
\[\begin{split} Cost(i,j)=(1-\alpha_{i}-\beta_{i})\cdot Cost_{speed} (i,j)+\alpha_{i}\cdot Cost_{form}(i,j)+\beta_{i}\cdot Cost_{target}(i,j)\\ \alpha_{i}=1-\frac{d_{nearest}}{r_{i}}\end{split} \tag{9}\]  
where \(Cost_{speed}(i,j)\), \(Cost_{form}(i,j)\) and \(Cost_{target}(i,j)\) are functions of speed cost, formation cost and path cost to the target of \(i\)-th agent's trajectory \(j\), respectively. \(\alpha_{i}\) and \(\beta_{i}\) are respective the relative weight coefficients of formation and path cost to compromise these factors and find the best trajectory. During the agent mission, the co-operated agents do not only move toward the immediate target point but also move closer to the virtual center of gravity of its team. To evaluate this cost function, \(Cost_{form}(i,j)\) is calculate according to the steps as shown in Equations (10)-(13), respectively. Firstly, each agent calculates a virtual center of gravity \(G_{i}\)=(\(x_{G_{i}}\), \(y_{G_{i}}\)) based on the position of its team neighbors and itself along a candidate trajectory \(j\).  
\[\begin{split} x_{G_{i}}&=\frac{1}{n+1}\cdot(x_{i}+ \sum_{j\in N_{i}}x_{j})\\ y_{G_{i}}&=\frac{1}{n+1}\cdot(y_{i}+\sum_{j\in N_{ i}}y_{j})\end{split} \tag{10}\]  
Secondly, we predict the new center of gravity \(PG_{i}\) after \(t_{T}\) time window which is used to evaluate the best trajectory. \(PG_{i}\) is calculated based on \(G_{i}\) with the current speed and orientation.  
\[\begin{split} x_{PG_{i}}&=x_{G_{i}}+t_{T}\cdot v_{i} \cdot cos\theta_{i}\\ y_{PG_{i}}&=y_{G_{i}}+t_{T}\cdot v_{i}\cdot cos \theta_{i}\end{split} \tag{11}\]  
Lastly, the overall formation cost and target cost functions after a time window are shown in Equations (12) and (13), respectively.  
\[cost_{form}(i,j)=dist(P_{i}^{j},PG_{i}) \tag{12}\]  
\[cost_{target}(i,j)=dist(P_{i}^{j},Target) \tag{13}\]  
Furthermore, the scoring system try to achieve a balance between individual target-path cost and team formation cost. In general, the farther the distances between an agent with its target and its team, the faster it should move. To accommodate this scenario, the speed cost function \(Cost_{speed}(i,j)\) is defined as the difference between the maximum speed and the speed at the predicted target point after the time window along candidate trajectory \(j\) of \(i\)-th agent. The equation used is shown as Equation (14):  
\[Cost_{speed}(i,j)=V_{max}-v_{i} \tag{14}\]  
The definition indicates that if an agent \(i\) moves at its maximum velocity along its trajectory \(j\) the \(Cost_{speed}(i,j)\) is zero.