A deadlock avoidance method considering multiple vehicle travel directions at unsignalized intersections

By dividing the right points of the road in a signal-free intersection and establishing a Petri network model, the vehicle is encoded and decoded, the scheduling sequence is generated and the scheduling sequence is repaired, and the problems of vehicle deadlock and cycle waiting are improved, and the space utilization rate of the intersection is improved.

CN119007437BActive Publication Date: 2025-08-19NANTONG UNIV
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411055986.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-02
Publication Date
2025-08-19
Estimated Expiration
2044-08-02

AI Technical Summary

Technical Problem

The existing signal-free vehicle scheduling method cannot effectively avoid deadlocks and cycle waiting between vehicles, especially between vehicles in multiple driving directions, resulting in low cross-intersection space utilization.

Method used

By dividing the road weight points at the signal-free intersection, establishing a Petri network model, encoding and decoding the vehicle, generating a scheduling coded sequence and decoding it into a scheduling change sequence, determining the order of the vehicle and whether a deadlock will occur, and repairing the scheduling sequence to ensure that the vehicle passes through the intersection smoothly.

Benefits of technology

The vehicle passes through the intersection in the order of arrival, avoiding deadlocks between the same lane and different lanes, and improving the utilization rate of the intersection space.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119007437B_ABST
    Figure CN119007437B_ABST
Patent Text Reader

Abstract

The present invention belongs to the field of intelligent transportation, and specifically relates to a deadlock avoidance method for an unsignaled intersection that takes into account multiple vehicle travel directions. The method comprises the following steps: S1, dividing the right-of-way points in the unsignaled intersection and establishing a Petri net model; S2, encoding the vehicles to be entered into the intersection and randomly generating a scheduling code sequence, decoding the scheduling code sequence into a scheduling transition sequence; S3, judging whether the order of vehicles in the same lane is satisfied by the scheduling code sequence, and judging whether deadlock occurs between vehicles in different lanes by the scheduling transition sequence. If the order of vehicles in the same lane is not satisfied or deadlock occurs between vehicles in different lanes, the codes and transitions that meet the conditions after the current position are replaced with those at the current position. In order to solve the problem of vehicle passage at an unsignaled intersection, the vehicles are encoded, decoded and repaired, so that the scheduling sequence satisfies the unchanged order of vehicle passage in each lane and avoids deadlock between vehicles in different lanes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of intelligent transportation, and in particular relates to a deadlock avoidance method at an unsignalized intersection taking into account multiple driving directions of vehicles. Background Art

[0002] Existing intersection control systems rely on traffic lights to schedule vehicles arriving at an intersection. This is a passive scheduling strategy that cannot adapt to real-time traffic flows. With the advent of intelligent connected vehicles, unsignalized intersection traffic flow strategies have become possible. Intelligent connected vehicles can exchange information with the outside world through vehicle-to-vehicle (V2X) technology. In autonomous driving mode, they can analyze real-time traffic information and make corresponding adjustments. Compared to traditional signal light control methods, this method adjusts vehicle scheduling based on real-time traffic flows, improving intersection space utilization. Outside the intersection, vehicles wait to pass through the intersection in a sequential order, and vehicles traveling in different directions may exist in the same lane. Vehicles admitted to the intersection compete for right-of-way points, which can lead to circular waiting. Each vehicle waits for the next vehicle to release a required right-of-way point while simultaneously occupying the right-of-way points of other vehicles. Therefore, a reasonable vehicle passage sequence is necessary to avoid this phenomenon. Summary of the Invention

[0003] The purpose of the present invention is to overcome the shortcomings of the existing technology and propose a deadlock avoidance method for unsignalized intersections that takes into account multiple vehicle travel directions. The vehicle is encoded, decoded and repaired to solve the vehicle passage problem at unsignalized intersections, so that the scheduling sequence satisfies the unchanged passage order of vehicles with different travel directions on each lane and avoids deadlock between vehicles in different lanes.

[0004] In order to achieve the above-mentioned purpose, the present invention adopts the following technical solutions:

[0005] A deadlock avoidance method for an unsignalized intersection taking into account multiple vehicle travel directions comprises the following steps:

[0006] S1. Divide the right-of-way points in the unsignalized intersection and establish a Petri net model;

[0007] S2. Encode the vehicles to enter the intersection and randomly generate a dispatch code sequence, and decode the dispatch code sequence into a dispatch transition sequence;

