Robot path planning method and system based on fusion of improved ant colony algorithm and DWA

By improving the fusion of ant colony algorithm and DWA, combining the potential field heuristic function and dynamic pheromone update mechanism, the problem of slow convergence speed and local optimality of path planning in the existing technology is solved, and a more efficient and safe robot path planning is achieved.

CN119714278APending Publication Date: 2025-03-28WUXI UNIV
View PDF 0 Cites 13 Cited by

Patent Information

Application Number
CN202411868681.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-18
Publication Date
2025-03-28

AI Technical Summary

Technical Problem

The prior art has problems in path planning that slow convergence speed, easy to fall into local optimality, lack of global path guidance, low environmental adaptability, and ineffectiveness of highly mobile obstacles.

Method used

By improving the fusion of the ant colony algorithm and DWA, the potential field heuristic function and dynamic pheromone update mechanism are adopted, combined with the local target point setting method and the evaluation function that considers dynamic obstacles, the global and local paths of the robot are generated.

Benefits of technology

It achieves faster convergence speed, higher path planning accuracy, better environmental adaptability and effective obstacle avoidance to dynamic obstacles, improving the safety and reliability of robot path planning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119714278A_ABST
    Figure CN119714278A_ABST
Patent Text Reader

Abstract

The invention provides a robot path planning method and system based on fusion of an improved ant colony algorithm and DWA, and the method comprises the steps: building a grid map of the movement of a robot, and generating a global path of the robot in the grid map through employing the ant colony algorithm; transmitting the global path to a DWA dynamic window model to generate a dynamic window; adding unknown static and dynamic obstacles into the grid map, and setting a local target point by using a local target point setting method based on the global path; based on the local target point and the robot movement information, robot speed sampling is carried out in the dynamic window, and a simulation track of robot movement is obtained; evaluating the simulation track by using an obstacle avoidance evaluation function, and if the robot reaches a target point, obtaining an optimal path; and if the robot does not arrive at the target point, regenerating a simulation track for iterative calculation until the robot arrives at the target point. The improved algorithm can effectively improve the performance and adaptability of robot path planning in different environments.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of mobile robot path planning, and in particular relates to a robot path planning method and system based on the fusion of an improved ant colony algorithm and DWA. Background Art

[0002] With the continuous development of robotics technology, path planning, as one of the key technologies for robot navigation and autonomous mobility, has received extensive attention and research. The goal of path planning is to find an optimal path for the robot from the starting point to the end point in a known or unknown environment. In this process, many factors need to be considered, such as the length of the path, the kinematic constraints of the robot, the distribution of obstacles, etc.

[0003] Ant Colony Algorithm (ACO), as a bionic optimization algorithm, has been widely used in the field of path planning due to its powerful global search capability and robustness. However, the traditional ant colony algorithm also has some defects, such as slow convergence speed and easy to fall into local optimal solution. On the other hand, DWA (Dynamic Window Approach) algorithm is an algorithm for local obstacle avoidance and path tracking of robots. However, the traditional DWA has the following problems: (1) Lack of global path guidance: The traditional DWA lacks global path guidance when planning the robot path and is easy to fall into the local optimal solution. (2) Low environmental adaptability: The traditional robot navigation method relies on the turning point of the global path. However, when there are many unknown static obstacles, the tracking accuracy of the robot will be reduced. (3) Ineffectiveness against highly mobile obstacles: The traditional DWA shows good robustness and obstacle avoidance in static environments, but it may become ineffective when highly mobile obstacles appear in the motion space.

[0004] In summary, the existing technology has many problems and needs to be improved. Summary of the invention

[0005] In order to solve the problems existing in the prior art, the present invention provides a robot path planning method and system based on the fusion of improved ant colony algorithm and DWA. By improving the ant colony fusion DWA, the respective advantages of the two algorithms are brought into play to achieve dynamic obstacle avoidance.

[0006] To achieve the above object, the present invention provides the following solutions:

[0007] The robot path planning method based on the fusion of improved ant colony algorithm and DWA includes the following steps:

[0008] Establishing a grid map for robot movement, in which an ant colony algorithm is used to generate a global path of the robot;

[0009] Passing the global path to the DWA dynamic window model to generate a dynamic window;

[0010] Add unknown static and dynamic obstacles to the grid map, and set local target points based on the global path using a local target point setting method;

[0011] Based on the local target point and the robot movement information, sampling the robot speed in the dynamic window to obtain a simulated trajectory of the robot movement;

[0012] The simulated trajectory is evaluated using an obstacle avoidance evaluation function. If the robot reaches the target point, the optimal path is obtained; if the robot does not reach the target point, the simulated trajectory is regenerated and iteratively calculated until the robot reaches the target point, completing the robot's path planning.

[0013] Preferably, the ant colony algorithm adopts an improved ant colony algorithm, and the method for generating the global path of the robot based on the improved ant colony algorithm includes:

[0014] The potential field heuristic function is introduced to calculate the distance between the preset node and the target node in the grid map, and the potential field concept is combined to evaluate the attractiveness of each node to obtain the heuristic information value;

[0015] Based on the heuristic information value and the pheromone concentration, the probability of the ant selecting the next node is calculated to obtain a node selection rule;

[0016] Based on the node selection rule and Dijkstra algorithm, the shortest path from the current node to the next node of the ant is calculated, and the pheromone on the shortest path is set as the initial pheromone value;

[0017] Adjusting the initial pheromone value based on the path length of the shortest path and the number of obstacles, and updating the pheromone matrix of the ant colony based on the adjusted initial pheromone value;

[0018] Based on the updated pheromone matrix, a dynamic pheromone update mechanism is adopted and the pheromone volatility coefficient is introduced to adjust the wit of the adaptive pheromone to update the global pheromone and obtain the global path;

[0019] A pruning strategy is used on the global path to obtain a global optimal path.

[0020] Preferably, the method of setting the local target point using the local target point setting method includes: when the robot is in a path planning state, checking the global optimal path to determine whether the robot will pass through an obstacle during movement, and if so, setting the local target point on the global optimal path that is closest to the obstacle.

[0021] Preferably, the obstacle avoidance evaluation function is an evaluation function that takes dynamic obstacles into consideration, and the construction method includes:

[0022] Based on the position and speed of the robot and the position and speed of the dynamic obstacle, calculate the relative distance and relative speed between the robot and each dynamic obstacle;

[0023] Based on the relative distance and the relative speed, obtaining an estimated collision time between the robot and the dynamic obstacle;

[0024] Based on the estimated collision time, obtaining a distance risk item between the robot and the dynamic obstacle;

[0025] Based on the distance risk term, the obstacle avoidance evaluation function is constructed.

[0026] The present invention also provides a robot path planning system based on the fusion of improved ant colony algorithm and DWA, which is used to implement the method, including:

[0027] A global path generation module is used to establish a grid map for robot movement, in which an ant colony algorithm is used to generate a global path for the robot;

[0028] A dynamic window generation module, used for passing the global path to a DWA dynamic window model to generate a dynamic window;

[0029] A local target point setting module, used for adding unknown static and dynamic obstacles to the grid map, and setting local target points based on the global path using a local target point setting method;

[0030] A simulation trajectory calculation module, used for sampling the robot speed in the dynamic window based on the local target point and the robot movement information, to obtain a simulation trajectory of the robot movement;

