Improved path planning algorithm for mobile robots

Path planning is an NP-hard problem in road network environments. Considering that the existing path planning algorithms mainly have the problems of low smoothness and low search efficiency in generating paths in large-scale complex environments, an improved rapidly exploring random tree (RRT) algorithm is proposed in this paper. First, the grid method is applied to model the road network environment, and the RRT algorithm based on adjacency expansion is proposed to search the initial path. Then, the strategies of identifying paths and eliminating redundant paths are adopted, respectively, to further optimize the selected paths. Experimental results show that, compared with other path planning algorithms, our algorithm can achieve faster convergence speed, shorter search path, and better smoothness in a complex map of the environment.

ways to move a robot in an environment with obstacles, from its initial position to reach a target location quickly, is one of the research highlights in the path planning problem for mobile robots (Patle et al. 2019;Zafar and Mohanta 2018).
The path planning algorithm lies at the heart of path planning. The mobile robot path planning problem can be divided into traditional optimization methods and intelligent optimization methods (Mac et al. 2016;Mohanty and Parhi 2013). Traditional optimization methods include the element decomposition method (Jung et al. 2019), artificial potential field method Sudhakara et al. (2018), virtual sub-target method (Singh et al. 2011), sampling-based method (Jeong et al. 2019;Karaman and Frazzoli 2011;Qureshi and Ayaz 2015;Shi et al. 2014;Tahir et al. 2018;Wang et al. 2020), Dijkstra algorithm (Dijkstra 1959;Broumi et al. 2016;Wu and Sun 2020;Yu et al. 2018). Jung et al. (2019) considered the problem of vertical cell decomposition by not considering the shape of obstacles and proposed a method based on diagonal accurate cell decomposition to obtain a smaller number of cells, before using the extended Douglas-Puck polygon approximation algorithm. As a result, the robot could plan its path in a static environment with curved obstacles, but the computational efficiency decreased as the complexity of the objects in the environment increased. Sudhakara et al. (2018) combined the grid method and artificial potential field technology using the characteristics of water flow to generate flow from a high potential field to a low potential field and by using boundary points to discretize the contours of obstacles of arbitrary shape. This solved the problem of the robot getting into a local minimum when searching for a path. Singh et al. (2011) used virtual sub-target information to navigate in a dynamic environment using a series of reachable virtual sub-targets between the starting point and the target point to avoid obstacles. A rapidly exploring random tree (RRT) is a sampling-based algorithm. The RRT algorithm has fewer parameters, a simple structure, strong search capability, and it is easy to combine with other algorithms. However, in the later stages of the RRT algorithm, the node utilization is low, the calculation load is too large, and the path is unstable. Consequently, many researchers have worked to improve the RRT algorithm in response to these limitations. Karaman and Frazzoli (2011) proposed a RRT * algorithm with asymptotic optimality based on the node expansion of RRT algorithm, which includes random geometry graph and pruning optimization theory, so that the nodes of random tree can converge to the current optimal value. However, the memory consumption and calculation overhead of the algorithm increases exponentially with growth in the number of nodes, and the algorithm efficiency is low. Tahir et al. (2018) introduced a potential-guided two-way tree in the RRT* algorithm and alternately led each continuous random sampling point to each tree in the bidirectional tree. The two trees were directed toward each other, which improved the speed of the algorithm converging to the optimal solution. Qureshi and Ayaz (2015) proposed an optimal algorithm for intelligent bidirectional search. Using the bidirectional tree method, the intelligent sample insertion heuristic method was introduced in the RRT* algorithm, and a unified sampling heuristic method was used to quickly converge to the optimal path. Jeong et al. (2019) improved the RRT* algorithm by using triangular inequalities to improve parent term selection and the rerouting process, which improved the quality of the initial solution and the speed of convergence to the optimal solution. Shi et al. (2014) combined the probabilistic road map with the RRT algorithm to improve the speed of the algorithm in generating paths on narrow roads. Wang et al. (2020) combined the convolutional neural network with the RRT* algorithm and used the convolutional neural network model to predict the probability distribution of the optimal path on the map. The Dijkstra algorithm is a single-source path algorithm, which is used to solve the shortest path problem from a vertex to other vertices. It expands to the outer layer through a starting point at its center, expanding to the end to obtain the shortest path (Dijkstra 1959). The Dijkstra algorithm is very simple and can effectively find the optimal solution, but its efficiency decreases with an increase in the number of data nodes, consuming a lot of memory resources and calculation time. Broumi et al. (2016) combined Dijkstra with the theory of neutrosophic sets, where the edge weight was changed from a single value to an interval-valued neutrosophic number to determine the shortest distance from each point to the source node. Wu and Sun (2020) added path factors to a part of the path when planning a path using the Dijkstra algorithm, which effectively reduced the conflict between multi-robot opposing paths. Yu et al. (2018) used the Dijkstra algorithm to plan a global path, after which a three-layer finite state machine was used to plan the route locally, which reduced the computational complexity when searching for the path.
The application of intelligent optimization methods in this field has been relatively extensive, including the genetic algorithm (GA) (Lee and Kim 2016), particle swarm optimization algorithm (Das et al. 2016;Tang et al. 2019), ant colony algorithm (Gao et al. 2020;Liu et al. 2017), neural network method (Wu et al. 2019), simulation plant growth algorithm (Zhou et al. 2017), weak roads detection algorithm , beetle antennae search algorithm , etc., the algorithms being continuously mixed for improvement. Lee and Kim (2016) created a directed acyclic graph to generate multiple paths for the initial GA path set from the obtained directed acyclic graph and improved the initialization process when the GA found a path. However, each time a path was generated, the length varied greatly. Das et al. (2016) proposed a multi-robot optimal path method, which optimized the path by improving a hybrid of the particle swarm and differential perturbation speed algorithms, reducing the energy consumption of a robot when turning. Tang et al. (2019) proposed an improved particle swarm optimization algorithm with adaptive inertia weight and obstacle avoidance function. At the same time, an improved fruit fly optimization algorithm was introduced to provide a better value for the particle swarm optimization algorithm to find the next optimal value, avoiding premature convergence and falling into local optimum, improving the robot's ability to avoid obstacles and the search efficiency. Liu et al. (2017) combined the artificial potential field and geometric local optimization methods. Pheromone was diffused along the direction of the potential field force during the ant search process, which reduced the cross path and improved the path search process. However, the algorithm required a lengthy search time and its convergence speed was slow. Gao et al. (2020) redefined the heuristic distance and pheromone diffusion radius formulas in the local visibility formula of the ant colony algorithm, introduced the backtracking and path merging strategies, and improved the efficiency of the ant colony algorithm and its global optimization ability. Wu et al. (2019) proposed an end-to-end neural network structure for the decomposition and synthesis of robot actions, which used a two-dimensional convolutional neural network to plan a three-dimensional path in real time. However, the algorithm relied on the learning environment and exhibited poor generalization ability. Zhou et al. (2017) used the characteristics of phototropism and negative geotropism to guide the path optimization direction based on the plant growth mechanism, only optimizing the value of the next point in each step of the path optimization process. This reduced the computational complexity and improved the calculation efficiency.  introduced a back-off mechanism in the beetle antennae search algorithm to reduce the probability of the robot falling into a local extreme during path planning. Chi et al. (2022) designed a heuristic path planning algorithm based on the Voronoi diagram (GVD) to generate heuristic paths, guide the sampling process of RRT, and further improve the efficiency of RRT motion planning. Low et al. (2022) proposed an improved Q-learning method for mobile robot path planning. Na et al. (2022) presented a path planning optimization (GEI-BBO) for mobile robots based on gradient feature decomposition invariance biogeography, which had the characteristics of high rotation invariance and excellent search performance.
After a robot plans its initial path, it needs to smooth the generated path (Dragan et al. 2013). Pan et al. (2012) smoothed the path generated based on sample planning through spline interpolation, randomly selecting a series of points along the original piecewise linear path and constructing cubic B-splines to interpolate or approximate these points. Ratliff et al. (2009) proposed a continuous path refinement method based on covariant gradient technology, which used covariant gradient technology to improve the quality of sampled trajectories. (Heiden et al. 2018) combined gradient optimization and fast cutting and proposed a gradient information path smoothing algorithm, skipping redundant vertices on feasible paths, and changing the trajectory by locally optimizing the position of the vertices. The generated path could maintain a sufficient distance from obstacles.
However, in the above-mentioned research, when the map scale is large, the calculation overhead is large and the search efficiency is reduced, or the random blind search when searching for the path causes sizable differences in the results of each path. In practical applications, a robot is required to perform the task of finding its path consistently and efficiently. The RRT algorithm takes an initial node as the root node, increases leaf nodes through random sampling, and generates a random extended tree. Usually, because of the complexity of solving the path space, the random expansion tree generates more redundant leaf nodes, which not only reduces the time efficiency of the algorithm, but also increases its storage consumption and the shortest path length generated.
To solve the above problems, we propose a mobile robot path planning method based on an improved RRT algorithm. Based on the random expansion tree in the traditional RRT algorithm, we propose an adjacent-relation rapidly exploring random tree (A-RRT) algorithm. The basic idea is to increase leaf nodes using the greedy strategy of adjacent grid node sampling instead of random sampling to generate an RRT extended tree. Compared with the random expansion tree of the traditional RRT algorithm, the A-RRT algorithm adds leaf nodes and generates RRT+ extended trees by replacing random sampling with adjacent grid node sampling of greedy strategy. To complete path planning, the Dijkstra path sequence search algorithm is used to search the shortest path from the starting node to the target node in the initial path sequence, and the repetitive sequence optimization algorithm is used to remove redundant paths. The contributions of this study are summarized as follows: (1) The proposed algorithm can successfully plan the route even on a narrow road on the map. (2) There is no randomness or uncertainty in generating points in the feasible area on the map, and the initial feasible path generated each time is unique. (3) The algorithm can simultaneously achieve the shortest distance and smoothest path by updating the position of each point in the path. (4) The proposed algorithm can quickly generate paths even in large-scale complex road network maps.
Compared with other algorithms, our algorithm has the advantages of high execution efficiency, low storage consumption, high smoothness of planned path and successful path planning for narrow roads on the map. The main novelty of our algorithm is that it combines the advantages of simple structure, strong adaptability and fast speed of the RRT algorithm with the advantages of high efficiency and fast speed of the Dijkstra algorithm. The remainder of this paper is organized as follows: Section 2 introduces the formulation of the problem and spatial modeling. Section 3 introduces the proposed A-RRT, Dijkstra path sequence search, and RSO algorithms. In Sect. 4, various experiments verify the effectiveness of the algorithm. Finally, the conclusion is drawn in Sect. 5.