[0008] S3. Determine whether the order of vehicles in the same lane is met through the scheduling code sequence, and determine whether a deadlock occurs between vehicles in different lanes through the scheduling transition sequence. If the order of vehicles in the same lane is not met or a deadlock occurs between vehicles in different lanes, replace the code and transition that meet the conditions after the current position with the current position.

[0009] As a preferred technical solution of the present invention, in S1: the intersection space is divided into c_num right-of-way points, and the number of right-of-way points on the left-turn, straight-ahead and right-turn paths are num_L, num_S, and num_R respectively; P is 、P if represents the waiting area and departure area for vehicles in lane i; P iLa 、P iRb 、P iLc , where 1≤a≤num_L, 1≤b≤num_S, 1≤c≤num_R, respectively represent the positions of the right-of-way points on the corresponding paths for vehicles turning left, going straight, and turning right in lane i; T iLe 、T iSf 、T iRg , where 1≤e≤num_L+1, 1≤f≤num_S+1, and 1≤g≤num_R+1 represent the vehicle actions of the vehicle turning left, going straight, and turning right in lane i on the corresponding path, respectively.

[0010] As a preferred technical solution of the present invention, in S2: the vehicle code consists of "lane number. Driving direction. Position"; the lane number is the lane number where the current vehicle is located, the driving directions including left turn, straight ahead, and right turn are represented by "1", "2", and "3" respectively, and the position is the order of the current vehicle in the lane; the dispatch code sequence is obtained by expanding the vehicle code and randomly shuffling it; the dispatch change sequence and the dispatch code sequence are in a one-to-one correspondence, indicating the vehicle action to be performed by the current vehicle.

[0011] As a preferred technical solution of the present invention, S3 includes the following steps:

[0012] S3.1. Initialize the table Input_car for vehicles about to enter the intersection and initialize Car_now for vehicles that have not yet left the intersection, setting Car_now = Input_car. Generate the dispatch code sequence Encode according to S2 and decode it into the dispatch transition sequence Decode. Place Encode and Decode results that have been judged to be completed into Encode_finish and Decode_finish, respectively. Use Mark_save to store the mark after the transition is triggered.

[0013] S3.2. Set i = 0. If i < scheduling sequence length, proceed to S3.8; otherwise, proceed to S3.14.

[0014] S3.3. Record the judgment position Judge = i;

[0015] S3.4. Find the vehicle Pre_car in Car_now that is ahead of the current vehicle Encode[Judge];

[0016] S3.5. Determine whether the order of vehicles in the same lane is met by using the dispatch code sequence;

[0017] S3.5.1. Determine whether Encode[Judge] is the first car in Pre_car. If so, proceed to S3.7; otherwise, proceed to S3.5.2.

[0018] S3.5.2. The number of times Pre_car appears in Encode_finish is recorded as Pre_num, and the number of times Encode[Judge] appears in Encode_finish is recorded as now_num. If Pre_num ≥ now_num + 1, proceed to S3.7; otherwise, proceed to S3.6.

[0019] S3.6, Judge = Judge + 1, proceed to S3.3;

[0020] S3.7. Determine whether Decode[Judge] can be triggered under the flag Mark_save[Judge]. If it can, proceed to S3.8; otherwise, proceed to S3.6.

[0021] S3.8. Determine whether vehicles in different lanes will cause a deadlock;

[0022] S3.8.1. Determine whether Decode[Judge] is the last transition of Encode[Judge]. If so, proceed to S3.7; otherwise, proceed to S3.8.2.

[0023] S3.8.2. Let r represent the previous resource repository of Decode[Judge]. Under the mark Mark_save[Judge], the transition Decode[Judge] is triggered to obtain the new mark Ms. T1 is the set of transitions that can increase the resource repository r under the mark Ms. Sets T2 and T3 are initialized as

[0024] S3.8.3. Determine whether there are unique sets in sets T1 and T2. If so, proceed to S3.8.4. Otherwise, output that a deadlock has been detected and proceed to S3.6.

[0025] S3.8.4. Take a t from the set that does not overlap T1 and T2 and determine whether t is the last transition of Encode[Judge]. If so, output it so that deadlock will not occur. Otherwise, proceed to S3.8.5.

[0026] S3.8.5. Let r represent the preceding resource location of t. Determine whether the number of tokens in r in Ms is 1. If it is 1, output that no deadlock will occur. Otherwise, proceed to S3.8.6.

