Multi-robot cleaning area division method and device, cleaning method, terminal and medium
By using a weighted Voronoi algorithm and an iterative optimization mechanism, the weights of the cleaning area and the positions of the seed points are dynamically adjusted, which solves the problem of uneven task distribution in multi-robot cleaning systems and improves cleaning efficiency and stability.
Patent Information
- Application Number
- CN202511280545.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-09
- Publication Date
- 2026-01-23
AI Technical Summary
Existing multi-robot cleaning systems fail to comprehensively consider obstacle distribution and differences in ground material in large-area scenarios, resulting in uneven task allocation, repetitive or missed cleaning, and a lack of dynamic adjustment capabilities, making them unable to adapt to environmental changes.
A weighted Voronoi algorithm combined with obstacle constraints is used to dynamically divide the environment map into regions. By adjusting the weights and penalty functions of clean regions, the area of each region is balanced. The seed point position is updated through an iterative optimization mechanism until the iteration cutoff condition is met.
It achieves a balanced distribution of cleaning areas in terms of size and cleaning difficulty, improves the efficiency and stability of multi-robot collaborative operation, and avoids uneven task allocation and path conflicts.
Smart Images

Figure CN121369988A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of space cleaning technology, and in particular to a method, device, cleaning method, terminal and medium for dividing cleaning areas by multiple robots. Background Technology
[0002] With the increasing use of cleaning robots in large-area scenarios such as supermarkets and offices, traditional single-robot systems are no longer sufficient to meet the demands for efficient cleaning. While multi-robot collaborative cleaning systems can improve efficiency, existing area division methods are mostly based on fixed partitions or Voronoi diagrams that only consider geometric distances. These methods fail to comprehensively consider factors such as obstacle distribution and differences in floor materials, leading to uneven task allocation, repetitive cleaning, or omissions. Furthermore, most methods employ static division strategies, lacking dynamic adjustment capabilities and unable to adapt to environmental changes. Summary of the Invention
[0003] In view of this, embodiments of this application provide a method, apparatus, cleaning method, terminal, and medium for dividing cleaning areas using multiple robots.
[0004] In a first aspect, embodiments of this application provide a method for dividing a cleaning area using multiple robots, including: Based on the position coordinates of each robot in the environmental map, corresponding seed points are determined; wherein, each seed point corresponds to one robot. Based on the seed points, a weighted Voronoi algorithm is used to divide the environment into clean areas to obtain a number of clean areas equal to the number of seed points. During the division, the weight of each clean area is dynamically adjusted according to environmental impact parameters to make the area of each clean area tend to be balanced, and the boundaries of each clean area are adjusted in combination with obstacle constraints. The centroid of each cleaning area is updated to a new seed point, and the environmental map is re-divided using the weighted Voronoi algorithm based on the updated seed points. If the current division result does not meet the iteration cutoff condition, the seed points are updated and the environmental area is re-divided until the iteration cutoff condition is met. The iteration cutoff condition is determined based on the cleaning time of each robot.
[0005] In some embodiments, before determining the corresponding seed point based on the position coordinates of each robot in the environmental map, the method further includes: Construct an environmental map of the required cleaning area with influencing factors; wherein, the influencing factors include obstacle density and the ground friction coefficient, the obstacle density represents the proportion of obstacles per unit area, and the ground friction coefficient is set according to the ground material to reflect the difference in cleaning energy consumption.
[0006] In some embodiments, the step of using a weighted Voronoi algorithm to partition the environment region based on the seed points to obtain a clean region equal in number to the seed points includes: Based on the seed points, the Voronoi algorithm is used to perform preliminary region division in the environmental map to obtain a preliminary clean area equal to the number of seed points. Each of the preliminary cleaning areas is weighted, and the weight of each preliminary cleaning area is dynamically adjusted according to the area, obstacle distribution, and ground friction coefficient to make the area of each preliminary cleaning area tend to be balanced. Based on the adjusted weights, the weighted Voronoi algorithm is used to re-divide the environment map into regions to obtain a clean area equal to the number of seed points.
[0007] In some embodiments, dynamically adjusting the weights of each cleaning area based on the area, obstacle distribution, and ground friction coefficient includes: In each iteration, the weight of the current iteration is determined based on the weight of the previous iteration, the current cleaning area, the average area of the area, and the smoothing coefficient. The average area of the area is determined based on the total area of the area, the area occupied by obstacles, the number of robots, and the ground friction coefficient corresponding to each grid. The current cleaning area is determined based on the number of grids contained in the current cleaning area and the ground friction coefficient corresponding to each grid.
[0008] In some embodiments, adjusting the boundaries of each of the clean areas in conjunction with obstacle constraints includes: Based on the location and distribution of obstacles, the boundaries of each cleaning area are restricted to ensure that each cleaning area does not overlap with the area where the obstacles are located; Based on the obstacle penalty function, the distance penalty value from each location point in the clean area to each obstacle is calculated, and combined with the original distance from the location point to the corresponding seed point, the penalty distance from the location point to the corresponding seed point is determined, so as to use the penalty distance for the region division of the weighted Voronoi algorithm, so that the seed point is far away from the obstacle.
[0009] In some embodiments, the iteration cutoff condition includes the maximum relative deviation between the cleaning time of each of the cleaned areas and the average cleaning time of all cleaned areas being less than or equal to a preset threshold.
[0010] Secondly, embodiments of this application provide a multi-robot cleaning method, including: In response to the cleaning command, each robot obtains its own cleaning area based on the multi-robot cleaning area division method described above, and performs cleaning work according to the division results.
[0011] Thirdly, embodiments of this application provide a multi-robot cleaning area division device, comprising: The determination module is used to determine corresponding seed points based on the position coordinates of each robot in the environmental map; wherein each seed point corresponds to one robot. The partitioning module is used to partition the environment region based on the seed points using a weighted Voronoi algorithm to obtain a number of clean regions equal to the number of seed points. During the region partitioning, the weight of each clean region is dynamically adjusted according to environmental influence parameters to make the area of each clean region tend to be balanced, and the boundaries of each clean region are adjusted in combination with obstacle constraints. The iteration module is used to update the centroid of each cleaning area to a new seed point, and re-divide the environmental map using the weighted Voronoi algorithm based on the updated seed points. If the current division result does not meet the iteration cutoff condition, the seed points are updated and the environmental area is re-divided until the iteration cutoff condition is met. The iteration cutoff condition is determined based on the cleaning time of each robot.
[0012] Fourthly, embodiments of this application provide a terminal device, which includes a processor and a memory. The memory stores a computer program, and the processor executes the computer program to implement the above-described multi-robot cleaning area division method or multi-robot cleaning method.
[0013] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed on a processor, implements the multi-robot cleaning area division method or the multi-robot cleaning method described above.
[0014] The embodiments of this application have the following beneficial effects: First, seed points are determined based on the robot's position. Then, a weighted Voronoi algorithm combined with obstacle constraints is used to dynamically divide the environmental map into regions, making each cleaning area more balanced in terms of area and cleaning difficulty. During the division process, the impact of obstacle distribution and differences in ground material on cleaning efficiency is comprehensively considered. By introducing a weight adjustment mechanism and a penalty function, fewer tasks are assigned to areas with dense obstacles, improving path accessibility and task execution efficiency. Combined with an iterative optimization mechanism, the seed point positions are continuously updated, gradually approaching the task time equilibrium state, thereby effectively improving the overall efficiency and stability of multi-robot collaborative operations. Attached Figure Description
[0015] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0016] Figure 1 This paper illustrates a first flowchart of a multi-robot cleaning area division method according to an embodiment of the present application. Figure 2 This paper illustrates a second flowchart of a multi-robot cleaning area division method according to an embodiment of this application. Figure 3 A schematic diagram of the third process of the multi-robot cleaning area division method according to an embodiment of this application is shown; Figure 4 This diagram illustrates the result of area division using a multi-robot cleaning area division method according to an embodiment of this application. Figure 5 A schematic diagram of a multi-robot cleaning area division device according to an embodiment of this application is shown. Detailed Implementation
[0017] The technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments.
[0018] The components of the embodiments of this application described and illustrated in the accompanying drawings can be arranged and designed in a variety of different configurations. Therefore, the following detailed description of the embodiments of this application provided in the drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0019] In the following text, the terms "comprising," "having," and their cognates, which may be used in various embodiments of this application, are intended only to indicate a particular feature, number, step, operation, element, component, or combination thereof, and should not be construed as primarily excluding the presence of one or more other features, numbers, steps, operations, elements, components, or combinations thereof, or adding the possibility of one or more combinations thereof. Furthermore, the terms "first," "second," "third," etc., are used only for distinguishing descriptions and should not be construed as indicating or implying relative importance.
[0020] Unless otherwise specified, all terms used herein (including technical and scientific terms) shall have the same meaning as commonly understood by one of ordinary skill in the art to which the various embodiments of this application pertain. Terms (such as those defined in commonly used dictionaries) shall be interpreted as having the same meaning as in their contextual meaning in the relevant technical field and shall not be construed as having an idealized or overly formal meaning, unless clearly defined in the various embodiments of this application.
[0021] The following detailed description of some embodiments of this application is provided in conjunction with the accompanying drawings. Unless otherwise specified, the following embodiments and features can be combined with each other.
[0022] The following examples illustrate the method for dividing the cleaning area for multiple robots.
[0023] Figure 1 A schematic flowchart of a multi-robot cleaning area division method according to an embodiment of this application is shown. Exemplarily, the multi-robot cleaning area division method includes the following steps: Step S110: Determine the corresponding seed points based on the position coordinates of each robot in the environmental map.
[0024] Before performing step S110, it is necessary to first construct a digital map containing environmental structure information and multi-dimensional influencing factors related to the cleaning task, namely, an environmental map with influencing factors.
[0025] Specifically, the environmental map is constructed using a SLAM (Simultaneous Localization and Mapping) system mounted on the robot. After entering the area to be cleaned, the robot performs a zigzag scan along the building's outline, gradually collecting spatial structural information about the environment, including walls, room boundaries, and passable areas. During mapping, the robot uses perception devices such as LiDAR, depth cameras, or visual sensors to identify the locations of obstacles in the environment, and combines this with pressure sensors, image recognition modules, or infrared sensors to determine the type of floor material, thus distinguishing areas with different coefficients of friction, such as tiles, carpets, and wooden floors. The system then fuses and processes the collected environmental information to generate a two-dimensional raster map with influencing factors. The map uses grids as its basic unit. Each grid not only represents spatial location information but also includes two influencing factors closely related to the cleaning task: obstacle density, which is the proportion of obstacles per unit area. This is used in the subsequent weighted Voronoi region division process to perform "region reduction" processing on densely obstacle areas, thereby reducing path conflicts and energy consumption for the robot in complex areas. The ground friction coefficient reflects the impact of different ground materials on cleaning resistance. The map friction coefficient can be adjusted based on actual test data. For example, the coefficient can be set to 0.8 for tiles, 1.2 for carpets, and 1.0 for wooden floors. The ground friction coefficient can be used to estimate subsequent cleaning time and energy consumption, improving task balance and recharging safety.
[0026] After the environmental map is built, the robot uploads the generated weighted grid environment map to the cloud server via Wi-Fi, Bluetooth, or 5G communication modules. The cloud server performs integrity verification on the uploaded environmental map, including checking whether the map boundaries are closed, whether the obstacle positions are continuous and reasonable, and setting an error tolerance (e.g., 5cm) to eliminate the influence of sensor noise. If the environmental map verification fails, an error message is returned, prompting the robot to rebuild the map or calibrate the sensors.
[0027] For step S110, in this embodiment, the initial position coordinates of each robot on the map are... As the corresponding seed points, where i = 1, 2, ..., n, and n is the number of robots participating in the cleaning, the seed point set S can be represented as: This serves as the base set for subsequent weighted Voronoi partitioning.
[0028] If the initial location of the robot has been preset before deployment (such as near a charging station), the preset location can be used as the seed point. If some robots have not fully entered the map or the positioning is inaccurate, interpolation estimation can be performed by combining historical location information or the locations of adjacent robots.
[0029] Step S120: Based on the seed points, use weighted Voronoi algorithm to divide the environment into regions to obtain a clean region with the same number of seed points.
[0030] In the process of dividing the area, the weight of each cleaning area is dynamically adjusted according to environmental impact parameters (including but not limited to area, obstacle distribution, and ground friction coefficient) to make the area of each cleaning area tend to be balanced, and the boundary of each cleaning area is adjusted in combination with obstacle constraints.
[0031] After determining the seed point set S, a weighted Voronoi algorithm is used to divide the environment map into regions based on this seed point set, resulting in multiple cleaning areas equal to the number of seed points. Each cleaning area corresponds to one robot, ensuring the independence and rationality of task allocation. In this step, a weighting factor is introduced so that the division of each cleaning area not only considers the distance relationship between seed points but also dynamically adjusts based on the actual influencing factors of the cleaning task (such as area size, obstacle distribution, and ground material), thereby making each cleaning area more balanced in terms of area and cleaning time.
[0032] In some implementations, such as Figure 2 As shown, step S120 includes steps S210-S230: Step S210: Based on the seed points, the Voronoi algorithm is used to perform preliminary region division in the environment map to obtain a preliminary clean area equal to the number of seed points.
[0033] As an example, the basic Voronoi algorithm is first used to perform initial region partitioning of the environment map. The essence of Voronoi partitioning is to divide the entire two-dimensional environment map into several non-overlapping polygonal regions, each region being "dominated" by a seed point, that is, the distance from any point in the clean region to its seed point is less than or equal to the distance to all other seed points.
[0034] The basic Voronoi algorithm is defined as follows: In the formula, Let represent the initial cleaned area (i.e., the Voronoi region) corresponding to the i-th seed point, and P represent any point on the environment map. This represents the distance from point P to the seed point. The distance (Euclidean distance). This represents the distance (Euclidean distance) from point p to other seed points. This represents the distance from point p to the seed point. The distance to it is less than or equal to the distance to other seed points. If the distance is equal to the distance between the two points, then the point belongs to the range of the two points. .
[0035] This embodiment uses Voronoi's partitioning method to quickly divide the area in the environmental map into non-overlapping areas. However, it does not consider the actual influencing factors in the cleaning task, such as uneven area, uneven distribution of obstacles, and differences in ground material. Therefore, it is only used as a basis for preliminary partitioning.
[0036] Step S220: Weight each preliminary cleaning area is applied, and the weight of each preliminary cleaning area is dynamically adjusted according to the area, obstacle distribution, and ground friction coefficient to make the area of each preliminary cleaning area tend to be balanced.
[0037] In a demonstrative manner, after obtaining the initial division results, the system performs weighted processing on each region. The introduction of weights is to dynamically adjust the "range of influence" of each region in subsequent weighted Voronoi divisions, thereby achieving a balanced distribution of region area and reasonable optimization of task allocation. In this embodiment of weighted Voronoi division, the affiliation of each region depends not only on the Euclidean distance between its seed point and a point on the environmental map, but also on the region's weight. The larger the weight, the stronger the region's "affiliation tendency" to surrounding points, meaning that the region is more "easy" to attract surrounding points during the division process, thus expanding its coverage area; conversely, the smaller the weight, the weaker the region's "affiliation tendency," and its coverage area will correspondingly shrink. It can be understood that by dynamically adjusting the weights of each region, a state of area equilibrium can be gradually approached in multiple rounds of division, thereby avoiding situations where some robots have excessively heavy tasks while others have excessively light tasks, thus improving overall cleaning efficiency and the fairness of task allocation.
[0038] The factors influencing the weight adjustment include, but are not limited to, area area (to ensure that the area of each area is as close as possible to the average value), obstacle distribution (to appropriately reduce the weight in areas with dense obstacles to avoid the area being too large), and ground friction coefficient (because different ground materials affect cleaning energy consumption, so energy consumption balance is considered when adjusting the weight).
[0039] Step S230: Based on the adjusted weights, the weighted Voronoi algorithm is used to re-divide the environment map into regions to obtain a clean area equal to the number of seed points.
[0040] After adjusting the weights, this embodiment re-partitions the region based on the weighted Voronoi algorithm. Unlike the basic Voronoi partitioning, the weighted Voronoi partitioning introduces weight factors. This means that a region's "ownership" depends not only on distance, but also on its "attractiveness" or "influence".
[0041] The weighted Voronoi region can be defined as follows: ;in, Represents the i-th weighted Voronoi region; The weight represents the i-th clean region. The larger the weight, the stronger the "attractiveness" of the region, and the larger the area occupied by the region in the partitioning result. The smaller the weight, the weaker the "attractiveness" of the region, and the smaller the area occupied by the region in the partitioning result. Weights for other regions (used in conjunction with the current region weights) By comparing and determining which region point p should belong to, the aim is to ensure that the division of each clean region is based not only on distance but also on weight adjustment, thereby achieving area balance. This refers to the two-dimensional space encompassed by the environmental map.
[0042] This embodiment uses the weighted Voronoi algorithm to obtain clean areas with a relatively balanced area and reasonable task allocation, thus laying the foundation for subsequent Lloyd iteration optimization and task execution.
[0043] In some implementations, such as Figure 3 As shown, the boundaries of each clean area are adjusted based on obstacle constraints, including steps S310-S320: Step S310: Based on the location and distribution of obstacles, restrict the boundaries of each cleaning area to ensure that each cleaning area does not overlap with the area where the obstacles are located.
[0044] As an example, after completing the initial weighted Voronoi region division, a hard constraint condition of obstacles is further introduced to adjust the boundaries of the divided clean areas to ensure that each area does not overlap with the area where the obstacle is located.
[0045] Specifically, based on the obstacle information obtained during the SLAM mapping phase, an obstacle set O is constructed. Where m is the total number of obstacles. Represents the k-th obstacle (k The position of each obstacle can be determined by its center coordinates. and its enclosing radius describe.
[0046] During the weighted Voronoi region partitioning process, it is possible to determine whether any point P belongs to a certain clean region. Further judgment is needed, and the constraints that need to be met are: In the formula, For the i-th Voronoi region containing obstacle constraints, The constraint condition states that the distance from point p to the k-th obstacle must be greater than or equal to its radius; therefore, the above constraint condition means that if a point p is at any obstacle... The distance is less than its radius If the boundary of the cleaning area is not within an obstacle or too close to an obstacle, the robot will be excluded from all cleaning areas. This ensures that the boundary of the cleaning area does not enter the interior of the obstacle or get too close to the obstacle, thereby avoiding task interruption or efficiency reduction caused by path conflict or frequent obstacle avoidance during the cleaning process.
[0047] This rigid constraint mechanism ensures the accessibility and safety of each cleaning area, thereby improving the feasibility of subsequent path planning and task execution.
[0048] Step S320: Based on the obstacle penalty function, calculate the distance penalty value from each location point in the clean area to each obstacle, and combine it with the original distance from the location point to the corresponding seed point to determine the penalty distance from the location point to the corresponding seed point, so as to use the penalty distance for the weighted Voronoi algorithm to divide the region, so that the seed point is far away from the obstacle.
[0049] As an example, this embodiment further introduces an obstacle penalty function on top of the hard constraints to guide seed points away from areas with dense obstacles during the weighted Voronoi region partitioning process, thereby improving the rationality of region partitioning and the efficiency of path planning.
[0050] Specifically, for each location point p in the environment map, calculate its distance to each obstacle. The penalty value, which reflects the proximity of the point to the obstacle, can be expressed as: Where p represents any point on the environment map, This indicates the distance from point p to the obstacle. The central Euclidean distance, This indicates taking the maximum value. If the value is greater than 0, then the value is positive; otherwise, it is 0. This is understandable. The larger the value, the closer point p is to the center of the obstacle.
[0051] To enhance the impact of obstacles on region division, this embodiment squares the penalty values and then performs a weighted summation to obtain the total penalty intensity at that point. This total intensity is then incorporated into the distance calculation for weighted Voronoi region division. The penalty distance can then be determined using the following formula: ;in: This represents the distance from point p to the i-th seed point. The original Euclidean distance; This is the obstacle penalty coefficient, used to control the weight of the obstacle's influence in the overall distance calculation (for example, it can take a value of 10.0). This is understandable. The larger the obstacle, the stronger its influence, and the further away the area is from the obstacle. The smaller the value, the weaker the influence of obstacles, and the closer the partition is to the original weighted Voronoi. The squared term can cause the penalty value to increase rapidly as the seed point gets closer to the obstacle. It can be understood that the closer to the obstacle, the greater the penalty value, and it increases exponentially. This squared term can be used to strengthen the "repulsion" effect on obstacles and prevent the seed point from getting close to the obstacle. From point p to seed point The penalty distance is used to replace the original Euclidean distance in the weighted Voronoi region division.
[0052] This embodiment introduces a penalty distance mechanism, which applies a cost to areas close to obstacles during the area division process, thereby reducing the tendency of these areas to belong to other areas. This encourages seed points to move to more open areas and avoids them falling into areas with dense obstacles, thus improving the robot's path accessibility and task execution efficiency during the cleaning process.
[0053] In practical applications, the aforementioned penalty distance can be used. As the basis for determining point affiliation in the weighted Voronoi partitioning, the clean area to which each point belongs is recalculated, and the area boundaries are updated. This process is continuously performed in the Lloyd iterative optimization until the iteration termination condition is met (such as time balance or maximum number of iterations), thereby achieving dynamic adaptation, strong obstacle avoidance capability, and balanced task allocation in the multi-robot clean area partitioning.
[0054] In some implementations, the weights of each cleaning area are dynamically adjusted based on the area, obstacle distribution, and ground friction coefficient. Specifically, this includes: determining the weights of the current iteration based on the weights of the previous iteration, the current cleaning area, the average area of the area, and the smoothing coefficient at each iteration. The average area of the area is determined based on the total area, the area occupied by obstacles, the number of robots, and the ground friction coefficient corresponding to each grid. The current cleaning area is determined based on the number of grids contained in the current cleaning area and the ground friction coefficient corresponding to each grid.
[0055] As an example, in the t-th iteration, the weight corresponding to the i-th clean region This weight controls the influence range of the region in the weighted Voronoi partitioning. A larger weight indicates a stronger tendency for the region to belong to surrounding points, resulting in a larger coverage area; conversely, a smaller weight indicates a smaller influence. In the (t+1)th iteration, the weights can be updated using the following formula: ;in: This represents the weight of the i-th clean region in the t-th iteration; Let be the area of the cleaning area of the i-th cleaning area at the t-th iteration (i.e., the current cleaning area). The average area of the cleaned zone across all areas is currently being covered. ∈(0,1) is a smoothing coefficient used to control the magnitude of weight adjustment, preventing oscillations in the iteration process due to excessive weight changes, and maintaining the stability of the iteration process. It is usually taken as 0.3 to 0.5.
[0056] Based on the above weight update formula, it can be understood that if... > If the weight is too high, it indicates that the current allocated area of the region is too large, and its weight should be appropriately reduced so that its coverage area is reduced in the next round of allocation. Conversely, if the weight is too low, it indicates that the current allocated area of the region is too small, and its weight should be appropriately increased so that its coverage area is expanded in the next round of allocation.
[0057] The average area represents the average cleaning area that each cleaning robot should be allocated in the current environment. Its calculation considers not only the total cleaning area but also the effects of obstacle distribution and differences in ground material. The calculation formula is: In the formula, W represents the total area of the entire area to be cleaned; n is the number of robots currently participating in the cleaning task; and g represents the total area occupied by obstacles. Based on a comprehensive evaluation of obstacle density and ground friction coefficient, when determining the area occupied by obstacles, it is first necessary to determine the actual area occupied by obstacles. This can be determined based on the number of grids occupied by each obstacle during map construction. In addition, different ground materials can be used as simulated obstacles. For example, the material corresponding to each grid is determined during map construction, and its friction coefficient is also determined. For example, the friction coefficient of wood flooring is 1, the friction coefficient of tile is 0.8, and the friction coefficient of carpet is 1.2. When simulating obstacles, if it is tile, it will not be used as an obstacle. If it is carpet, its mapped obstacle area is determined based on the number of grids it occupies. If it is wood flooring, its mapped obstacle area is determined based on the number of grids it occupies. Finally, the total obstacle area is calculated. For example, if the total area comprises 100 grids, with real obstacles (such as flower pots and tables) occupying 20 grids and carpet occupying 10 grids, and based on the established mapping relationship between materials and simulated obstacles, the carpet maps to 2 simulated obstacle grids, resulting in a total of 22 obstacles occupying 22 grids. It's understandable that the above example of simulated obstacles is illustrative; the purpose of setting simulated obstacles is primarily to balance the cleaning difficulty between different materials.
[0058] The area to be cleaned is determined by the number of grids and the coefficient of friction of the ground corresponding to each grid. Similarly, the coefficient of friction of the ground corresponding to each grid can be mapped to simulated obstacles, and then the actual area to be cleaned can be determined. For example, if the area to be cleaned includes 30 grids, of which 10 grids are carpet, then the actual area to be cleaned can be the area corresponding to 32 grids.
[0059] By incorporating the ground friction coefficient, the actual cleaning difficulty can be included in the area assessment, avoiding a situation where "the area is balanced but the workload is unbalanced." For example, a smaller area covered with carpet may take more time and energy than a larger area with a tiled floor, so appropriate compensation should be made in the weighting adjustment.
[0060] Step S130: Update the centroid of each clean region to a new seed point, and re-divide the environment map using the weighted Voronoi algorithm based on the updated seed points. If the current division result does not meet the iteration cutoff condition, continue to update the seed points and re-divide the environment regions until the iteration cutoff condition is met.
[0061] As an example, after completing the current round of weighted Voronoi region partitioning and adjusting the clean area boundaries based on obstacle constraints, the process enters the Lloyd iteration optimization flow to further improve the balance of region partitioning and the rationality of task allocation. The core of this optimization flow is: based on the geometric center (centroid) position of each currently partitioned clean area, the corresponding seed point coordinates are updated, and based on the updated seed point set, the weighted Voronoi region partitioning is re-executed, thereby gradually approaching the goal of task time balance and region area balance.
[0062] The iteration cutoff conditions include: First, the maximum number of iterations is capped at a preset limit, such as 50. This prevents the algorithm from getting stuck in an infinite loop or running for an extended period of time.
[0063] Second, the maximum relative deviation between the cleaning time of each cleaning area and the average cleaning time of all cleaning areas is less than or equal to a preset threshold; where the preset threshold can be 10%. This cutoff condition can be expressed as: In the formula, Let i be the estimated cleaning time for the i-th cleaning area. This represents the average cleaning time for all cleaning areas. This cutoff condition reflects the requirement for task time balance in this embodiment, ensuring that there are no significant differences in task time among the various robots, thereby improving overall efficiency and recharging safety.
[0064] The cleaning time can be estimated by combining the number of grids in the cleaning area, the ground friction coefficient of each grid (to reflect the difference in cleaning resistance), the expected cleaning path length (estimated based on path planning algorithm), and hardware parameters such as robot movement speed and cleaning equipment power.
[0065] By further dividing the total cleaning area using the method described above in this embodiment, the difference in task time among each robot is controlled within a preset range, thereby avoiding the problem of some robots being overworked while others are too idle. Figure 4 As shown (where blue represents inaccessible areas (map boundaries), green represents accessible areas for the robot, and red represents obstacles), Figure 4 In (a), due to the uniform distribution of obstacles, the areas of each cleaned zone are approximately equal; while in... Figure 4 In (b), the obstacle density increases in the left region, causing the Voronoi boundary of the corresponding region to shrink to the left, resulting in a reduction in the clean area; Figure 4 In (c), an obstacle is added to the upper right region, which causes the seed point in the corresponding region to be affected by the obstacle penalty, and its clean area is further reduced, thereby realizing dynamic region division based on obstacle density. In summary, when the clean area is divided in this embodiment, the clean area area is relatively small in areas with more obstacles and relatively large in areas with fewer obstacles.
[0066] In some implementations, this embodiment also possesses the ability to respond to temporary obstacles in real time and update the global map. When the robot detects a temporary obstacle (such as a moving chair) during the cleaning process using LiDAR or a vision sensor, the system immediately initiates a local path replanning mechanism, employing the Dynamic Window Method (DWA) for obstacle avoidance. The dynamic window parameters can be set to a maximum linear velocity v_max = 0.5 m / s and ω_max = 1.2 rad / s to ensure that the robot can quickly bypass obstacles while maintaining motion stability. If the obstacle persists in the environment for more than 5 minutes, the system determines it to be a long-term obstacle and uploads the updated map information to the cloud via Wi-Fi or a 5G communication module, triggering a global map update process to ensure the accuracy and consistency of subsequent task allocation and path planning.
[0067] This embodiment achieves efficient cleaning area division for multiple robots in complex dynamic environments by introducing a weighted Voronoi partitioning algorithm combined with an obstacle penalty mechanism. The system first constructs an environmental map based on SLAM technology, incorporating influencing factors such as obstacle density and ground friction coefficient, providing multi-dimensional decision-making basis for subsequent area division. Based on this, a weighted Voronoi algorithm is used for area division. By dynamically adjusting the weights of each area, the cleaning task tends to be balanced in both area and energy consumption dimensions, avoiding the problem of some robots being overloaded or underloaded. Furthermore, combined with the Lloyd iterative optimization mechanism, the seed point positions of each area are continuously updated, gradually converging the division results to a time-equilibrium state, thereby improving overall operational efficiency and robot recharging safety. Simultaneously, by introducing hard constraints and penalty functions for obstacles, the system ensures that the divided cleaning areas avoid densely obstacle-prone areas, enhancing path accessibility and task execution stability.
[0068] Figure 5 A schematic diagram of a multi-robot cleaning area division device according to an embodiment of this application is shown. Exemplarily, the multi-robot cleaning area division device includes: The determination module 100 is used to determine the corresponding seed points based on the position coordinates of each robot in the environmental map; wherein each seed point corresponds to one robot. The partitioning module 200 is used to partition the environment region based on seed points using a weighted Voronoi algorithm to obtain a number of clean regions equal to the number of seed points. During the region partitioning, the weight of each clean region is dynamically adjusted according to environmental impact parameters to make the area of each clean region tend to be balanced, and the boundaries of each clean region are adjusted in combination with obstacle constraints. The iteration module 300 is used to update the centroid of each cleaning area to a new seed point, and re-divide the environmental map into regions based on the updated seed points using the weighted Voronoi algorithm. If the current division result does not meet the iteration cutoff condition, the seed points are updated and the environmental regions are re-divided until the iteration cutoff condition is met. The iteration cutoff condition is determined based on the cleaning time of each robot.
[0069] It is understood that the device in this embodiment corresponds to the multi-robot cleaning area division method in the above embodiments, and the options in the above embodiments are also applicable to this embodiment, so they will not be described again here.
[0070] This application also provides a multi-robot cleaning method, including: in response to a cleaning command, each robot obtains its own cleaning area based on the above-mentioned multi-robot cleaning area division method, and performs cleaning work according to the division result.
[0071] The cleaning command can be a command issued by the user through the terminal, or it can be automatically triggered by a timer. For example, it can be scheduled to clean once every 6 hours, and the cleaning work will be automatically triggered when the time is reached.
[0072] In this embodiment, after receiving the cleaning command, each robot begins cleaning the designated area. During the cleaning process, if a malfunction occurs (such as insufficient power or inability to move), a fault alarm will be issued directly so that the user can be notified immediately. After cleaning is completed, each robot will automatically return to the charging station to recharge.
[0073] This application also provides a terminal device, exemplary of which includes a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to enable the terminal device to perform the above-described multi-robot cleaning method or the above-described multi-robot cleaning area division method.
[0074] The processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, including at least one of a Central Processing Unit (CPU), Graphics Processing Unit (GPU), Network Processor (NP), Digital Signal Processor (DSP), Application-Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this application.
[0075] The memory can be, but is not limited to, Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), etc. The memory is used to store computer programs, and the processor can execute the computer programs accordingly after receiving execution instructions.
[0076] This application also provides a computer-readable storage medium for storing the computer program used in the aforementioned terminal device. For example, the computer-readable storage medium may include, but is not limited to, various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0077] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings show the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that, in alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and combinations of blocks in the block diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0078] In addition, the functional modules or units in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0079] If the aforementioned functions are implemented as software functional modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a smartphone, personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application.
[0080] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A method for dividing cleaning areas using multiple robots, characterized in that, include: Based on the position coordinates of each robot in the environmental map, corresponding seed points are determined; wherein, each seed point corresponds to one robot. Based on the seed points, a weighted Voronoi algorithm is used to divide the environment into clean areas to obtain a number of clean areas equal to the number of seed points. During the division, the weight of each clean area is dynamically adjusted according to environmental impact parameters to make the area of each clean area tend to be balanced, and the boundaries of each clean area are adjusted in combination with obstacle constraints. The centroid of each cleaning area is updated to a new seed point, and the environmental map is re-divided using the weighted Voronoi algorithm based on the updated seed points. If the current division result does not meet the iteration cutoff condition, the seed points are updated and the environmental area is re-divided until the iteration cutoff condition is met. The iteration cutoff condition is determined based on the cleaning time of each robot.
2. The multi-robot cleaning area division method according to claim 1, characterized in that, Before determining the corresponding seed point based on the position coordinates of each robot in the environmental map, the process also includes: Construct an environmental map of the required cleaning area with influencing factors; wherein, the influencing factors include obstacle density and ground friction coefficient, the obstacle density represents the proportion of obstacles per unit area, and the ground friction coefficient is set according to the ground material to reflect the difference in cleaning energy consumption.
3. The multi-robot cleaning area division method according to claim 1, characterized in that, The step of using a weighted Voronoi algorithm to partition the environment based on the seed points to obtain a clean region equal in number to the seed points includes: Based on the seed points, the Voronoi algorithm is used to perform preliminary region division in the environmental map to obtain a preliminary clean area equal to the number of seed points. Each of the preliminary cleaning areas is weighted, and the weight of each preliminary cleaning area is dynamically adjusted according to the area, obstacle distribution, and ground friction coefficient to make the area of each preliminary cleaning area tend to be balanced. Based on the adjusted weights, the weighted Voronoi algorithm is used to re-divide the environment map into regions to obtain a clean area equal to the number of seed points.
4. The multi-robot cleaning area division method according to claim 3, characterized in that, The method of dynamically adjusting the weight of each cleaning area based on the area, obstacle distribution, and ground friction coefficient includes: In each iteration, the weight of the current iteration is determined based on the weight of the previous iteration, the current cleaning area, the average area of the area, and the smoothing coefficient. The average area of the area is determined based on the total area of the area, the area occupied by obstacles, the number of robots, and the ground friction coefficient corresponding to each grid. The current cleaning area is determined based on the number of grids contained in the current cleaning area and the ground friction coefficient corresponding to each grid.
5. The multi-robot cleaning area division method according to claim 1, characterized in that, The adjustment of the boundaries of each of the cleaned areas in conjunction with obstacle constraints includes: Based on the location and distribution of obstacles, the boundaries of each cleaning area are restricted to ensure that each cleaning area does not overlap with the area where the obstacles are located; Based on the obstacle penalty function, the distance penalty value from each location point in the clean area to each obstacle is calculated, and combined with the original distance from the location point to the corresponding seed point, the penalty distance from the location point to the corresponding seed point is determined, so as to use the penalty distance for the region division of the weighted Voronoi algorithm, so that the seed point is far away from the obstacle.
6. The multi-robot cleaning area division method according to claim 1, characterized in that, The iteration cutoff condition includes the maximum relative deviation between the cleaning time of each cleaning area and the average cleaning time of all cleaning areas being less than or equal to a preset threshold.
7. A multi-robot cleaning method, characterized in that, include: In response to the cleaning command, each robot obtains its own cleaning area based on the multi-robot cleaning area division method according to any one of claims 1-6, and performs cleaning work according to the division results.
8. A multi-robot cleaning area division device, characterized in that, include: The determination module is used to determine corresponding seed points based on the position coordinates of each robot in the environmental map; wherein each seed point corresponds to one robot. The partitioning module is used to partition the environment region based on the seed points using a weighted Voronoi algorithm to obtain a number of clean regions equal to the number of seed points. During the region partitioning, the weight of each clean region is dynamically adjusted according to environmental influence parameters to make the area of each clean region tend to be balanced, and the boundaries of each clean region are adjusted in combination with obstacle constraints. The iteration module is used to update the centroid of each cleaning area to a new seed point, and re-divide the environmental map using the weighted Voronoi algorithm based on the updated seed points. If the current division result does not meet the iteration cutoff condition, the seed points are updated and the environmental area is re-divided until the iteration cutoff condition is met. The iteration cutoff condition is determined based on the cleaning time of each robot.
9. A terminal device, characterized in that, The terminal device includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the multi-robot cleaning area division method according to any one of claims 1-6 or the multi-robot cleaning method according to claim 7.
10. A computer-readable storage medium, characterized in that, It stores a computer program, which, when executed on a processor, implements the multi-robot cleaning area division method according to any one of claims 1-6 or the multi-robot cleaning method according to claim 7.