[0031] The optimal path acquisition module is used to evaluate the simulated trajectory using the obstacle avoidance evaluation function. If the robot reaches the target point, the optimal path is obtained; if the robot does not reach the target point, the simulated trajectory is regenerated and iterative calculation is performed until the robot reaches the target point, completing the robot's path planning.

[0032] Preferably, the global path generation module includes:

[0033] A heuristic information value calculation unit is used to introduce a potential field heuristic function, calculate the distance between a preset node and a target node in a grid map, and evaluate the attractiveness of each node in combination with the potential field concept to obtain a heuristic information value;

[0034] A node selection unit, used to calculate the probability of the ant selecting the next node based on the heuristic information value and the pheromone concentration, and obtain a node selection rule;

[0035] A pheromone initialization unit, used to calculate the shortest path from the current node to the next node of the ant based on the node selection rule and the Dijkstra algorithm, and set the pheromone on the shortest path as the initial pheromone value;

[0036] A pheromone matrix updating unit, configured to adjust the initial pheromone value based on the path length of the shortest path and the number of obstacles, and update the pheromone matrix of the ant colony based on the adjusted initial pheromone value;

[0037] A global pheromone updating unit is used to update the global pheromone based on the updated pheromone matrix, adopt a dynamic pheromone updating mechanism and introduce an adaptive adjustment of the pheromone volatility coefficient to obtain a global path;

[0038] The pruning unit is used to apply a pruning strategy to the global path to obtain a global optimal path.

[0039] Preferably, in the local target point setting module, the method of setting the local target point using the local target point setting method includes: when the robot is in a path planning state, checking the global optimal path to determine whether the robot will pass through an obstacle during the movement process, and if so, setting the local target point on the global optimal path of the grid closest to the obstacle.

[0040] Preferably, the optimal path acquisition module includes an evaluation function construction unit for constructing an evaluation function taking into account dynamic obstacles; the evaluation function construction unit includes:

[0041] A relative distance and relative speed calculation subunit, used to calculate the relative distance and relative speed between the robot and each dynamic obstacle based on the position and speed of the robot and the position and speed of the dynamic obstacle;

[0042] an estimated collision time calculation subunit, configured to obtain an estimated collision time between the robot and the dynamic obstacle based on the relative distance and the relative speed;

[0043] a distance risk item calculation subunit, configured to obtain a distance risk item between the robot and the dynamic obstacle based on the estimated collision time;

[0044] The obstacle avoidance evaluation function construction subunit is used to construct the obstacle avoidance evaluation function based on the distance risk item.

[0045] Compared with the prior art, the beneficial effects of the present invention are as follows: the present invention integrates the improved ant colony algorithm with the improved dynamic window method (DWA). In the ant colony algorithm, the path planning is guided by the potential field to more accurately cope with complex environments. In the heuristic function, the safety and reliability of the path are enhanced by the introduction of risk assessment and historical frequency, and past experience data is fully utilized to provide a reference for the current path planning. The optimization of the pheromone strategy adjusts the pheromone update strategy according to the path quality, which improves the search ability and guiding role of the algorithm. The adaptive adjustment mechanism can automatically adjust parameters and strategies according to environmental changes and algorithm operation conditions to ensure that the algorithm can adapt well to different scenarios. The triangle pruning method is used to further optimize the path and better improve the path quality. In the dynamic window method, an evaluation function that considers the risk of collision with dynamic obstacles is added to improve the accuracy of the algorithm in avoiding moving obstacles. By improving the ant colony fusion DWA, the respective advantages of the two algorithms are brought into play to achieve dynamic obstacle avoidance. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] In order to more clearly illustrate the technical solution of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0047] Figure 1 A grid map constructed for an embodiment of the present invention;

[0048] Figure 2 A schematic diagram of a motion model according to an embodiment of the present invention;

[0049] Figure 3 is a curve diagram of the change of the pheromone volatility coefficient ρ(k) after improvement in the embodiment of the present invention;

[0050] Figure 4 This is a flow chart of the pruning strategy according to an embodiment of the present invention;

[0051] Figure 5 This is a comparison diagram before and after the fusion algorithm of an embodiment of the present invention;

[0052] Figure 6 A flowchart of an improved algorithm according to an embodiment of the present invention;

[0053] Figure 7 This is a schematic diagram of the pruning strategy according to an embodiment of the present invention;

[0054] Figure 8 A search route map of the basic ant colony algorithm of the embodiment of the present invention;

[0055] Fig. 9 A search roadmap for improving the algorithm of the embodiment of the present invention;

[0056] Fig.10 The convergence diagrams of the algorithms in the embodiments of the present invention are shown in FIG. 1 ; wherein (a) is the convergence diagram of the basic ant colony algorithm; (b) is the convergence diagram of the elite ant colony algorithm; and (c) is the convergence diagram of the improved ant colony algorithm.

[0057] Fig.11 The dynamic path planning diagram of the embodiment of the present invention; wherein (a) is the global path planning diagram; (b) is the obstacle adding diagram; (c) is the global path planning diagram after the obstacle is added; (d) is the overall operation result diagram;

[0058] Fig.12 Graphs showing the change of robot parameters according to an embodiment of the present invention; wherein (a) is a graph showing the change of linear velocity and angular velocity; (b) is a graph showing the change of posture angle;

[0059] Fig.13 This is a robot dynamic path planning diagram with more and larger random obstacles added to the map according to an embodiment of the present invention; wherein (a) is a global path planning diagram; (b) is a more and larger random obstacle diagram; (c) is a global path planning diagram after adding more and larger random obstacles; (d) is a diagram of the overall operation result;

[0060] Fig.14 The robot parameter change curves of adding more and larger random obstacles to the embodiment of the present invention; wherein (a) is a linear velocity and angular velocity change curve; (b) is a posture angular velocity change curve. DETAILED DESCRIPTION

[0061] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0062] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0063] Embodiment 1

[0064] The robot path planning method based on the fusion of improved ant colony algorithm and DWA includes the following steps:

[0065] S1: Build a grid map for the robot to move. In the grid map, use the ant colony algorithm to generate the global path of the robot. The grid method is one of the most commonly used modeling methods in the field of path planning. It is widely used because of its simplicity, clarity, ease of planning and execution. Figure 1As shown in the figure. In a two-dimensional environment, the grid map is reasonably divided into regions with binary information of 0 and 1 to achieve optimal storage, resolution, and planning efficiency. In this binary information, 0 represents a free grid and 1 represents an obstacle grid. When there are no obstacles in the adjacent grids, the robot can move in 8 directions. In an M×M grid environment, the grid number i and the coordinate (x i ,y i ) is as follows:

[0066]

[0067] Where: a is the side length of the grid, where a=1, mod is the remainder operation, and ceil represents the rounding operation. The usual path planning algorithm searches for the optimal path between free grids to ensure that the robot can safely cross the grid map and reach the target location.

[0068] The traditional ant colony algorithm is as follows:

[0069] (1) Probabilistic selection: At time t, ant k is located at node i with probability q 1 (q 1∈ [0,1]) transfers to the node with the largest product of pheromone concentration and heuristic information. The state transfer formula of the ant is as follows:

[0070]

