# Safe Path Planning of Mobile Robot Based on Improved A* Algorithm in Complex Terrains
## 4 Path Planning in Complex Terrains
### Simulation Experiments and Analysis in Complex Terrain Environment  
Assume the average speeds of the robot moving on flat land, grassland, and mountain land are 2 m/s, 1.6 m/s, and 1.2 m/s, respectively. The speed of the robot should be adjusted according to the minimum distance between the robot and obstacles; the adjustment rules are shown in Table 4.  
The smooth path generated by simulation is shown in Figure 10.  
It can be seen from Figure 10 that the planned path keeps a certain distance from the obstacles to ensure the safety of the path. A predominant portion of the path is on flat land because the robot moves faster on it. Nevertheless, there is also a part of path which passes through mountain land and grassland instead of detouring around them to favor a path exclusively on flat land. This is because the detouring process would take more time. The ant colony optimization (ACO) algorithm, the conventional A* algorithm, and the improved RRT* algorithm are applied to search the shortest paths respectively in the same environment. The parameters configuration of the ACO is shown in Table 5, where \(K\) indicates the largest number of iterations, \(M\) indicates the total number of ants, \(\alpha\) and \(\beta\) indicate the stimulating factors of pheromone concentration and visibility respectively, \(\rho\) indicates the coefficient of the pheromone volatilization, and \(Q\) indicates the initial value of the pheromone concentration. For the RRT* algorithm, the risk zones around the vehicle consisted of four zones and the function of the risk zones is presented as follows. \begin{table}
\begin{tabular}{c c} \hline \hline
**Minimum Distance (m)** & **Speed Reduction Ratio** \\ \hline
0–1 & 50\% \\
1–2 & 40\% \\
2–3 & 30\% \\
3–4 & 20\% \\
4–5 & 10\% \\ \textgreater{}5 & 0\% \\ \hline \hline \end{tabular}
\end{table} 
Table 4: The adjustment rules of the robot speed. Figure 10: Path planning in complex terrain environment by using the improved A* algorithm. \[Risk(q)=\left\{ \begin{array}{ll}1.8,&\quad\quad\quad\quad if\ Collision(zone_{1})\\ 1.6,&\quad\quad\quad if\ Collision(zone_{2})\\ 1.4,&\quad\quad\quad if\ Collision(zone_{3})\ q=[x,y,\psi]^{T}\\ 1.2,&\quad\quad\quad if\ Collision(zone_{4})\\ 1,&\quad\quad if\ not\ Collision(any\ zone)\end{array} \right. \tag{10}\]  
The radius of the set _Xnear_ of vertices is \(15,\eta=2\), the number of iterations was set to 1500. The planning results of the three algorithms are shown in Figure 11.  
Obviously, the planned paths generated by the ACO algorithm and the conventional A* algorithm had many turning points and also directly passed through a large area of grassland and mountain land. Both paths were close to the obstacles and were not time-optimal paths. The paths generated by the improved RRT* algorithm and the improved A* algorithm kept away from the obstacles. Table 6 shows the detailed parameters of the four paths shown in Figures 10 and 11. Although the improved A* algorithm increased the path length by 1.7%, Table 6 demonstrates that it reduced the turning times by 41.2%, reduced the sum of turning angles by 80.3%, reduced the  
Figure 11: Path planning in complex terrain environment by using different algorithms: (**a**) Simulation result of the ant colony optimization (ACO) algorithm; (**b**) Simulation result of the conventional A* algorithm; (**c**) Simulation result of the improved RRT* algorithm. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline \(K\) & \(M\) & \(\alpha\) & \(\beta\) & \(\rho\) & \(Q\) \\ \hline
15 & 18 & 1 & 4 & 0.35 & 140 \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Parameters configuration of the ant colony optimization algorithm. length of risky path and dangerous path by 67.5% and 96.3% respectively, reduced the computation time by 70.6%, and it eventually led to a 37.5% fall in the movement time of the robot compared to the ACO algorithm.