Problem statement and spatial modeling
To express path planning in a road network environment, we first construct a grid map model of a complex road. Figure 1 shows a map of a road in Shenzhen, China.
The grid method is simple and effective and can express irregular obstacles and reduce the complexity of environmental modeling. The grid method creates a grid map based on The grid is divided into two types: a free grid and an obstacle grid. The white grid is the free grid, and the black grid is the obstacle grid. The robot can move only within the free grid. For the convenience of research, the following assumptions are made about the mobile robot and its working environment: (1) The mobile robot is regarded as a cylinder whose bottom diameter is equal to the length of a grid; (2) The starting point, the end point, and the information of the static obstacles in the environment are known; (3) The height of the obstacle is negligible and stationary.
For mobile robots, the purpose of path planning is to find a feasible path in a specific environment. The grid map is defined as a collection of nodes M. As shown in Fig. 2, this path starts from the starting point S of the map and ends at the target point D. The path is defined as P = (V , E), where v i ∈ V (i = 1, 2, . . . , n) denotes the node. Each node represents a grid unit, where S is the starting node, D is the target node, v i and v i+1 are connected by straight line segments, and the coordinates of v i are defined as connecting v i and v i+1 exists. Through the modeling and division of the robot operating environment using the grid method, the path planning problem becomes based on the starting point S and the target point D, using an algorithm to find an ordered subset of grids in the free grid collection, the center line of these ordered grids being the path planned P by the algorithm.

