CN109145350A - A kind of process analysis method based on queue logic Petri network - Google Patents

A kind of process analysis method based on queue logic Petri network Download PDF

Info

Publication number
CN109145350A
CN109145350A CN201810616589.6A CN201810616589A CN109145350A CN 109145350 A CN109145350 A CN 109145350A CN 201810616589 A CN201810616589 A CN 201810616589A CN 109145350 A CN109145350 A CN 109145350A
Authority
CN
China
Prior art keywords
token
queue
vehicle
transition
time
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201810616589.6A
Other languages
Chinese (zh)
Other versions
CN109145350B (en
Inventor
刘伟
刘雷
冯新
蔺茂
闫春
杜玉越
张福新
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shandong University of Science and Technology
Original Assignee
Shandong University of Science and Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shandong University of Science and Technology filed Critical Shandong University of Science and Technology
Priority to CN201810616589.6A priority Critical patent/CN109145350B/en
Publication of CN109145350A publication Critical patent/CN109145350A/en
Application granted granted Critical
Publication of CN109145350B publication Critical patent/CN109145350B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/10Geometric CAD
    • G06F30/18Network design, e.g. design based on topological or interconnect aspects of utility systems, piping, heating ventilation air conditioning [HVAC] or cabling

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Geometry (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a kind of process analysis methods based on queue logic Petri network, belong to queue logic Petri network process analysis procedure analysis field, specifically includes the following steps: analyzing first shared system fairness problem, deficiency present in fairness modeling for existing Petri network to shared system simultaneously, adds bank of queues institute, queue transition and time list for Petri network and is defined as queue logic Petri network;Then modeling and property analysis are carried out to garage shutdown system using queue logic Petri network, according to the invariant and utilization rate up to sequence analysis garage shutdown system, and analyzes critical nature relevant to garage shutdown system model;The system after modeling is compared with original shared system finally, show that the shared system with queue has the conclusion of validity.

Description

A kind of process analysis method based on queue logic Petri network
Technical field
The invention belongs to queue logic Petri network process analysis procedure analysis fields, and in particular to one kind is based on queue logic Petri network Process analysis method.
Background technique
Petri network is the mathematical notation to discrete parallel system, is suitable for describing asynchronous, concurrent computer system mould Type.Petri nets existing stringent formulation mode, also there is intuitive avatars mode, existing System describe hand abundant Section and system action analytical technology, and solid conceptual foundation is provided for computer science.Petri network, which is that one kind is special, to be had Xiang Tu.There are two disjoint nodes for it, are transition and library institute respectively.From library to transition or from be transitted towards library camber line It is relationship camber line.Logical Petri net (Logical Petri Net-LPN) is a high-level abstractions for inhibiting arc PN, has and patrols Collect input and output transition and logical expression.LPN can be used to simulate and analyze the biography value in shared system function and system not Certainty.
Petri network realizes the modeling of shared system, and it is also the effective tool of analyzing system performance.Due to existing Token is not distinguished in Petri network, therefore when there are multiple token in same library institute, it is impossible to ensure token Fairness.Traditional logical Petri net can not describe the fairness of the task schedule of shared system.Existing logic Petri Logic input and output transition and logical expression in net can effectively describe the logical relation in shared system but no pair The sequence of token distinguishes when token enters library institute, also not can guarantee the fairness of token.
In garage shutdown system, when vehicle arriving rate is greater than service rate, it may appear that wait phenomenon.Vehicle is according to arrival Time receives service, this is fair for the vehicle.It is that vehicle allocation parking stall can be with according to the feature of prerequisite variable It avoids arriving first vehicle and not can enter garage parking.If reaching vehicle afterwards obtains service time earlier than the vehicle first reached, this is to elder generation The vehicle of arrival is unfair.Meanwhile this will lead to the vehicle first reached cannot be assigned to parking stall.
Summary of the invention
For the above-mentioned technical problems in the prior art, the invention proposes one kind to be based on queue logic Petri network Process analysis method, design rationally, overcome the deficiencies in the prior art, have good effect.
To achieve the goals above, the present invention adopts the following technical scheme:
A kind of process analysis method based on queue logic Petri network, comprising the following steps:
Step 1: shared system fairness problem is analyzed;
Step 2: for existing Petri network, when modeling to shared system, existing fairness problem is analyzed;
Step 3: adding bank of queues institute, queue transition and time list for Petri network, define queue logic Petri network;
Step 4: garage shutdown system being modeled and analyzed using queue logic Petri network;
Step 5: property analysis is carried out to queue logic Petri net model;
Step 6: the system after modeling being compared with original shared system, obtains the shared system tool with queue There is the conclusion of validity.
Preferably, in step 3, Petri network is a kind of special digraph, and there are two disjoint nodes for it, that is, is become Move with library institute, from library to transition or from be transitted towards library camber line be relationship camber line;
Defining 1:N=(P, T, F) is a net, in which:
(1) P is limited set of library;
(2) T is limited transition collection,And
(3)It is the set of directed arc;
Define 2: input and output collection: setting x ∈ P ∪ T is the arbitrary element for netting N, in which:
X=y | (y, x) ∈ F be known as x input set or preceding collection;
X=y | and (x, y) ∈ F } it is known as the output collection or rear collection of x;
N=(P, T, F) is known as a pure net, meets
Define 3: four-tuple ∑=(P, T, F, M) is known as Petri network, and if only if:
(1) N=(P, T, F) is a pure net;
(2) M:P → N is mark function, wherein M0It is initial marking;
(3) there are ∑ following transition to cause rule:
A) for changing t ∈ T, ifM (p) >=1 then changes t and enables in the case where identifying M, is denoted as M [t >;
If b) M [t >, in the case where identifying M, t can cause, and cause after generate a new logo M ', be denoted as M [t > M ',
Define 4: logical Petri net LPN
LPN is the high-level abstractions that can be used for simulating and analyzing the bound arc Petri network of shared system function;
If LPN=(P, T, F, I, O), LPN=(LN, M) is known as a logical Petri net, and if only if:
P is limited set of library;
T=TD∪TI∪TOIt is limited transition collection,Wherein:
(a)TDIndicate classical Petri nets transition;
(b)TIIndicate that the logic of T inputs transition collection, andTIAll input magazines suffered by logic input expression formula fI Limitation;
(c)TOIndicate that the logic of T exports transition collection, andTOAll output libraries suffered by logic export expression formula fO Limitation;
It is finite arc collection;
I is logic limitation input function, is made pairI (t)=fIIt is logic input expression formula;
O is logic limitation output function, is made pairO (t)=fOIt is logic output expression formula;
M:P → { 0,1 } is mark function,M (p) indicates the token number in p;
Transition cause rule:
A) rightIfIt changes t and causes the regular formula a) for meeting and defining in 3;
B) rightI (t)=fIIf fI| meet logical expression f under M=T, tI, then claim t enabled in M; If t is enabled, and t causes in the case where identifying M, develops and arrives new markM'(p)=0,M ' (p)=M (p)+ 1,M ' (p)=M (p);
C) rightO (t)=fOIfM (p)=1, then t is enabled in M;If t is enabled, t be can trigger, And after t causes at M, develops and arrive new markM ' (p)=M (p) -1,M ' (p)=M (p);And To t, f should be metO| M '=T, i.e. t must satisfy logical expression f in M 'O
Define 5: queue logic Petri network QLPN
Queue logic Petri network is that bank of queues institute, queue transition and time list are added in logical Petri net, is used The fairness problem of token in description shared system and solution shared system, and according to the initiation of token when transition initiation The property of time analysis system;
If QLPN=(P, T, t.no, L, ti(tokj),Pi(tokj),F,L,I,O,Q,Prea,Pfro,len,Plen,Dtok, Atok,M)
(1) P is limited set of library: wherein
(a)PpIt is classical limited set of library;
(b)PqIt is limited queue set of library;
(2) T=TD∪TI∪TO∪TQFor limited transition collection,And Wherein:
(a)TDIt is the transition collection of classical Petri nets;
(b)TIIndicate that the logic in logical Petri net inputs transition, andLogical table suffered by all input magazines of t Up to formula fILimitation;
(c)TOIndicate that logic exports transition collection, andLogic suffered by all output libraries of t exports expression formula fO's Limitation;
(d) Tq indicates queue transition collection, andQueue transition are inputted expression formula F by queueqLimitation and for reach Token be lined up;
(3) t.no is the mark of token;The mark of each token is uniquely, for marking token;
(4) L is time list, and time list includes two column, and wherein L.no indicates the mark of token in transition, and L.tim Indicate initiation time of the token in transition;
(5)ti(tokj) indicate token in transition tiIn the initiation time, work as ti∈TQ, ti(tokj) it is mark j Token reaches tiTime, wherein i represents the coding of transition, j represents the coding of token;
(6)Pi(tokj) represent token reach library time, wherein i represent library coding, j represents the volume of token Code;
(7)It is the set of directed arc;
(8) I is logic input function,I (t)=fIIt is logic input expression formula;
(9) O is logic output function,Q (t)=fQIt is logic output expression formula;
(10) Q is queue limitation input function,Q (t)=fQIt is queue input expression formula;
(11)PreaFor bank of queues tail of the queue, after queue transition cause, token reaches bank of queues institute, and is added to Bank of queues tail of the queue;
(12)PfroFor bank of queues team's head, when bank of queues rear collection transition cause when, token bank of queues Team's head is deleted;
(13) len is the quantity that queue can accommodate token;
(14)PlenBe bank of queues in the number containing token;
(15) D (tok) be delete function, token by this function bank of queues institute team head deletion;
(16) A (tok) is that token adds function, adds function by A (tok) when queue transition cause and token is added Be added to bank of queues tail of the queue;
(17) M:P → N is mark function, wherein MOIt is initial marking;
(18) fractional representation exported on arc causes from token to the time consumed by token arrival library;In order to distinguish power Value, fractional representation of the elapsed time with decimal point;
The transition rule of QLPN
Token pass in and out bank of queues rule
When queue transition triggering when, token be added to bank of queues tail of the queue;When bank of queues after collection transition cause When, token bank of queues team head be deleted;
(1)This function be used to calculate queue transition the library Qian Ji in token number, this In k >=1, token (Pi) it is the library Qian Ji institute piThe number of middle token, N are the weights of the input arc of queue transition, and n is the library Qian Ji Number;
(4) work as TQWhen initiation, if m≤len, token by function A (tok) be added to bank of queues tail of the queue, if M > len queue transition can only shift len token, and the time that the token that these token ratios are not transferred is reached is early;
(5) whenPlenTransition can trigger when-n > 0, PqReduce n token, Plen=Plen- n, n are bank of queues The weight of exported arc;
Queue transition cause rule
When queue transition cause, it is necessary to meet following rule
(5) work as PlenWhen=0, queue transition cause;
(6)TqEach library is not required to have token when initiation, and if only ifp∈·TqAnd Plen=0;
(7) when queue transition cause, the arrival time of each token and mark are stored in list;
(8) work as Pi(toki)=Pi(tokn), Pi∈·Tq, random alignment is carried out to two token;
Time list record rule
When token enters QLPN, the mark of token is set, and record token arrival queue is patrolled in reaching library institute The time of petri net is collected, while adding a record in time list when token causes in transition, this record includes L.no and initiation time;Wherein the mark of token be uniquely do not allow it is identical as the mark of other token, when token into When entering next transition, mark is transferred to the time list of next transition, and the mark of token is until token is in QLPN Disappearance is just released;
Define the fairness definition of 6:token
In QLPN, the initiation sequence of token was lined up according to the time for reaching queue, can be avoided in QLPN The problem of single token falls into a long wait;
Pi(tokj) be token reach library institute time, when queue transition TqAfter initiation, and Pi∈·Tq, Pi(tokj) < Pi+1(tokj+1), token is by orderly arrival bank of queues institute, the tok in bank of queues institutejIn tokj+1Front;If t ∈ Pq ·, change t and cause then t (tokj)<t(tokj), this is fair for token.
Preferably, in step 4, what is introduced first is that library changes and the meaning of expression formula;P in this model11, P12, P23And P24It is to reach library institute, represents vehicle and enter shutdown system preparation queuing storage;If vehicle is external vehicle, library Institute P11Or P12In have token;If vehicle is the vehicle of the cell, library institute P23Or P24In have token;Enter system in token When, wait library institute in increase time list;In t11And t12After initiation, external vehicle obtains temporary parking card;If queue Have a token in the institute of library, newly arrived token must be waited in waiting library institute, if bank of queues in without waiting for Token, and have token in the institute of waiting library, then queue transition are enabled;After queue transition cause, bank of queues passes through addition function M token is added in tail of the queue portion;HereThen Plen=m;If P8And Pq1There is token, then t3It is enabled, t3 Initiation indicate be verification parking card, while bank of queues institute in by delete function team head delete token, Plen=Plen- 1;If parking card is effective, vehicle waiting gate opening;P4In have token, then t3It is enabled;If parking card is invalid , vehicle will leave queue, t3Token enters P after initiation6;If not having remaining parking stall in garage, vehicle cannot be into Enter garage, vehicle will leave queue, P8In there is no a token, change t3It cannot enable, but t5It is enabled;
According to the time in garage shutdown system model, the mark and state of available QLPN and up to sequence and basis Up to the invariant and utilization rate of sequence analysis garage system;
The reachable sequence of system
It is obtained according to sequence table corresponding up to sequence;M indicates status information, M (p)=(num, t.no, ti(tokj),Pi (tokj)), wherein num represent library in token quantity;That t.no is indicated is the mark of token, Pi(tokj) represent It is tokjReach PiTime, ti(tokj) that represent is tokjIn transition tiIn the initiation time;
State changes the initiation time at the latest that the time is token when reaching next state;Vehicle can be obtained in state table The property of library shutdown system, according to the property up to sequence analysis garage shutdown system;
M0[(1,1,0,1),(1,2,0,2,),0,0,(1,3,0,2),(1,4,0,4)0,0,0,0,0,0,0,n];
t11 M1[0,(1,2,0,2),(1,1,1,1.5),0,(1,3,0,2),(1,4,0,4),0,0,0,0,0,0,0,n];
t2 M2[0,(1,2,0,2),0,0,(1,3,0,2),(1,4,0,4),(1,1,1.5,1.5),0,0,0,0,0,0, n];
t3 M3[0,(1,2,0,2),0,0,(1,3,0,2),(1,4,0,4),0,0(1,1,1.5,3.5),0,0,0,0,0, n];
t2 M4[0,(1,2,0,2),0,0,0,(1,4,0,4),(1,3,2,2),0,0,0,0,0,0,n];
t12 M5[0,0,0,(1,2,0,2.5),0(1,4,0,4),(1,3,2,2),(1,1,1.5,3.5),0,0,0,0,0, n];
t2 M6[0,0,0,0,0,(1,4,0,4),(2,(3,2),(2,2.5),(2,2.5)),(1,1,1.5,3.5)0,0, 0,0,0,n];
t3 M7[0,0,0,0,0,(1,4,0,4),(1,2,2.5,2.5),(2,(1,3),(1.5,3.5),(3.5,5.5)), 0,0,0,0,0,n-1];
t4 M8[0,0,0,0,0,(1,4,0,4),(1,2,2.5,2.5),(1,3,3.5,5.5),(1,1,3.5,5),0,0, 0,0,n-1];
t2 M9[0,0,0,0,0,0,(2,(2,4),(2.5,4),(2.5,4)),(1,3,3.5,5.5),(1,1,3.5,5), 0,0,0,0,n-1];
t3 M10[0,0,0,0,0,0,(1,4,0,4),(2,(3,2),(3.5,5.5),(5.5,7.5)),(1,1,3.5, 5),0,0,0,0,n-2];
t4 M11[0,0,0,0,0,0,(1,4,0,4),(1,2,5.5,7.5),(2,(1,3),(3.5,5.5),(5,7))0, 0,0,0,n-2];
t3 M12[0,0,0,0,0,0,0,(1,2,5.5,7.5),(2,(1,3),(3.5,5.5),(5,7)),(1,4,7.5, 9.5),0,0,0,n-3];
t4 M13[0,0,0,0,0,0,0,0,(3,(,3,2),(3.5,5.5,7.5)(5,7,9)),(1,4,7.5,9.5), 0,0,0,n-3];
t5 M14[0,0,0,0,0,0,0,0,(3,(,3,2),(3.5,5.5,7.5)(5,7,9)),0,(1,4,9.5, 11.5),0,0,n-3];
It prepares to exit from vehicle to vehicle and leaves garage
t6 M15[0,0,0,0,0,0,0,0,(2,(3,2),(5.5,7.5),(7,9)),0,(1,4,9.5,11.5),(1, 1,15,15),0,0,n-3];
t6 M16[0,0,0,0,0,0,0,0,(1,2,7.5,9),0,(1,4,9.5,11.5),(1,3,20,20),(1,1, 15,16),0,n-2];
t6 M17[0,0,0,0,0,0,0,0,0,0,(1,4,9.5,11.5),(1,2,26,26),0,0,n-1];
t7 M18[0,0,0,0,0,0,0,0,(2,(3,2),(5.5,7.5),(7,9)),0,(1,4,9.5,11.5),0, (1,1,15,16),n-2];
t7 M19[0,0,0,0,0,0,0,0,(1,2,7.5,9),0,(1,4,9.5,11.5),0,(2,(1,3),(15, 20),(16,21),n-1)];
t7 M20[0,0,0,0,0,0,0,0,0,0,(1,4,9.5,11.5),0,(3,(1,2,3),(15,20,26),(16, 21,27)),n];
Invariant
According to the invariant of state table analysis garage shutdown system;Regardless of that state, P in state table5, P4And P8In Token number be all n, be expressed as (P with expression formula5)+token(P4)+token(P8)=n, wherein n is parking stall in garage Number;
The utilization rate in garage
The utilization rate in garage refers to the ratio of the quantity of parking stall in the number of vehicle and garage in garage;
It is expressed as η=(token (P5)+token(P4))/n;
Wherein, token (P5) and token (P4) it is respectively library institute P5And P4In token quantity, (token (P5)+ token(P4)) be vehicle in garage quantity;N is the quantity of parking stall in garage;
The utilization rate in garage under each state can be calculated by QLPN state table.
Preferably, in steps of 5, property analysis is carried out to the queue logic Petri net model, in which:
Property analysis
According to the feature of shutdown system, from the property of two different form of arrival rate analysis garage shutdown system: wherein It is reached one is random, second is reached according to index;Analyzed under both forms vehicle average latency, The waiting number of vehicle residence time in the queue and vehicle.
The property of garage shutdown system in the case of random arrival
The random arrival of vehicle refers to that the random arrival of vehicle does not follow any rule, is stopped according to the garage of QLPN creation The model of system analyzes the property of garage shutdown system, average latency, vehicle including vehicle in the case where random reach The waiting number of mean residence time and vehicle in the queue;
The average latency of vehicle
The average latency of vehicle refers to that a certain number of vehicles queue to the average waiting serviced from preparation Time;According to the model of garage shutdown system, the waiting time of each vehicle can be calculated by formula (1);
In the time list of model, the preparation time being lined up of each vehicle and the time serviced can be obtained, The time that vehicle prepares to be lined up is expressed as token in a model and reaches library institute P2Time, vehicle obtain be to the time of service Token is in transition t3In the initiation time;
The mean residence time of vehicle
When vehicle freely reaches, the mean residence time of vehicle in the queue be a certain number of vehicles in the queue Mean residence time;The residence time of vehicle in the queue refer to vehicle from queue is reached to being serviced, vehicle in a model Residence time in the queue is indicated by formula (2):
Index is obeyed to reach
Vehicle, which is obeyed index and reached, refers to that the time interval that two neighboring vehicle reaches obeys exponential distribution;When arriving for vehicle Vehicle forms queue when entering garage when being greater than service rate up to rate, and token is in bank of queues after queue transition cause in a model Queue is formed in institute;When vehicle reaches system in a manner of completely random, exponential distribution is obeyed at adjacent arrival time interval, Formula (3) is the relational expression of service rate μ, time t and arrival rate λ;
F (t)=λ e-λt(3);
Wherein, λ indicates the arriving amt of vehicle in the unit time;
The model analyzes the property of garage shutdown system, the average waiting number including vehicle in the case where index reaches Amount, the mean residence time of average latency and vehicle;
The average latency of vehicle
When reaching rule obedience exponential distribution, the average latency of vehicle is calculated according to formula (4);
The mean residence time of vehicle in the queue
When vehicle arriving rate obeys exponential distribution, the mean residence time of vehicle in the queue is calculated according to formula (5);
Wait the par of vehicle
It waits the par of vehicle to refer to the par for waiting vehicle in different moments queue, passes through the feature of queue Garage shutdown system is analyzed, the par for waiting vehicle is calculated according to formula (6);
Advantageous effects brought by the present invention:
Present invention mainly solves the unfair problems of task schedule in shared system, and team is increased in shared system Column, and create one and describe the shared system with queue based on the QLPN of LPN, QLPN uses queue transition and bank of queues Queue sections in shared system are described, the time that record token causes in transition in time list is able to record altogether Enjoy system task scheduling time, can according to token reach library institute time describe task arrival different conditions time, The queue logic Petri network of creation can not only be modeled effectively for shared system, and according to model to the property in shared system Analysis according to the invariant in reachable sequence analysis system, and can optimize shared system according to property.
Detailed description of the invention
Fig. 1 is queue logic Petri network schematic diagram.
Fig. 2 is the model schematic of the queue logic Petri network of garage shutdown system.
Fig. 3 is the reachable sequence chart of garage shutdown system.
Fig. 4 is that the fairness of three kinds of different sharing systems verifies schematic diagram.
Fig. 5 is the average latency of three kinds of different sharing systems to verify schematic diagram.
Specific embodiment
With reference to the accompanying drawing and specific embodiment invention is further described in detail:
1, basic knowledge
1.1 garage shutdown systems
With the quickening of social rhythm, the production structure adjustment and method of service of enterprise are more and more using shared mould Formula.Therefore, shared model is used for the various aspects of business administration.Since the business environment and competitive pressure of enterprise are taken altogether It enjoys mode and realizes resource-sharing, having complementary advantages becomes the certainty of enterprise development, while also improving the quality and effect of teamwork Rate.However, the fairness of task schedule is also very important shared system.
When the demand of demander is greater than the service that supplier provides, the phenomenon that waiting, just will appear.In this case, The fairness of task schedule is very important each task, this needs a good algorithm to handle task schedule Fairness.The fairness of task schedule not only meets the equity dispatching of task, but also avoids the deadlock of system.In resource tune In degree research, some researchs are to be serviced by resource contention, but this competition normally results in deadlock.Some scholars Priority is added for task, but in fairly large shared system, the priority that task is arranged may result in system Load excessive.Other researchers are that shared system adds storehouse, and the characteristic of storehouse is to service afterwards first, if always had new Task arrive, this will lead to first task and will not be serviced, storehouse is added in the task schedule of shared system, right First reaching for task is inequitable.In some papers, it has been suggested that queue is added to shared system.But these are discussed Text does not provide proper implements to the fairness modeling of shared system.
1.2 petri net rudimentary knowledge brief introductions
It is defined as follows about petri net:
Petri network is a kind of special digraph.There are two disjoint nodes for it, these are transition and library institute.From library To transition or from be transitted towards library camber line be relationship camber line.
Defining 1:N=(P, T, F) is a net, in which:
(1) P is limited set of library;
(2) T is limited transition collection,And
(3)It is the set of directed arc.
Define 2: input and output collection: setting x ∈ P ∪ T is the arbitrary element for netting N,
X=y | (y, x) ∈ F be known as x input set or preceding collection
X=y | and (x, y) ∈ F } it is known as the output collection or rear collection of x
N=(P, T, F) is known as a pure net, meets
Define 3: four-tuple ∑=(P, T, F, M) is known as Petri network[1], and if only if:
(1) N=(P, T, F) is a pure net;
(2) M:P → N is mark function, wherein M0It is initial marking;
(3) there are ∑ following transition to cause rule:
A) for changing t ∈ T, ifM (p) >=1 then changes t and enables in the case where identifying M, is denoted as M [t >;
If b) M [t >, in the case where identifying M, t can cause, and cause after generate a new logo M ', be denoted as M [t > M ',
It is defined as follows about logical Petri net
LPN is to can be used for simulating the high-level abstractions with the bound arc Petri network of analysis system shared system function.Logic Defined below come from of Petri network models using Petri network and analyzes e-commerce system.
It defining 4: setting LPN=(P, T, F, I, O), LPN=(LN, M) is known as a logical Petri net, and if only if
(1) P is limited set of library;
(2) T=TD∪TI∪TOIt is limited transition collection,
Wherein:
(a)TDIndicate classical Petri nets transition;
(b)TIIndicate that the logic of T inputs transition collection, andTIAll input magazines suffered by logic input expression formula fI;Limitation;
(c)TOIndicate that the logic of T exports transition collection, andTOAll output libraries suffered by logic export expression formula fO Limitation;
(3)It is finite arc collection;
(4) I is logic limitation input function, is made pairI (t)=fIIt is logic input expression formula;
(5) O is logic limitation output function, is made pairO (t)=fOIt is logic output expression formula;
(6) M:P → { 0,1 } is mark function,M (p) indicates the token number in p;
(7) transition, which cause rule, is:
A) rightIfIt changes t and causes the regular formula a) for meeting and defining in 3;
B) rightI (t)=fIIf fI| meet logical expression f under M=T, tI, then claim t enabled in M; If t is enabled, and t causes in the case where identifying M, develops and arrives new markM ' (p)=M (p)+ 1,M ' (p)=M (p);
C) rightO (t)=fOIfM (p)=1, then t is enabled in M;If t is enabled, it can draw Hair, and after t causes at M, it develops to new markM ' (p)=M (p) -1,M ' (p)=M (p). And to t, f should be metO| M '=T, i.e. t must satisfy logical expression f in M 'O
2 queue logic Petri networks
Queue logic Petri network is that bank of queues institute and queue transition and time time column are added in logical Petri net Table, for describing shared system and solving the problems, such as that token's in shared system is unfair, and according to token when transition initiation The property of triggered time analysis system.
The definition of 2.1 queue logic Petri networks
If QLPN=(P, T, t.no, L, ti(tokj),Pi(tokj),F,L,I,O,Q,Prea,Pfro,len,Plen,Dtok, Atok,M)
(1) P is limited set of library: wherein
(a)PpIt is classical limited set of library
(b)PqIt is limited queue set of library
(2) T=TD∪TI∪TO∪TQFor limited transition collection,And
Wherein
(a)TDIt is the transition collection of classical Petri nets
(b)TIIndicate that the logic in logical Petri net inputs transition, andLogical table suffered by all input magazines of t Up to formula fILimitation;
(c)TOIndicate that logic exports transition collection, andLogic suffered by all output libraries of t exports expression formula fO's Limitation;
(d) Tq indicates queue transition collection, andQueue transition are that the token reached is lined up;
(3) t.no is the mark of token.The mark of each token is uniquely, for marking token.
(4) L is time list, and time list includes two column, and wherein L.no indicates the mark of token in transition, and L.tim Indicate initiation time of the token in transition;
(5)ti(tokj) indicate the time that token causes in transition, to work as ti∈TQ, ti(tokj) it is to be identified as j's Token reaches the time of transition i, and wherein i represents the coding of transition, j represents the coding of token.
(6)Pi(tokj) represent token reach library time, wherein i represent library coding, j represents the volume of token Code.
(7)It is the set of directed arc
(8) I is logic input function,I (t)=fIIt is logic input expression formula;
(9) O is logic output function,Q (t)=fQIt is logic output expression formula;
(10) Q is queue limitation input function,Q (t)=fQIt is queue input expression formula
(11)PreaFor bank of queues tail of the queue, after queue transition cause, token reaches bank of queues institute, and is added to Bank of queues tail of the queue;
(12)PfroFor bank of queues team's head, when bank of queues rear collection transition cause when, token bank of queues Team's head is deleted;
(13) len is the quantity that queue can accommodate token
(14)PlenBe bank of queues in the number containing token;
(15) D (tok) be delete function, token by this function bank of queues institute team head deletion
(16) A (tok) is that token adds function, adds function by A (tok) when queue transition cause and token is added Be added to bank of queues tail of the queue;
(17) M:P → N is mark function, wherein MOIt is initial marking;
(18) fractional representation exported on arc causes from token to the time consumed by token arrival library.In order to distinguish power Value, elapsed time decimally indicate.
The transition rule of 2.2 QLPN
2.2.1 token pass in and out bank of queues rule
When queue transition triggering when, these token be added to bank of queues tail of the queue.When bank of queues after collection transition When initiation, token bank of queues team head be deleted.
(1)This function be used to calculate queue transition the library Qian Ji in token number, this In k >=1,token(Pi) it is the library Qian Ji institute PiThe number of middle token, N are the defeated of queue transition Enter the weight of arc, n is number obtained by the library Qian Ji;
(6) work as TQWhen initiation, if m≤len, token are added to tail of the queue obtained by bank of queues as function A (tok), if M > len queue transition can only shift len token, and the time that the token that these token ratios are not transferred is reached is early;
(7) whenPlenTransition can trigger when-n > 0, PqReduce n token, Plen=Plen- n, n are bank of queues The weight of exported arc
(8) this queuing principle meets user's prerequisite variable, and this characteristic has public affairs to the task that each is reached Levelling, avoiding for task are reached for a long time and cannot be serviced.
2.2.2 queue transition cause rule
When queue transition cause, it is necessary to meet following rule
(1) work as PlenWhen=0, queue transition cause
(2)TqEach library is not required to have token when initiation, and if only ifp∈·TqAnd Plen=0;
(3) when queue transition cause, the arrival time of each token and mark are stored in list;
(4) work as Pi(toki)=Pk(tokn), Pi∈·Tq, random alignment is carried out to two token.
2.2.3 time list record rule
When token enters QLPN, the mark of token is set, and record token arrival queue is patrolled in reaching library institute The time of petri net is collected, while adding a record in time list when token causes in transition, this record includes L.no and initiation time.Wherein the mark of token be uniquely do not allow it is identical as the mark of other token, when token into When entering next transition, mark is transferred to next transition list, and the mark of token disappears ability until token in QLPN It is released.
2.3.token fairness definition
In QLPN, the initiation sequence of token was lined up according to the time for reaching queue.It can be avoided in QLPN The problem of single token falls into a long wait is the fairness definition of token below:
Define 6.Pi(tokj) be token reach library institute time, when queue transition TqAfter initiation, and Pi∈·Tq, Pi (tokj) < Pi+1(tokj+1), token is by orderly arrival bank of queues institute, the tok in bank of queues institutejIn tokj+1Front.Such as FruitIt changes t and causes then t (tokj)<t(tokj).This is fair for token.
Fig. 1 is a queue logic Petri network.What is introduced first is the meaning of each symbol and expression formula.P1,P2,P3, P4And P5It is classical set of library, PqIt is bank of queues institute, TqIt is queue transition, t1What is represented is logic output transition, changes TqTo team Arrange transition the library Qian Ji in token be lined up, P1,P2And P3。Expression formula FQ=(P1ΔP2ΔP3) queue expression formula, when Queue transition must satisfy expression formula when causing.Expression formula, which is meant, works as TqP when generation1,P2And P3At least contain one token。 It is logic output expression formula.When logic transition cause, this expression formula is expressed.This Expression formula means that token enters P4Or P6.In time list, what first row represented is mark, the secondary series of token What is represented is the departure time.For example, in TqTime list in the first row represent be t.no=1 and tTq(tok1)=1. What first row represented is token 1 in transition TqIn the initiation time be 1.Token 2 reaches P4Time be 4.t1Export arc On decimal represent be from token transition t1The time of middle initiation to reach p4Time.If the number on output arc is What integer then represented is weight.
Here is the operational process of model, and at the moment 1, token reaches P1, in this moment Pqlen=0 queue transition make Energy. TqP after initiationqIn have token, while t1It is enabled, t1After initiation, token enters library institute P4Or P5, because of t1Cause necessary Meet logic output expression formula.In 2time, token 2 and token 3 enters P2And P3.Because of Pqlen=0, TqIt is enabled.Cause Arrival time for token2 and token3 it is identical thus bank of queues in discharge be it is random, queue transition cause after Pqlen=2, t1It is enabled.
The queue logic Pteri of 3 garage shutdown systems nets modeling
Fig. 2 is the model of the queue logic Petri network of garage shutdown system;
The process passes in and out garage according to the mode of queue, and queue logic Petri network can accurately describe shared system Queue sections can be avoided the problem of vehicle falls into a long wait and cannot service according to this rule.
The elicitation procedure of token in Fig. 2 is described below, what is introduced first is the meaning of each symbol.In this model P11, P12And P23These are to wait library institute, represent vehicles while passing garage shutdown system and prepare to be lined up.If vehicle is external vehicle , library institute P11Or P12In have token.If vehicle is the vehicle of the cell, library institute P23Or P24In have token.Token into While entering system, into library institute in add time list.In t11And t12After initiation, external vehicle obtains temporary parking card. If having a token in bank of queues institute, token must be waited in waiting library institute, if bank of queues in without waiting for token And having token in the library the Qian Ji institute of queue transition, queue transition are enabled.After queue transition cause, bank of queues, which passes through, to be added Function tail of the queue portion obtained by bank of queues is added to add m token.HerePlen=m.If P8With Pq1There is token, then t3It is enabled.t3Initiation indicate be verification parking card, while bank of queues institute in by delete function in team Team's head of column deletes token, Plen=Plen-1.If parking card is effective, vehicle waiting gate opening.P4In have token Then t3It is enabled.If parking card be it is invalid, vehicle will leave queue.t3Token enters P after initiation6.If do not had in garage There is remaining parking stall, both P8In there is no token, vehicle, which not can enter garage, will leave queue.Change t3It cannot enable, but It is t5It is enabled, then cause.
The efficiency of the arrival rate of vehicle in garage shutdown system, the quantity on parking stall in garage, and service is all to influence The factor of system performance.We are analyzed by QLPN and are arrived in free arrival rate and obedience index arrival rate two herein The performance of garage shutdown system under up to rate, while we analyze the benefit of invariant and garage in model according to reachable sequence With rate.
The reachable sequence of 3.1 systems
Fig. 3 is the reachable sequence table that garage shutdown system according to fig. 2 obtains.And it is obtained according to sequence table corresponding reachable Sequence.M indicates status information, M (p)=(num, t.no, ti(tokj),Pi(tokj)), wherein num represents token in the institute of library Quantity;That t.no is indicated is the mark of corresponding token, Pi(tokj) that represent is tokjReach PiTime, ti(tokj) generation Table is tokjIn transition tiIn the initiation time, such as P4(tok1)=3.5, t4(tok3)=5.5.Vehicle reaches garage and stops The time of vehicle system is respectively: P11(tok1)=1, P12(tok2)=2, P23(tok3)=2, P24(tok4)=4;Vehicle 1 is in vehicle Residence time in library is 10 chronomeres, and residence time of the vehicle 2 in garage is 13 chronomeres, and vehicle 3 is in vehicle Residence time in library is 12 chronomeres, and residence time of the vehicle 3 in garage is 17 chronomeres.
Time in timetable according to fig. 2 is the mark and state of QLPN below:
M0[(1,1,0,1),(1,2,0,2,),0,0,(1,3,0,2),(1,4,0,4)0,0,0,0,0,0,0,n];
t11 M1[0,(1,2,0,2),(1,1,1,1.5),0,(1,3,0,2),(1,4,0,4),0,0,0,0,0,0,0,n];
t2 M2[0,(1,2,0,2),0,0,(1,3,0,2),(1,4,0,4),(1,1,1.5,1.5),0,0,0,0,0,0, n];
t3 M3[0,(1,2,0,2),0,0,(1,3,0,2),(1,4,0,4),0,0(1,1,1.5,3.5),0,0,0,0,0, n];
t2 M4[0,(1,2,0,2),0,0,0,(1,4,0,4),(1,3,2,2),0,0,0,0,0,0,n];
t12 M5[0,0,0,(1,2,0,2.5),0(1,4,0,4),(1,3,2,2),(1,1,1.5,3.5),0,0,0,0,0, n];
t2 M6[0,0,0,0,0,(1,4,0,4),(2,(3,2),(2,2.5),(2,2.5)),(1,1,1.5,3.5)0,0, 0,0,0,n];
t3 M7[0,0,0,0,0,(1,4,0,4),(1,2,2.5,2.5),(2,(1,3),(1.5,3.5),(3.5,5.5)), 0,0,0,0,0,n-1];
t4 M8[0,0,0,0,0,(1,4,0,4),(1,2,2.5,2.5),(1,3,3.5,5.5),(1,1,3.5,5),0,0, 0,0,n-1];
t2 M9[0,0,0,0,0,0,(2,(2,4),(2.5,4),(2.5,4)),(1,3,3.5,5.5),(1,1,3.5,5), 0,0,0,0,n-1];
t3 M10[0,0,0,0,0,0,(1,4,0,4),(2,(3,2),(3.5,5.5),(5.5,7.5)),(1,1,3.5, 5),0,0,0,0,n-2];
t4 M11[0,0,0,0,0,0,(1,4,0,4),(1,2,5.5,7.5),(2,(1,3),(3.5,5.5),(5,7))0, 0,0,0,n-2];
t3 M12[0,0,0,0,0,0,0,(1,2,5.5,7.5),(2,(1,3),(3.5,5.5),(5,7)),(1,4,7.5, 9.5),0,0,0,n-3];
t4 M13[0,0,0,0,0,0,0,0,(3,(,3,2),(3.5,5.5,7.5)(5,7,9)),(1,4,7.5,9.5), 0,0,0,n-3];
t5 M14[0,0,0,0,0,0,0,0,(3,(,3,2),(3.5,5.5,7.5)(5,7,9)),0,(1,4,9.5, 11.5),0,0,n-3];
Vehicle, which is prepared to exit, from vehicle leaves garage
t6 M15[0,0,0,0,0,0,0,0,(2,(3,2),(5.5,7.5),(7,9)),0,(1,4,9.5,11.5),(1, 1,15,15),0,0,n-3];
t6 M16[0,0,0,0,0,0,0,0,(1,2,7.5,9),0,(1,4,9.5,11.5),(1,3,20,20),(1,1, 15,16),0,n-2];
t6 M17[0,0,0,0,0,0,0,0,0,0,(1,4,9.5,11.5),(1,2,26,26),0,0,n-1];
t7 M18[0,0,0,0,0,0,0,0,(2,(3,2),(5.5,7.5),(7,9)),0,(1,4,9.5,11.5),0, (1,1,15,16),n-2];
t7 M19[0,0,0,0,0,0,0,0,(1,2,7.5,9),0,(1,4,9.5,11.5),0,(2,(1,3),(15, 20),(16,21),n-1)];
t7 M20[0,0,0,0,0,0,0,0,0,0,(1,4,9.5,11.5),0,(3,(1,2,3),(15,20,26),(16, 21,27)),n];
According to the state of Fig. 3, obtain up to sequence
State changes the initiation time at the latest that the time is token when reaching next state.Vehicle can be obtained in state table The properties of library shutdown system.We are according to the property up to sequence analysis garage shutdown system below.
3.2 invariant
According to the invariant of state table analysis garage shutdown system.Regardless of that state, P in state table5, P4And P8In Token number be all n, be expressed as (P with expression formula5)+token(P4)+token(P8)=n, wherein n is stopped in garage The number of position.The utilization rate in 3.3 garages
The utilization rate in garage refers to the ratio of the quantity of parking stall in the number of vehicle and garage in garage, be expressed as η= (token(P5) +token(P4))/n.Token (P in expression formula5) and token (P4) that indicate is library institute P5And P4In The quantity of token, expression formula (token (P5)+token(P4)) be vehicle in garage quantity.N is the number of parking stall in garage Amount.The utilization rate in garage under each state can be calculated by QLPN state table.
4. property analysis
According to the feature of shutdown system, we analyze the property of garage shutdown system from the arrival rate of two different forms Matter.One of which is to reach at random, and second is reached according to index.Being averaged for vehicle etc. is analyzed under both forms To time, vehicle residence time in the queue and the waiting number of vehicle.
The property of garage shutdown system in the case of 4.1 random arrival
The random arrival of vehicle refers to that the random arrival of vehicle does not follow any rule.According to the garage parking of QLPN creation The model of system analyzes the properties of garage shutdown system in the case where random reach.Such as the waiting time of vehicle, The residence time of vehicle in the queue.
4.1.1 the average latency of vehicle
The average latency of vehicle refers to that a certain number of vehicles queue to the average waiting serviced from preparation Time.According to the model of garage shutdown system, we can calculate waiting time and the vehicle of vehicle by following formula Average latency, passing through following formula indicates:
The waiting time of 1 vehicle of table
In the time list of model, each vehicle can be obtained from the time for preparing to be lined up and serviced, passed through (1) Formula we can calculate the waiting time of each vehicle.The waiting time of vehicle 1 is 0, and the waiting time of vehicle 2 is 3, vehicle 3 waiting time is 1.5, and the waiting time of vehicle 4 is 3.5.The average latency for being calculated from the formula 4 vehicles is 2。
4.1.2 the mean residence time of vehicle
When vehicle freely reaches, the mean residence time of vehicle in the queue be a certain number of vehicles in the queue Average time.The residence time of vehicle in the queue refers to vehicle from queue is reached to being serviced, and vehicle is in team in a model Residence time in column is indicated by following formula:
The residence time of 2 vehicle of table in the queue
What table 2 indicated is that vehicle enters and leaves the residence time of the time and each vehicle of queue in the queue: vehicle 1 residence time is 2;The residence time of vehicle 2 is 5, and the residence time of vehicle 3 is 3.5.According to formulaThe residence time for calculating vehicle is 3.5.
4.2, which obey index, reaches
Vehicle, which is obeyed index and reached, refers to that the time interval that two neighboring vehicle reaches obeys exponential distribution.When arriving for vehicle Vehicle forms queue when entering garage when being greater than service rate up to rate, and token is in bank of queues after queue transition cause in a model Queue is formed in institute.When vehicle reaches system in a manner of completely random, exponential distribution is obeyed at adjacent arrival time interval, Following formula is the relational expression of service rate μ, time t and arrival rate λ
F (t)=λ eλt(3);
λ indicates the arriving amt of vehicle in the unit time, it is assumed that λ=1.Following table describes vehicle general greater than time t Rate and probability less than time t.
The arrival rate of the obedience exponential distribution of table 3
The model analyzes the property of garage shutdown system in the case where index reaches, including being averaged for vehicle etc. To quantity, the mean residence time of average latency and vehicle.We assume that the average service time that vehicle enters garage is 5time, the average service time that vehicle leaves garage is 4time.And the quantity for reaching vehicle obeys Poisson distribution.Due to vehicle Enter garage average service time be 5time, and vehicle leave garage average service time be 4time.Assuming that 60time is a chronomere, and when vehicle enters garage, it is 12/unite that we, which can calculate service rate, and works as vehicle When leaving garage, service rate is 14/unite.
QLPN is used to describe the shared system with queue, it is the mapping of queue.The property of QLPN and the property of queue It is similar.Therefore, the analysis of the shared system property with queue can combine with queue.
4.2.1 the average latency of vehicle
When reaching rule obedience exponential distribution, the average latency of vehicle is calculated.Average latency can be used down Formula indicates:
Under different arrival rate, the average latency in vehicles while passing garage is calculated by formula (4), the average latency It represents in the following table:
The average latency of 4. vehicle of table
Therefore as can be seen from the table, the value of arrival rate is higher, and the vehicle waiting time is longer.By analysis operation flow and Property can help us to optimize operation flow.It can be improved service rate, shorten the waiting time.
4.2.2 the mean residence time of vehicle in the queue
When vehicle arriving rate obeys exponential distribution, the mean residence time of vehicle in the queue is calculated.Vehicle is averaged Residence time can be indicated with following formula
Vehicle passes through being averaged in the queue of vehicle when formula (5) calculating vehicles while passing garage under different arrival rate Residence time is as shown in the table:
The residence time of vehicle under the different arrival rate of table 5
The model is for analyzing the mean residence time of vehicle in the queue.But general LPN cannot be analyzed well These characteristics.Arrival rate is higher, and the residence time of vehicle in the queue is longer.
4.2.3 the quantity of average waiting vehicle
The par for waiting vehicle is the par that vehicle is waited before each vehicle receives service in the queue, is led to Cross the signature analysis garage shutdown system of queue.The par of waiting vehicle can be indicated with following formula:
Under different arrival rate, according to formula (6), we obtain waiting the par of vehicle as shown in the table:
Table 6. waits the par of vehicle under different arrival rate
According to table 6, it may be seen that the par of waiting vehicle also increases with the increase of arrival rate.It formulates Corresponding appropriate scheme, solves the problems, such as that vehicles while passing garage falls into a long wait.
If describing garage shutdown system by LPN, the queue sections in shared system cannot be described.LPN is difficult accurately Ground models and analyzes these properties.QLPN adds queue transition and bank of queues on LPN to describe queue in shared system Part.And the model based on QLPN creation can analyze the property of shared system.By these properties, system is adjusted Whole and optimization.For example, efficiency of service can be improved to reduce being averaged for vehicle in we if the average latency of vehicle is too long Waiting time.Meanwhile being conducive to system performance analysis in QLPN addition time list.Garage shutdown system is analyzed by QLPN, It can prove that QLPN is the effective tool for describing queue sharing system.Queue sharing system is demonstrated in following comparative experiments The validity of system.
4.3.1 fairness is verified
Improved shared system is compared with traditional shared system and in the shared system with stack by 3-D graphic The fairness of task schedule.X-axis indicates that car number, Y-axis indicate vehicle arrival time, and Z axis indicates the service time of vehicle. Red line indicates the vehicle code of improved shared system and the relationship between arrival time and service time.Blue line is traditional The vehicle code of shared system and the relationship between arrival time and service time.Green line is that the vehicle of storehouse shared system is compiled Code and the relationship between arrival time and service time.Overlapping indicates service time having the same and arrival in this section Time.
As seen in Figure 4, in traditional shared system, the sequence that waiting task is serviced be it is random, this can Some task can be caused to fall into a long wait.It can see the arrival more early than other vehicles of some vehicles from blue line, but reached than late Vehicle receive service evening time.For example, vehicle 5 reaches earlier than vehicle 7, but more late than the time that vehicle 7 is serviced, This is inequitable to vehicle 5.And green line indicates the shared system with storehouse.In the figure it may be seen that vehicle 2 etc. To for a long time.But due to the improved characteristic with queue sharing system with prerequisite variable, so that vehicle is according to arrival Time is serviced, this is fair for each vehicle.
4.3.2 the average latency is verified
Following two-dimensional vector figure compares improved shared system and traditional shared system and shares with storehouse The average latency of system.X-axis indicates vehicle code, and Y-axis indicates the vehicle waiting time.We are available than red line ratio Blue line average time is longer.
The average latency verifying of two kinds of different sharing systems
In Fig. 5, in the case where the same time reaches the identical situation of vehicle fleet size, it may be seen that representing different sharing system Unite vehicle in three lines waiting time it is different.Vehicle 5 waits for a long time in traditional shared system.Due to improvement Shared system has queue, can fall into a long wait to avoid vehicle.We can calculate the average waiting of traditional shared system Time is 11.9 unit time.And the average time for improving shared system is 8.8 unit time.It is shared with queue The average time of system is 11 unit time.
Queue sharing system and other kinds of shared system are subjected to fair comparison.By analyze each car waiting when Between, it was demonstrated that the shared system in task schedule with queue is fair.
Fig. 5 illustrates the waiting time of different sharing system.Pass through analysis, it can be deduced that conclusion, the average latency compared with Short is queue sharing system.This can prove fairness of the shared system in task schedule and in terms of system optimization Validity.
Certainly, the above description is not a limitation of the present invention, and the present invention is also not limited to the example above, this technology neck The variations, modifications, additions or substitutions that the technical staff in domain is made within the essential scope of the present invention, also should belong to the present invention Protection scope.

