A multi-AGV path planning and obstacle avoidance method based on Petri net model
Through the path planning method based on the Petri net model, the path conflict problem in multi-AGV scenarios is solved, and efficient and stable obstacle avoidance path calculation is achieved, which is suitable for real-time dynamic path planning of multiple AGVs.
Patent Information
- Application Number
- CN202210196612.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-02
- Publication Date
- 2025-09-09
- Estimated Expiration
- 2042-03-02
AI Technical Summary
Existing path planning algorithms are difficult to effectively deal with route conflicts and node occupancy in multi-AGV scenarios. Static planning algorithms are prone to collisions, and dynamic planning algorithms have high computational complexity and are difficult to meet the real-time dynamic path planning requirements of multiple AGVs.
A path planning method based on the Petri net model is adopted. By recording the position and vacancy information of AGVs, a Petri net model of the intersection is established to distinguish three types of conflicts. The obstacle avoidance path is calculated through the reachability tree to realize the path planning of multiple AGVs.
It achieves stable and accurate efficient obstacle avoidance in multi-AGV scenarios. The algorithm has low time and space complexity and is suitable for path planning under real-time dynamic conditions.
Smart Images

Figure CN114740834B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of path planning, and in particular relates to a multi-AGV path planning and obstacle avoidance method based on a Petri net model. Background Art
[0002] With the rapid development of the intelligent manufacturing industry, automated guided vehicles (AGVs) have received widespread attention at home and abroad. They can be applied to assembly line manufacturing, logistics warehousing, environmental detection, scene modeling and other fields. They are key equipment for building intelligent manufacturing and automated production line systems, saving production and transportation costs while improving transportation efficiency.
[0003] Path planning is a key issue in AGV motion control technology. When multiple AGVs are operating simultaneously, the path planning for each AGV must take into account possible route conflicts and node occupancy. Existing path planning algorithms are mainly divided into static planning and dynamic planning. Static planning algorithms perform path planning before departure, but in actual implementation, they have difficulty dealing with various unexpected situations (such as power outages and unknown objects occupying the route), which can easily lead to AGV collisions and even path deadlocks. Dynamic planning algorithms (such as ant colony algorithms and genetic algorithms) have high computational complexity and slow convergence speed. They are mainly suitable for single AGV path planning and are difficult to meet the path planning requirements of multi-AGV scenarios. Summary of the Invention
[0004] In order to solve the problems existing in the above background technology, the purpose of the present invention is to provide a multi-AGV path planning and obstacle avoidance method based on the Petri net model.
[0005] To this end, the present invention adopts the following technical solutions:
[0006] A multi-AGV path planning and obstacle avoidance method based on a Petri net model is characterized in that: the Petri net model is applicable to a situation where two AGVs collide at an intersection, the path planning is applicable to planning of discrete steps, the collision will occur within two steps, and the method comprises the following steps:
[0007] Step 1: Record the original driving paths and vacant space information of the two AGVs. This step is mainly implemented by the following sub-steps:
[0008] Step 1.1: Record the current position, next position, and next position of AGV1 into path1, and record the current position, next position, and next position of AGV2 into path2, obtaining two arrays path1 and path2.
[0009] Step 1.2: Record the positions at each intersection that are not used by path1 and path2, and store them in the AvailablePlace array. This array can be empty.
[0010] Step 2: Establish a Petri net model of AGVs meeting at the intersection. This step is mainly implemented by the following sub-steps:
[0011] Step 2.1: Let the library S = {S1, S2} represent the set of locations that the AGV has passed through in the map, where S1 = {s1, s2, s3} corresponds to the location path1 that AGV1 has passed through, and S2 = {s4, s5, s6} corresponds to the location path2 that AGV2 has passed through;
[0012] Step 2.2: With the identifier M = {m1, m2, ..., m n} represents the AGV position set, m i =1 means there is an AGV at the i-th position, and M0 represents the positions of all AGVs in the initial state;
[0013] Step 2.3: With transition T = {t1, t2, ..., t n} indicates that the AGV moves from one position to another, such as: M0[t1>M1 and M0≠M1, which means that the position of the AGV has changed after the transformation of t1, and M1 represents the position of all AGVs after the transformation;
[0014] Step 3: The conflict types between the two AGVs are divided into three categories: if the two AGVs do not travel in opposite directions throughout their original routes, it is recorded as a first-type conflict; if the two AGVs travel in opposite directions for half of their original routes, it is recorded as a second-type conflict; if the two AGVs travel in opposite directions for the entire original routes, it is recorded as a third-type conflict;
[0015] Step 4: Determine the type of conflict between the two vehicles based on path 1 and path 2 in step 3. This step is mainly implemented by the following sub-steps:
[0016] Step 4.1: Reverse the order of the elements in path2 to obtain path2′. For example, if path2 = [A, B, C], reverse it to path′2 = [C, B, A];
[0017] Step 4.2: If path1 = path2′, then the two vehicles are traveling towards each other throughout the entire journey, which is a third type of conflict, and the judgment is exited;
[0018] Step 4.3: If path1[1] = path′2[1] or path1[3] = path′2[3], then the two vehicles are traveling towards each other halfway, which is a second type of conflict, and the judgment is exited;
[0019] Step 4.4: The two vehicles are not traveling in opposite directions at all times, which is a Type 1 conflict.
[0020] Step 5: Solve the reachable tree based on the conflict type. This step is mainly implemented by the following sub-steps:
[0021] Step 5.1: Input the Petri net model constructed by the present invention;
[0022] Step 5.2: Determine T i Are all t i =0, if yes, go to step 5.7; if no, go to step 5.3;
[0023] Step 5.3: Record T i The position of the element that is not 0 in t en ;
[0024] Step 5.4: If it is a first type conflict or a second type conflict, en Take out the first unused element from t to make the transition; if it is the third type conflict, en Take out the last unused element to make a transition; transition method: M i+1 =M i +(IO)*T;
[0025] Step 5.5: Remember M i+1 The parent node is M i ;
[0026] Step 5.6: According to M i+1 and (IO) calculate the new T i , recursively enter step 4.1;
[0027] Step 5.7: Output the reachable tree and end the recursion;
[0028] Step 6: Calculate the path plan with obstacle avoidance based on the reachability tree. This step is mainly implemented by the following sub-steps:
[0029] Step 6.1: Let P1 = [M i (1) M i (2) M i (3)], P2=[M i (4) M i (5) M i (6)];
[0030] Step 6.2: From i=1 to the end, calculate p1=path1*P′1 and p2=path2*P′2 each time;
[0031] Step 6.3: If p1 = 0 or p2 = 0, assign the first element value of the AvailablePlace array to p1 or p2;
[0032] Step 6.4: Each time p1 is connected, the path planning of AGV1 is obtained, and each time p2 is connected, the path planning of AGV2 is obtained.
[0033] This paper provides a multi-AGV path planning and obstacle avoidance method based on a Petri net model. This method identifies intersection conflict types based on the Petri net model and proposes a complete path planning method to achieve conflict avoidance. This method can be used for obstacle avoidance planning in multi-AGV scenarios. The algorithm has low time and space complexity and is adaptable to path planning calculations under real-time dynamic conditions. Experimental results demonstrate the stability and accuracy of this method. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] Figure 1 This is an overall flow chart of the multi-AGV path planning and obstacle avoidance method based on the Petri net model provided by the present invention.
[0035] Figure 2 This is the intersection model to which the present invention is applicable.
[0036] Figure 3 For the present invention, the Petri net concept is used to represent the intersection.
[0037] Figure 4 This is the Petri net model constructed by the present invention.
[0038] Figure 5 This is the Petri net reachable tree calculated by the present invention.
[0039] Figure 6 This is the process of calculating path planning in the present invention.
[0040] Figure 7 This is one of the path planning results calculated by the present invention, and the 5-step path planning achieves obstacle avoidance.
[0041] Figure 8 This is the second path planning result calculated by the present invention, 7-step path planning to achieve obstacle avoidance. DETAILED DESCRIPTION
[0042] The present invention will be further described below in conjunction with the accompanying drawings and specific examples. It should be understood that the following specific embodiments are intended to illustrate the present invention and are only preferred embodiments of the present invention, rather than limiting the present invention. Within the spirit of the present invention and the scope of protection of the claims, any modifications, equivalent substitutions, improvements, etc. made to the present invention fall within the scope of protection of the present invention.
[0043] Combine Figure 1 The overall flow chart of the multi-AGV path planning and obstacle avoidance method based on the Petri net model is shown in the figure. The specific implementation steps are described as follows:
[0044] Step 1: If Figure 2 At the intersection shown, AGV1 is now at position p1, with its target position being p2. AGV2 is now at position p4, with its target position being p1. If the two vehicles depart at the same time, a conflict will occur at position p3. Therefore, the order of departure needs to be controlled to achieve obstacle avoidance: ① If AGV1 goes first, AGV2 starts after AGV1 passes position p3, and both vehicles can pass smoothly; ② If AGV2 goes first, AGV1's position is now AGV2's target position, and AGV1 cannot give way. To avoid deadlock, AGV2 can first move to position p5, which neither vehicle passes through, to give way. Then AGV1 departs and passes position p3 to continue forward, and then AGV2 returns to position p3 and moves to target position p1. This departure order can also achieve obstacle avoidance for both vehicles, but its efficiency is significantly lower than the first departure order.
[0045] To provide the driving sequence using the Petri net model, record the path path1 of AGV1 = [p1 p3 p2], record the path path2 of AGV2 = [p4 p3 p1], and the array AvailablePlace = [p5]
[0046] Step 2: If Figure 3 As shown, place S1 = {s1, s2, s3} represents path1, place S2 = {s4, s5, s6} represents path2, and the identifier M = {m1, m2, m3, m4, m5, m6} represents the AGV position set. The initial state M1 = {1, 0, 0, 1, 0, 0} indicates that there are AGVs at positions s1 and s4; the transition T = {t1, t2, t3, t4} represents the movement of AGV from one position to another. If the transition t1 occurs, we get: M1[t1>M2, M2={0 1 0 1 0 0}] indicates that there are AGVs at positions s2 and s4.
[0047] Step 3: The conflict types between the two AGVs are divided into three categories: if the two AGVs do not travel in opposite directions throughout their original routes, it is recorded as a first-type conflict; if the two AGVs travel in opposite directions for half of their original routes, it is recorded as a second-type conflict; if the two AGVs travel in opposite directions for the entire original routes, it is recorded as a third-type conflict.
[0048] Step 4: Flip and get path′2=[p1 p3 p4]. We know that path1[1]=path′2[1]. The two vehicles are traveling towards each other halfway, which is a second type of conflict.
[0049] Step 5: Input the Petri net model constructed by the present invention, such as Figure 4 As shown, its mathematical expression is ∑=(S,T,I,O,M), where:
[0050] S=[s1 s2 s3 s4 s5 s6 s7 s8 s9 s 10 ]′
[0051] T=[t1 t2 t3 t4 t5 t6]′
[0052] M=[1 0 0 1 0 0 1 1 0 0]′
[0053]
[0054]
[0055] In the initial state, M1=[1 0 0 1 0 0 1 1 0 0]′, T1=[1 0 1 0 0 0]′, record t en =
[13] , indicating that t1=t3=1. First, let t1 undergo a transition, and we get: M2=[0 1 0 1 0 0 0 1 0 1]′, T2=[0 1 0 0 00]′. At this time, only t2=1 in the transition; let t2 undergo a transition, and we get: M3=[0 0 1 1 0 0 1 1 0 1]′, T3=[0 01 0 0 0]′. At this time, only t3=1 in the transition; let t3 undergo a transition, and we get: M4=[0 0 1 0 1 0 0 1 0 1]′, T4=[0 0 0 1 0 0]′. At this time, only t4=1 in the transition; let t4 undergo a transition, and we get: M5=[0 0 1 0 0 1 1 1 00]′, T5=[0 0 0 0 0 0]′, at this time no transition can occur and the traversal ends.
[0056] If t3 is taken to change first in the initial state M1, avoidance can also be achieved, but more steps are required: take t3 to change, and get: M6 = [1 0 0 0 1 0 0 1 0 0]′, T6 = [0 0 0 0 1 0]′, at this time only t5 = 1 in the transition; take t5 to change, and get: M7 = [1 0 0 0 0 0 1 0 1 0]′, T7 = [1 0 0 0 0 0]′, at this time only t1 = 1 in the transition; take t1 to change, and get: M8 = [0 1 0 0 0 0 0 0 1 1]′, T8 = [0 1 0 0 0 0]′, at this time only t2 = 1 in the transition; take t2 to change, and get: M9 = [0 0 1 0 0 0 1 0 1 1]′, T9=[0 0 0 0 01]′, at this time only t6=1 in the transition; take t6 to change, and get: M4=[0 0 1 0 1 0 0 1 0 1]′, T4=[0 00 1 0 0]′, at this time only t4=1 in the transition; take t4 to change, and get: M5=[0 0 1 0 0 1 1 1 0 0]′, T5=[0 0 0 0 0 0]′, at this time no transition can occur, and the traversal ends.
[0057] In summary, the reachable tree obtained by the two traversals is as follows Figure 5 shown.
[0058] Step 6: Calculate p1=path1*S1 and p2=path2*S2 each time. The calculation process is as follows: Figure 6 As shown in the figure, when the AGV position is "none", the first element in AvailablePlace, i.e. p5, is replaced. The final path planning result is as follows: Figure 7 、 Figure 8 shown. Figure 7 In the first three steps, AGV2 waits at the starting point p4, while AGV1 moves from p1 to p3 and then to p2. From the fourth step, AGV2 starts to move, and the two vehicles avoid collision. Figure 8 In the first three steps, AGV1 waits at the starting point p1, AGV2 moves from p4 to p3 and then to p5, AGV2 waits at p5 in the 3rd to 5th steps, AGV1 moves from p1 to p3 and then to p2, and in the last three steps, AGV2 moves from p5 to p3 and then to p1. The two vehicles also achieve conflict avoidance.
[0059] Both solutions achieve path planning and obstacle avoidance, as expected. However, the first solution requires only five steps, while the second solution requires seven. This example demonstrates both solutions. When applied to path planning, selecting the transition sequence based on the conflict type yields the simplest path.
Claims
1. A multi-AGV path planning and obstacle avoidance method based on a Petri net model, characterized by: The Petri net model is applicable to a situation where two AGVs collide at an intersection. The path planning is applicable to planning of discrete steps. The conflict will occur within two steps. The method includes the following steps: Step 1: Record the original driving paths and vacant space information of the two AGVs; Step 1 is mainly implemented by the following sub-steps: Step 1.1: Record the current position, next position, and next position of AGV1 into path1, and record the current position, next position, and next position of AGV2 into path2, obtaining two arrays path1 and path2. Step 1.2: Record the positions at each intersection that are not used by path1 and path2, and store them in the AvailablePlace array. This array can be empty. Step 2: Build a Petri net model of AGVs meeting at the intersection; Step 2 is mainly implemented by the following sub-steps: Step 2.1: Let the library S = {S1, S2} represent the set of locations that the AGV has passed through in the map, where S1 = {s1, s2, s3} corresponds to the location path1 that AGV1 has passed through, and S2 = {s4, s5, s6} corresponds to the location path2 that AGV2 has passed through; Step 2.2: With the identifier M={m1,m2,…,m n } represents the AGV position set, m i =1 means there is an AGV at the i-th position, and M0 represents the positions of all AGVs in the initial state; Step 2.3: Take transition T = {t1, t2, …, t n } indicates that the AGV moves from one position to another. After t1 transformation, the position of the AGV changes, which is expressed as: M0[t1>M1 and M0≠M1, where M0 represents the position of all AGVs before the transformation and M1 represents the position of all AGVs after the transformation; Step 3: The conflict types between the two AGVs are divided into three categories: if the two AGVs do not travel in opposite directions throughout their original routes, it is recorded as a first-type conflict; if the two AGVs travel in opposite directions for half of their original routes, it is recorded as a second-type conflict; if the two AGVs travel in opposite directions for the entire original routes, it is recorded as a third-type conflict; Step 4: Determine the type of conflict between the two vehicles based on the path 1 and path 2 of AGV1 in step 3. Step 4 is mainly implemented by the following sub-steps: Step 4.1: Reverse the order of the elements in path2 to obtain path2′. For example, if path2 = [A, B, C], reverse it to path′2 = [C, B, A]; Step 4.2: If path1 = path2′, then the two vehicles are traveling towards each other throughout the entire journey, which is a third type of conflict, and the judgment is exited; Step 4.3: If path1[1] = path′2[1] or path1[3] = path′2[3], then the two vehicles are traveling towards each other halfway, which is a second type of conflict, and the judgment is exited; Step 4.4: The two vehicles are not traveling in opposite directions at all times, which is a Type 1 conflict. Step 5: Solve the reachable tree according to the conflict type; Step 6: Calculate the path planning with obstacle avoidance based on the reachability tree.
2. The Petri net model-based multi-AGV path planning and obstacle avoidance method according to claim 1, characterized in that: Step 5 is mainly implemented by the following sub-steps: Step 5.1: Input the Petri net model constructed by the present invention; Step 5.2: Determine T i Are all t i =0, if yes, go to step 5.7; if no, go to step 5.3; Step 5.3: Record T i The position of the element that is not 0 in en ; Step 5.4: If it is a first type conflict or a second type conflict, en Take out the first unused element to make the transition; If it is a third type conflict, from t en Take out the last unused element to make a transition; transition method: M i+1 =M i +(IO)*T; Step 5.5: Remember M i+1 The parent node is M i ; Step 5.6: According to M i+1 and (IO) calculate the new T i , recursively enter step 4.1; Step 5.7: Output the reachable tree and end the recursion.
3. The Petri net model-based multi-AGV path planning and obstacle avoidance method according to claim 1, characterized in that: Step 6 is mainly implemented by the following sub-steps: Step 6.1: Let P1 = [M i (1)M i (2)M i (3)], P2=[M i (4)M i (5)M i (6)]; Step 6.2: From i=1 to the end, calculate p1=path1*P′1 and p2=path2*P′2 each time; Step 6.3: If p1 = 0 or p2 = 0, assign the first element value of the AvailablePlace array to p1 or p2; Step 6.4: Each time p1 is connected, the path planning of AGV1 is obtained, and each time p2 is connected, the path planning of AGV2 is obtained.