Proposed algorithm
In this section, the main steps of the path planning algorithm proposed in this study are introduced: (1) A-RRT algorithm generates the extension tree based on the adjacency-relation.
(2) Initializes the path sequence from the starting node S to the target node D in step (1). (3) It uses the Dijkstra path sequence search algorithm to optimize the path sequence in step (2) to obtain the optimized path sequence. (4) It uses the RSO algorithm to optimize the path sequence in step (2) to obtain the optimized path sequence.

Adjacent-relation rapidly exploring random tree algorithm
collection of nodes that are adjacent to the node v and can pass directly from node v. distance(v i , v j ) is defined as the length between any two nodes v i and v j , and distance(v i , v j ) ≥ 0 (indicated by the Euclidean distance). Define Flag(v) to mark whether the node v has been searched. If it has been searched, it is True, otherwise it is False. The parent node of the node v in the spanning tree of A-RRT is represented as v. parent.
The specific steps of A-RRT algorithm are shown in Algorithm 1, as follows: Algorithm 1 Adjacent-relation rapidly exploring random tree algorithm end for 20: end while 21: return T .
Step 1 Initialize a tree T with only the target D and initialize a queue Q, and add the target node D to the queue Q.
Step 2 The head node v t of the queue leaves the team and Ad jacent(v t ) enters the team. If the node v that is adjacent to the head node of the team and can be directly passed has not been explored, calculate the shortest path length from the adjacent node of the node v to the target node D based on Eq. (1) and select the node with the smallest path length to connect to the node v, as the parent node of the node v in T . Based on Eq. (2), the path length between node v and the parent node is recorded as

