An Improved Grey Wolf Optimization Algorithm and its Application in Path Planning

Grey wolf algorithm (GWO) is a classic swarm intelligence algorithm, but it has the disadvantages of slow convergence speed and easy to fall into local optimum on some problems. Therefore, an improved grey wolf optimization algorithm(IGWO) is proposed. The lion optimizer algorithm and dynamic weights are integrated into the original grey wolf optimization algorithm. When the positions of <inline-formula> <tex-math notation="LaTeX">$\alpha $ </tex-math></inline-formula> wolf, <inline-formula> <tex-math notation="LaTeX">$\beta $ </tex-math></inline-formula> wolf, and <inline-formula> <tex-math notation="LaTeX">$\delta $ </tex-math></inline-formula> wolf are updated, the lion optimizer algorithm is used to add disturbance factors to the wolves to give <inline-formula> <tex-math notation="LaTeX">$\alpha $ </tex-math></inline-formula> wolf, <inline-formula> <tex-math notation="LaTeX">$\beta $ </tex-math></inline-formula> wolf, and <inline-formula> <tex-math notation="LaTeX">$\delta $ </tex-math></inline-formula> wolf active search capabilities. Dynamic weights are added to the grey wolf position update to prevent wolves from losing diversity and falling into local optimum. Through multiple benchmark function test experiments and path planning experiments, the experimental results show that the improved grey wolf optimization algorithm can effectively improve the accuracy and convergence speed, and the optimization effect is better.


I. INTRODUCTION
Robot Path Planning (RPP) is one of the important topics in the field of robotics research. The purpose of the research is to optimize the path and get an optimal path from the starting point to the end point [1]. With the development of technology, the research on robots has become more and more in-depth, and the application of robots has become more and more extensive, such as: cargo handling, underwater operations, etc. These applications all involve the RPP problem, so the research on the RPP algorithm has great practical significance.
The classic path planning algorithms include A * algorithm, random road map method, cell decomposition method, artificial potential field and other algorithms [2]. The advantage of the classic path planning algorithm is that the calculation speed is fast and the UAV path can be obtained The associate editor coordinating the review of this manuscript and approving it for publication was Wai-Keung Fung .
efficiently, but its disadvantages are also very obvious. For example, the calculation complexity is high, and the destination is unreachable. In recent years, with the development of swarm intelligence algorithms, new ideas have been provided for RPP problems. At this stage, many swarm intelligence algorithms have been applied to RPP problems and have achieved effective results.
Swarm intelligence optimization algorithm is an algorithm that observes the cooperative foraging process of biological groups in the natural world, simulates the sharing of information and mutual learning among members of the group, constantly changes the search direction, and finally realizes the optimization of search results [3].
Since Simulated Annealing algorithm (SA) [4] and Genetic Algorithm (GA) [5] were proposed, many scholars have devoted themselves to this research field. After decades of development, many swarm intelligence optimization algorithms have been proposed and widely used in research fields and practical scenarios, such as Butterfly optimization algorithm (BOA) [6], Chicken Swarm Optimization (CSO) [7], Whale Optimization Algorithm (WOA) [8] and Harris Hawks Optimization (HHO) [9], etc.
Grey Wolf Optimization (GWO) algorithm is a new swarm intelligence algorithm inspired by the grey wolf leadership hierarchy and group hunting behavior in nature by Mirjalili et al. [10]. Due to its simple principle, few parameters, easy programming, and support for distributed parallel computing and strong global search capabilities, the GWO algorithm is widely used in global optimization problems in the fields of computer science [11], engineering science [12], and management science [13]. Yongqi and Wei [14] quoted the position update formula of the grey Wolf optimization algorithm and applied it to the fault location problem of distribution network. Yuan et al. [15] et al. proposed an adaptive probability mutation strategy, which adjusted the hunting mode during the optimization process to improve the global search ability of the algorithm, and applied the algorithm to research on turbofan engine performance and jet noise comprehensive optimization control. Zhijun et al. [16] first improved the grey wolf algorithm through Tent chaos mapping, nonlinear control parameters and the idea of particle swarm algorithm. Chunhua and Huan [17] optimized and mixed the grey Wolf algorithm with sine and cosine algorithm, and applied the algorithm to the path planning of pharmaceutical logistics distribution. Fei and Xin [18] introduced the migration operation in the grey wolf optimization algorithm, and dynamically modified the migration probability according to the fitness function value of the grey wolf, and applied it to low-carbon transportation scheduling in open-pit mines.
The original grey wolf algorithm has the shortcomings of slow convergence in the later stage and falling into local optimality. This paper proposes a new improved grey wolf algorithm (IGWO), which integrates lion optimization algorithm and adds dynamic weights to increase the diversity of the population, enhance the search ability of the population. The segmented search is added, which balances the local search and global search capabilities, and makes the grey wolf algorithm further improve the convergence speed and convergence accuracy; and the improved grey wolf algorithm is applied to path planning. The simulation experiment shows that the performance of the algorithm is significantly improved.
The main structure of this paper is organized as follows: Section 2 introduces GWO, LOA and their mathematical models. In Section 3, the IGWO description and its algorithm flow are introduced. In Section 4, IGWO is used to test benchmark functions and path planning applications, and the experimental results are analyzed. Finally, Section 5 concludes the paper.