[0071] (2) Roulette selection: If the probability is greater than q 1 , then the next node is selected in a roulette manner. The ant calculates the probability of each neighbor node, and then the ant selects the next node based on these probabilities.

[0072]

[0073]

[0074] Where: a k is the neighborhood candidate movable grid set, α is the pheromone heuristic factor, β is the distance heuristic factor, d ij is the Euclidean distance from the candidate node i to the next node j.

[0075] (3) Pheromone update: At any time, after ant k moves from node i to node j according to the selection rule, the pheromone concentration on the path from node i to node j will be updated in real time. The formula for updating pheromone concentration is as follows:

[0076] τ ij (t+1)=(1-λ)τ ij (t)+λτ 0

[0077] Among them, λ is the pheromone volatility, which indicates the degree of pheromone attenuation over time, 0<λ<1. τ 0 is the initial pheromone concentration, which is used to ensure that ants can find the path.

[0078] The formula for global pheromone update is as follows:

[0079]

[0080] Among them, ρ is the global pheromone volatility, which indicates the degree of global pheromone attenuation over time, where 0<ρ<1. The calculation formula for the pheromone concentration increment is as follows:

[0081]

[0082] Among them, L k is the length of the global optimal path searched by ant k; p k is the set of all ant path points that reach the destination in this iteration.

[0083] A further implementation method is that the ant colony algorithm adopts an improved ant colony algorithm, and the method for generating a global path of the robot based on the improved ant colony algorithm includes:

[0084] S11: Introduce the potential field heuristic function to calculate the distance between the preset node and the target node in the grid map, and combine the potential field concept to evaluate the attractiveness of each node to obtain the heuristic information value;

[0085] S12: Based on the heuristic information value and the pheromone concentration, the probability of the ant selecting the next node is calculated to obtain the node selection rule.

[0086] Specifically, in the aforementioned traditional ant colony algorithm, the heuristic function usually uses the Euclidean distance formula to evaluate the attractiveness of the node, which greatly reduces the globality of the ant's search. In the present invention, an improved potential field heuristic function is introduced to evaluate the attractiveness of each point by calculating the distance between the point and the target point and combining the concept of potential field. The introduction of the improved potential field heuristic function enables ants to choose paths more intelligently during the search process and better utilize spatial information and environmental features. The specific calculation process of the improved potential field heuristic function is as follows:

[0087] Calculate the potential field force: Assume that the coordinates of node i are p i , the coordinates of the target node g are p g .

[0088] F r =δ·(d ij +d jg ) 2

[0089] Where, djg δ is the Euclidean distance between node j and target node g. It usually represents the potential field constant, which is used to control the relative importance of ants to pheromone concentration and heuristic information when selecting the next node. Its value will affect the search behavior of ants and the convergence of the algorithm. The larger the value of δ, the more ants tend to choose the path with higher pheromone concentration when selecting the next node; and the smaller the value of δ, the more ants tend to choose the path with stronger heuristic information when selecting the next node.

[0090]

[0091] Where: λ is the potential field heuristic coefficient. Generally, the target node has a higher heuristic value, which means that the ants are more inclined to choose the target node as the next step. The ants are more inclined to choose the target node as the next step, which enhances the goal orientation of the algorithm and improves the search efficiency. Risk(ij) represents the risk assessment value from node i to j, and H(ij) represents the historical visit frequency from node i to j.

[0092] The improved potential field heuristic function has many significant advantages. First, by introducing risk assessment, ants can effectively avoid high-risk areas when choosing a path, which comprehensively improves the safety of the path. Second, the addition of historical frequency makes full use of past experience data, so that ants tend to choose routes with better performance and stronger adaptability, greatly enhancing the reliability of the path. The heuristic function that integrates multiple factors provides ants with diversified decision-making basis, so that they no longer rely on a single factor to choose a path, and make smarter and more optimized decisions.

[0093] S13: Based on the node selection rule and Dijkstra algorithm, the shortest path from the current node to the next node of the ant is calculated, and the pheromone on the shortest path is set as the initial pheromone value;

[0094] S14: Based on the path length of the shortest path and the number of obstacles, the initial pheromone value is adjusted, and based on the adjusted initial pheromone value, the pheromone matrix of the ant colony is updated.

[0095] Specifically, in the ant colony algorithm, the initial value of the pheromone has an important impact on the performance and convergence speed of the algorithm. By differentially initializing the pheromone, running the Dijkstra algorithm to generate a relatively optimal path, and setting the pheromone on the path as the initial value, using the Dijkstra algorithm to calculate the shortest path length from the starting point to each vertex, the shortest path length array is obtained]D = [d 1 ,d 2 ,…,d n ], where d i Represents the shortest path length from the starting point to vertex i.

[0096] For the selected path, calculate each edge e ij pheromone concentration. Using a base value τ 0 represents the initial pheromone concentration, which is then adjusted according to the number of obstacles and path length factors.

[0097]

[0098] Where: τ ij 0 is the initial pheromone level of path i to j. τ 0 is the global initial pheromone level. ij is the number of obstacles on the path from i to j. ij is the length of the path from i to j. α and β are adjustment parameters used to balance the impact of the number of obstacles and path length, respectively.

[0099] Update the ant colony's pheromone matrix using the calculated initial pheromone value:

[0100] τ ij , = τ ij +Δτ ij

[0101] Among them, Δτ ij is the initial pheromone value calculated from the previous step. The purpose of the update is to guide the ant colony to make more use of known paths in the initial stage and improve the convergence speed of the algorithm.

[0102] In the ant colony algorithm, the initial value of pheromone plays an important role in the algorithm performance and convergence speed. By differentially initializing pheromones, the Dijkstra algorithm is first run to generate a relatively optimal path, and the pheromone on the path is set as the initial value. The Dijkstra algorithm is used to calculate the shortest path length from the starting point to each vertex to obtain the shortest path length array.

[0103] For the selected path, the initial pheromone concentration of each edge is calculated based on the number of obstacles on the path and the path length. Among them, the global initial pheromone level τ 0 As the base value, combined with the exponential term e -αoij and the power term (1 / L ij ) β To adjust the pheromone concentration. The adjustment parameters α and β balance the impact of the number of obstacles and path length on the pheromone concentration. If there are many obstacles on the path, the exponential term will reduce the pheromone concentration; the longer the path length, the power term will also reduce the pheromone concentration.

[0104] Finally, the calculated initial pheromone value is used to update the pheromone matrix of the ant colony. The purpose of this is to guide the ant colony to make more use of known relatively better paths in the initial stage, thereby improving the convergence speed of the algorithm and enabling the ant colony to find a better solution faster.

[0105] S15: Based on the updated pheromone matrix, a dynamic pheromone update mechanism is adopted and the pheromone volatility coefficient is introduced to adaptively adjust the intelligence, update the global pheromone and obtain the global path.

[0106] Specifically, regarding the dynamic pheromone update mechanism: the traditional ant colony algorithm global pheromone only leaves pheromone for the optimal path, which makes the algorithm extremely convergent, but it is easy to fall into the local optimum and cannot jump out. In the improved ant colony algorithm, the pheromone update method has been redesigned, and the pheromone difference mechanism is used to update pheromones for paths of different qualities, thereby achieving better results in both global search and local optimization, so as to achieve faster convergence of high-quality nodes.