[0027] S3.8.6. Store T3 under the tag Ms to add the set of transitions to the repository. Add the transitions in T3 that are not duplicates of T1 to T1 and proceed to S3.8.3.

[0028] S3.9. Determine whether Judge is equal to i. If so, proceed to S3.11; otherwise, proceed to S3.10.

[0029] S3.10. Move the element at the Judge position in Encode and Decode to the front of the i position.

[0030] S3.11. Determine whether the current vehicle Encode[Judge] has left the intersection. If so, proceed to S3.12; otherwise, proceed to S3.13.

[0031] S3.12. Delete the current vehicle Encode[Judge] from Car_now;

[0032] S3.13. Add the identifier Ms to Mark_save, add Encode[i] and Encode[i] to Encode_finish and Decode_finish respectively, set i = i + 1, and proceed to S3.2;

[0033] S3.14. Output Encode_finish and Decode_finish.

[0034] The deadlock avoidance method for an unsignalized intersection taking into account multiple vehicle travel directions according to the present invention has the following technical effects compared with the prior art:

[0035] (1) The present invention realizes the specific order and vehicle actions of each vehicle passing through the intersection by encoding and decoding the vehicles.

[0036] (2) After the vehicle sequence and deadlock are repaired, the scheduling sequence satisfies the requirement that vehicles in different directions in the same lane pass through the intersection in the order of arrival and no circular waiting occurs in the intersection, so vehicles can pass through the intersection smoothly. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] Figure 1 is a flow chart of the method of the present invention;

[0038] Figure 2 is a Petri net model of an unsignalized intersection in a specific example of the present invention;

[0039] Figure 3 Schematic diagram of scheduling sequence repair in a specific example of the present invention. DETAILED DESCRIPTION

[0040] In order to enable those skilled in the art to better understand the technical solutions in the embodiments of the present application, some symbols in the embodiments of the present application are first explained to facilitate understanding by those skilled in the art.

[0041] like Figure 1 As shown, a deadlock avoidance method for an unsignalized intersection considering multiple vehicle travel directions includes the following steps: S1, dividing the right-of-way points in the unsignalized intersection and establishing a Petri net model;

[0042] S2. Encode the vehicles to enter the intersection and randomly generate a dispatch code sequence, and decode the dispatch code sequence into a dispatch transition sequence;

[0043] S3. Determine whether the order of vehicles in the same lane is met by dispatching the code sequence, and determine whether a deadlock occurs between vehicles in different lanes by dispatching the transition sequence. If the order of vehicles in the same lane is not met or a deadlock occurs between vehicles in different lanes, replace the code and transition that meet the conditions after the current position with the current position;

[0044] In S1: the intersection space is divided into c_num right-of-way points, and the number of right-of-way points on the left-turn, straight-ahead, and right-turn paths are num_L, num_S, and num_R respectively; P is 、P if represents the waiting area and departure area for vehicles in lane i; P iLa 、P iRb 、P iLc (where 1≤a≤num_L, 1≤b≤num_S, 1≤c≤num_R) respectively represent the locations of the right-of-way points on the corresponding paths for vehicles turning left, going straight, and turning right in lane i. iLe 、T iSf 、T iRg (where 1≤e≤num_L+1, 1≤f≤num_S+1, 1≤g≤num_R+1) represent the vehicle actions of the vehicle in lane i turning left, going straight, and turning right on the corresponding path, respectively;

[0045] In S2, the vehicle code consists of "lane number, driving direction, and position". The lane number is the lane number of the current vehicle. The driving directions (left turn, straight ahead, and right turn) are represented by "1", "2", and "3" respectively. The position is the order of the current vehicle in the lane. The dispatch code sequence is obtained by expanding and randomly shuffling the vehicle code. The dispatch transition sequence corresponds one-to-one with the dispatch code sequence, indicating the vehicle action to be performed by the current vehicle.

[0046] S3 includes the following steps:

[0047] S3.1. Initialize the table Input_car for vehicles about to enter the intersection and initialize Car_now for vehicles that have not yet left the intersection, setting Car_now = Input_car. Generate the dispatch encoding sequence Encode according to S2 and decode it into the dispatch transition sequence Decode. Place Encode and Decode results that have been determined to be completed into Encode_finish and Decode_finish, respectively. Use Mark_save to store the mark after the transition is triggered.