Initialization path sequence algorithm
We define the initial path sequence P init =(V init , E init ), where V init and E init are the node set and edge set of the path sequence P init , respectively.The specific steps of initializing the path sequence from the starting node S to the target node D are shown in Algorithm 2. Starting from the initial node S, an initial path sequence P init that reaches the target node D is searched based on the shortest path length from the neighboring nodes to the target node D.
Algorithm 2 Initialization path sequence algorithm

Dijkstra path sequence search algorithm
The Dijkstra algorithm is an algorithm that finds the shortest path in the location nodes of the workspace. The Dijkstra path sequence generated by the Dijkstra path sequence search algorithm can be expressed as P = (V , E), where V and E are the node set and edge set of path sequence P, respectively. Suppose dist(v) is the shortest distance from source node S to node v, prev(v) represents the last node v in the sequence of the shortest ordered distance from the starting node S to node v, and distance(v i , v j ) is defined as the length between node v i and node v j , and distance(v i , v j ) ≥ 0 (represented by Euclidean distance). Then, the algorithm defines the tag of the next node j as follows: The specific steps of the Dijkstra path sequence search algorithm are shown in Algorithm 3, as follows: Algorithm 3 Dijkstra path sequence search algorithm end if 6: end for 7: end for 8: V ← ∅; 9: L ← ∅; 10:  Step 1 In the initial path sequence P init , if there is no obstacle node in the line between any two nodes v i and v j on the map M, then add edge < v i , v j > in the initial path sequence P init .