[0107] In the improved part, the pheromone update amount is adjusted according to the number of ants on the optimal and worst paths. The improved pheromone update formula is:

[0108]

[0109]

[0110] C and Ψ are parameters and can be adjusted; Z im is the number of turning points, Q is a constant representing the intensity of pheromone deposition; M is the number of ants; L km represents the length of the path taken by ant m in the kth cycle; b is the number of ants that find the shortest path in the current cycle; L min represents the length of the shortest path in the current loop; w represents the number of ants that find the longest path in the current loop; L max Indicates the length of the longest path in the current loop.

[0111] Where: τ min is the minimum pheromone concentration, τ max is the maximum pheromone concentration. When updating pheromones, the diversity of pheromones is maintained by limiting the value range of pheromones, preventing pheromones from converging to the local optimal solution too early, thereby better avoiding falling into the local optimal solution.

[0112] This improvement to the pheromone update mechanism of the ant colony algorithm has significant advantages. On the one hand, by considering both the path length and the number of turning points at the same time, the path quality can be measured more accurately. Instead of relying solely on a single path length indicator, the algorithm combines the number of turning points to better guide ants to choose a short and relatively smooth path, avoid too many twists and turns, and improve the practical feasibility and efficiency of the path. On the other hand, this improvement can greatly improve the convergence speed of the algorithm. Since the evaluation of path quality is more accurate, ants can lock on better paths more quickly, reduce unnecessary searches in complex search spaces, and speed up the solution process. In addition, the weight coefficient can be adjusted to adapt to different problem requirements, which enhances the adaptability of the algorithm. Whether it is a problem with high requirements for path smoothness or a problem that focuses more on path length, the most suitable solution can be found by adjusting the weight coefficient.

[0113] About the adaptive adjustment mechanism:

[0114] Compared with the traditional ant colony algorithm in which ρ is a fixed constant, the improved pheromone volatility coefficient introduces an adaptive adjustment mechanism to change the pheromone volatility coefficient from a static value to a value that is dynamically adjusted according to the number of iterations. Figure 3 As shown, the improved pheromone volatility coefficient formula is:

[0115]

[0116] Among them: k is the current iteration number, K is the maximum iteration number, and the figure shows the change curve of ρ(k) after improvement. Strong dynamic adaptability: The improved pheromone volatility coefficient is no longer a fixed value, but is dynamically adjusted according to the number of iterations. In the early stage of the algorithm, the number of iterations k is small, at this time (1-k / K) λ The value of is larger, and the pheromone volatility coefficient is closer to ρ max This makes the pheromone volatilization speed relatively slow in the early stage, which is conducive to the ants to explore more paths, increase the diversity of the algorithm, and avoid falling into the local optimal solution too early. Improve the convergence speed: As the number of iterations increases, k gradually approaches K, (1-k / K) λ The value of gradually decreases, and the pheromone volatility coefficient is closer to ρ min At this time, the pheromone volatilization speed is accelerated, making ants more inclined to choose the path with high pheromone concentration, thereby accelerating the convergence speed of the algorithm. Flexible adjustment: By adjusting the parameters, the changing trend of the pheromone volatilization coefficient can be flexibly controlled according to different problems and needs, improving the adaptability and performance of the algorithm.

[0117] By adaptively adjusting the pheromone volatility coefficient, the coefficient is small in the early stage of the iteration and gradually increases, which encourages ants to explore more. In the later stage of the iteration, as the number of iterations increases, the pheromone content on the path gradually increases, which enhances the guiding effect of the pheromone concentration on the ants and reduces the search time of the ants. The pheromone volatility coefficient can be kept within a certain range while ensuring the dynamic change of the pheromone volatility coefficient. The pheromone volatility coefficient ρ is flexibly adjusted at different stages of the algorithm, which better balances the global search and local search.

[0118] The adaptive pheromone volatility coefficient is dynamically adjusted. In the early stage of the search, a larger value is used to encourage ants to explore the solution space extensively and avoid premature convergence to the local optimum. As the iteration proceeds, the value gradually decreases to enhance the high-quality solution. It can adapt to the characteristics of different problems, avoid premature convergence of the algorithm, balance the exploration and development capabilities to improve the quality of the solution, and reduce the algorithm calculation time, thereby improving the search efficiency and the overall performance of the algorithm.

[0119] S16: Use pruning strategy on the global path to obtain the global optimal path. Specifically, the ant colony algorithm is an eight-degree-of-freedom search probability algorithm derived from the foraging behavior of ants. The ant colony algorithm has a simple step size selection, which limits the efficiency of mobile robot path planning. In order to solve this problem, the pruning strategy is used to eliminate redundant turning points and improve the diversity of the algorithm step size.

[0120] Specifically, when considering the connection between the starting point and the target point, first check whether the straight line path between the two points intersects with obstacles. If it intersects, it means that this path is not feasible. At this time, the system will intelligently judge the previous point in turn and continue to find suitable points that are connected and do not intersect with obstacles for connection. The specific process is as follows Figure 4 shown.

[0121] It is detected that A and G can be directly connected, but the straight line path connecting the two points intersects with an obstacle, indicating that the path is not feasible, and the previous point needs to be re-judged, and the adjacent points connected are selected in this way.

[0122] Use the cross product formula to determine the path segment (X 1 ,Y 1 ) to (X 2 ,Y 2 ) intersects with the obstacle boundary.

[0123] cross=(X 2 -X 1 )·(Y max -Y 1 )-(Y 2 -Y 1 )·(X max -X 1 )

[0124] Among them, (Xmax, Ymax) is the maximum coordinate point of the obstacle boundary. If the cross product cross is a positive value, it means that the path segment intersects with the obstacle boundary and this path needs to be avoided. If the cross product cross is zero or negative, it means that the path does not intersect with the obstacle and the path is feasible.

[0125] like Figure 7 As shown in the figure: First, determine whether the starting point A and the target point G can be connected, then determine the previous point F, and so on, until a point that can be connected and the connecting line does not intersect with obstacles is found, and then connect. The original path is ABCDEFG, and after optimization it is AEG (dashed line), which reduces the number of turning points and the path length.

[0126] S2: Pass the global path to the DWA dynamic window model to generate a dynamic window. The dynamic window method (DWA) refers to sampling multiple groups of speeds in the speed search space based on the robot's motion model. Within a period of time, the robot trajectory of each group of speeds is analyzed and predicted, and the mobile robot is driven to perform local motion planning according to the speed corresponding to the optimal trajectory.

[0127] The traditional DWA algorithm is as follows:

[0128] (1) Robot motion model:

[0129] DWA can sample the linear velocity v(t) and angular velocity ω(t) of the mobile robot within the window and establish the kinematic model of the two-wheel differential mobile robot, such as Figure 2 As shown. Assuming that the robot trajectory can be decomposed into multiple time slices, and in each time slice Δt, the robot performs uniform linear motion, then the robot's kinematic model can be expressed as follows:

[0130]

[0131] Among them, x(t), y(t) and θ(t) represent the position and angle of the robot in the x and y directions at time t, respectively; the range of variation of the linear velocity v(t) depends on the closest distance to the obstacle and the maximum linear deceleration; the content of the variation of the angular velocity ω(t) is determined by the closest distance to the obstacle and the maximum angular deceleration.