[0048] S3.2. Set i = 0. If i < scheduling sequence length, proceed to S3.8; otherwise, proceed to S3.14.

[0049] S3.3. Record the judgment position Judge = i;

[0050] S3.4. Find the vehicle Pre_car in Car_now that is ahead of the current vehicle Encode[Judge];

[0051] S3.5. Determine whether the order of vehicles in the same lane is met by using the dispatch code sequence;

[0052] S3.5.1. Determine whether Encode[Judge] is the first car in Pre_car. If so, proceed to S3.7; otherwise, proceed to S3.5.2.

[0053] S3.5.2. The number of times Pre_car appears in Encode_finish is recorded as Pre_num, and the number of times Encode[Judge] appears in Encode_finish is recorded as now_num. If Pre_num ≥ now_num + 1, proceed to S3.7; otherwise, proceed to S3.6.

[0054] S3.6, Judge = Judge + 1, proceed to S3.3;

[0055] S3.7. Determine whether Decode[Judge] can be triggered under the flag Mark_save[Judge]. If it can, proceed to S3.8; otherwise, proceed to S3.6.

[0056] S3.8. Determine whether vehicles in different lanes will cause a deadlock;

[0057] S3.8.1. Determine whether Decode[Judge] is the last transition of Encode[Judge]. If so, proceed to S3.7; otherwise, proceed to S3.8.2.

[0058] S3.8.2. Let r represent the previous resource repository of Decode[Judge]. Under the mark Mark_save[Judge], the transition Decode[Judge] is triggered to obtain the new mark Ms. T1 is the set of transitions that can increase the resource repository r under the mark Ms. Sets T2 and T3 are initialized as ;

[0059] S3.8.3. Determine whether there are unique sets in sets T1 and T2. If so, proceed to S3.8.4. Otherwise, output that a deadlock has been detected and proceed to S3.6.

[0060] S3.8.4. Take a t from the set that does not overlap T1 and T2 and determine whether t is the last transition of Encode[Judge]. If so, output it so that deadlock will not occur. Otherwise, proceed to S3.8.5.

[0061] S3.8.5. Let r represent the preceding resource location of t. Determine whether the number of tokens in r in Ms is 1. If it is 1, output that no deadlock will occur. Otherwise, proceed to S3.8.6.

[0062] S3.8.6. Store T3 under the tag Ms to add the set of transitions to the repository. Add the transitions in T3 that are not duplicates of T1 to T1 and proceed to S3.8.3.

[0063] S3.9. Determine whether Judge is equal to i. If so, proceed to S3.11; otherwise, proceed to S3.10.

[0064] S3.10. Move the element at the Judge position in Encode and Decode to the front of the i position.

[0065] S3.11. Determine whether the current vehicle Encode[Judge] has left the intersection. If so, proceed to S3.12; otherwise, proceed to S3.13.

[0066] S3.12. Delete the current vehicle Encode[Judge] from Car_now;

[0067] S3.13. Add the identifier Ms to Mark_save, add Encode[i] and Encode[i] to Encode_finish and Decode_finish respectively, set i = i + 1, and proceed to step 3.2.

[0068] S3.14, output Encode_finish and Decode_finish;

[0069] When implementing it specifically, Figure 2As shown, taking a two-way two-lane road as an example, the intersection is divided into four right-of-way points.

[0070] 1) Divide the intersection space into c_num = 4 right-of-way points, with the number of right-of-way points on the left-turn, straight-ahead, and right-turn paths being num_L = 3, num_S = 2, and num_R = 1, respectively.

[0071] 2) The vehicle code consists of "lane number, driving direction, and position." The lane number is the lane number of the current vehicle. The driving directions (left turn, straight ahead, and right turn) are represented by "1," "2," and "3," respectively. The position is the order of the current vehicle in the lane. The dispatch code sequence is obtained by expanding and randomly shuffling the vehicle code. The dispatch transition sequence corresponds one-to-one to the dispatch code sequence, indicating the vehicle action to be performed by the current vehicle. 3)