A. GREY WOLF ALGORITHM
Wolves are social animals. There are usually more than a dozen grey wolves in each group, forming a strict hierarchy.
In the grey wolf algorithm, wolves are divided into four levels: α wolf, β wolf, δ wolf, and ω wolf. Among them, the α wolf is the head wolf, which is mainly responsible for the various decision-making affairs of the group; the rights of the β wolf and the δ wolf decline in order to assist the head wolf operation, and the ω wolf represents the remaining wolves. Their actions are affected by the first three wolves and obey their commands. Grey wolves rely on this hierarchy to forage and prey. α, β, and δ wolves are closest to their prey, and ω wolves follow these three to search, track, and surround their prey. When the encircling circle is small enough, they begin to attack and capture the prey.

1) SEARCH FOR PREY
The hunting of grey wolves starts from searching for prey, and their behavior can be described by the following formula: (1) In the formula, D represents the distance between the grey wolf and the target prey, t is the current iteration, X p (t) represents the current position of the prey, X (t) represents the position vector of the current search wolf individual, X(t+1) is the updated position vector of the next generation search wolf, A and C are coefficient vectors, and A is determined by Equation (3) is determined, and C is determined by Equation (4): In the formula, r1 and r2 are random vectors with values between [0,1], and a linearly decreases from 2 to 0 in the iterative process Thus, the value range of A is [−2,2], and the range of C is [0,2].

2) SURROUND PREY
Under the leadership of α wolf, β wolf and δ wolf gradually approach their prey. First, calculate the distance between them and α, β, and δ according to Equations (6) ∼ (11), and then use Equation (12) to determine how the grey wolf individual moves to the prey: In the formula, X α represents the location of α wolf, X β represents the location of β wolf, X δ represents the location of δ wolf, and C 1 , C 2 , and C 3 are random vectors. The general VOLUME 9, 2021

3) ATTACKING PREY
When the prey stops moving, the group of grey wolves attack the prey. This process can be simulated by decreasing A from 2 to 0 with a in the iterative process. When |A| >1, the grey wolf individual moves away from the target and performs a global search. When |A| ≤1, the grey wolf starts to attack its prey.

B. LION OPTIMIZER ALGORITHM
When the lion group solves the objective function optimization problem, the lion group is divided into three categories: lion king, lioness and cub. The main idea of the lion optimization algorithm is as follows: starting from an initial position in the space to be optimized, the one with the best fitness value is the lion king, and then a certain proportion of hunting lions are selected, and the hunting lions cooperate with each other to hunt, once found prey of higher quality than the prey currently occupied by the lion king, the position of the prey will be owned by the lion king. Lion cubs follow the lioness to learn to hunt or eat near the lion king. When they become adults, they will be driven out of the lion group. In order to survive, the driven lion will try to get closer to the best position in memory. According to the division of labor, the lion group continuously repeats the search to obtain the optimal value of the objective function.

1) PROPORTION FACTOR B 1 OF ADULT LIONS
The proportion of adult lions in the entire lion group affects the final optimization effect. The larger the proportion of adult lions, the fewer the number of cubs. The renewal of the position of the cubs can increase the diversity of the population, so the proportion of adult lions is a random number in (0,1) because β 1 is a random number within (0,1). In order to make the algorithm converge faster, the value of β 1 is generally less than 0.5.

