PETRI network-based food delivery robot path optimization and task allocation method

文档序号:85344 发布日期:2021-10-08 浏览:28次 中文

阅读说明:本技术 基于petri网的送餐机器人路径优化及任务分配方法 (PETRI network-based food delivery robot path optimization and task allocation method ) 是由 冯引安 赵俊波 于 2021-07-12 设计创作,主要内容包括:本发明公开了基于PETRI网的送餐机器人路径优化及任务分配方法,属于机器人路径优化技术领域。基于PETRI网的送餐机器人路径优化及任务分配方法,包括以下步骤:步骤一:对送餐机器人工作环境建模,将机器人工作空间划分为若干个房间,房间之间有一个或多个双向门进行连接;步骤二:送餐机器人任务分配;步骤三:对送餐机器人完成任务的过程中作假设;步骤四:模型建立的方法;本发明运用Petri网的理论方法对其进行建模分析,运用整数线性规划模型求解最优路径,以达到用时最短的目的,该路径规划能够使机器人从原点到目标点的移动过程中,在保证系统稳定性的前提下以最快的速度完成任务,并避免机器人互相碰撞,送餐效率较高,提升顾客满意度。(The invention discloses a food delivery robot path optimization and task allocation method based on a PETRI network, and belongs to the technical field of robot path optimization. The PETRI network-based food delivery robot path optimization and task allocation method comprises the following steps: the method comprises the following steps: modeling the working environment of the food delivery robot, dividing the working space of the robot into a plurality of rooms, and connecting the rooms by one or more two-way doors; step two: distributing tasks of the food delivery robot; step three: making an assumption in the process of completing the task by the food delivery robot; step four: a method of model building; the invention carries out modeling analysis on the Petri network by applying a theoretical method of the Petri network, and solves the optimal path by applying an integer linear programming model so as to achieve the purpose of shortest time consumption.)

1. The PETRI network-based food delivery robot path optimization and task allocation method is characterized by comprising the following steps of: the method comprises the following steps:

the method comprises the following steps: modeling the working environment of the food delivery robot, dividing the working space of the robot into a plurality of rooms, and connecting the rooms by one or more two-way doors;

each room is considered as a store Pi1,2,3iMove to room RjReferred to as a transition TkIf the number of robots in each room is called as the "department" of the warehouse, (1,2, 3.·, m), the food delivery problem of the robots is converted into a process that a certain number of robots reach the designated warehouse through limited transition;

step two: distributing tasks of the food delivery robot;

dividing the food delivery area into different areas, including a public area, an exclusive area, an obstacle avoidance area, a cooperation area and a termination area;

the position of the food delivery robot at any time can be represented in a Petri network, and when i is 1.2.3, n is, M (P) isi) A ∈ N ═ {0.1.2.3. }, this indicates a library post PiA food delivery robots are arranged in the food delivery robot;

step three: the following assumptions are made in the process of completing the task by the food delivery robot:

(1) the total number of the food delivery robots is K;

(2) the maximum number of steps for the robot to complete the task is H;

(3) the public area of the food delivery robot is Ic, the exclusive area is Ie, the cooperative area is Ix, the termination area is If, and the obstacle avoidance area is Ia;

(4) the robot set working in the exclusive area is Eti, namely the robot set completing the exclusive task i, wherein: 1,2, …; the robot set of the collaborative area is Ex;

step four: in a Petri network, each transition t is assigned a certain time, let f ═ f (t)1),f(t2),…,f(tm)]∈NmRepresenting a transition time between adjacent regions, the transition time including a time to complete a task; optimizing the objective function to make the total working time of all robots shortest, namely, the sum of the time corresponding to transitions in all trigger steps of the food delivery robot is the smallest, and finally obtaining the objective function as follows:

wherein the content of the first and second substances,a trigger vector representing the h step of the robot r; let Mr,h=[m(p1),m(p2),…,m(pn)]TH1, 2, …, H denotes the H th position of the robot rThe position of the step is marked, so that the running track of the food delivery robot r can pass through a limited identification sequence Mr,1,Mr,2,…,Mr,HDescribing, the position change of the food delivery robot r in the step h can be represented by the state equation (1):obtaining the formula (2):