[0073] 3.1) Initialize the table Input_car of vehicles to enter the intersection, and initialize the vehicle Car_now that has not left the intersection yet, and let Car_now = Input_car. Generate the scheduling code sequence Encode according to S2 and decode it into the scheduling transition sequence Decode. Put the Encode and Decode that have been judged to be completed into Encode_finish and Decode_finish respectively. Use Mark_save to store the initial identification and the identification after the transition is triggered. The corresponding relationship between the identification and the library is: ['P1LS','P1L1','P1L2','P1L3','P1SS','P1S1','P1S2','P1RS','P1R1','P2LS','P2L1','P2L2','P2L3','P2SS','P2S1','P2S2','P2RS','P2R1','P3L S','P3L1','P3L2','P3L3','P3SS','P3S1','P3S2','P3RS','P3R1','P4LS','P4L1','P4L2','P4L3 ','P4SS','P4S1','P4S2','P4RS','P4R1','P1SF','P2SF','P3SF','P4SF','C1','C2','C3','C4']

[0074] Input_car=[['1.1.1','1.1.2','1.1.3'],

[0075] ['2.1.1','2.3.2'],

[0076] ['3.1.1','3.2.2'],

[0077] ['4.1.1','4.2.2']]

[0078] Car_now=[['1.1.1','1.1.2','1.1.3'],

[0079] ['2.1.1','2.3.2'],

[0080] ['3.1.1','3.2.2'],

[0081] ['4.1.1','4.2.2']]

[0082] Encode=['3.2.2','3.1.1','4.1.1','1.1.1','2.1.1','4.2.2','4.1.1','1 .1.3','2.1.1','2.3.2','4.2.2','1.1.3','3.1.1','1.1.1','3.2.2','4.2 .2','3.1.1','1.1.1','1.1.2','2.3.2','3.1.1','4.1.1','2.1.1','1.1.2','1.1.1','3.2.2','1.1.2','4.1.1','2.1.1','1.1.3','1.1.3','1.1.2']

[0083] Decode=['T3S1','T3L1','T4L1','T1L1','T2L1','T4S1','T4L2','T1L1','T2L2','T2R1','T4S2','T1L2','T3L2','T1L2','T3S2','T4 S3','T3L3','T1L3','T1L1','T2R2','T3L4','T4L3','T2L3','T1L2','T1L4','T3S3','T1L3','T4L4','T2L4','T1L3','T1L4','T1L4']

[0084] Mark_save[0]=[3,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,1,0,0,0,1,0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,1,1,1,1]

[0085] 3.2) Set i = 0. If i < the scheduling sequence length, the scheduling sequence length obtained from step 3.1) is 32, and proceed to step 3.8). Otherwise, proceed to step 3.14);

[0086] 3.3) Record the judgment position Judge = i;

[0087] 3.4) Find the vehicle Pre_car in Car_now that is ahead of the current vehicle Encode[Judge].

[0088] 3.5) Determine whether the order of vehicles in the same lane is met through the dispatch code sequence;

[0089] 3.5.1) Determine whether Encode[Judge] is the first car in Pre_car. If so, proceed to step 3.7). Otherwise, proceed to step 3.5.2). If i = 0, Judge = 0, then Encode[Judge] = Encode[0] = '3.2.2', Pre_car = ['3.1.1', '3.2.2'], proceed to step 3.5.2).

[0090] If i=0, Judge=1, then Encode[Judge]=Encode[1]='3.1.1', Pre_car=['3.1.1'], which satisfies the order of vehicles in the same lane, and proceed to step 3.7)

[0091] 3.5.2) The number of times the vehicle number preceding Encode[Judge] appears in Encode_finish is recorded as Pre_num, and the number of times Encode[Judge] appears in Encode_finish is recorded as now_num. If Pre_num ≥ now_num + 1, proceed to step 3.7); otherwise, proceed to step 3.6). If i = 0 and Judge = 0, then Encode[Judge] = Encode[0] = '3.2.2', Pre_car = ['3.1.1', '3.2.2'], Pre_num = 0, and now_num = 0. This does not meet the vehicle order requirement, so proceed to step 3.6). 3.6) Judge = Judge + 1, and proceed to step 3.3).

[0092] 3.7) Determine whether Decode[Judge] can be triggered under the flag Mark_save[Judge]. If so, proceed to step 3.8); otherwise, proceed to step 3.6);

[0093] 3.8) Determine whether vehicles in different lanes will cause a deadlock;

[0094] 3.8.1) Determine if Decode[Judge] is the last transition of the vehicle. If so, proceed to step 3.7). Otherwise, proceed to step 3.8.2.