Claims (4)

1. a kind of process analysis method based on queue logic Petri network, it is characterised in that: the following steps are included:
Step 1: shared system fairness problem is analyzed;
Step 2: for existing Petri network, when modeling to shared system, existing fairness problem is analyzed;
Step 3: adding bank of queues institute, queue transition and time list for Petri network, define queue logic Petri network;
Step 4: garage shutdown system being modeled using queue logic Petri network and carries out property analysis;
Step 5: the property of garage shutdown system is analyzed;
Step 6: the system after modeling being compared with original shared system, show that the shared system with queue has The conclusion of effect property.
2. the process analysis method according to claim 1 based on queue logic Petri network, it is characterised in that: in step 3 In, Petri network is a kind of special digraph, and there are two disjoint nodes, i.e. transition and library institute for it, from library institute to transition or From be transitted towards library camber line be relationship camber line;
Defining 1:N=(P, T, F) is a net, in which:
(1) P is limited set of library;
(2) T is limited transition collection,And
(3)It is the set of directed arc;
Define 2: input and output collection: setting x ∈ P ∪ T is the arbitrary element for netting N, in which:
X=y | (y, x) ∈ F be known as x input set or preceding collection;
X=y | and (x, y) ∈ F } it is known as the output collection or rear collection of x;
N=(P, T, F) is known as a pure net, meets
Define 3: four-tuple ∑=(P, T, F, M) is known as Petri network, and if only if:
(1) N=(P, T, F) is a pure net;
(2) M:P → N is mark function, wherein M0It is initial marking;
(3) there are ∑ following transition to cause rule:
A) for changing t ∈ T, ifM(p) >=1, then change t to enable in the case where identifying M, be denoted as M [t >;
If b) M [t >, in the case where identifying M, t can cause, and cause after generate a new logo M ', be denoted as M [t > M ',
Define 4: logical Petri net LPN
LPN is the high-level abstractions that can be used for simulating and analyzing the bound arc Petri network of shared system function;
If LPN=(P, T, F, I, O), LPN=(LN, M) is known as a logical Petri net, and if only if:
P is limited set of library;
T=TD∪TI∪TOIt is limited transition collection,Wherein:
(a)TDIndicate classical Petri nets transition;
(b)TIIndicate that the logic of T inputs transition collection, andTIAll input magazines suffered by logic input expression formula fILimit System;
(c)TOIndicate that the logic of T exports transition collection, andTOAll output libraries suffered by logic export expression formula fOLimit System;
It is finite arc collection;
I is logic limitation input function, is made pairI (t)=fIIt is logic input expression formula;
O is logic limitation output function, is made pairO (t)=fOIt is logic output expression formula;
M:P → { 0,1 } is mark function,M (p) indicates the token number in p;
Transition cause rule:
A) rightIt changes t and causes the regular formula a) for meeting and defining in 3;
B) rightI (t)=fIIf fI| meet logical expression f under M=T, tI, then claim t enabled in M;If t makes Can, and t causes in the case where identifying M, develops and arrives new mark M':M ` (p)=0,M ' (p)=M (p)+1,M ' (p)=M (p);
C) rightO (t)=fOIfM (p)=1, then t is enabled in M;If t is enabled, t be can trigger, and t is in M After lower initiation, develops and arrives new mark M ':M ' (p)=M (p) -1,M ' (p)=M (p);And to t, it answers Meet fO| M '=T, i.e. t must satisfy logical expression f in M 'O
Define 5: queue logic Petri network QLPN
Queue logic Petri network is that bank of queues institute, queue transition and time list are added in logical Petri net, for retouching The initiation time point of token when stating shared system and solve the fairness problem of token in shared system, and being caused according to transition The property of analysis system;
If QLPN=(P, T, t.no, L, ti(tokj),Pi(tokj),F,L,I,O,Q,Prea,Pfro,len,Plen,Dtok,Atok,M)
(1) P is limited set of library: wherein
(a)PpIt is classical limited set of library;
(b)PqIt is limited queue set of library;
(2) T=TD∪TI∪TO∪TQFor limited transition collection,AndIts In:
(a)TDIt is the transition collection of classical Petri nets;
(b)TIIndicate that the logic in logical Petri net inputs transition, andLogical expression f suffered by all input magazines of tI Limitation;
(c)TOIndicate that logic exports transition collection, andLogic suffered by all output libraries of t exports expression formula fOLimitation;
(d) Tq indicates queue transition collection, andQueue transition are inputted expression formula F by queueqLimitation and for reach Token is lined up;
(3) t.no is the mark of token;The mark of token is uniquely, for marking token;
(4) L is time list, and time list includes two column, and wherein L.no indicates the mark of token, and L.tim indicates token The initiation time in transition;
(5)ti(tokj) indicate token in transition tiIn the initiation time, work as ti∈TQ, ti(tokj) it is the token arrival for identifying j tiTime, wherein i represents the coding of transition, j represents the coding of token;
(6)Pi(tokj) represent token reach library time, wherein i represent library coding, j represents the coding of token;
(7)It is the set of directed arc;
(8) I is logic input function,I (t)=fIIt is logic input expression formula;
(9) O is logic output function,Q (t)=fQIt is logic output expression formula;
(10) Q is queue limitation input function,Q (t)=fQIt is queue input expression formula;
(11)PreaFor bank of queues tail of the queue, after queue transition cause, token reaches bank of queues institute, and is added to queue Library tail of the queue;
(12)PfroFor bank of queues team's head, when bank of queues rear collection transition cause when, token bank of queues team's head It deletes;
(13) len is the quantity that queue can accommodate token;
(14)PlenBe bank of queues in the number containing token;
(15) D (tok) be delete function, token by this function bank of queues institute team head deletion;
(16) A (tok) is that token adds function, adds function by A (tok) when queue transition cause and token is added to Bank of queues tail of the queue;
(17) M:P → N is mark function, wherein MOIt is initial marking;
(18) fractional representation exported on arc causes from token to the time consumed by token arrival library;In order to distinguish weight, Elapsed time decimally indicates;
The transition rule of QLPN
Token pass in and out bank of queues rule
When queue transition triggering when, token be added to bank of queues tail of the queue;When bank of queues rear collection transition cause when,
Token bank of queues team head be deleted;
(1)This function be used to calculate queue transition the library Qian Ji in token number, here k >= 1, token (Pi) it is the library Qian Ji institute PiThe number of middle token, N are the weights of the input arc of queue transition, n be the library Qian Ji it is a Number;
(2) work as TQWhen initiation, if m≤len, token by function A (tok) be added to bank of queues tail of the queue, if m > len Queue transition can only shift len token, and the time that the token that these token ratios are not transferred is reached is early;
(3) whenPlenTransition can trigger when-n > 0, PqReduce n token, Plen=Plen- n, n are that bank of queues institute is defeated The weight of arc out;
Queue transition cause rule
When queue transition cause, it is necessary to meet following rule
(1) work as PlenWhen=0, queue transition cause;
(2)TqEach library is not required to have token when initiation, and if only ifp∈·TqAnd Plen=0;
(3) when queue transition cause, the arrival time of each token and mark are stored in time list;
(4) work as Pi(toki)=Pi(tokn), Pi∈·Tq, random alignment is carried out to two token;
Time list record rule
When token enters QLPN, the mark of token is set, and record token reaches queue logic in reaching library institute The time of petri net, while a record is added in time list when token causes in transition, this record includes L.no and initiation time;Wherein the mark of token be uniquely do not allow it is identical as the mark of other token, when token enter When next transition, mark is transferred to the time lists of next transition, and the mark of token disappears in QLPN until token Mistake is just released;
Define the fairness definition of 6:token
In QLPN, the initiation sequence of token was lined up according to the time for reaching queue, can be avoided in QLPN single The problem of token falls into a long wait;
Pi(tokj) be token reach library institute time, when queue transition TqAfter initiation, and Pi∈·Tq, Pi(tokj) < Pi+1 (tokj+1), token is by orderly arrival bank of queues institute, the tok in bank of queues institutejIn tokj+1Front;If t ∈ Pq, become It moves t and causes then t (tokj)<t(tokj), this is fair for token.
3. the process analysis method according to claim 1 based on queue logic Petri network, it is characterised in that: in step 4 In, what is introduced first is that library changes and the meaning of expression formula;P in this model11, P12, P23And P24It is to reach library institute, generation Table vehicle enters shutdown system and prepares to be lined up storage;If vehicle is external vehicle, library institute P11Or P12In have token;If vehicle It is the vehicle of the cell, library institute P23Or P24In have token;When token enters system, waits in the institute of library and increase the time List;In t11And t12After initiation, external vehicle obtains temporary parking card;It is newly arrived if having token in bank of queues institute Token must wait library institute in wait, if bank of queues institute in without waiting for token, and wait library in have token, Then queue transition are enabled;After queue transition cause, bank of queues passes through addition function and adds m token in tail of the queue portion;HereThen Plen=m;If P8And Pq1There is token, then t3It is enabled, t3Initiation indicate be verification parking card, Token, P are deleted in team's head by deleting function in bank of queues institute simultaneouslylen=Plen-1;If parking card is effective, vehicle Wait gate opening;P4In have token, then t3It is enabled;If parking card be it is invalid, vehicle will leave queue, t3After initiation Token enters P6;If not having remaining parking stall in garage, vehicle not can enter garage, and vehicle will leave queue, P8In There is no token, changes t3It cannot enable, but t5It is enabled;
According to the time in garage shutdown system model, the mark and state of available QLPN and up to sequence and according to reachable The invariant and utilization rate of sequence analysis garage system;
The reachable sequence of system
It is obtained according to sequence table corresponding up to sequence;M indicates status information, M (p)=(num, t.no, ti(tokj),Pi (tokj)), wherein num represent library in token quantity;That t.no is indicated is the mark of token, Pi(tokj) represent be tokjReach PiTime, ti(tokj) that represent is tokjIn transition tiIn the initiation time;
State changes the initiation time at the latest that the time is token when reaching next state;It can obtain to garage and stop in state table The property of vehicle system, according to the property up to sequence analysis garage shutdown system;
M0[(1,1,0,1),(1,2,0,2,),0,0,(1,3,0,2),(1,4,0,4)0,0,0,0,0,0,0,n];
t11 M1[0,(1,2,0,2),(1,1,1,1.5),0,(1,3,0,2),(1,4,0,4),0,0,0,0,0,0,0,n];
t2 M2[0,(1,2,0,2),0,0,(1,3,0,2),(1,4,0,4),(1,1,1.5,1.5),0,0,0,0,0,0,n];
t3 M3[0,(1,2,0,2),0,0,(1,3,0,2),(1,4,0,4),0,0(1,1,1.5,3.5),0,0,0,0,0,n];
t2 M4[0,(1,2,0,2),0,0,0,(1,4,0,4),(1,3,2,2),0,0,0,0,0,0,n];
t12 M5[0,0,0,(1,2,0,2.5),0(1,4,0,4),(1,3,2,2),(1,1,1.5,3.5),0,0,0,0,0,n];
t2 M6[0,0,0,0,0,(1,4,0,4),(2,(3,2),(2,2.5),(2,2.5)),(1,1,1.5,3.5)0,0,0,0, 0,n];
t3 M7[0,0,0,0,0,(1,4,0,4),(1,2,2.5,2.5),(2,(1,3),(1.5,3.5),(3.5,5.5)),0,0, 0,0,0,n-1];
t4 M8[0,0,0,0,0,(1,4,0,4),(1,2,2.5,2.5),(1,3,3.5,5.5),(1,1,3.5,5),0,0,0,0, n-1];
t2 M9[0,0,0,0,0,0,(2,(2,4),(2.5,4),(2.5,4)),(1,3,3.5,5.5),(1,1,3.5,5),0,0, 0,0,n-1];
t3 M10[0,0,0,0,0,0,(1,4,0,4),(2,(3,2),(3.5,5.5),(5.5,7.5)),(1,1,3.5,5),0, 0,0,0,n-2];
t4 M11[0,0,0,0,0,0,(1,4,0,4),(1,2,5.5,7.5),(2,(1,3),(3.5,5.5),(5,7))0,0,0, 0,n-2];
t3 M12[0,0,0,0,0,0,0,(1,2,5.5,7.5),(2,(1,3),(3.5,5.5),(5,7)),(1,4,7.5, 9.5),0,0,0,n-3];
t4 M13[0,0,0,0,0,0,0,0,(3,(,3,2),(3.5,5.5,7.5)(5,7,9)),(1,4,7.5,9.5),0,0, 0,n-3];
t5 M14[0,0,0,0,0,0,0,0,(3,(,3,2),(3.5,5.5,7.5)(5,7,9)),0,(1,4,9.5,11.5),0, 0,n-3];
It prepares to exit from vehicle to vehicle and leaves garage
t6 M15[0,0,0,0,0,0,0,0,(2,(3,2),(5.5,7.5),(7,9)),0,(1,4,9.5,11.5),(1,1,15, 15),0,0,n-3];
t6 M16[0,0,0,0,0,0,0,0,(1,2,7.5,9),0,(1,4,9.5,11.5),(1,3,20,20),(1,1,15, 16),0,n-2];
t6 M17[0,0,0,0,0,0,0,0,0,0,(1,4,9.5,11.5),(1,2,26,26),0,0,n-1];
t7 M18[0,0,0,0,0,0,0,0,(2,(3,2),(5.5,7.5),(7,9)),0,(1,4,9.5,11.5),0,(1,1, 15,16),n-2];
t7 M19[0,0,0,0,0,0,0,0,(1,2,7.5,9),0,(1,4,9.5,11.5),0,(2,(1,3),(15,20), (16,21),n-1)];
t7 M20[0,0,0,0,0,0,0,0,0,0,(1,4,9.5,11.5),0,(3,(1,2,3),(15,20,26),(16,21, 27)),n];
Invariant
According to the invariant of state table analysis garage shutdown system;Regardless of that state, P in state table5, P4And P8In Token number is all n, is expressed as (P with expression formula5)+token(P4)+token(P8)=n, wherein n is parking stall in garage Number;
The utilization rate in garage
The utilization rate in garage refers to the ratio of the quantity of parking stall in the number of vehicle and garage in garage;
It is expressed as η=(token (P5)+token(P4))/n;
Wherein, token (P5) and token (P4) it is respectively library institute P5And P4In token quantity, (token (P5)+token (P4)) be vehicle in garage quantity;N is the quantity of parking stall in garage;
The utilization rate in garage under each state can be calculated by QLPN state table.
4. the process analysis method according to claim 1 based on queue logic Petri network, it is characterised in that: in step 5 In, property analysis is carried out to the queue logic Petri net model, in which:
Property analysis
According to the feature of shutdown system, from the property of two different form of arrival rate analysis garage shutdown system: one of It is to reach at random, refers to count to for second and reach;Average latency that vehicle is analyzed under both forms, vehicle are in queue In residence time and vehicle waiting number.
The property of garage shutdown system in the case of random arrival
The random arrival of vehicle refers to that the random arrival of vehicle does not follow any rule, the garage shutdown system created according to QLPN Model the property of garage shutdown system is analyzed in the case where random reach, average latency, vehicle including vehicle exist The waiting number of mean residence time and vehicle in queue;
The average latency of vehicle
The average latency of vehicle refers to that a certain number of vehicles queue to the time of the average waiting serviced from preparation; According to the model of garage shutdown system, the waiting time of each vehicle can be calculated by formula (1);
In the time list of model, each vehicle can be obtained and prepare the time being lined up and the time serviced, vehicle is quasi- The standby time being lined up is expressed as token in a model and reaches library institute P2Time, vehicle obtains to the time of service being that token exists Change t3In the initiation time;
The mean residence time of vehicle
When vehicle freely reaches, the mean residence time of vehicle in the queue is a certain number of vehicles being averaged in the queue Residence time;The residence time of vehicle in the queue refers to vehicle from queue is reached to being serviced, and vehicle is in team in a model Residence time in column is indicated by formula (2):
Index is obeyed to reach
Vehicle, which is obeyed index and reached, refers to that the time interval that two neighboring vehicle reaches obeys exponential distribution;When the arrival rate of vehicle Vehicle forms queue when entering garage when greater than service rate, and token is in bank of queues institute after queue transition cause in a model Form queue;When vehicle reaches system in a manner of completely random, exponential distribution, formula are obeyed in adjacent arrival time interval It (3) is the relational expression of service rate μ, time t and arrival rate λ;
F (t)=λ e-λt(3);
Wherein, λ indicates the arriving amt of vehicle in the unit time;
The model analyzes the property of garage shutdown system in the case where index reaches, the average waiting quantity including vehicle, The mean residence time of average latency and vehicle;
The average latency of vehicle
When reaching rule obedience exponential distribution, the average latency of vehicle is calculated according to formula (4);
The mean residence time of vehicle in the queue
When vehicle arriving rate obeys exponential distribution, the mean residence time of vehicle in the queue is calculated according to formula (5);
Wait the par of vehicle
It waits the par of vehicle to refer to the par for waiting vehicle in different moments queue, passes through the signature analysis of queue Garage shutdown system calculates the par for waiting vehicle according to formula (6);
CN201810616589.6A 2018-06-15 2018-06-15 Process analysis method based on queue logic Petri net Active CN109145350B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810616589.6A CN109145350B (en) 2018-06-15 2018-06-15 Process analysis method based on queue logic Petri net

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810616589.6A CN109145350B (en) 2018-06-15 2018-06-15 Process analysis method based on queue logic Petri net