if the Token number in the food delivery robot r after the h-th step transition enabling is not negative, the food delivery robot has the following formula (3):

the robot r can only reach one position in the h step, namely the h step can only trigger one transition at most, and the formula (4) is shown:

2. the PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the public area in the step two is an area which can be accessed by all the food delivery robots; the exclusive area refers to the fact that only the corresponding type of food delivery robot can execute tasks; the obstacle avoidance area is an area which cannot be accessed by all the meal delivery robots; the cooperative area refers to an area where a plurality of robots need to cooperatively complete a task; the termination area is an area that the robot needs to return after completing a task.

3. The PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the Petri net is a quaternary elementGroup (2): n ═ P, T, F, W, where P ═ { P1, P2. } denotes the set of N bins; T-T1, T2.., tm } represents a set of m transitions,set called directed arc, W: f → N, a weight function called net N, where N ═ {0, 1,2, … }, a set of non-negative integers; w (p, t) is the weight of the directed arc from bin p to bin t, W (t, p) is the weight of the directed arc from bin t to bin p, and W (p, t) ═ W (t, p) ═ 0 indicates that there is no corresponding directed arc; the library contains a Token which is represented by a black dot or a number; the transition enables the Token in the front bank to flow to the rear bank according to the direction of the directional arc and the weight of the corresponding directional arc.

4. The PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the public area is used as an area that all meal delivery robots can access, and if at least one robot is ensured to access the public area, the public area has the following formulas (5) and (6):

wherein:

5. the PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the exclusive area of the meal delivery robot can only be accessed and worked by the corresponding type of robot, other types of robots cannot reach the area, and the exclusive area meets the following formulas (7) and (8):

6. the PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the cooperative work area of the meal delivery robot, except for the corresponding robot to visit, other robots cannot reach the area, and the cooperative work area of the meal delivery robot satisfies the following formula (9) and formula (10):

7. the PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the meal delivery robot will reach at least one stop area, and the formula (14) meets the target:

where H is a sufficiently large number, zj, r, r ═ 1, …, and K is a variable 0-1 indicating whether or not the robot r has visited the area Rj; namely:

8. the PETRI network-based meal delivery robot path optimization and task allocation method according to claim 1, wherein: the food delivery robot should avoid reaching the obstacle area and should satisfy the formula (15):

Technical Field

The invention relates to the technical field of robot path optimization, in particular to a food delivery robot path optimization and task allocation method based on a PETRI network.

Background

As a mechatronic system integrating a plurality of functions of environmental perception, behavior control and dynamic decision, the mobile robot has been widely applied to various fields because of its advantages of functional completeness, system stability and intelligence, etc. The food delivery robot serving as a robot with a special function can replace human beings to finish food delivery service of a restaurant, labor cost can be greatly reduced, and repetitive labor can be reduced.

In the process of completing tasks, how to plan the route track of the food delivery robot and efficiently and cooperatively complete the food delivery task becomes the research key point of cooperative work of the food delivery robot, the current food delivery robot has a long planned path, and the food delivery efficiency is reduced when the robot walks more distance. In addition, when the number of robots is large, collision is easy to occur, and the loss caused by the dropping of the meal is caused.

Disclosure of Invention

The invention aims to provide a PETRI network-based food delivery robot path optimization and task allocation method, so as to solve the problems proposed in the background art: the current meal delivery robot has a long planned path, and the meal delivery efficiency is reduced when the robot walks more distance. And when the robot quantity is great, collision easily takes place, leads to the meal to drop and causes the loss.

In order to achieve the purpose, the invention provides the following technical scheme:

the PETRI network-based food delivery robot path optimization and task allocation method comprises the following steps:

the method comprises the following steps: modeling the working environment of the food delivery robot, dividing the working space of the robot into a plurality of rooms, and connecting the rooms by one or more two-way doors;

each room is considered as a store Pi1,2,3iMove to room RjReferred to as a transition TkIf the number of robots in each room is called as the "department" of the warehouse, (1,2, 3.·, m), the food delivery problem of the robots is converted into a process that a certain number of robots reach the designated warehouse through limited transition;

step two: distributing tasks of the food delivery robot;

dividing the food delivery area into different areas, including a public area, an exclusive area, an obstacle avoidance area, a cooperation area and a termination area;