[0095] 3.8.2) Let r represent the previous resource library of Decode[Judge], and trigger the transition Decode[Judge] under the mark Mark_save[Judge] to obtain the new mark Ms. T1 is the set of transitions that can increase the resource library r under the mark Ms. Sets T2 and T3 are initialized to ;

[0096] 3.8.3) Determine whether there are unique elements in sets T1 and T2. If so, proceed to step 3.8.4). Otherwise, output a deadlock detection and proceed to step 3.6).

[0097] 3.8.4) Take a t from the set that does not overlap between T1 and T2 and determine if t is the last transition of the vehicle. If so, output that deadlock will not occur. Otherwise, proceed to step 3.8.5)

[0098] 3.8.5) Let r represent the preceding resource location of t. Determine whether the number of tokens in r in Ms is 1. If it is 1, output that no deadlock will occur. Otherwise, proceed to step 3.8.6.

[0099] 3.8.6) Store T3 under the tag Ms, which is the set of transitions that can be added to the repository. Add the transitions in T3 that are not duplicates of T1 to T1, and proceed to step 3.8.3).

[0100] If i=3, Judge=4, Decode[Judge]=Decode[4]=['T2L1'], Encode[Judge]=Encode[4]=['2.1.1'], 'T2L1' is not the last transition of '2.1.1', so proceed to step 3.8.2), the predecessor resource library of 'T2L1' r='C2', triggering the transition 'T2L1' to obtain the identifier Ms=[2,1,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0], T1='T2L2', Proceed to step 3.8.3),

[0101] There are non-repeating elements in sets T1 and T2, proceed to step 3.8.4), take out a t='T2L2' from the non-repeating sets of T1 and T2, t='T2L2' is not the last transition of the vehicle, proceed to step 3.8.5), the predecessor resource library of t='T2L2' is r='C1', the number of tokens in r='C1' in Ms is not 1, proceed to step 3.8.6), T3=['T1L2'], T1=['T2L2','T1L2'], T2=['T2L2'], proceed to step 3.8.3). There are non-repeating elements in T1 and T2, proceed to step 3.8.4), take out a t='T1L2' from the non-repeating sets of T1 and T2, t='T1L2' is not the last transition of the vehicle, proceed to step 3.8.5), the predecessor resource library of t='T1L2' is r='C4', the number of tokens in r='C4' in Ms is not 1, proceed to step 3.8.6), T3=['T4L2'], T1=['T2L2','T1L2','T4L2'], T2=['T2L2','T1L2'], proceed to step 3.8.3). There are non-repeating elements in T1 and T2, proceed to step 3.8.4), take out a t='T4L2' from the non-repeating sets of T1 and T2, t='T4L2' is not the last transition of the vehicle, proceed to step 3.8.5), the predecessor resource library of t='T4L2' is r='C3', the number of tokens in r='C4' in Ms is not 1, proceed to step 3.8.6), T3=['T3L2'], T1=['T2L2','T1L2','T4L2','T3L2'], T2=['T2L2','T1L2','T4L2'], proceed to step 3.8.3). There are unique elements in T1 and T2. Proceed to step 3.8.4). Extract a unique transition t = 'T3L2' from the unique sets of T1 and T2. t = 'T3L2' is not the last transition of the vehicle. Proceed to step 3.8.5). The predecessor resource of t = 'T3L2' is r = 'C2'. The number of tokens in r = 'C4' in Ms is not 1. Proceed to step 3.8.6). T3 = ['T2L2'], T1 = ['T2L2', 'T1L2', 'T4L2', 'T3L2'], T2 = ['T2L2', 'T1L2', 'T4L2', 'T3L2']. Proceed to step 3.8.3). At this point, there are no unique elements in T1 and T2. A deadlock is detected.

[0102] 3.9) Determine whether Judge is equal to i. If so, proceed to step 3.11). Otherwise, proceed to step 3.10.

[0103] 3.10) Move the Judge position element in Encode and Decode to the front of position i; when i = 3 and Judge = 12, En code

[12] = '3.1.1' and Judge

[12] = 'T3L2', which meet the two requirements of vehicle sequence in the same lane and no deadlock, so move '3.1.1' and 'T3L2' to Encode[3] and Decode[3] respectively.

[0104] 3.11) Determine whether the current vehicle Encode[Judge] has left the intersection. If so, proceed to step 3.12). Otherwise, proceed to step 3.13.

[0105] 3.12) Delete the current vehicle Encode[Judge] from Car_now.

[0106] When i=10,