Publications (2)

Publication Number Publication Date
CN109145350A true CN109145350A (en) 2019-01-04
CN109145350B CN109145350B (en) 2023-04-07

Family

ID=64802047

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810616589.6A Active CN109145350B (en) 2018-06-15 2018-06-15 Process analysis method based on queue logic Petri net

Country Status (1)

Country Link
CN (1) CN109145350B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110033125A (en) * 2019-03-14 2019-07-19 山东科技大学 A kind of business process analysis method based on fuzzy logic Petri network
CN112905151A (en) * 2021-03-23 2021-06-04 广东工业大学 Rapid creation method for multi-sensing channel fusion virtual experiment

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103632005A (en) * 2013-12-04 2014-03-12 中国航空综合技术研究所 Task reliability modeling method for failure reconfiguration process of dynamic reconfiguration system
CN108090720A (en) * 2017-12-07 2018-05-29 山东科技大学 A kind of process analysis method based on type petri nets

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103632005A (en) * 2013-12-04 2014-03-12 中国航空综合技术研究所 Task reliability modeling method for failure reconfiguration process of dynamic reconfiguration system
CN108090720A (en) * 2017-12-07 2018-05-29 山东科技大学 A kind of process analysis method based on type petri nets

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
王聘 等: "基于逻辑数据Perti网的业务过程建模与分析", 《计算机集成制造系统》 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110033125A (en) * 2019-03-14 2019-07-19 山东科技大学 A kind of business process analysis method based on fuzzy logic Petri network
CN110033125B (en) * 2019-03-14 2023-04-18 山东科技大学 Service flow analysis method based on fuzzy logic Petri network
CN112905151A (en) * 2021-03-23 2021-06-04 广东工业大学 Rapid creation method for multi-sensing channel fusion virtual experiment

