Mobile robot path planning method and device
Through adaptive neighborhood search and improved DWA algorithm to optimize path planning, the problem of low efficiency and insufficient scientificity of path planning in complex scenarios is solved, and efficient and safe path navigation is achieved.
Patent Information
- Application Number
- CN202510845636.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-23
- Publication Date
- 2025-08-19
- Estimated Expiration
- 2045-06-23
AI Technical Summary
The existing mobile robot path planning algorithms are difficult to adaptively select search parameters in complex scenarios, resulting in low efficiency and insufficient scientificity of path planning, and often have problems of crossing obstacles or detours too far.
Adaptive neighborhood search method is adopted to dynamically adjust the search range according to the location of the obstacle, and optimize local path planning with the improved DWA algorithm. The global and local paths are optimized by adjusting the azimuth difference, priming-repulsive force and velocity evaluation functions.
It improves the efficiency and scientific nature of path planning, ensures that mobile robots can reach their goals efficiently and safely in complex environments, and enhances autonomous navigation performance.
Smart Images

Figure CN120353232B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of mobile robot path planning, and in particular to a mobile robot path planning method and device. Background Art
[0002] Mobile robots are widely used in logistics, services, industry and other fields, and path planning is crucial for the movement of mobile robots. The current conventional path planning method is to use the A* algorithm and the DWA algorithm for combined path planning. However, in terms of global path planning, the traditional A* algorithm path planning algorithm has fixed neighborhood search parameters, which are usually set based on experience. It is difficult to adaptively select in complex scenarios. Manual settings usually cause the neighborhood search value to be too large or too small in the scene, resulting in low path planning efficiency. The paths planned by the DWA algorithm are not scientific enough, and often pass through faults or travel to longer paths to bypass faults. As a result, the mobile robot's movement trajectory is not scientific enough and the planning time is too long, which seriously limits the application and performance improvement of mobile robots. New path planning methods and devices are urgently needed to solve these problems. Summary of the Invention
[0003] In view of this, the present application provides a mobile robot path planning method and device for accurately considering the position of obstacles and more scientifically planning the moving path of the mobile robot.
[0004] Specifically, this application is implemented through the following technical solutions:
[0005] A first aspect of the present application provides a mobile robot path planning method, the method comprising:
[0006] Constructing a map model, determining the starting and ending points, using the starting point as the initial center point, and determining a search range for the initial center point based on the locations of obstacles in the map model, wherein the search range radius corresponding to the initial center point varies in different calculation cycles;
[0007] Traversing all child nodes within the search range, removing child nodes that overlap with those in the previous calculation cycle from all child nodes in the current calculation cycle as the remaining child nodes, calculating the evaluation function value of each child node in the remaining child nodes, and determining the child node with the smallest evaluation function value as the optimal child node;
[0008] Determining the optimal child node as a new initial center point, and returning to the step of determining a search range for the initial center point based on obstacles in the map model until the initial center point coincides with an end point in the global path;
[0009] sequentially connecting the starting point, each optimal sub-node, and the end point to obtain a global path, and the mobile robot walks along the global path;
[0010] The real-time position of the mobile robot is obtained, the inflection point on the global path that is closest to the real-time position is determined as a temporary end point, the position information of all obstacles between the real-time position and the temporary end point is determined, the constraints and evaluation function in the DWA algorithm are adjusted according to the position information of all obstacles and the position of the temporary end point, and a local path between the real-time position and the temporary end point is planned using the improved DWA algorithm. The mobile robot travels along the local path until the mobile robot reaches the end point.
[0011] A second aspect of the present application provides a mobile robot path planning device, the device comprising a determination module, a calculation module and a planning module; wherein,
[0012] The determination module is used to construct a map model, determine the starting point and the end point, use the starting point as the initial center point, and determine the search range of the initial center point according to the obstacle positions in the map model. The search range radius corresponding to the initial center point in different calculation cycles is different;
[0013] The calculation module is used to traverse all child nodes within the search range, remove the child nodes that overlap with the previous calculation cycle from all child nodes in the current calculation cycle, and use them as the remaining child nodes, calculate the evaluation function value of each child node in the remaining child nodes, and determine the child node with the smallest evaluation function value as the optimal child node;
[0014] The calculation module is further configured to determine the optimal child node as a new initial center point, and return to the step of determining a search range for the initial center point based on obstacles in the map model until the initial center point coincides with an end point in the global path;
[0015] The planning module is used to sequentially connect the starting point, each optimal sub-node and the end point to obtain a global path, and the mobile robot walks according to the global path;
[0016] The planning module is also used to obtain the real-time position of the mobile robot, determine the inflection point on the global path closest to the real-time position as a temporary end point, determine the position information of all obstacles between the real-time position and the temporary end point, adjust the constraints and evaluation function in the DWA algorithm according to the position information of all obstacles and the position of the temporary end point, use the improved DWA algorithm to plan a local path between the real-time position and the temporary end point, and the mobile robot travels along the local path until the mobile robot reaches the end point.
[0017] The mobile robot path planning method and device provided in the present application are based on the overall goal of improving the efficiency and scientificity of path planning. Taking into account that the global path planning will be corrected by the DWA algorithm after it, the efficiency of global path planning is optimized. On the one hand, an adaptive neighborhood search method is adopted, with the starting point as the initial center point, and the search range of each initial center point is dynamically adjusted based on the distribution of obstacles in the map model. The size of the search neighborhood is adaptively determined according to the environment itself based on the position of the obstacle. On the basis of ensuring that there will be no obstacles in the search area of each calculation cycle, that is, it will not affect the scientificity of the global path planning, the efficiency of path planning is improved in each calculation cycle as much as possible to avoid planning the path with an overly small area step size; on the other hand, while expanding the single planning space, the sub-nodes overlapping with the previous calculation cycle are removed, while ensuring the scientificity of the global path, further reducing the amount of calculation.
[0018] Furthermore, based on global path planning, the expanded search range results in insufficient precision at difficult locations. As a supplement, the DWA algorithm is employed to refine the local path at inflection points. When irregularly shaped obstacles are present, and there are multiple obstacles, the traditional DWA algorithm tends to detour at the location farthest from the longest side length. This preference prioritizes the most prominent location from the obstacle, which is farthest from all obstacles. This approach often results in significant detours in the planned path. Adjusting the orientation difference evaluation function allows the algorithm to consider the short sides of irregular obstacles. Adjusting the attraction-repulsion evaluation function allows the path planner to select a path that traverses multiple obstacles. Improvements to the speed evaluation function further increase speed when there are no obstacles and increase the safe distance when obstacles are present. This allows the DWA algorithm to safely navigate multi-obstacle path planning scenarios with a closer, more traversable approach, ensuring the robot reaches its destination efficiently, safely, and stably. This significantly enhances the autonomous navigation performance of mobile robots in complex scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 This is a flowchart of Example 1 of the mobile robot path planning method provided in this application;
[0020] Figure 2 This is a schematic diagram of the initial search range exemplified in this application;
[0021] Figure 3 A schematic diagram of the position difference shown in an exemplary embodiment of the present application;
[0022] Figure 4This is a structural diagram of Example 1 of the mobile robot path planning device provided in this application. DETAILED DESCRIPTION
[0023] Exemplary embodiments are described in detail herein, with examples illustrated in the accompanying drawings. When the following description refers to the drawings, identical numerals in different drawings represent identical or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with this application.
[0024] The terms used in this application are for the purpose of describing specific embodiments only and are not intended to limit this application. The singular forms "a," "the," and "the" used in this application are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" as used herein refers to and includes any or all possible combinations of one or more of the associated listed items.
[0025] It should be understood that although the terms first, second, third, etc. may be used in this application to describe various information, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from each other. For example, without departing from the scope of this application, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".
[0026] Specific embodiments are given below to introduce the technical solutions of the present application in detail.
[0027] Figure 1 This is a flow chart of the first embodiment of the mobile robot path planning method provided by this application. Figure 1 The method provided in this embodiment may include:
[0028] S101. Construct a map model, determine the starting and ending points, use the starting point as the initial center point, and determine a search range for the initial center point based on the obstacle positions in the map model. The search range radius corresponding to the initial center point in different calculation cycles is different.
[0029] Specifically, the mobile robot path planning method provided in this embodiment is used to plan the moving path of a four-wheel differential mobile robot. The map model refers to a digital representation of the real environment in which the mobile robot is located. The shapes and sizes of obstacles in the real environment will be presented in a corresponding form in the map model. By planning the path in the map model, the mobile robot can move according to the planned path in the real environment, avoid colliding with obstacles, and improve the efficiency and success rate of task execution.
[0030] Optionally, the steps for building a map model may include:
[0031] (1) Determine the application range and resolution of the mobile robot;
[0032] Specifically, the application site range refers to the area range of the real environment where the mobile robot is located, and the resolution refers to the actual physical size of each area divided into the application site range. The length and width of the application site range can be obtained through actual measurement. The size of the resolution is set according to actual needs and is not limited in this embodiment.
[0033] (2) Dividing the application site into m*n grids according to the resolution;
[0034] Specifically, according to the determined application site range and resolution, the application site range is divided into m*n grids using the resolution, and each grid has the same size.
[0035] (3) Obtaining obstacle information within the application site;
[0036] Specifically, various sensors can be used to obtain obstacle information in the map environment. Common sensors include lidar, depth cameras, ultrasonic sensors, etc. These sensors can measure the distance between the mobile robot and surrounding objects to determine the location of obstacles.
[0037] (4) Determine the grid corresponding to the obstacle information, and assign a status value to the grid, where the status value is used to indicate that the grid is the obstacle.
[0038] Specifically, the collected sensor data is mapped onto a grid, and each grid is assigned a status value to represent the situation within that grid. If no obstacle is detected within a grid, it is marked as idle, usually represented by a value of 0. If an obstacle is detected within a grid, it is marked as an obstacle, usually represented by a value of 1. This constructs a map model that can represent the distribution of obstacles in the real environment.
[0039] Furthermore, each grid cell in the map model represents a point. The mobile robot's starting and ending locations are determined based on its mission, and the distribution of obstacles in the map model is used to determine the search range for the initial center point. The search range radius may vary depending on the initial center point. For example, in areas with dense obstacles, the search range radius may be smaller, while in open areas, the search range radius may be larger. This is done to more efficiently avoid obstacles during path search.
[0040] Furthermore, the steps for determining the search range of the initial center point include:
[0041] (1) Determine a basic neighborhood, with the initial center point as the center, and the basic neighborhood as the initial search range of size;
[0042] Specifically, the basic neighborhood is a pre-set area of a fixed size. In one possible implementation, the basic neighborhood can be set to a range of 3×3 grids around the current point, with the initial center point as the center. The size of the basic neighborhood is used as the initial search range, which is equivalent to defining a preliminary "exploration area" for path search. Subsequent sub-node searches will begin within this range.
[0043] (2) Determine a new size unit, and expand the range of the new size unit outside the initial search range to define it as a candidate search range;
[0044] Specifically, the additional size unit is a predetermined fixed-size increment used to expand the search range. The initial search range is expanded by the additional size unit, resulting in a new range called the candidate search range. The candidate search range can be thought of as a "to-be-explored area" that further expands the initial search range.
[0045] (3) Determine whether there are obstacles within the non-overlapping range between the initial search range and the candidate search range, and adjust the initial search range according to the determination result.
[0046] Specifically, checking whether there are obstacles in the non-overlapping part between the initial search range and the candidate search range (that is, the newly added area) can be achieved through the obstacle information recorded in the map model. For example, in the map model, if the value of a certain grid indicates that there is an obstacle at that location, it can be determined that there is an obstacle in the area.
[0047] Furthermore, the steps of adjusting the initial search range according to the judgment result include:
[0048] 3.1. If the determination result is that no obstacle exists, the initial search range is adjusted using the vertical distance between the obstacle and the initial search range as the newly added size unit;
[0049] Specifically, if the result is that there are no obstacles within the non-overlapping range, it means that the search range can continue to expand outward. At this time, it is necessary to measure the vertical distance of the obstacle from the initial search range. The vertical distance refers to the shortest vertical distance from the boundary of the initial search range to the nearest obstacle. For example, in a two-dimensional grid map, if the initial search range is a rectangular area, then the shortest vertical distance from the rectangular boundary to the grid where the nearest obstacle is located is measured. The measured vertical distance is used as the additional size unit. Based on the initial search range, the range of the additional size unit is expanded outward, that is, the candidate search range is used as the new search range for node search.
[0050] Optionally, in one possible implementation, Figure 2 For an example of the initial search range shown in this application, please refer to Figure 2 , Figure 2 The yellow grid shown in the figure is the starting point, the area formed by the green grid is the initial search area, and the gray grid is the obstacle. When it is judged that there is no obstacle, the closest distance between the green grid and the obstacle is measured, and the closest distance is used as a new size unit to adjust the initial search range.
[0051] 3.1. If the judgment result is that there is an obstacle, the initial search range is used as the search range.
[0052] Specifically, if the result indicates that there are obstacles within the non-overlapping range, further expanding the search range may encounter obstacles, which is not conducive to path planning. In this case, the current initial search range remains unchanged and is not further expanded to avoid searching for unfeasible path points. In this case, the initial search range is used as the search range for node search.
[0053] Furthermore, the traditional A* algorithm usually uses an 8-node adjacent search, that is, when searching for nodes between the starting point and the end point, the traditional A* algorithm usually only uses a fixed search range for the search. This will result in the traditional A* algorithm being able to only perceive the obstacle situation within the search range, and having poor perception of the overall obstacle situation. The area beyond the search range is equivalent to a black box for the mobile robot, which can only determine the node based on the obstacle information within the search range, and cannot perceive the distribution of obstacles outside the search range. However, the present application adaptively determines the node search range based on the obstacle position, thereby realizing obstacle perception and deeper node search.
[0054] S102: traverse all child nodes within the search range, delete the child nodes that overlap with the previous calculation cycle from all child nodes in the current calculation cycle, and use them as the remaining child nodes. Calculate the evaluation function value of each child node in the remaining child nodes, and determine the child node with the smallest evaluation function value as the optimal child node.
[0055] Specifically, based on the description above, a grid in the map model represents a node. The current calculation cycle refers to the complete process from starting with a certain point as the initial center point to determining the optimal child node within that cycle. Each calculation cycle involves determining the search range for the initial center point, searching for child nodes within that search range, and calculating and determining the optimal child node from multiple child nodes. Upon completion of these steps, a calculation cycle ends, and the optimal child node is used as the new initial center point for the next calculation cycle, repeating the above steps until the initial center point coincides with the end point of the global path.
[0056] Furthermore, from all the child nodes of the current calculation cycle, the child nodes that overlap with the previous calculation cycle are deleted to obtain the remaining child nodes. This can avoid repeated calculations and improve the efficiency of path planning. The evaluation function is used to calculate the evaluation function value of the remaining child nodes, and the child node with the smallest evaluation function value is determined as the optimal child node, which means that the child node is the most suitable choice as the next step of the path within the current search range.
[0057] Furthermore, the evaluation function value of the child node can be calculated by the following formula:
[0058] ;
[0059] in, The x-axis coordinate value of the child node;
[0060] The y-axis coordinate value of the child node;
[0061] is the x-axis coordinate value of the starting point;
[0062] is the y-axis coordinate value of the starting point;
[0063] is the x-axis coordinate value of the end point;
[0064] The y-axis coordinate value of the end point.
[0065] By calculating the straight-line distance between the child node and the starting point in the plane rectangular coordinate system and the straight-line distance between the child node and the end point, the straight-line distances between the child node and the starting point and the end point are summed, and the sum is used as the evaluation function value of the child node.
[0066] S103: Determine the optimal child node as a new initial center point, and return to the step of determining a search range of the initial center point according to obstacles in the map model until the initial center point coincides with an end point in the global path.
[0067] Specifically, the optimal child node found is used as the initial center point, and the above steps of determining the search range, filtering child nodes, and determining the optimal child node are repeated until the initial center point coincides with the end point of the global path. The steps of determining the search range, filtering child nodes, and determining the optimal child node are described above and will not be repeated here.
[0068] S104 , sequentially connecting the starting point, each optimal sub-node, and the end point to obtain a global path, and the mobile robot walks along the global path.
[0069] Specifically, the starting point, each optimal child node, and the end point are connected in sequence to obtain a global path from the starting point to the end point. The mobile robot will walk along this global path.
[0070] S105. Obtain the real-time position of the mobile robot, determine the inflection point on the global path that is closest to the real-time position as a temporary end point, determine the position information of all obstacles between the real-time position and the temporary end point, adjust the constraints and evaluation function in the DWA algorithm according to the position information of all obstacles and the position of the temporary end point, use the improved DWA algorithm to plan a local path between the real-time position and the temporary end point, and the mobile robot travels along the local path until the mobile robot reaches the end point.
[0071] Specifically, the DWA (Dynamic Window Approach) algorithm is a local path planning algorithm based on a dynamic window. The improved DWA algorithm is based on improvements to the DWA algorithm and can plan local paths more accurately. When a mobile robot walks on a global path, the obstacles in the global path are not static and may contain some unpredictable obstacles. In this case, it is necessary to use the improved DWA algorithm to plan the local path of the mobile robot during the walking process. The improved DWA algorithm plans local paths more accurately by improving the evaluation function. The improved evaluation function includes the azimuth difference function, the attraction-repulsion function, and the speed function. Among them, the azimuth difference function is used to measure the difference between the current direction of the robot and the target direction; the attraction-repulsion function takes into account the attraction of the target point and the repulsion of obstacles; and the speed function is related to the movement speed of the robot.
[0072] Furthermore, an inflection point refers to a point on the global path where the direction changes. When the mobile robot moves along the global path, the local path needs to be continuously adjusted due to dynamic changes in the environment and the need to avoid obstacles. At this time, the inflection point on the global path that is closest to the robot's real-time position will be selected as the temporary end point. Based on the improved DWA algorithm, the robot plans a local path with the current real-time position as the starting point and the inflection point as the temporary end point, so that the robot can flexibly respond to changes in the local environment, effectively avoid dynamic obstacles, and move along a reasonable local path to the temporary end point. It can be understood that the global path is divided into multiple path segments by multiple inflection points, and the improved DWA algorithm performs local planning on multiple path segments respectively, thereby effectively avoiding dynamic obstacles and optimizing the moving path of the mobile robot.
[0073] Furthermore, the steps for implementing local path planning based on the improved DWA algorithm include:
[0074] (1) Determine the speed range within the sampling time interval based on the current speed and kinematic constraints of the mobile robot to form a dynamic window;
[0075] Specifically, during a mobile robot's motion, its actual speed consists of linear velocity and angular velocity. Linear velocity (the linear distance traveled per unit time) and angular velocity (the angle of rotation per unit time) are limited by the robot's physical properties and the environment. Based on the robot's current speed and kinematic constraints (kinematic constraints refer to the physical constraints imposed on the robot, including maximum and minimum speeds determined by motor performance, as well as acceleration and deceleration limits), the kinematic constraints limit the robot's speed limit. The feasible range of its linear and angular velocities within a sampling interval can be determined, forming the mobile robot's speed range. This speed range is known as the dynamic window, which defines the range of possible speed combinations for the mobile robot at the next moment in its current state. The dynamic window restricts the speed combinations the robot can choose at each sampling moment, ensuring that the robot's motion is physically feasible and safe.
[0076] (2) performing velocity sampling based on the dynamic window, and simulating the motion trajectory of the mobile robot within the sampling time interval according to each sampled velocity combination;
[0077] Specifically, velocity sampling is performed within the linear velocity and angular velocity ranges determined by the dynamic window. Each sampled velocity combination consists of a value v selected from the determined linear velocity range and a value ω selected from the determined angular velocity range. Such a pair of values (v, ω) constitutes a velocity combination.
[0078] Furthermore, a four-wheel differential model can be used to build a dynamic model for the mobile robot. The robot's motion state is represented by velocity and angular velocity, while its position is represented by coordinates and direction. For each sampled velocity combination, the robot's motion trajectory within the sampling interval is simulated using the mobile robot's dynamic model. Assuming a sampling interval of one second, the kinematic model calculates that the robot starts from its current position, moves at a certain velocity combination, and reaches its new position one second later. By repeatedly repeating this calculation process, a series of position points are obtained, which are connected to form a motion trajectory. By simulating motion trajectories under different velocity combinations, a basis for subsequent optimal path selection is provided.
[0079] (3) Calculating the DWA evaluation function value of each motion trajectory, wherein the DWA evaluation function value includes the orientation deviation, obstacle avoidance distance, and motion state;
[0080] Specifically, for each simulated trajectory, the DWA evaluation function value is calculated. The DWA evaluation function value comprehensively considers several important factors: orientation deviation, obstacle avoidance distance, and motion state. Orientation deviation measures the difference between the target direction of the trajectory and the direction from the robot's current position to the target end point; the smaller the difference, the better. The obstacle avoidance distance represents the distance between the trajectory and surrounding obstacles; the larger the distance, the better the obstacle avoidance effect. The motion state can be considered from aspects such as the rationality of the speed, such as whether the speed is stable and whether it is consistent with the robot's motion capabilities.
[0081] Furthermore, the DWA evaluation function can be expressed by the following formula:
[0082] ;
[0083] in, is the orientation difference evaluation function;
[0084] is the attraction-repulsion evaluation function;
[0085] is the speed evaluation function;
[0086] 、 、 are the weights corresponding to each function respectively.
[0087] (4) taking the speed combination corresponding to the motion trajectory with the largest DWA evaluation function value as the control speed of the mobile robot at the next moment, and updating the motion state and trajectory of the mobile robot;
[0088] Specifically, the DWA evaluation function values of all motion trajectories are compared, and the velocity combination corresponding to the motion trajectory with the largest DWA evaluation function value is selected as the mobile robot's control velocity at the next moment. The motion state and trajectory of the mobile robot, including position, velocity, and other information, are then updated based on this control velocity. For example, if the robot's current position is , and this velocity combination is used as the control velocity, after time Δt, the motion state at the new position can be updated according to the corresponding kinematic formula.
[0089] (5) After updating the motion state and trajectory of the mobile robot, return to the step of sampling the velocity based on the dynamic window until the mobile robot reaches the end point and stops.
[0090] Specifically, the robot resamples the velocity based on the updated motion state to obtain multiple new motion trajectories. The DWA evaluation function values for these motion trajectories are recalculated, and the optimal velocity combination is selected and the motion state is updated. This process is repeated until the mobile robot reaches the end point and stops.
[0091] Furthermore, the constraints and evaluation functions in the DWA algorithm are adjusted based on the location information of all obstacles and the location of the temporary endpoints, including:
[0092] (1) calculating a first angle between the current trajectory direction of the mobile robot and the temporary end point, and a second angle between the alternative trajectory direction and the temporary end point;
[0093] Specifically, Figure 3 For the schematic diagram of the position difference shown in the exemplary embodiment of this application, please refer to Figure 3 , Figure 3 The two alternative trajectories obtained by DWA planning at the current position of the mobile robot are shown. The first angle between the current trajectory direction of the mobile robot and the temporary end point is the angle between the vector from the current position of the mobile robot to the temporary end point and the vector of the current trajectory direction of the robot (i.e. ), the second angle between the direction of the alternative trajectory and the temporary end point refers to the angle between the vector pointing to the temporary end point from a certain alternative trajectory to be evaluated and the vector of the robot's direction of travel along the alternative trajectory (i.e. or ), the first angle and the second angle can be calculated through trigonometric function relationship.
[0094] (2) Calculating an angle difference based on the first angle and the second angle, and minimizing the angle difference as an evaluation target of the orientation difference evaluation function.
[0095] Specifically, calculate the angle difference between the first angle and the second angle. The angle difference reflects the degree of deviation of each trajectory position relative to the robot's current position in the direction of the end point. Please refer to Figure 3 , Figure 3 The second angle of trajectory 1 shown in , the second angle of trajectory 2 is , respectively calculate the angle difference between the first angle and trajectory 1 and the angle difference between the first angle and trajectory 2, compare the sizes of the two angle differences, and make the mobile robot select the moving trajectory with the smallest angle difference as the moving trajectory. Because the smaller the angle difference, the closer the direction of the trajectory is to the direction directly pointing from the current position of the robot to the end point, which means that selecting this trajectory can make the robot move more directly towards the end point, which is a better choice in path planning.
[0096] Furthermore, by calculating the angle difference and using its minimum as the evaluation target for the orientation difference evaluation function, the robot can prioritize trajectories that are closer to the temporary destination when planning its path. In complex obstacle environments, or when the temporary destination is blocked by obstacles, trajectories with a small angle difference tend to prevent the mobile robot from penetrating into areas densely populated with obstacles, instead advancing in a relatively open and safe direction. Choosing a trajectory with a large angle difference may cause the mobile robot to move away from the temporary destination and closer to obstacles, increasing the risk of collision. Trajectories with a small angle difference, on the other hand, allow the robot to effectively avoid obstacles while approaching the destination, ensuring its own safety and thus preventing the mobile robot from being trapped by obstacles.
[0097] Furthermore, the steps of determining the movement trajectory of the local path according to the attraction-repulsion evaluation function include:
[0098] (1) calculating the gravity values of the plurality of moving trajectories of the mobile robot according to the gravity evaluation function;
[0099] Specifically, the gravity function is used to measure the degree of attraction of the end target to the mobile robot.
[0100] The gravitational function can be expressed by the following formula:
[0101] ;
[0102] in, is the gravitational adjustment parameter;
[0103] is the distance between the mobile robot and the final target.
[0104] (2) calculating repulsive force values of a plurality of moving trajectories of the mobile robot according to the repulsive force function;
[0105] Specifically, the steps of calculating the repulsive force values of multiple moving trajectories of the mobile robot according to the repulsive force function include:
[0106] 2.1. Calculate the distance moved by the mobile robot after the acquisition time interval;
[0107] Specifically, within the sampling interval, the distance d traveled is calculated based on the robot's current velocity (linear velocity v) using the formula d = v × Δt, where Δt is the sampling interval. This step prepares for determining the extent of the scanning area, as the robot's potential reachable locations within this timeframe are necessary to determine the spatial area to scan for obstacles.
[0108] 2.2. Scanning the spatial area with the current position as the radiation center according to the preset radiation radius, and calculating the repulsive force at the current position;
[0109] Specifically, the current position of the mobile robot is used as the radiation center and the spatial area is scanned according to a preset radiation radius. It should be noted that the value of the radiation radius is set according to actual needs and is not limited in this embodiment.
[0110] Furthermore, the repulsion function can be expressed by the following formula:
[0111] ;
[0112] in, is the repulsion adjustment parameter;
[0113] is the distance between the mobile robot and the obstacle;
[0114] is the speed of the mobile robot's current position.
[0115] Calculate the repulsive force at the current position through the repulsion function.
[0116] 2.3. Mark the scanned obstacle, calculate the third distance between the obstacle and the current position, and calculate the repulsive force at the obstacle position;
[0117] Specifically, all detected obstacles are marked within the scanning area. For each marked obstacle, the third distance between it and the mobile robot's current position is calculated. The repulsive force at that obstacle's position is then calculated using the repulsion function. This yields the magnitude of the repulsive force each obstacle exerts on the robot's current position.
[0118] 2.4. Selecting target obstacles based on the repulsive force at the obstacle position;
[0119] Specifically, the calculated repulsive force of each obstacle is compared with the repulsive force at the current position, and obstacles with strong repulsive force are selected as target obstacles. These target obstacles have a greater impact on the robot's movement and need to be avoided as a priority.
[0120] 2.5. For each target obstacle, calculate the distance from all trajectories to the target obstacle. If the distance is less than the preset safety distance, discard the trajectory to obtain the target trajectory set.
[0121] Specifically, for each target obstacle, the distance from all moving trajectories to that target obstacle is calculated. Trajectories with distances less than a preset safety distance are discarded, as these are too close to the obstacle and could pose a collision risk. After screening, a set of target trajectories that meet the safety distance requirements is obtained. It should be noted that the safety distance is set based on actual needs and is not limited in this embodiment.
[0122] 2.6. Calculate the repulsive force from the target trajectory to the target obstacle, calculate the sum of the repulsive forces of all target obstacles on the same trajectory, and determine the sum of the repulsive forces as the repulsive force value of the moving trajectory.
[0123] Specifically, for each trajectory in the target trajectory set, the repulsive force between that trajectory and each target obstacle is calculated. The repulsive forces of all target obstacles on the same trajectory are then summed to obtain the sum of the repulsive forces for that trajectory. This sum is the repulsive force value for that trajectory. By comparing the repulsive force values of different trajectories, we can evaluate each trajectory's ability to avoid obstacles. Trajectories with smaller repulsive force values are less affected by obstacles and are more likely to pass safely.
[0124] (3) For the plurality of moving trajectories of the mobile robot, a weighted value of the attraction value and the repulsion value is calculated, and the maximum weighted value is used as an evaluation target of the attraction-repulsion evaluation function.
[0125] Specifically, the weighted value can be calculated using the following formula:
[0126] ;
[0127] in, is the weight of the gravity value;
[0128] is the gravity value;
[0129] is the weight of the repulsive force value;
[0130] is the repulsive force value.
[0131] It should be noted that the weights corresponding to the attraction value and the repulsion value are set according to actual needs and are not limited in this embodiment. For example, in one embodiment, there are many obstacles in the map model and the mobile robot needs to be controlled to avoid obstacles, so the weight of the repulsion value can be increased; in another embodiment, the map model is an open area with fewer obstacles. At this time, the weight of the attraction value can be increased so that the mobile robot can reach the destination faster.
[0132] Specifically, the repulsion evaluation function allows the mobile robot to consider the impact of obstacles when planning its path. As the robot approaches an obstacle, the repulsion value increases. By calculating the repulsion values of multiple trajectories and incorporating them into the attraction-repulsion evaluation function, the robot tends to choose trajectories with smaller repulsion values. The gravity evaluation function reflects the attraction of the destination to the mobile robot. By calculating the gravity values of multiple trajectories, the mobile robot tends to choose trajectories with larger gravity values, because larger gravity values indicate closer trajectories to the destination. The attraction-repulsion evaluation function comprehensively considers the weighted values of gravity and repulsion, ensuring that the robot avoids obstacles while also avoiding excessive deviations from the target. This prevents the mobile robot from choosing an excessively long path due to excessive obstacle avoidance. By adjusting the weights of gravity and repulsion, a suitable balance is found between obstacle avoidance and target proximity. This allows the mobile robot to select a path from among many possible trajectories that both avoids obstacles and reaches the destination as quickly as possible, thus achieving effective obstacle avoidance and optimizing path length in complex environments.
[0133] Furthermore, the steps of determining the movement trajectory of the local path according to the speed evaluation function include:
[0134] (1) Determine the safe distance based on the nearest obstacle to the current position;
[0135] Specifically, the safety distance is a key parameter for ensuring a safe distance between a mobile robot and obstacles. Its determination requires consideration of factors such as the robot's size, motion performance, and obstacle characteristics. For example, if the robot is large and fast, or if the obstacle is sharp or dangerous, the safety distance should be increased; otherwise, it can be appropriately reduced. This distance provides a safety benchmark for subsequent planning, preventing collisions between the robot and obstacles during operation. The safety distance can be determined based on obstacle characteristics. For example, sharp obstacles, such as metal edges and protruding nails, can cause significant damage to the robot, so a larger safety distance is required. For soft obstacles, such as foam and plastic film, the safety distance can be appropriately reduced while ensuring that no damage is caused to critical robot components. For example, for unstable obstacles, such as swaying objects and potentially collapsing shelves, the safety distance should be increased to prevent sudden movement or collapse that could impact the robot. For stable obstacles, such as fixed walls and large machinery and equipment, the safety distance can be relatively smaller.
[0136] (2) Calculating the sum of the safety distance and the distance from the current position to the nearest obstacle as the deceleration constraint distance;
[0137] Specifically, the distance from the current position to the nearest obstacle can be calculated using the coordinate system's linear distance calculation formula. This is then added to the safety distance, and the sum is used as the deceleration constraint distance, allowing the robot to prepare for deceleration in advance. If the robot approaches or reaches the deceleration constraint distance, it must slow down to avoid being unable to avoid the obstacle due to excessive speed.
[0138] (3) Calculating the product of the deceleration constraint distance, the maximum deceleration, and the maximum angular velocity reduction, and obtaining the obstacle deceleration constraint based on the product;
[0139] (4) Determine the constraint trigger distance;
[0140] Specifically, the maximum deceleration and the maximum angular velocity reduction determine the deceleration capability of the mobile robot. Multiplying the deceleration constraint distance with these two parameters yields the obstacle deceleration constraint. This clarifies the speed limit that the robot should follow when approaching an obstacle, ensuring sufficient time and space to decelerate at a safe distance to prevent collisions.
[0141] Furthermore, the constraint trigger distance determines when the robot activates its obstacle response mechanism. It is typically greater than the deceleration constraint distance and serves as the robot's early warning range. Once an obstacle is detected within the constraint trigger distance, the robot begins to focus on it and prepare for possible deceleration. This distance is set based on the robot's sensor detection range, reaction time, and motion performance to ensure the robot has ample time to respond.
[0142] (5) Determine whether there are any obstacles within the range of the constrained starting distance from the current position;
[0143] Specifically, sensors can continuously scan the surrounding environment to determine if there are any obstacles within the constraint trigger distance. Sensors such as lidar and ultrasonic sensors can acquire environmental information in real time. If no obstacles are detected, the robot will operate as planned.
[0144] (6) If present, remove the obstacle deceleration constraint from the constraints in the DWA algorithm.
[0145] Specifically, when there are obstacles within the starting distance of the current position constraint, the original deceleration constraint based on long-distance planning may no longer apply at close distances. The robot needs a more flexible control strategy, relying on other constraints and algorithms to quickly avoid obstacles, avoid getting into trouble due to following the original deceleration constraint, and ensure that the robot can respond quickly and operate safely in complex environments.
[0146] The mobile robot path planning method provided in this embodiment plans a global path through an improved A* algorithm. As the mobile robot moves along the planned global path, it uses an improved DWA algorithm to plan the mobile robot's local path in real time, achieving effective obstacle avoidance and path length optimization. Firstly, the method uses the mobile robot's starting point as the initial center point and dynamically determines the search range for different initial center points based on the obstacle distribution in the map model. While ensuring the absence of obstacles within the calculation cycle, it also expands the ability to perceive the surrounding environment, providing more path trajectory options. This can improve the algorithm's ability to avoid local optimality or oscillation cycles, enabling the mobile robot to gain a holistic understanding of obstacles in the environment at a macro level, avoid large, fixed obstacle areas, and plan a relatively safe approximate route, allowing the mobile robot to avoid possible collision risks in the initial stages. Furthermore, global path planning determines the approximate direction of the mobile robot from its starting point to its destination, providing a holistic path framework for the mobile robot. This framework connects the starting point, optimal subnodes, and the destination, giving the mobile robot a clear direction of travel, preventing blind movement in complex environments and saving path search time. This optimizes global path planning by shortening node search time and reducing path complexity. Secondly, based on the mobile robot's real-time position and inflection points in the global path, inflection points are identified as temporary endpoints on local paths. Local paths are planned using an improved DWA algorithm that incorporates a bearing difference evaluation function, an attraction-repulsion evaluation function, and a speed evaluation function. This allows the mobile robot to quickly traverse areas with few or no obstacles. In areas with many obstacles, the evaluation functions enable the mobile robot to plan shorter trajectories with higher obstacle avoidance efficiency. Furthermore, when faced with sudden obstacles, the mobile robot can quickly find the optimal path around them, reducing detours. The collaborative work of global and local path planning achieves comprehensive path planning from the macro to the micro level. Under varying environmental conditions, the two work together to ensure the mobile robot avoids obstacles and maintains efficient paths. Global path planning provides the first layer of security, allowing the mobile robot to avoid major obstacles as a whole. Local path planning, on the other hand, provides the second layer of security, handling unexpected obstacles not foreseen in the global plan in real time during the mobile robot's motion. This reduces the risk of collisions in complex environments, improves operational safety, and ultimately enhances the mobile robot's path planning capabilities and execution efficiency in various scenarios.
[0147] Corresponding to the aforementioned embodiment of a mobile robot path planning method, the present application also provides an embodiment of a mobile robot path planning device.
[0148] Figure 4 This is a structural diagram of the first embodiment of the mobile robot path planning device provided by this application. Figure 4 The device provided in this embodiment includes a determination module 410, a calculation module 420 and a planning module 430; wherein,
[0149] The determination module 410 is configured to construct a map model, determine the start and end points, use the start point as the initial center point, and determine a search range for the initial center point based on the locations of obstacles in the map model. The search range radius corresponding to the initial center point varies in different calculation cycles.
[0150] The calculation module 420 is configured to traverse all child nodes within the search range, remove the child nodes that overlap with those in the previous calculation cycle from all child nodes in the current calculation cycle, and use them as the remaining child nodes. The calculation module 420 calculates the evaluation function value of each of the remaining child nodes, and determines the child node with the smallest evaluation function value as the optimal child node.
[0151] The calculation module 420 is further configured to determine the optimal child node as a new initial center point, and return to the step of determining a search range for the initial center point based on obstacles in the map model until the initial center point coincides with an end point in the global path;
[0152] The planning module 430 is used to sequentially connect the starting point, each optimal sub-node and the end point to obtain a global path, and the mobile robot walks according to the global path;
[0153] The planning module 430 is also used to obtain the real-time position of the mobile robot, determine the inflection point on the global path that is closest to the real-time position as a temporary end point, determine the position information of all obstacles between the real-time position and the temporary end point, adjust the constraints and evaluation function in the DWA algorithm according to the position information of all obstacles and the position of the temporary end point, use the improved DWA algorithm to plan a local path between the real-time position and the temporary end point, and the mobile robot moves along the local path until the mobile robot reaches the end point.
[0154] The device of this embodiment can be used to perform Figure 1 The steps, specific implementation principles and implementation processes of the method embodiment shown are similar and will not be repeated here.
[0155] The implementation process of the functions and effects of each unit in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, and will not be repeated here.
[0156] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can be referred to the partial description of the method embodiments. The device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present application scheme. A person of ordinary skill in the art can understand and implement it without paying any creative work.
[0157] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A mobile robot path planning method, characterized in that: The method comprises: Constructing a map model, determining the starting and ending points, using the starting point as an initial center point, and determining a search range for the initial center point based on obstacle positions in the map model, wherein the search range radius corresponding to the initial center point in different calculation cycles is different; wherein determining the search range for the initial center point includes: Determine a basic neighborhood, with the initial center point as the center, and the basic neighborhood as the initial search range of size; Determine a newly added size unit, and define the range of the newly added size unit expanded outside the initial search range as a candidate search range; Determine whether there is an obstacle within a non-overlapping range between the initial search range and the candidate search range, and adjust the initial search range according to the determination result; Traversing all child nodes within the search range, deleting the child nodes that coincide with the previous calculation cycle from all child nodes in the current calculation cycle as the remaining child nodes, calculating the evaluation function value of each child node in the remaining child nodes, and determining the child node with the smallest evaluation function value as the optimal child node; calculating the straight-line distance between the child node and the starting point and the straight-line distance between the child node and the end point in a plane rectangular coordinate system, summing the straight-line distances between the child node and the starting point and the end point, and using the sum as the evaluation function value of the child node; Determining the optimal child node as a new initial center point, and returning to the step of determining a search range for the initial center point based on obstacles in the map model until the initial center point coincides with an end point in the global path; sequentially connecting the starting point, each optimal sub-node, and the end point to obtain a global path, and the mobile robot walks along the global path; Obtaining the real-time position of the mobile robot, determining the inflection point on the global path closest to the real-time position as a temporary end point, determining position information of all obstacles between the real-time position and the temporary end point, and adjusting the constraints and evaluation function in the DWA algorithm according to the position information of all obstacles and the position of the temporary end point, wherein the adjusting the constraints and evaluation function in the DWA algorithm according to the position information of all obstacles and the position of the temporary end point includes: Calculating a first angle between the current trajectory direction of the mobile robot and the temporary end point, and a second angle between the alternative trajectory direction and the temporary end point; Calculating an angle difference based on the first angle and the second angle, and minimizing the angle difference as an evaluation target of the orientation difference evaluation function; Determine the safe distance based on the nearest obstacle to the current position; Calculating the sum of the safety distance and the distance from the current position to the nearest obstacle as the deceleration constraint distance; Calculating the product of the deceleration constraint distance, the maximum deceleration, and the maximum angular velocity reduction, and obtaining the obstacle deceleration constraint according to the product; Determine the constraint trigger distance; Determine whether there are any obstacles within the range of the constrained starting distance from the current position; If so, deleting the obstacle deceleration constraint from the constraints in the DWA algorithm; The improved DWA algorithm is used to plan a local path between the real-time position and the temporary destination, and the mobile robot travels along the local path until the mobile robot reaches the destination.
2. The method according to claim 1, characterized in that The adjusting the initial search range according to the judgment result includes: If the judgment result is that there is no obstacle, the initial search range is adjusted using the vertical distance between the obstacle and the initial search range as the newly added size unit; If the judgment result is that an obstacle exists, the initial search range is used as the search range.
3. The method according to claim 1, characterized in that The method of planning a local path between the real-time location and the temporary destination using the improved DWA algorithm includes: Determining a velocity range within a sampling time interval based on the current velocity and kinematic constraints of the mobile robot to form a dynamic window; Performing velocity sampling based on the dynamic window, and simulating the motion trajectory of the mobile robot within a sampling time interval according to each sampled velocity combination; Calculating a DWA evaluation function value for each motion trajectory, wherein the DWA evaluation function value includes azimuth deviation, obstacle avoidance distance, and motion state; using the speed combination corresponding to the motion trajectory with the maximum DWA evaluation function value as the control speed of the mobile robot at the next moment, and updating the motion state and trajectory of the mobile robot; After updating the motion state and trajectory of the mobile robot, the process returns to the step of performing speed sampling based on the dynamic window until the mobile robot reaches the end point and stops.
4. The method according to claim 1, wherein Adjusting the constraints and evaluation function in the DWA algorithm according to the position information of all obstacles and the position of the temporary end point; including: Calculating the gravity values of a plurality of moving trajectories of the mobile robot according to the gravity function; Calculating repulsive force values of a plurality of moving trajectories of the mobile robot according to a repulsive force function; For a plurality of movement trajectories of the mobile robot, weighted values of the attraction value and the repulsion value are calculated, and the maximum weighted value is used as an evaluation target of an attraction-repulsion evaluation function.
5. The method according to claim 4, characterized in that The step of calculating the repulsive force values of the plurality of moving trajectories of the mobile robot according to the repulsive force function comprises: Calculating the distance moved by the mobile robot after the acquisition time interval; Taking the current position as the radiation center, scanning the space area according to a preset radiation radius, and calculating the repulsive force at the current position; Marking the scanned obstacles, calculating a third distance between the obstacle and the current position, and calculating the repulsive force at the obstacle position; Selecting target obstacles based on the repulsive force at the obstacle position; For each target obstacle, calculate the distance from all trajectories to the target obstacle. If the distance is less than the preset safety distance, discard the trajectory to obtain the target trajectory set. The repulsive force from the target trajectory to the target obstacle is calculated, the sum of the repulsive forces of all target obstacles on the same trajectory is calculated, and the sum of the repulsive forces is determined as the repulsive force value of the moving trajectory.
6. The method according to claim 1, characterized in that The map model is constructed; comprising: Determining the application field range and resolution of the mobile robot; Divide the application site into m*n grids according to the resolution; Obtaining obstacle information within the application site; The grid corresponding to the obstacle information is determined, and a status value is assigned to the grid, where the status value is used to indicate that the grid is the obstacle.
7. A mobile robot path planning device, characterized in that: The device includes a determination module, a calculation module and a planning module; wherein, The determination module is used to construct a map model, determine the starting point and the end point, use the starting point as the initial center point, and determine the search range of the initial center point according to the obstacle positions in the map model. The search range radius corresponding to the initial center point in different calculation cycles is different; wherein, determining the search range of the initial center point includes: Determine a basic neighborhood, with the initial center point as the center, and the basic neighborhood as the initial search range of size; Determine a newly added size unit, and define the range of the newly added size unit expanded outside the initial search range as a candidate search range; Determine whether there is an obstacle within a non-overlapping range between the initial search range and the candidate search range, and adjust the initial search range according to the determination result; The calculation module is used to traverse all child nodes within the search range, delete the child nodes that coincide with the previous calculation cycle from all child nodes in the current calculation cycle, and use them as the remaining child nodes, calculate the evaluation function value of each child node in the remaining child nodes, and determine the child node with the smallest evaluation function value as the optimal child node; calculate the straight-line distance between the child node and the starting point in the plane rectangular coordinate system and the straight-line distance between the child node and the end point, sum the straight-line distances between the child node and the starting point and the end point, and use the sum as the evaluation function value of the child node; The calculation module is further configured to determine the optimal child node as a new initial center point, and return to the step of determining a search range for the initial center point based on obstacles in the map model until the initial center point coincides with an end point in the global path; The planning module is used to sequentially connect the starting point, each optimal sub-node and the end point to obtain a global path, and the mobile robot walks according to the global path; The planning module is further configured to obtain the real-time position of the mobile robot, determine the inflection point on the global path closest to the real-time position as a temporary end point, determine the position information of all obstacles between the real-time position and the temporary end point, and adjust the constraints and evaluation function in the DWA algorithm based on the position information of all obstacles and the position of the temporary end point, wherein the adjusting the constraints and evaluation function in the DWA algorithm based on the position information of all obstacles and the position of the temporary end point includes: Calculating a first angle between the current trajectory direction of the mobile robot and the temporary end point, and a second angle between the alternative trajectory direction and the temporary end point; Calculating an angle difference based on the first angle and the second angle, and minimizing the angle difference as an evaluation target of the orientation difference evaluation function; Determine a safety distance based on the nearest obstacle to the current position; calculate the sum of the safety distance and the distance from the current position to the nearest obstacle as the deceleration constraint distance; Calculating the product of the deceleration constraint distance, the maximum deceleration, and the maximum angular velocity reduction, and obtaining an obstacle deceleration constraint based on the product; determining a constraint trigger distance; and determining whether an obstacle exists within the range of the current position constraint starting distance; if so, removing the obstacle deceleration constraint from the constraints in the DWA algorithm. The improved DWA algorithm is used to plan a local path between the real-time position and the temporary destination, and the mobile robot travels along the local path until the mobile robot reaches the destination.
Citation Information
Patent Citations
Mobile robot intelligent path planning method
CN112631294A
Autonomous vehicle path planning method based on improved Astar and DWA fusion algorithm
CN116429144A