2) PERTURBATION FACTOR OF LIONESS MOVING RANGE α F
Add a disturbance factor α f to change the range of activity of the lioness, so that it explores food in a larger area first, and the exploration range transitions from large to small. The disturbance factor makes the global exploration capability and local development capability get a better balance, and the algorithm is fast Convergence, and effectively avoid the premature problem, so as to obtain the optimal solution. The disturbance factor is defined as follows: Among them, step represents the maximum step length for the lion to move within the range of activity, low and high respectively represent the minimum mean and maximum average of each dimension of the lion's range of motion space; T is the maximum number of iterations of the group, and t is the current iteration number.

3) DISTURBANCE FACTOR αC OF CUB MOVING RANGE
When the lion cub approaches the lion king to eat or the cub learns to hunt with the lioness, the cub will search within the specified range, and the disturbance factor can lengthen or compress the range, allowing the cub to explore for food in this range. After finding the food and then searching in small steps, it shows a linear downward trend. The disturbance factor α c is defined as follows: The meaning of other parameters is the same as above.

4) ALGORITHM PRINCIPLE
Suppose there are N lions in the D-dimensional target search space to form a group, and the number of adult lions is nLeader: There is only one male lion and the rest are lionesses. The position of the i (1 ≤ i ≤ N) lion is: Number of adult lions: The number of lion cubs is N-nLeader. During the hunting process, different types of lions move in different ways. The lion king moves in a small area at the best food place to ensure that his privileges are updated according to (19): The lioness needs to cooperate with another lioness during the predation process, and adjust its position according to Equation (20): The cub adjusts its position according to Equation (21): Among them, γ is a random number generated according to the normal distribution N(0,1); p k i is the historical optimal position of the i-th child and the k generation; g k is the optimal position of the k generation group; p k c is the mother from the k generation. The best historical position of a hunting partner selected at random among the lions, p k m is the best position in history of the k-th generation of cubs following the lioness, g k represents the best position of the k-th generation group,ḡ k is determined by Equation (22): Among them, low and high are the minimum mean and maximum mean of each dimension within the range of the lion's activity space, respectively; p k m is the k historical best position of the cub following the lioness; the probability factor q is according to uniformly distribute the uniform random value generated by U [0,1].

III. IMPROVED GREY WOLF OPTIMIZATION ALGORITHM (IGWO) A. FUSION LION OPTIMIZER ALGORITHM
A large number of studies have shown that algorithms with strong global search capabilities have a wider search space and richer population diversity, so that they have a stronger convergence accuracy and are not easy to fall into a local optimum. Algorithms with strong local development capabilities have faster convergence speed [19]. In the GWO, due to the leadership role of α wolf, the wolves are clustered, all grey wolves in the group approach the optimal individual α wolf. Therefore, it has strong local search ability, and it is easy to lose the diversity of the population and fall into the local optimum. Incorporating the disturbance factor of the lion optimizer algorithm, so that the position update of α wolf, β wolf, and δ wolf are not close to the optimal individual α wolf, but has a certain degree of randomness, which strengthens the diversity of the population to a certain extent, expands the search range, and avoids convergence precocious, a new generation of α wolf, β wolf, and δ wolf are calculated as follows: In the formula, the value of step in α f and α c is 1.

B. ADD DYNAMIC WEIGHT
When updating individual positions, the GWO only considers that ω wolf is greatly affected by the dominant grey wolves (α wolf, β wolf, and δ wolf) in the current population. It can be seen from Equation (12) that X i (i=1,2,3) uniformly affects the position update of ω wolf, but in fact, the abilities of α wolf, β wolf, and δ wolf are different, and their functions should also be different. Adding dynamic weights can balance and restrict the mutual influence of global search and local search. As the number of iterations increases, the influence of α wolf, β wolf, and δ wolf on ω wolf is dynamically changed, so dynamic weights are introduced to update the position of ω wolf: Among them, C 1 is a random vector, its range is [0,2]. VOLUME 9, 2021