Also Published As

Publication number Publication date
CN109145350B (en) 2023-04-07

Similar Documents

Publication Publication Date Title
Fu et al. Multiobjective stochastic economic dispatch with variable wind generation using scenario-based decomposition and asynchronous block iteration
Swain et al. Gravitational search algorithm for optimal economic dispatch
Balázs et al. Cube root fluctuations for the corner growth model associated to the exclusion process
CN106168797B (en) A kind of method that modularization obtains the useful item failure probability of nuclear power station fault tree
CN106936645B (en) The optimization method of tree network topology structure based on queueing theory
CN105740977A (en) Multi-target particle swarm-based power outage management optimization method
CN109840154A (en) A kind of computation migration method that task based access control relies under mobile cloud environment
CN109145350A (en) A kind of process analysis method based on queue logic Petri network
CN111667191A (en) Method and system for distributing dual-target robust resources under resource sharing and transfer visual angles
CN111695806A (en) Resource allocation method, device equipment and storage medium
Kong et al. Safety verification of nonlinear hybrid systems based on invariant clusters
CN109299160B (en) Power CPS security analysis method based on monitoring big data mining
CN108647771A (en) The layout method of research-on-research flow data under a kind of mixing cloud environment
CN105302650A (en) Dynamic multi-resource equitable distribution method oriented to cloud computing environment
CN112306658A (en) Digital twin application management scheduling method for multi-energy system
Archibald et al. Probabilistic bigraphs
Baroni et al. Fixed speed competition on the configuration model with infinite variance degrees: unequal speeds
CN107360031A (en) It is a kind of based on optimization overhead gains than mapping method of virtual network
CN102611924B (en) Flow control method and system of video cloud platform
CN110163255A (en) A kind of data stream clustering method and device based on density peaks
CN101299758B (en) Well-regulated group system for cosmically processing event as well as processing method
CN116405498A (en) Container scheduling method and system based on entropy weight method and multi-strategy particle swarm algorithm
CN105022870A (en) Service-oriented software performance modeling and simulation analysis method based on CPN (Coloured Petri Net)
US20090022160A1 (en) Low-latency scheduling in large switches
Ge et al. Hybrid ant colony optimization algorithm for solving the open vehicle routing problem

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant