# Research on Path Planning Multiple Mobile Robots Based on the LAPGWO Algorithm
## 3 Methodology
### LAPGWO Algorithm
#### 3.1.1 GWO Algorithm  
The GWO algorithm is a relatively new swarm intelligence optimization algorithm inspired by the predatory behavior of grey wolf packs in nature. Simulating the behaviors of grey wolf packs, such as searching, encircling, and attacking prey, can efficiently solve complex optimization problems. A wolf pack has a relatively straightforward hierarchical system divided into four levels. Among them, the \(\alpha\) wolf is the leader of the group, representing the optimal solution, and is responsible for deciding the hunting direction; the \(\beta\) wolf is the second-best individual, assisting the \(\alpha\) wolf in making decisions, representing the second-best solution; the \(\delta\) wolf is the third-best individual, executing the instructions of the \(\alpha\) and \(\beta\) wolves and is responsible for tasks such as scouting and guarding; the \(\omega\) wolves are ordinary members, following the actions of the former three. The position information of \(\alpha\), \(\beta\), and \(\delta\) guides the entire group to move towards the optimal solution. The predatory behavior of grey wolves is divided into the following three stages: encircling, hunting, and attacking. The mathematical model of the overall predatory behavior of grey wolves can be expressed as follows:  
\[X_{(i+1)}=X_{p}(i)-M\cdot\left|N\cdot X_{p}(i)-X(i)\right| \tag{1}\]  
Among them, \(i\) is the iteration number at the current moment. \(X\) and \(X_{p}\) are the positions of the grey wolf individual and the prey, respectively. \(M\) and \(N\) represent vector coefficients, and \(M\cdot\left|N\cdot X_{p}(i)-X(i)\right|\) is the Manhattan distance between the position of the grey wolf and the position of the prey.  
\[M=2a\cdot r_{1}-a \tag{2}\]  
\[N=2r_{2} \tag{3}\]Among them, \(r_{1}\) and \(r_{2}\) are random numbers between 0 and 1, and \(a\) is the convergence factor, which linearly decreases from 2 during the iterative process until it reaches 0, that is:  
\[a(I)=2-2\frac{i}{i_{max}} \tag{4}\]  
Among them, \(i_{max}\) is the maximum number of iterations.  
When the leader wolf \(\alpha\) finds the position of the prey, it commands the entire wolf pack to approach the prey. When the appropriate distance is reached, \(\alpha\) will lead the \(\beta\) wolves and \(\delta\) wolves to launch a joint attack on the prey. Other individuals in the wolf pack will make predictions based on the position information of the three wolves \(\alpha\), \(\beta\), and \(\delta\), and the expression is:  
\[\begin{cases}H_{\alpha}=N_{1}\cdot X_{\alpha}(i)-X(i)\\ H_{\beta}=N_{2}\cdot X_{\beta}(i)-X(i)\\ H_{\delta}=N_{3}\cdot X_{\delta}(i)-X(i)\end{cases} \tag{5}\]  
Among them, \(X_{\alpha}\), \(X_{\beta}\), and \(X_{\delta}\) are the positions of the three wolves \(\alpha\), \(\beta\), and \(\delta\), respectively. \(\delta\), \(H_{\beta}\), and \(H_{\delta}\) are the distances between the three wolves \(\alpha\), \(\beta\), \(\delta\), and other individuals in the group, respectively.  
\[\begin{cases}X_{1}(i)=X_{\alpha}(i)-M_{1}H_{\alpha}\\ X_{2}(i)=X_{\beta}(i)-M_{2}H_{\beta}\\ X_{3}(i)=X_{\delta}(i)-M_{3}H_{\delta}\end{cases} \tag{6}\]  
\[X_{(i+1)}=\frac{X_{1}(i)+X_{2}(i)+X_{3}(i)}{3} \tag{7}\]