C. SEGMENT SEARCH
In the initial stage of the algorithm, the wolves are far away from the prey, and the global search ability and search range should be improved. As the number of iterations increases, the wolves are getting closer and closer to the prey. At this time, the local search ability should be improved to enhance its search speed. Therefore, balancing the global search ability and the local search ability is a key factor to improve the convergence speed and accuracy of the algorithm. Because a decreases linearly with the number of iterations from 2 to 0, you can set a segmentation for a. A large number of experiments show that when the threshold of a is set to 0.5, the global search and local search capabilities can be better balanced. When a >=0.5, improve the global search ability; when a <0.5, improve the local search ability, the formula is as follows: Among them, C 1 is a random vector, its range is [0,2]. The algorithm flow of IGWO is: if a >=0.5 10:

Algorithm 1 A Novel Grey Wolf Optimization Algorithm Based on Hybrid Lion Optimizer Algorithm and
Update ω wolf using Eq.(26) 11: else 12: Update ω wolf using Eq. (12)

IV. EXPERIMENTAL SIMULATION AND ANALYSIS A. SIMULATION ENVIRONMENT AND PARAMETER SETTINGS
In order to experimentally verify the effectiveness of the proposed 3 improvement strategies, 16 internationally used benchmark test functions are selected as shown in Table 1 for simulation experiments. The experimental environment is Intel(R) Core(TM) i5-10210U CPU, 1.60GHz, 16GB, Windows 10 64-bit operating system, all codes are programmed through Matlab (version: R2020a), and compared with Grey Wolf Optimizer(GWO), Grey Wolf Optimization Algorithm based on Levy flight(LGWO) [20], Improved

Grey Wolf Algorithm for Solving Global Optimization
Problems(MGWO) [21], Improved Grey Wolf Optimization Algorithm for Nonlinear Convergence Factor(GWO-S) [22], Butterfly Optimization Algorithm(BOA), Chicken Swarm Optimizer (CSO), Whale Optimizer Algorithm(WOA), Table 2 shows the detailed settings of related parameters. In order to ensure fairness, the population number N of each algorithm is set to 30, and the maximum number of iterations T is 1000; to eliminate the influence of randomness, all experiments are run independently 30 times, and the Mean and Std of 30 times are taken as the metric of algorithm performance, as shown in Table 3.

B. ANALYSIS OF RESULTS
It can be seen from Table 3 that in the function f 5 , IGWO is inferior to GWO, LGWO, MGWO, GWO-S, WOA in terms of the worst, best, mean and std, but its fitness difference is within the allowable range, as shown in Fig.9, it can be seen that the convergence speed of IGWO is better than other algorithms. For function f 6 , it can be seen from Fig.11 that all algorithms converge fast at the beginning of the iteration, and fall into a local optimum at the end of the iteration,   and the convergence speed has slowed down. Table 3 shows that IGWO failed to find the optimal value, but, best, worst, mean and std of the IGWO are better than other algorithms. For function f 8 , the convergence speed of IGWO is slow in the later stage, as shown in Fig.15, but its convergence speed is still higher than that of other algorithms. From Table 3, except for WOA, IGWO is superior to other algorithms in terms of worst, best, mean and std.
For functions f 7 , f 9 ∼ f 11 , all algorithms can find the optimal value. For function f 7 , as shown in Fig.13, IGWO   can converge quickly, and its convergence speed is slightly higher than that of MGWO. From Table 3, except for the WOA, the worst, mean and std of IGWO are better than other algorithms. For functions f 9 ∼ f 10 , it can be seen from Table 3 that although all algorithms can find the optimal value, the worst, mean and std of IGWO are better than other algorithms, and the convergence speed is faster, as shown in Fig.17, Fig.19. Function f 11 , except BOA, the best, worst, mean and std of all algorithms are good, but from Fig.21,    it can be seen that the convergence speed of IGWO is slightly faster than other algorithms. For the function f 12 , except for WOA and GWO-S, IGWO's the best and the worst, and the mean is better than other functions. It can be seen from Fig.23 that the convergence speed is much faster than other functions. It can be seen from Table 3     IGWO is superior to other algorithms in best, worst and mean values.
From the time of table 3, the optimization time of IGWO is higher than that of GWO, but the difference is within the acceptable range. Compared with the other three improved grey wolf algorithms (LGWO, MGWO, GWO-S), the optimization time of IGWO has been reduced to a certain extent.    The experimental results show that IGWO is significantly better than the other seven comparison algorithms. It has a higher optimization ability and a higher solution accuracy. At the same time, from the std and box plot, it has high robustness.

C. ANALYSIS OF RESULTS
The path planning problem is to find an optimal path from the start point to the end point. This article assumes that the robot workspace is a two-dimensional plane, and any point   can be represented by (x, y). The green point and the blue point represent the start point and the end point, respectively, and the black points represent obstacles. Through analysis, it is found that although the model established by the grid method discretizes the space, the robot's movement path is still continuous in essence [23]. Therefore, when optimizing the robot path, this article stipulates that the robot's movement path cannot be roundabout, that is, when the robot    moves from the initial position to the target position, its longitudinal and lateral movement directions can only point to the target position, not the opposite. Assuming that the current raster coordinate of the robot is (x 1 , y 1 ) and the next raster coordinate of the robot is (x 2 , y 2 ), then it must satisfy that x 2 is greater than x 1 or y 2 is greater than y 1 . In addition, the motion of the robot is also restricted by obstacles, that is, the motion trajectory of the robot cannot pass through the grid area with obstacles.   In order to further verify the optimization ability of IGWO, a comparative experiment of IGWO and other algorithms to solve path planning problems in simple environments and complex environments is carried out. The total number of obstacles in the 2 environments is 21 and 51 (the map size is 30 * 30), and the test algorithm parameters are set as follows: the population size of the 4 algorithms is 30, and the maximum number of iterations is 1000. For simple and complex environments, the 4 algorithms are run    independently for 20 times, and the experimental results are shown in Fig. 33∼Fig. 36 and Table 4∼Table 5.    According to Fig. 33 and Fig.35, in the early stage of the algorithm, both GWO and IGWO have strong search   capabilities, but in the later stage of the algorithm, the GWO algorithm tends to fall into the local optimum. The IGWO, which adopts the fusion lion optimizer algorithm and the dynamic weight and segment update strategy, overcomes the shortcomings of falling into the local optimum, and can better find an optimal path. From Table 4 and Table 5, it can be seen that IGWO achieves the best performance in both simple and complex environments. The maximum value of IGWO is greater than GWO in simple environments, but the maximum value of IGWO is less than GWO in complex environments.

V. CONCLUSION
Through researching and analyzing the principle of the standard grey wolf algorithm, the update formula and the staged update, an improved grey wolf optimization algorithm is proposed for the basic grey wolf algorithm with low accuracy, slow convergence speed and easy to fall into local optimal problems. In this paper, the hybrid lion optimizer algorithm is used to add disturbance factors α f , β 1 , and α c to the grey wolf algorithm α wolf, β wolf, and δ wolf position update to enhance the search ability of α wolf, β wolf, and δ wolf. In addition, a dynamic weight strategy is introduced to make the grey wolf position update more diverse, so as to obtain the best value. The experimental results also show that IGWO better balances the algorithm's global search and local development capabilities, making IGWO perform better than the original algorithm and other intelligent algorithms; and to a certain extent, it improves the ability to find the best path. From the experimental results, IGWO has certain shortcomings. Although the optimization ability has been improved, the optimization time has increased, and part of the time has been sacrificed to improve the optimization ability.
In future work, firstly, more indicators will be used to test the performance of IGWO. Secondly, using IGWO to solve more complex applications (such as workshop scheduling and logistics transportation) will be very valuable. Finally, integrating different intelligent algorithms into new other methods is another research direction.
JINGYI LIU was born in Jingmen, Hubei, in 1996. She is currently pursuing the master's degree major in electronic information with Guangxi University for Nationalities. Her main research interest includes intelligent optimization.
XIUXI WEI received the M.S. degree from the School of Computer and Electronic Information, Guangxi University, in 2009. He is currently an Associate Professor with the College of Artificial Intelligence, Guangxi University for Nationalities. He has published more than 20 academic papers on artificial intelligence field. His current research interests include support vector machine, data mining, and intelligent optimization.
HUAJUAN HUANG received the Ph.D. degree from the School of Computer Science and Technology, China University of Mining and Technology, in 2014. She is currently an Associate Professor with the College of Artificial Intelligence, Guangxi University for Nationalities. She has published more than 30 academic papers on machine learning and support vector machine. Her current research interests include twin support vector machines, data mining, and pattern recognition.