[0132] (2) Robot speed sampling:

[0133] In velocity space, DWA describes the robot's obstacle avoidance problem as a constrained optimization problem, including the incomplete motion constraints of the differential robot, the dynamic constraints of the robot structure, and the environmental constraints.

[0134] (1) The maximum and minimum constraints of the robot are as follows:

[0135] v s ={(v,w)|v∈[v min ,v max ],w∈[w min ,w max ]}

[0136] (2) The motor acceleration and deceleration constraints are as follows:

[0137]

[0138] Among them, v c and w c are the linear velocity and angular velocity of the robot at the current moment; a v min and a w min are the minimum linear deceleration and the minimum angular deceleration respectively; a v max and a w max are the maximum linear acceleration and maximum angular acceleration respectively; Δt is the sampling time.

[0139] (3) The braking distance constraints are as follows:

[0140]

[0141] Where dist(v, w) is the distance between the simulated trajectory and the nearest obstacle. According to the expression 0-v a 2 = -2dist(v, w)a v min and 0-w a 2 = -2dist(v, w)a w min , the simulation speed must satisfy the conditions of the equation to ensure the safety of the robot movement to a greater extent.

[0142] (3) Evaluation function:

[0143] The dynamic window method evaluates the predicted trajectory through an evaluation function and outputs the optimal speed that satisfies the constraints. The traditional evaluation function is expressed as follows:

[0144] G(ν,w)=σ[δ·heading(ν,ω)+η·vel(ν,ω)+γ·dist(ν,ω)]

[0145] θ is the angle between the robot's motion direction and the target node, vel(v, w) is the speed evaluation function, which generally refers to the robot's linear speed, and dist(v, w) is the obstacle distance evaluation function, which indicates the shortest distance from the end of the predicted trajectory to the obstacle.

[0146] δ, η, and γ are weight coefficients of each evaluation function; σ is an evaluation function indicating that the evaluation function is normalized.

[0147] Traditional DWA has the following problems:

[0148] (1) Lack of global path guidance: Traditional DWA lacks global path guidance when planning the robot path and is prone to fall into local optimal solutions.

[0149] (2) Low environmental adaptability: Traditional robot navigation methods rely on the turning points of the global path. However, when there are many unknown static obstacles, the robot's tracking accuracy will decrease.

[0150] (3) Ineffectiveness against highly mobile obstacles: Traditional DWA shows good robustness and obstacle avoidance in static environments, but may become ineffective when highly mobile obstacles appear in the moving space.

[0151] In response to the above problems, the following improvement strategies are proposed to enable the mobile robot to achieve efficient and safe movement in complex static and dynamic environments.

[0152] S3: Add unknown static and dynamic obstacles to the grid map, and use the local target point setting method to set the local target point based on the global path; in order to address the defect that the traditional DWA planning path lacks the guidance of global planning, the global path information planned by the improved ant colony algorithm is combined with the robot motion to ensure that the local action basically follows the global path. Figure 5As shown in the figure: It can be seen from the figure that the robot under the fusion algorithm has better safety and smoothness, and can finally reach the target point smoothly. A further implementation method is that the method of setting the local target point using the local target point setting method includes: when the robot is in the path planning state, the global optimal path is checked to determine whether the robot will pass through an obstacle during the movement process. If it passes, the local target point is set on the global optimal path of the grid closest to the obstacle. Specifically, there are certain limitations in the traditional DWA local path planning process. Usually, the robot tends to focus only on the turning point on the global path and use it as the local target point. However, in a complex environment where obstacles are extremely densely distributed and filled with a large number of unknown factors, this method of simply relying on turning points as local navigation points is stretched. Because this method cannot make full use of the rich information contained in the global path, when the robot tries to cross the area near the obstacle, it is very easy to deviate from the predetermined route, and then lose the correct direction of advance, and finally cause the robot to fail to reach the target location smoothly.

[0153] In order to effectively deal with this problem, a local target point insertion method is introduced. Specifically, when the robot is in the path planning state, it is necessary to first check the global path to determine whether it will pass through obstacles. If it passes, the local target point is carefully set on the global path of the grid closest to the obstacle. In this way, these additional local target points are like lighthouses, guiding the robot to smoothly cross the obstacle-dense area while approaching the global path. This method has a significant effect on improving the path planning effect of the robot in complex environments. It can effectively prevent the robot from deviating from the correct direction due to interference from the complex environment, thereby ensuring the robot's navigation accuracy and the success rate of task execution, and further enhancing the adaptability and stability of the entire path planning system in complex scenarios.

[0154] S4: Based on the local target point and the robot movement information, the robot speed is sampled in the dynamic window to obtain the simulated trajectory of the robot movement;

[0155] S5: Use the obstacle avoidance evaluation function to evaluate the simulated trajectory. If the robot reaches the target point, the optimal path is obtained. If the robot does not reach the target point, the simulated trajectory is regenerated and iterative calculation is performed until the robot reaches the target point, completing the robot's path planning.

[0156] In particular, in local path planning, the presence of dynamic obstacles brings great uncertainty to the robot's motion. The traditional DWA evaluation function usually only considers static obstacles and ignores the motion characteristics of dynamic obstacles. However, the speed, direction and position changes of dynamic obstacles may cause the robot to collide with the obstacles, thereby affecting the safety and effectiveness of path planning. The present invention adds an evaluation function that considers dynamic obstacles.

[0157] A further implementation method is that the obstacle avoidance evaluation function is an evaluation function that takes dynamic obstacles into consideration, and the construction method includes:

[0158] Based on the position and speed of the robot and the position and speed of the dynamic obstacle, the relative distance and relative speed between the robot and each dynamic obstacle are calculated; specifically, the relative position and relative speed between the robot and each dynamic obstacle need to be determined first. Assume that the position of the robot is (x r ,y r ), the speed is (v r ,θ r ), where v r is the linear velocity, θ r is the direction angle. The position of the dynamic obstacle is (x 0 ,y 0 ), the speed is (v 0 ,θ 0 ).

[0159] Then, the relative distance d between the robot and the dynamic obstacle is calculated rel and relative velocity v rel .

[0160]

[0161]

[0162] Based on the relative distance and relative speed, the estimated collision time between the robot and the dynamic obstacle is obtained;

[0163] Based on the expected collision time, the distance risk term between the robot and the dynamic obstacle is obtained; specifically, the expected collision time T is calculated based on the relative distance and relative speed. collision (When the relative velocity is not zero.) If the relative velocity is zero or close to zero, a larger estimated time to collision can be set to avoid division by zero.

[0164]

[0165]

[0166] The distance risk term D dynamicWhen the evaluation function is added, the shorter the expected collision time is, the larger the value of the distance risk item is, which means that the robot is closer to the dynamic obstacle and needs to avoid it as soon as possible.

[0167] Based on the distance risk term, an obstacle avoidance evaluation function is constructed. Specifically, the traditional DWA evaluation function is improved by adding the factor of dynamic obstacles. By calculating the relative distance, relative speed and expected collision time between the robot and the dynamic obstacle, the distance risk term is obtained and added to the evaluation function. This improvement improves the safety of the robot in a dynamic environment, enhances its adaptability to the dynamic environment, optimizes the effectiveness of path planning, and ensures the real-time and reliability of path planning.