23:
Step 2 Initialize the node set V and L to be empty, add the node v of V init to the set V and calculate the shortest distance dist(v) of the node v and S.
Step 3 Delete the node u with the smallest value of dist(v) in the set V and add it to L, update the shortest distance from the starting node S to v. And save u as the previous node of node v in prev(v) until the queue Q becomes empty.
Step 4 Initialize the path sequence P, start from the target node D, add the starting node S to the previous node of the node v in the sequence of the shortest distance to the node v, and get Dijkstra path sequence P.

Repeat sequence optimization algorithm
Define P opt = (V opt , E opt ) as the sequence after path optimization, where V opt and E opt are the node set and edge set of the path sequence P opt , respectively. Define v Cur_S and v Cur_D (1 ≤ Cur_S ≤ Cur_D ≤ n) to be any two nodes in the initial path sequence V init obtained by Algorithm 4. The specific steps of the repeated sequence optimization algorithm are shown in Algorithm 4, as follows:

Algorithm 4 Repeat sequence optimization algorithm
Require: M, P init Ensure: P opt 1: Cur_S ← 1; 2: Cur_D ← 1; Cur_D ← Cur_D + 1; 8: end while 9: if v Cur_D = D then 10: if isEqual(Cur_D − 1, Cur_S + 1) then 11: Step 1 Initialize the path sequence P opt , where there is only the starting node S in the node set, and the edge set is empty. Initialize the values of Cur_S and Cur_D; Step 2 Find the maximum value of Cur_D so that the connection between nodes v Cur_S and v Cur_D is not hindered by obstacles. If the node v Cur_D is the target node D, then add the target node D to V opt and add the edge < v Cur_S , D > to E opt , the path sequence optimization work is completed. If Cur_D − 1 and Cur_S + 1 are equal, then add edge < v Cur_S , v Cur_S+1 > to E opt , otherwise add edge < v Cur_S , v Cur_D−1 >, update the values of Cur_S and Cur_D and add the node v Cur_S to V opt . The loop repeats until the node v Cur_D is the target node D.

Time complexity analysis
As described in Sects. 3.1, 3.2, 3.3, and 3.4, our model includes four steps: The A-RRT algorithm generates an extended tree, initializes the path sequence from the starting node S to the target node D, uses the Dijkstra path sequence search algorithm to optimize the path sequence, and uses the RSO algorithm to optimize the path sequence. The time complexity of the A-RRT algorithm to generate the spanning tree (algorithm 1) is O(n 2 ), where n represents the number of nodes in the path sequence. The time complexity of the initialization of the path sequence from the starting node S to the target node D (algorithm 2) is O(n). The time complexity of the Dijkstra path sequence search algorithm to optimize the path sequence (algorithm 3) is O(n 2 ). The time complexity of the RSO algorithm to optimize the path sequence (algorithm 4) is O(n 2 ). Combining these analysis results, the time complexity of our model is O(n 2 ).

Experimental settings
In this section, we present a series of simulation experiments to verify the effectiveness and efficiency of our proposed algorithm. All simulation experiments were implemented on the 3.6 GHz Intel Core i5 processor using MATLAB R2018b. The robot was regarded as a particle, with red dots representing the starting node and green dots representing the target node. The experimental environment space consisted of twenty 500 × 500 maze maps and four 1000 × 1000 complex road network maps.
Because the characteristics of the obstacles to a robot's path planning have great influence, we used an obstruction in the same environment to verify the effectiveness of the proposed algorithm. We conducted the experiment in three parts. First, the performance of the A-RRT-Dijkstra and A-RRT-RSO algorithms was compared in the maze map environment to obtain the improved algorithm. This was then compared with the intelligent bidirectional RRT* (IB-RRT*) (Na et al. 2022), Quick-RRT*(Q-RRT*) (Heiden et al. 2018), A* Gao et al. (2020), and the genetic algorithm-based robot path planning (GARPP) method (Karaman and Frazzoli 2011) for many times. Finally, the algorithm was compared in a complex road network map environment to verify the effectiveness of the proposed algorithm.

Experimental indicators
As mentioned earlier, the algorithm based on the sampling process will generate a different path each time it runs. Therefore, the algorithm was executed fifty times for each environment category to calculate the average performance variables. In response to the needs of actual path planning, all comparative experiments in this study set the same starting node and target node and recorded the shortest path length, execution time, and smoothness under different algorithms. The shortest path length refers to the length of the shortest path sequence from the starting node to the target node obtained after the algorithm was executed. The shorter the shortest path length, the better the path effect of the algorithm planning. For points N on the path P, the total length of the path P can be calculated using Eq. (3): where distance(v i , v i+1 ) is defined as the length between node v i and node v i+1 , and distance(v i , v i+1 ) ≥ 0 (represented by Euclidean distance).
Execution time refers to the running time from the beginning of the algorithm input data to the planned path. The shorter the execution time, the better the timeliness of the algorithm.
The smoothness of the path is measured by calculating the angle of the inflection point on the path. The average path angle represents the smoothness of the path, and the ideal average angle is 180 • . For three consecutive points v i ,v i+1 and v i+2 (1 ≤ i ≤ N − 2), calculate the angle between the vector v i − v i+1 and vector v i+2 − v i+1 and then average all the angles on the path P to obtain the smoothness value of the path (Eq. (4)).

Comparison of A-RRT-Dijkstra and A-RRT-RSO algorithms in maze map environment
As shown in Fig. 3, the red and blue lines in the path planning results obtained in our experiment after the execution of the A-RRT algorithm are the Dijkstra path sequence search and the RSO algorithm results, respectively. The algorithm in this study could plan a path between the starting node and the target node of twenty maze maps. After initializing the path sequence from the starting node to the target node, both the Dijkstra path sequence search and the RSO algorithms could optimize the initialization path sequence, and the optimization effect was relatively good. The execution times of the A-RRT-Dijkstra sequence optimization and A-RRT-RSO algorithms are shown in Table  1. In the A-RRT-Dijkstra sequence optimization algorithm, Fig. 3 The path planning results of A-RRT-Dijkstra and A-RRT-RSO algorithms in the maze maps when Dijkstra was used to optimize the initial path sequence generated by A-RRT, the execution time was longer because of the algorithm's complexity. The RSO algorithm improved the time efficiency by 77.89% on average compared with the Dijkstra sequence optimization algorithm.
The shortest path lengths of the A-RRT-Dijkstra and A-RRT-RSO algorithms are shown in Table 2. The optimized shortest path length of the A-RRT-Dijkstra algorithm was 0.78% shorter than that of the A-RRT-RSO algorithm, on average. Considering the balance efficiency and optimality of the actual path planning, the RSO algorithm was superior to the Dijkstra sequence search algorithm. Consequently, the A-RRT-RSO algorithm was adopted as the path sequence optimization algorithm in the following comparison experiments.