[0107] Car_now=[['1.1.1','1.1.2','1.1.3'],

[0108] ['2.1.1','2.3.2'],

[0109] ['3.1.1','3.2.2'],

[0110] ['4.1.1','4.2.2']]

[0111] When i=11, Judge=20, Decode

[20] ='T2R2', vehicle '2.3.2' leaves the intersection, and '2.3.2' is deleted from Car_now

[0112] Car_now=[['1.1.1','1.1.2','1.1.3'],

[0113] ['2.1.1'],

[0114] ['3.1.1','3.2.2'],

[0115] ['4.1.1','4.2.2']]

[0116] 3.13) Add the marker Ms to Mark_save, add Encode[i] and Encode[i] to Encode_finish and Decode_finish respectively, let i=i+1, and proceed to step 3.2).

[0117] 3.14) Output Encode_finish and Decode_finish;

[0118] Encode_finish=['4.1.1','4.1.1','4.2.2','2.1.1','2.1.1','2.3.2','2.3 .2','4.1.1','4.2.2','2.1.1','1.1.1','4.1.1','4.2.2','3.1.1','3.1.1', '3.2.2','2.1.1','1.1.1','3.1.1','3.2.2','1.1.1','3.1.1','1.1.2','1.1.2','1.1.3','1.1.1','3.2.2','1.1.2','1.1.3','1.1.2','1.1.3','1.1.3']

[0119] Decode_finish=['T4L1','T4L2','T4S1','T2L1','T2L2','T2R1','T2R2','T4L3','T4S2','T2L3','T1L1','T4L4','T4S3','T3L1','T3L2' ,'T3S1','T2L4','T1L2','T3L3','T3S2','T1L3','T3L4','T1L1','T1 L2','T1L1','T1L4','T3S3','T1L3','T1L2','T1L4','T1L3','T1L4']

[0120] The present invention checks and repairs the randomly generated dispatch code sequence and dispatch transition sequence one by one. The dispatch code sequence is used to detect the vehicle sequence. If the vehicle corresponding to the current dispatch code is the first vehicle in the current lane that has not left the intersection, the vehicle sequence detection is passed. Otherwise, in the code that has completed the judgment, it is determined whether the number of vehicle codes before the current vehicle is greater than or equal to the number of vehicle codes of the current vehicle. If so, the vehicle sequence detection is passed. Otherwise, the first position that passes the vehicle sequence detection is found from the current position. After passing the vehicle sequence detection, it is determined whether the transition of the corresponding position can be triggered. If it can be triggered, a deadlock judgment is entered. Otherwise, the first position that can be triggered by the transition is found from the current position. Deadlock judgment is performed starting from the transition position that can be triggered. If the deadlock judgment is not passed, the first transition that can pass the deadlock judgment is found from the current position. The encoding and decoding that have passed the above three steps are moved before the current judgment position, and the judgment and repair of the sequence are completed.

[0121] The specific implementation scheme described above further illustrates in detail the purpose, technical solutions and beneficial effects of the present invention. It should be understood that the above is only a specific implementation scheme of the present invention and is not intended to limit the scope of the present invention. Any equivalent changes and modifications made by any technician in this field without departing from the concept and principle of the present invention should fall within the scope of protection of the present invention.

Claims

1. A deadlock avoidance method for an unsignalized intersection taking into account multiple vehicle travel directions, characterized in that: The following steps are involved: S1. Divide the right-of-way points in the unsignalized intersection and establish a Petri net model; S2. Encode the vehicles to enter the intersection and randomly generate a dispatch code sequence, and decode the dispatch code sequence into a dispatch transition sequence; S3. Determine whether the order of vehicles in the same lane is met by dispatching the code sequence, and determine whether a deadlock occurs between vehicles in different lanes by dispatching the transition sequence. If the order of vehicles in the same lane is not met or a deadlock occurs between vehicles in different lanes, replace the code and transition that meet the conditions after the current position with the current position; In S1: Divide the intersection space into c_num The number of right-of-way points on the left-turn, straight-ahead, and right-turn paths are num_L , num_S, num_R ; P is 、 P if Indicates the i Waiting and departure areas for vehicles in lane 1; P iLa 、P iSb 、 P iRc , where 1≤ a ≤ num_L , 1≤ b ≤ num_ S , 1≤ c ≤ num_ R, Respectively represent i Vehicles turning left, going straight, or turning right in lane No. 1 drive to the right-of-way point on the corresponding path; T iLe 、 T iSf 、 T iRg , where 1≤ e ≤ num_L +1, 1≤ f ≤ num_ S +1, 1≤ g ≤ num_ R +1, respectively, i Vehicle actions of vehicles turning left, going straight, and turning right in lane No. on the corresponding path; In S2: the vehicle code consists of "lane number. driving direction. position"; The lane number is the lane number of the current vehicle. The driving directions (left turn, straight ahead, and right turn) are represented by "1", "2", and "3" respectively. The position is the order of the current vehicle in the lane. The dispatch code sequence is obtained by expanding the vehicle code and randomly shuffling it. The dispatch transition sequence has a one-to-one correspondence with the dispatch code sequence, indicating the vehicle action to be performed by the current vehicle. S3 includes the following steps: S3.