[0168] Finally, the evaluation function of the improved robot obstacle avoidance is:

[0169] G(ν,w)=σ[δ·heading(ν,ω)+η·vel(ν,ω)+γ·dist'(ν,ω)+λ·D dynamic ]

[0170] Where: λ is the distance risk term of the evaluation function D dynamic The weight of .

[0171] In summary, the present invention aims at the problems existing in traditional ACO and DWA in large-scale complex environments, comprehensively considers the advantages and disadvantages of these two algorithms, fuses the improved ACO and the improved DWA, uses IACO to obtain the global navigation path of the robot, and uses IDWA to build the kinematic model of the robot for dynamic path planning. The fusion of the improved ant colony algorithm and the improved DWA can be carried out in the following steps. First, the ant colony algorithm and DWA are improved and the environmental model is determined respectively. Then, the global path is generated by the ant colony algorithm and the information is passed to DWA for initialization. Then it enters the hierarchical planning stage. The ant colony algorithm in the global planning layer continuously optimizes the global path through ant search and pheromone update. The improved DWA in the local planning layer generates a dynamic window, calculates the evaluation function and selects the optimal speed. In the dynamic adjustment and feedback link, when DWA finds a better path or encounters an obstacle, it feeds back to the ant colony algorithm to adjust the pheromone distribution and the global path. The ant colony algorithm can also optimize the global path and adjust the heuristic function according to the DWA feedback. Finally, the iterative process is repeated continuously, and the robot acts according to the local path planned by DWA to continuously optimize the path planning. The process of the fusion algorithm is as follows Figure 6 shown.

[0172] Embodiment 2

[0173] The present invention also provides a robot path planning system based on the fusion of improved ant colony algorithm and DWA, which is used to implement the method, including:

[0174] The global path generation module is used to establish a grid map for the robot's movement. In the grid map, the ant colony algorithm is used to generate the robot's global path;

[0175] A dynamic window generation module is used to pass the global path to the DWA dynamic window model to generate a dynamic window;

[0176] The local target point setting module is used to add unknown static and dynamic obstacles to the grid map and set the local target point based on the global path using the local target point setting method;

[0177] The simulation trajectory calculation module is used to sample the robot speed in the dynamic window based on the local target point and the robot movement information to obtain the simulation trajectory of the robot movement;

[0178] The optimal path acquisition module is used to evaluate the simulated trajectory using the obstacle avoidance evaluation function. If the robot reaches the target point, the optimal path is obtained; if the robot does not reach the target point, the simulated trajectory is regenerated and iterative calculation is performed until the robot reaches the target point, completing the robot's path planning.

[0179] A further implementation is that the global path generation module includes:

[0180] A heuristic information value calculation unit is used to introduce a potential field heuristic function, calculate the distance between a preset node and a target node in a grid map, and evaluate the attractiveness of each node in combination with the potential field concept to obtain a heuristic information value;

[0181] A node selection unit is used to calculate the probability of the ant selecting the next node based on the heuristic information value and the pheromone concentration, and obtain the node selection rule;

[0182] The pheromone initialization unit is used to calculate the shortest path from the current node to the next node of the ant based on the node selection rule and the Dijkstra algorithm, and set the pheromone on the shortest path as the initial pheromone value;

[0183] A pheromone matrix updating unit, used for adjusting the initial pheromone value based on the path length of the shortest path and the number of obstacles, and updating the pheromone matrix of the ant colony based on the adjusted initial pheromone value;

[0184] A global pheromone updating unit is used to update the global pheromone based on the updated pheromone matrix, adopt a dynamic pheromone updating mechanism and introduce an adaptive adjustment of the pheromone volatility coefficient to obtain a global path;

[0185] The pruning unit is used to apply the pruning strategy to the global path to obtain the global optimal path.

[0186] A further implementation method is that in the local target point setting module, a method for setting a local target point using a local target point setting method includes: when the robot is in a path planning state, checking the global optimal path to determine whether the robot will pass through an obstacle during movement, and if so, setting the local target point on the global optimal path of the grid closest to the obstacle.

[0187] A further implementation method is that the optimal path acquisition module includes an evaluation function construction unit for constructing an evaluation function that takes dynamic obstacles into consideration; the evaluation function construction unit includes:

[0188] A relative distance and relative speed calculation subunit, used to calculate the relative distance and relative speed between the robot and each dynamic obstacle based on the position and speed of the robot and the position and speed of the dynamic obstacle;

[0189] An estimated collision time calculation subunit, used for obtaining an estimated collision time between the robot and the dynamic obstacle based on a relative distance and a relative speed;

[0190] A distance risk item calculation subunit, used for obtaining a distance risk item between the robot and the dynamic obstacle based on an estimated collision time;

[0191] The obstacle avoidance evaluation function construction subunit is used to construct an obstacle avoidance evaluation function based on the distance risk item.

[0192] Embodiment 3

[0193] This embodiment provides a simulation experiment of a robot path planning method and system based on the fusion of an improved ant colony algorithm and DWA. Simulation experiment environment: Run in the windows1064bits environment, the simulation platform is Matlab 2021b, the computer processor is Intel(R) Core(TM) i5-7400 CPU, the main frequency is 3.00GHz, and the memory is 8GB.

[0194] 1. IACO simulation comparative analysis

[0195] After determining the parameter values, a simulation experiment is performed for comparison. The settings of other relevant parameters in the experiment are shown in Table 1.

[0196] Table 1

[0197]

[0198] In order to verify the effectiveness and superiority of the improved ant colony algorithm in path planning in a grid map environment, the basic ant colony algorithm, the elite ant colony algorithm and the improved ant colony algorithm were used to carry out simulation comparison in a 20×20 grid environment.

[0199] Figure 7This is the pruning strategy graph. The improved and optimized path length is reduced, the number of turning points is reduced, and it is more suitable for the robot's movement. For paths with more complex environments and more turning points, the effect of pruning strategy optimization is more obvious.

[0200] like Figure 8 As shown in the figure, the traditional ant colony algorithm has a large search range and consumes a lot of time. Fig. 9 As shown in the figure: Ant search is guided, which enables ants to approach the target faster, reduces invalid movements during the search process, and improves the search efficiency of the ant colony algorithm.

[0201] like Fig.10 The following are the convergence diagrams of the three algorithms. The convergence speed of the improved algorithm is significantly higher than that of the other two algorithms. Among them, (a) is the convergence diagram of the basic ant colony algorithm; (b) is the convergence diagram of the elite ant colony algorithm; (c) is the convergence diagram of the improved ant colony algorithm.

[0202] As shown in Table 3, when compared with the other two algorithms, the improved algorithm has advantages in many aspects. First, compared with other algorithms, the improved ant colony algorithm has achieved a significant reduction in the optimal path length, reaching 30.3848, which is about 10.1% lower than the basic ant colony algorithm, and the path length is further shortened after removing redundant turning points.

[0203] Secondly, guided by the artificial potential field, ants can focus on the optimal path more quickly during the search process, reducing unnecessary search blindness. The average number of iterations was reduced from 92 in the basic ant colony algorithm to 18, and the average convergence time was only 6.25, which was an improvement of about 18.65% compared with the basic ant colony algorithm.

[0204] In addition, compared with the 19 turning points of the basic ant colony algorithm, the improved algorithm has only 13 turning points, and the algorithm after further pruning optimization has only 9 turning points, which is a reduction of about 31.6% to 52.6%. Table 2 is a comparison of simulation experiment data.

[0205] Table 2

[0206]

[0207] 2. IACO-IDWA simulation experiment analysis

[0208] In order to verify the performance of the improved ACO fused with the improved DWA, a complex unknown environment is established to verify the feasibility of obstacle avoidance of the proposed algorithm in a complex environment. The standard parameters of DWA are shown in Table 3:

[0209] Table 3

[0210]

[0211] like Fig.11 As shown in Figure 2, a static environment for the robot is established in a 30×30 grid environment, and the optimal global path is planned based on IACO, as shown in Figure 2. Fig.11 (a) is shown in the figure. (b) is the obstacle map; (c) is the global path planning map after adding obstacles; (d) is the overall operation result map. In this environment, an unknown static obstacle and an unknown dynamic obstacle are set. The robot moves along the global path, judges the surrounding environment in real time, and avoids obstacles according to the situation of the obstacles.

[0212] like Fig.12 As shown in the figure, (a) is the curve of linear velocity and angular velocity change; (b) is the curve of attitude angle change. Through the distance risk term, the position of dynamic obstacles is predicted in advance, thereby achieving dynamic obstacle avoidance. Due to the local target point insertion method adopted in this paper, when the robot passes near an obstacle, a new navigation point is inserted, which avoids the robot from deviating from the global path when passing through an obstacle and can better track the global path.

[0213] like Fig.13 As shown, (a) is the global path planning map; (b) is the map of more and larger random obstacles; (c) is the global path planning map after adding more and larger random obstacles; (d) is the overall operation result map. In the experiment, when more and larger new random obstacles (multiple moving obstacles) are added to the map, they are passed in the direction of the robot's movement, where: the moving obstacle starts moving at a speed of 0.16m / s. During the robot's movement, the robot detects the moving obstacle moving towards itself at a speed of 0.16m / s through the sensor in the early stage and executes the obstacle avoidance strategy. And in the later process, unknown static obstacles are discovered and obstacle avoidance is executed.

[0214] The changes of the robot's linear velocity, angular velocity and posture angle in the simulation experiment are recorded in Fig.14 In the figure, (a) is the curve of linear velocity and angular velocity change; (b) is the curve of posture angular velocity change. It can be seen that after improving the evaluation function, the robot's movement is generally stable, and it can maintain a uniform speed throughout the movement process, and the change of angular velocity is relatively stable.

[0215] In the simulation experiment, the robot performed real-time path planning along the global path, and the path was basically the same as the original path. The tracking ability of IDWA was verified again. The robot passed safely along this path without colliding with any obstacles and arrived at the target point safely.

[0216] In a 30×30 grid environment, based on the global path planned by IACO, unknown static and dynamic obstacles are set, and the robot can judge and avoid obstacles in real time. Dynamic obstacle avoidance is achieved through the distance risk item, and the local target point insertion method prevents the robot from deviating from the global path. When adding more moving obstacles, the robot can still execute the obstacle avoidance strategy, the overall movement is stable, the linear velocity, angular velocity and attitude angle change relatively smoothly, and the path is basically the same as the original path, which verifies the tracking ability of IDWA.

[0217] 3. Analysis of path planning simulation experiment based on ROS

[0218] The effectiveness of the fused algorithm was verified by building an environment in ROS for simulation experiments and an actual path planning experiment on an actual robot operating platform. In order to verify the effectiveness of the fused improved ant colony and DWA algorithm proposed in the paper, the paper used Gazebo simulation software to simulate the real environment before conducting experimental verification. The simulation environment was built using a custom modeling tool in Gazebo, and the simulation experiment results were obtained using the visualization tool Rviz.

[0219] Construction of map simulation environment:

[0220] The navigation function of mobile robots mainly includes robot positioning and path planning. Robot positioning and path planning are implemented by amcl function package and move_bace function package in ROS. In ROS, move_bace function package can realize global path planning and local path planning. To realize the improved fusion algorithm proposed in the paper, it is necessary to write global path planning plug-in and local path planning plug-in. Based on the lobal planner global path planning and local planner local path planning in the move_bace function package, the BetterAstar global path planning and BetterDWA local path planning plug-ins are modified. Register the modified plug-in, modify the relevant parameter files, and add the plug-in to the ROS package system. When using, replace the global path planning algorithm with the BetterSCSO global path planner in the 3D visualization tool Rviz, and replace the local path planning algorithm with the BetterDWA local path planner. The robot implements the path planning of the two improved algorithms through two modified and registered plug-ins. After completing the configuration of the global path and local path plug-ins, first, use the Gmapping algorithm to obtain the grid map of the simulation environment, use map_server to save the map and provide it to the robot. Secondly, the robot uses the amcl function package to realize its own positioning. Then, the robot uses the global path plug-in to calculate a global optimal path. Finally, the robot uses the local path plug-in to plan the path in sequence according to the path points published by the global path, and sends the speed command calculated by the local path planner to the robot chassis controller to drive the robot from the starting point to the target point.

[0221] Rviz visualization platform:

[0222] The construction of the environmental map is the basis of path planning. After completing the creation of the mobile robot model and the environmental model, the static map required for global path planning can be built through the SLAM algorithm. First, load the simulation environment and mobile robot model in Gazebo, load the mobile robot model in Rviz, open the SLAM algorithm function package, control the movement of the simulated mobile robot through keyboard codes, and transmit the environmental information scanned by the radar to Rviz for display. When the radar has scanned the entire environment, save the map for subsequent path planning experiments.

[0223] Gazebo environmental simulation platform:

[0224] Gazebo is a 3D environment simulation software provided by ROS. It can build experimental environments for mobile robots and simulate parameters such as gravity and friction. It also provides common sensor model libraries for robots, including camera, depth camera, laser, imu, etc. Users can create data by themselves and build a real-world 3D environment on the platform. Gazebo provides high-fidelity physical simulation and is very user-friendly and program-friendly. The Gazebo large simulation environment is shown in the figure.

[0225] After completing the preparations for map construction, determine the target point to be reached through 2D Nav Goal. The planned path will be displayed in Rviz. Select different end points for multiple control experiments to ensure the accuracy of the experiment.

[0226] First, start the mobile robot, open the RVIZ visualization software, and call the SLAM mapping algorithm on the terminal. Here, the Gmapping algorithm is used, and the program for building the model starts running. Use the keyboard control node to remotely operate the robot. At this time, the laser radar sensor continuously scans the surroundings, collects the surrounding environment information, and transmits it to the lower computer in the form of point cloud for data processing. The first-person perspective is shown in the figure

[0227] Based on the environment constructed above, the improved fusion algorithm is used to perform the global path planning task of the mobile robot. The moving car model is blue, the black area is the obstacle area, and the green line is the moving route planned by the moving car.

[0228] The simulation results show that the robot successfully calculated the global path, and the planned local path followed the global path well, and finally reached the target point smoothly. The path planned by the fusion algorithm is relatively smooth, and it effectively avoids obstacles and maintains a certain distance from obstacles. In order to verify the accuracy and effectiveness of the experiment, the experiment will be conducted again in the field, and the original algorithm and the improved fusion algorithm will be compared.

[0229] Considering the advantages and disadvantages of the ant colony algorithm and the dynamic window method, the two are improved and integrated. The improved ant colony algorithm solves the problems of early search blindness, slow convergence speed and local optimal solution, and optimizes the path twice through the pruning strategy. The improved dynamic window method improves the navigation and dynamic obstacle avoidance capabilities. The experimental environment is built in the ROS environment, and the path planning and autonomous navigation of the mobile robot are realized through a series of operations, including building a map simulation environment, using the visualization tool Rviz to obtain results, and using the improved fusion algorithm for path planning tasks. The experimental results show that the robot can successfully complete the path planning, verifying the effectiveness and superiority of the fusion algorithm in different environments, enabling it to navigate efficiently and safely in a global static environment, and better avoid obstacles dynamically in a complex dynamic environment.

[0230] The embodiments described above are only descriptions of the preferred embodiments of the present invention and are not intended to limit the scope of the present invention. Without departing from the design spirit of the present invention, various modifications and improvements made to the technical solutions of the present invention by ordinary technicians in this field should all fall within the protection scope determined by the claims of the present invention.

Claims

1. A robot path planning method based on the fusion of improved ant colony algorithm and DWA, characterized in that: The following steps are involved: Establishing a grid map for robot movement, in which an ant colony algorithm is used to generate a global path of the robot; Passing the global path to the DWA dynamic window model to generate a dynamic window; Add unknown static and dynamic obstacles to the grid map, and set local target points based on the global path using a local target point setting method; Based on the local target point and the robot movement information, sampling the robot speed in the dynamic window to obtain a simulated trajectory of the robot movement; The simulated trajectory is evaluated using an obstacle avoidance evaluation function. If the robot reaches the target point, the optimal path is obtained; if the robot does not reach the target point, the simulated trajectory is regenerated and iteratively calculated until the robot reaches the target point, completing the robot's path planning.

2. The method according to claim 1, characterized in that The ant colony algorithm adopts an improved ant colony algorithm. The method for generating a global path of a robot based on the improved ant colony algorithm includes: The potential field heuristic function is introduced to calculate the distance between the preset node and the target node in the grid map, and the potential field concept is combined to evaluate the attractiveness of each node to obtain the heuristic information value; Based on the heuristic information value and the pheromone concentration, the probability of the ant selecting the next node is calculated to obtain a node selection rule; Based on the node selection rule and Dijkstra algorithm, the shortest path from the current node to the next node of the ant is calculated, and the pheromone on the shortest path is set as the initial pheromone value; Adjusting the initial pheromone value based on the path length of the shortest path and the number of obstacles, and updating the pheromone matrix of the ant colony based on the adjusted initial pheromone value; Based on the updated pheromone matrix, a dynamic pheromone update mechanism is adopted and the pheromone volatility coefficient is introduced to adjust the wit of the adaptive pheromone to update the global pheromone and obtain the global path; A pruning strategy is used on the global path to obtain a global optimal path.

3. The method according to claim 1, characterized in that The method of setting a local target point using the local target point setting method includes: when the robot is in a path planning state, checking the global optimal path to determine whether the robot will pass through an obstacle during movement. If so, setting the local target point on the global optimal path that is closest to the obstacle.

4. The method according to claim 1, characterized in that: The obstacle avoidance evaluation function is an evaluation function that takes dynamic obstacles into consideration, and the construction method includes: Based on the position and speed of the robot and the position and speed of the dynamic obstacle, calculate the relative distance and relative speed between the robot and each dynamic obstacle; Based on the relative distance and the relative speed, obtaining an estimated collision time between the robot and the dynamic obstacle; Based on the estimated collision time, obtaining a distance risk item between the robot and the dynamic obstacle; Based on the distance risk term, the obstacle avoidance evaluation function is constructed.

5. A robot path planning system based on the fusion of improved ant colony algorithm and DWA, used to implement the method described in any one of claims 1 to 4, characterized in that: include: A global path generation module is used to establish a grid map for robot movement, in which an ant colony algorithm is used to generate a global path for the robot; A dynamic window generation module, used for passing the global path to a DWA dynamic window model to generate a dynamic window; A local target point setting module, used for adding unknown static and dynamic obstacles to the grid map, and setting local target points based on the global path using a local target point setting method; A simulation trajectory calculation module, used for sampling the robot speed in the dynamic window based on the local target point and the robot movement information, to obtain a simulation trajectory of the robot movement; The optimal path acquisition module is used to evaluate the simulated trajectory using the obstacle avoidance evaluation function. If the robot reaches the target point, the optimal path is obtained; if the robot does not reach the target point, the simulated trajectory is regenerated and iterative calculation is performed until the robot reaches the target point, completing the robot's path planning.

6. The system according to claim 5, characterized in that The global path generation module includes: A heuristic information value calculation unit is used to introduce a potential field heuristic function, calculate the distance between a preset node and a target node in a grid map, and evaluate the attractiveness of each node in combination with the potential field concept to obtain a heuristic information value; A node selection unit, used to calculate the probability of the ant selecting the next node based on the heuristic information value and the pheromone concentration, and obtain a node selection rule; A pheromone initialization unit, used to calculate the shortest path from the current node to the next node of the ant based on the node selection rule and the Dijkstra algorithm, and set the pheromone on the shortest path as the initial pheromone value; A pheromone matrix updating unit, configured to adjust the initial pheromone value based on the path length of the shortest path and the number of obstacles, and update the pheromone matrix of the ant colony based on the adjusted initial pheromone value; A global pheromone updating unit is used to update the global pheromone based on the updated pheromone matrix, adopt a dynamic pheromone updating mechanism and introduce an adaptive adjustment of the pheromone volatility coefficient to obtain a global path; The pruning unit is used to apply a pruning strategy to the global path to obtain a global optimal path.

7. The system according to claim 5, characterized in that In the local target point setting module, the method of setting the local target point using the local target point setting method includes: when the robot is in a path planning state, checking the global optimal path to determine whether the robot will pass through an obstacle during movement. If so, setting the local target point on the global optimal path of the grid closest to the obstacle.

8. The system according to claim 5, characterized in that The optimal path acquisition module includes an evaluation function construction unit, which is used to construct an evaluation function that takes dynamic obstacles into consideration; The evaluation function construction unit comprises: A relative distance and relative speed calculation subunit, used to calculate the relative distance and relative speed between the robot and each dynamic obstacle based on the position and speed of the robot and the position and speed of the dynamic obstacle; an estimated collision time calculation subunit, used to obtain an estimated collision time between the robot and the dynamic obstacle based on the relative distance and the relative speed; a distance risk item calculation subunit, configured to obtain a distance risk item between the robot and the dynamic obstacle based on the estimated collision time; The obstacle avoidance evaluation function construction subunit is used to construct the obstacle avoidance evaluation function based on the distance risk item.

Citation Information

Cited By

  • Intelligent light truck path planning method

    CN120368999A

  • Robot motion control method and device, robot, medium and product

    CN120523087A

  • Track planning and tracking method suitable for small underwater robot

    CN120593762A

  • A trajectory planning and tracking method suitable for small underwater robots

    CN120593762B

  • Mechanical arm thoracocentesis path planning system and method based on dynamic adaptive ant colony optimization algorithm

    CN120635117A