Comparison of A*, GARPP, Q-RRT*, IB-RRT* and A-RRT-RSO algorithms in maze map environment
In our simulations, grid processing was performed on twenty maze environment maps, and the mobile robot was assumed to be a point. Each algorithm carried out fifty independent experiments using different maps. The initial parameters were set as follows: Let the maximum number of iterations of the IB-RRT* algorithm be 10 000, and the maximum number of iterations of the Q-RRT* algorithm be 10 000, the ancestor depth was set to 1, and the depth during rewiring was set to 1. As shown in Fig. 4, the blue, red, green, brown, and purple lines shown in the path planning results obtained in this experiment are the A-RRT-RSO algorithm in this study, GARPP, IB-RRT*, A*, and Q-RRT* algorithms, respectively. As shown in Fig. 4, there are twenty simulation maps with trap areas and local minima. Several algorithms ran in the same simulation map environment. The simulation results   showed that in the maze environment, the path of IB-RRT* on the map due to sampling heuristics and the path of GARPPwhich uses a directed acyclic graph-resulted in the robot finding longer paths with larger corners. The robot using the A* and the Q-RRT* algorithms could escape from the trap area and local minima in the maze environment and reach the end, but the path was not particularly smooth; the algorithm used in this study was optimized by introducing repeated sequences, so the robot would not fall into the trap area or struggle with the dilemma of local minima, guiding the robot to avoid the trap area. The planned path was composed of several straight-line segments, and the path was smooth and short, with no large corners.
The simulation data are shown in Tables 3, 4, 5 and Fig. 5. The A-RRT-RSO algorithm took less time than the other algorithms to plan the path from the starting node to the target node in Map1, Map3, Map4, Map5, Map7, and Map15. The shortest path length planned using the A-RRT-RSO algorithm was 4.60, 36.82, 3.92, and 10.29% shorter than the A*, GARPP, Q-RRT*, and IB-RRT* algorithms, respectively. The average running time of the GARPP algorithm in Map6, Map10, and Map16 was better than that of the A-RRT-RSO algorithm, and the running time of the A-RRT-RSO algorithm was closer to that of the GARPP algorithm in Map9, Map13, and Map17. From the twenty maze path diagrams in Fig. 4, it can be seen that the GARPP algorithm had greater volatility for different map environments, execution time, and path to be searched. The A-RRT-RSO algorithm was relatively stable compared to the GARPP algorithm. In Map2, Map8, Map12, Map14, and Map18, the IB-RRT* algorithm exhibited an advantage over the A-RRT-RSO algorithm in terms of time. In Map11, Map19, and Map20, the A-RRT-RSO algorithm was closer to the IB-RRT* algorithm in time, but the shortest path of the A-RRT-RSO algorithm was shorter than that of the IB-RRT* algorithm. Through the above simulation results, the following conclusions were  Best results in each row are shown in bold Best results in each row are shown in bold obtained. Each time the GARPP algorithm resulted in a different path, and the path length was longer, the IB-RRT* and the Q-RRT* algorithm took more time to execute in some maps, and the path length was longer than that of the A-RRT-RSO algorithm. The average execution time of the A* algorithm was the longest. The A-RRT-RSO algorithm had a unique result for each generated path of all maps. It had the fastest solution speed and the shortest generated path. In short, the A-RRT-RSO algorithm performed better than the other algorithms.