1. Initialize the table of vehicles waiting to enter the intersection Input_car , initialize the vehicles that have not left the intersection Car_now ,make Car_now = Input_car ; Generate scheduling code sequence according to S2 Encode and decoded into a scheduling transition sequence Decode ;Will Encode and Decode Those that have been judged to be completed are placed separately Encode_finish and Decode_finish in; use Mark_ save Store the flag after the change is triggered; set i =0; S3.2 If i <Scheduling code sequence length, proceed to S3.8, otherwise proceed to S3.14; S3.

3. Record the judgment location Judge = i ; S3.

4. Find out Car_now Middle row in the current vehicle Encode [ Judge Vehicle ahead Pre_car ; S3.

5. Determine whether the order of vehicles in the same lane is met by using the dispatch code sequence; S3.5.

1. Judgment Encode [ Judge ]Is it Car_now If the first car is in the list, proceed to S3.7, otherwise proceed to S3.5.2; S3.5.2, Pre_car exist Encode_finish The number of occurrences is recorded as Pre_num , Encode [Judge] Encode_finish The number of occurrences is recorded as now_num ,if Pre_num ≥ now_num+ 1, proceed to S3.7, otherwise proceed to S3.6; S3.6, Judge = Judge+ 1. Proceed to S3.3; S3.

7. Judgment Decode [ Judge ] Can it be marked Mark_save [ Judge ] is triggered, if it can trigger, proceed to S3.8, otherwise proceed to S3.6; S3.

8. Determine whether vehicles in different lanes will be deadlocked; S3.8.

1. Judgment Decode [ Judge ]Is it Encode The last transition of [Judge] is to proceed to S3.7 if applicable, otherwise proceed to S3.8.2; S3.8.2, expressed as r Decode [ Judge ]'s front-end resource repository, in the identifier Mark_save [ Judge ] triggers changes Decode [ Judge ]Get a new logo Ms , T1 is the mark Ms Next, let the resource library r The added transition sets, sets T2 and T3 are initialized to Ø; S3.8.

3. Determine whether there are unique sets in sets T1 and T2. If so, proceed to S3.8.

4. Otherwise, output that a deadlock has been detected and proceed to S3.

6. S3.8.

4. Take out a t from the non-repeating sets T1 and T2 and determine whether t is Encode The last transition of [Judge] is: if the output does not cause deadlock, then proceed to S3.8.5; S3.8.5, use r' to represent the previous resource library of t, and determine the identifier Ms Check whether the number of tokens in r' is 1. If so, output that no deadlock will occur. Otherwise, proceed to S3.8.

6. S3.8.6, T3 is stored in the marked Ms Next, add the transition set that can increase the resource library, add the transitions in T3 that are not repeated in T1 to T1, and perform S3.8.3; S3.

9. Judgment Judge Is it equal to i If yes, proceed to S3.11, otherwise proceed to S3.10; S3.10, Encode and Decode middle Judge Position element moved to i Position in front; S3.11, determine the current vehicle Encode [Judge] Whether to leave the intersection. If yes, proceed to S3.12; otherwise, proceed to S3.

13. S3.12, from Car_now Delete the current vehicle Encode [Judge]; S3.13, mark Ms Add in Mark_save ,Will Encode [i] and Decode [i] Add separately Encode_ finish and Decode_finish In, order i = i +1, proceed to S3.2; S3.14, Output Encode_finish and Decode_finish .

Citation Information

Patent Citations

  • Petri net modeling-based intelligent network connection vehicle non-signalized intersection traffic control method

    CN118314747A