the position of the food delivery robot at any time can be represented in a Petri network, and when i is 1.2.3, n is, M (P) isi) A ∈ N ═ {0.1.2.3. }, this indicates a library post PiA food delivery robots are arranged in the food delivery robot;

step three: the following assumptions are made in the process of completing the task by the food delivery robot:

(1) the total number of the food delivery robots is K;

(2) the maximum number of steps for the robot to complete the task is H;

(3) the public area of the food delivery robot is Ic, the exclusive area is Ie, the cooperative area is Ix, the termination area is If, and the obstacle avoidance area is Ia;

(4) the robot set working in the exclusive area is Eti, namely the robot set completing the exclusive task i, wherein: 1,2, …; the robot set of the collaborative area is Ex;

step four: in a Petri network, each transition t is assigned a certain time, let f ═ f (t)1),f(t2),…,f(tm)]∈NmRepresenting a transition time between adjacent regions, the transition time including a time to complete a task; optimizing the objective function to make the total working time of all robots shortest, namely, the sum of the time corresponding to transitions in all trigger steps of the food delivery robot is the smallest, and finally obtaining the objective function as follows:

wherein the content of the first and second substances,a trigger vector representing the h step of the robot r; let Mr,h=[m(p1),m(p2),…,m(pn)]TAnd H is 1,2, …, H represents the position mark of the H step of the robot r, the running track of the food delivery robot r can pass through the limited mark sequence Mr,1,Mr,2,…,Mr,HDescribing, the position change of the food delivery robot r in the step h can be represented by the state equation (1):obtaining the formula (2):

if the Token number in the food delivery robot r after the h-th step transition enabling is not negative, the food delivery robot has the following formula (3):

the robot r can only reach one position in the h step, namely the h step can only trigger one transition at most, and the formula (4) is shown:

preferably, the common area in the second step is an area accessible to all meal delivery robots; the exclusive area refers to the fact that only the corresponding type of food delivery robot can execute tasks; the obstacle avoidance area is an area which cannot be accessed by all the meal delivery robots; the cooperative area refers to an area where a plurality of robots need to cooperatively complete a task; the termination area is an area that the robot needs to return after completing a task.

Preferably, the Petri net is a quadruple: n ═ P, T, F, W, where P ═ { P1, P2. } denotes the set of N bins; T-T1, T2.., tm } represents a set of m transitions, set called directed arc, W: f → N, a weight function called net N, where N ═ {0, 1,2, … }, a set of non-negative integers; w (p, t)Is the weight of the directed arc from the repository p to the transition t, W (t, p) is the weight of the directed arc from the transition t to the repository p, W (p, t) ═ W (t, p) ═ 0 indicates that there is no corresponding directed arc; the library contains a Token which is represented by a black dot or a number; the transition enables the Token in the front bank to flow to the rear bank according to the direction of the directional arc and the weight of the corresponding directional arc.

Preferably, the common area is an area that all meal delivery robots can access, and if at least one robot is ensured to access, the common area has the following formula (5) and formula (6):

wherein:

preferably, the exclusive area of the meal delivery robot can only be accessed and worked by the corresponding type of robot, and other types of robots cannot reach the area, and the areas satisfy the formula (7) and the formula (8):

preferably, the cooperative work area of the meal delivery robot, which cannot be reached by other robots except the corresponding robot for access, should satisfy the following equations (9) and (10):

preferably, the meal delivery robot will reach at least one stop area, and equation (14) satisfies this goal:

where H is a sufficiently large number, zj, r, r ═ 1, …, and K is a variable 0-1 indicating whether or not the robot r has visited the area Rj; namely:

the food delivery robot should avoid reaching the obstacle area and should satisfy the formula (15):

compared with the prior art, the invention has the beneficial effects that:

(1) the invention carries out modeling analysis on the Petri network by applying a theoretical method of the Petri network, and solves the optimal path by applying an integer linear programming model so as to achieve the purpose of shortest time consumption.

Drawings

FIG. 1 is a diagram of a Petri net model of an indoor room structure according to the present invention.

Detailed Description

The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments.

Example 1:

referring to fig. 1, the PETRI network-based food delivery robot path optimization and task allocation method includes the following steps:

the method comprises the following steps: modeling the working environment of the food delivery robot, dividing the working space of the food delivery robot into a plurality of rooms, connecting the rooms by one or more two-way doors, considering that the food delivery robot generally works indoors, communicating the robots except for communicating with a central controller, and making independent decisions and autonomous movement by the robots;

each room is considered as a store Pi1,2,3iMove to room RjReferred to as a transition TkIf the number of robots in each room is called "token" of the pool "(1, 2, 3.·, m), the meal delivery problem of the robots is converted into a process of designating a certain number of robots to reach the designated pool through limited transition.

Step two: distributing tasks of the food delivery robot;

dividing the food delivery area into different areas including a public area, an exclusive area, an obstacle avoidance area, a cooperation area and a termination area, and considering that the layout of a restaurant generally comprises a hall, a bunk, a kitchen, a toilet and the like, dividing the restaurant into different areas;

the position of the food delivery robot at any time can be represented in a Petri network, and when i is 1.2.3, n is, M (P) isi) A ∈ N ═ {0.1.2.3. }, this indicates a library post PiThe food delivery robots are a, and the operation states of the food delivery robots are judged according to the positions (places) of the food delivery robots representing the positions of the food delivery robots at different times. Example (c): when the food delivery robot r is at the h step, the storehouse P12Containing a Token, i.e. Mr,h(p12) When the food delivery robot runs to the region R, the food delivery robot turns to 112

Step three: the following assumptions are made in the process of completing the task by the food delivery robot:

(1) the total number of the food delivery robots is K;

(2) the maximum number of steps for the robot to complete the task is H;

(3) the public area of the food delivery robot is Ic, the exclusive area is Ie, the cooperative area is Ix, the termination area is If, and the obstacle avoidance area is Ia;

(4) the robot set working in the exclusive area is Eti, namely the robot set completing the exclusive task i, wherein: 1,2, …; the set of robots in the collaborative work area is Ex.

(5) The operation environment of the food delivery robot is loose, the condition that a plurality of robots are in one room together can be met, if the food delivery robot enters and leaves the same room, different robots are communicated with each other to determine the robot which preferentially enters and leaves the room, and therefore collision and collision are avoided;

step four: in order to realize efficient work, the shortest working time of the food delivery robot is taken as an optimization target, namely the shortest time consumed for completing all tasks from an initial position after all the robots complete task allocation is ensured, in a Petri network, each transition t is assigned with a certain time, and f is set as [ f (t is t) for a certain time1),f(t2),…,f(tm)]∈NmRepresenting a transition time between adjacent regions, the transition time including a time to complete a task; optimizing the objective function to minimize the total working time of all robots, namely, the transition pairs in all trigger steps of the food delivery robotThe sum of the required times is minimum, and the final objective function is:

wherein the content of the first and second substances,a trigger vector representing the h step of the robot r; let Mr,h=[m(p1),m(p2),…,m(pn)]TAnd (H is 1,2, …, H) represents the position identification of the H step of the robot r, the running track of the food delivery robot r can pass through the limited identification sequence Mr,1,Mr,2,…,Mr,HThe position change of the food delivery robot r in the step h can be described by the state equation (1):obtaining the formula (2):

if the Token number in the food delivery robot r after the h-th step transition enabling is not negative, the food delivery robot has the following formula (3):

the robot r can only reach one position in the h step, namely the h step can only trigger one transition at most, and the formula (4) is shown:

the public area is an area that all meal delivery robots can access, and if at least one robot is ensured to access, the public area has the following formula (5) and formula (6):

wherein:

the exclusive area (task execution area) of the meal delivery robot can only be accessed and worked by the corresponding type of robot, other types of robots can not reach the area, and the formula (7) and the formula (8) are satisfied:

in the cooperative work area of the meal delivery robot, except for the corresponding robot for access, other robots cannot reach the area, and the cooperative work area of the meal delivery robot satisfies the following formula (9) and formula (10):

the food delivery robot will reach at least one stop area, and equations (11) to (14) satisfy the objective:

wherein H is a sufficiently large number, zj,r(R ═ 1, …, K) is a variable 0 to 1, indicating whether or not the robot R has visited the region Rj(ii) a Namely:

the food delivery robot should avoid reaching the obstacle area and should satisfy equation (15):

the public area in the step two is an area which can be accessed by all the food delivery robots; the exclusive area refers to the fact that only the corresponding type of food delivery robot can execute tasks; the obstacle avoidance area is an area which cannot be accessed by all the meal delivery robots; the cooperative area refers to an area where a plurality of robots need to cooperatively complete a task; the termination area is the area that the robot needs to return to after completing the task.

The Petri net is a quadruple: n ═ P, T, F, W, where P ═ { P1, P2. } denotes the set of N bins; T-T1, T2.., tm } represents a set of m transitions, is called as havingSet of directional arcs, W: f → N, a weight function called net N, where N ═ 0, 1,2, …, a set of non-negative integers, W (p, t) is the weight of the directed arcs from bin p to bin t, W (t, p) is the weight of the directed arcs from bin t to bin p, and W (p, t) ═ W (t, p) ═ 0, indicates that there are no corresponding directed arcs; the library contains Token (resource) which is represented by black dots or numbers; the transition enables the Token (resource) in the front-end library to flow to the rear-end library according to the directional arc direction and the weight of the corresponding directional arc;

the identifier of a Petri net N is a vector M → P → N ═ {0, 1,2, … }, the identifier in the library is called token (token), and M (P) represents the token number in the library P (N, M)0) Referred to as a net system, where N is a Petri net structure, M0Is the initial identification.

Let x be a node of the Petri network N, and then the prepositive set and the postive set of x are respectively defined asAndaccordingly, letIs a set of nodes, the pre-set and post-set of X are defined asAnd

the transition T epsilon T is enabled (enabled) under the identification M and is recorded as M [ T ∈ T>And if and only if:

denotes the transition transmit sequence σ ═ t1,t2,…,tmEnabled under the flag M, where the trigger vector of σ is defined as:

if transition t occurs k times in transition transmission sequence σ, σ (t) becomes k.

The correlation matrix [ N ] -Post-Pre of the Petri net N is an integer matrix with | P | × | T | as a sequence, and is defined as [ N ] (P, T) [ < W (T, P) > -W (P, T) ], the physical meaning of the correlation matrix is the variable quantity of Token in a library P after transition T enables, a row vector corresponding to the library P is called a correlation vector of P and is marked as [ N ] (P, ·); the column vector corresponding to the transition T is called a correlation vector of T, and is denoted as an input matrix and an output matrix of [ N ] (·, T) ·, Pre:p × T → N and Post: P × T → N are respectively called N, N ═ 0, 1,2, … }, Pre (P, T) ═ W (P, T) denotes the decrease amount of the P-interior token of the Post-transition-T enabled bank, and Post (P, T) ═ W (T, P) denotes the increase amount of the P-interior token of the Post-transition-T-enabled bank.

In a Petri net system (N, M), the transition t enables the net system to transition to another state, producing a new marker M ═ M' (p)1),Mˊ(p2),…,Mˊ(pn)]TWherein, in the step (A),P,Mˊ(p)=M(p)+[N](p, t) triggering transition t to reach the mark M' under the mark M, and recording as M [ t ]>M' in the Petri net N, the set of all markers that can be reached starting from marker M is called the reachable set of (N, M), denoted as R (N, M)

For a transition t in the Petri net N, there are:according to the transition triggering rule, the following steps are known: m' ═ M + [ N ]](. t), i.e.:

accordingly, if the slave M0Start triggering any finite transition sequence sigma to generate new identifier, M0[σ>M', then:

the equation (1) is called a state equation of the Petri network and represents the relation between the identifier and the occurrence number of the transition in the transition sequence.

The invention carries out modeling analysis on the Petri network by applying a theoretical method of the Petri network, and solves the optimal path by applying an integer linear programming model so as to achieve the purpose of shortest time consumption.

The foregoing shows and describes the general principles, essential features, and advantages of the invention. It will be understood by those skilled in the art that the present invention is not limited to the embodiments described above, and the preferred embodiments of the present invention are described in the above embodiments and the description, and are not intended to limit the present invention. The scope of the invention is defined by the appended claims and equivalents thereof.

12页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:群体机器人分布式围捕控制方法及系统

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类