Complex road network map environment
In this section, we discuss the impact of the complex road network environment space on the robot target search. Thus far, we have tested several path planning methods using twenty maze maps. To verify the performance of the method discussed in this paper in a map composed of a large number of nodes, we created four maps of different regions in China and used them in our simulations. Each map was composed of 1000 × 1000 nodes. The difference between the research environment of the maze map and the complex road network map was that in a complex environment, the greater the dis- Fig. 6 Road maps of the real world tance between two points, the less likely there was to be a direct connection between them. Figure 6 shows an illustration of four real-world maps. In these experiments, we still used the IB-RRT*, Q-RRT*, A*, and GARPP algorithms for comparative analysis.
Assuming the mobile robot to be a point, each algorithm carried out fifty independent experiments using different maps. The initial parameters were set as follows: Let the maximum number of iterations of IB-RRT* be 40,000; the maximum number of iterations of the Q-RRT* algorithm was 40,000; the ancestor depth setting was set to 1, and the depth during rewiring was set to 1. As shown in Fig. 7, the blue, red, green, brown, and purple lines in the path planning results obtained in this experiment are the A-RRT-RSO, GARPP, IB-RRT*, A*, and Q-RRT* algorithms, respectively.
As shown in Fig. 7, there are four road network maps with dense obstacles, narrow passages, depressions, and mazes. Several algorithms were run on the same simulation map environment. The simulation results showed that in a complex road network environment, the GARPP algorithm would trap the area or the location of the local minimum first and then reach the end smoothly after leaving, which lead to a long path that is less smooth, and with many corners being too large; the IB-RRT*, A*, and Q-RRT* algorithms would detour to reach the end point in multiple narrow roads, resulting in longer paths; the path planned by the A-RRT-RSO algorithm was shorter, the path was smoother, and there were no large corners.
The simulation data are shown in Tables 6, 7, 8, and Fig. 8. It can be seen that, compared to other methods, the A-RRT-RSO algorithm had significantly better performance in Area3 and Area4. As can be seen from Fig. 7 and Table 8, although the average running time of the A-RRT-RSO algorithm was higher than that of the GARPP algorithm in Area 1 and Area 2, the path length of the A-RRT-RSO algorithm was 40.99% and 16.83% shorter than that of the GARPP algorithm. Over fifty runs of each map, the stability of the GARPP algorithm was poor, and the length of each generated path varied greatly. It can be seen intuitively from Fig. 7 that the shortest path length of the GARPP algorithm was the longest of the tested algorithms. In Area 1, the running time of the IB-RRT* algorithm was longer than that of the other Fig. 7 The path planning results of A*, GARPP, Q-RRT*, IB-RRT* and A-RRT-RSO algorithms in complex road network maps Best results in each row are shown in bold Best results in each row are shown in bold Best results in each row are shown in bold algorithms. The IB-RRT* algorithm was less efficient in the tortuous path environments of Area 1 and Area 3, while the A-RRT-RSO algorithm was more effective in such narrow and curved channels and could generate the shortest path stably and quickly. In short, as the size of the search space increased, the performance advantages of the A-RRT-RSO algorithm became more apparent.
The following conclusions can be drawn from the simulation results. When the environment map is complex and large in scale, the search paths of the GARPP and IB-RRT* algorithms are longer and differ each time. The A* and Q-RRT* algorithms cause low search efficiency and time consumption because of the increase in the map scale. The A-RRT-RSO algorithm, however, is still able to search for the smoothest, shortest path more quickly in a large-scale complex road network environment and obtain better results than the other algorithms.

Discussion
The average execution time, the shortest path length and the smoothness of different algorithms in the maze map and the complex road network map environments are shown in Figs. 5 and 8. It can be found that the A-RRT-RSO algorithm is superior to the other algorithms in the average execution time, shortest path length and the smoothness. The A-RRT-RSO algorithm may be weaker than other algorithms in some aspects, but its performance is better than other algorithms in most aspects. For example, although the average running time of the A-RRT-RSO algorithm in Area 1 and Area 2 in Fig. 8 is higher than that of the GARPP algorithm, the shortest path length of the A-RRT-RSO algorithm is shorter than that of the GARPP algorithm, and the smoothness is also better than that of the GARPP algorithm. The above statement fully demonstrates the effectiveness and excellence of the A-RRT-RSO algorithm in path planning.

Conclusions
In order to solve the problem of the current path planning algorithms generating tortuous paths with low search efficiency in a large-scale complex map environment, we proposed an improved RRT algorithm. The optimal path between the source point and the target point is determined using the proposed A-RRT algorithm and RSO algorithm. The algorithm initializes a path from the start node to the target node based on the adjacency relationship between the nodes, and then, it uses the path sequence optimization algorithm to plan an optimal path. The experimental results showed that compared with other heuristic and deterministic algorithms, the proposed algorithm could reduce the search nodes in a large-scale road network environment, avoid blind search, and minimize the path calculation cost, obtain a better path, and quickly find solutions.
At present, we study robot path planning in a twodimensional static environment. This research content can be extended to more fields, such as unmanned aerial vehicles, robot arm movements and robot navigation in more complex terrain. Future research will focus on dynamic and high-dimensional environments. Now it is required that the path planning algorithm should have the ability to quickly respond to the changes in complex environments. This is not a problem that can be solved by a single or unilateral algorithm. Therefore, in the future path planning technology, using a hybrid algorithm to solve the path planning problem may be an effective research direction. In addition, we will intend to apply path planning methods to image segmentation, obstacle avoidance and penetration flight of UAVs, GPS navigation and other fields.