MODELING TRAFFIC LIGHTS IN INTERSECTION USING PETRI NETS

Similar documents
Lecture 3: Probability Distributions

An efficient algorithm for multivariate Maclaurin Newton transformation

More metrics on cartesian products

Structure and Drive Paul A. Jensen Copyright July 20, 2003

College of Computer & Information Science Fall 2009 Northeastern University 20 October 2009

Transfer Functions. Convenient representation of a linear, dynamic model. A transfer function (TF) relates one input and one output: ( ) system

Lecture 4: November 17, Part 1 Single Buffer Management

The L(2, 1)-Labeling on -Product of Graphs

Affine transformations and convexity

find (x): given element x, return the canonical element of the set containing x;

Basic Regular Expressions. Introduction. Introduction to Computability. Theory. Motivation. Lecture4: Regular Expressions

Random Walks on Digraphs

Case A. P k = Ni ( 2L i k 1 ) + (# big cells) 10d 2 P k.

EEE 241: Linear Systems

Lecture 12: Discrete Laplacian

Lectures - Week 4 Matrix norms, Conditioning, Vector Spaces, Linear Independence, Spanning sets and Basis, Null space and Range of a Matrix

Expected Value and Variance

Problem Set 9 Solutions

On the Multicriteria Integer Network Flow Problem

COMPARISON OF SOME RELIABILITY CHARACTERISTICS BETWEEN REDUNDANT SYSTEMS REQUIRING SUPPORTING UNITS FOR THEIR OPERATIONS

Chapter 8. Potential Energy and Conservation of Energy

Modulo Magic Labeling in Digraphs

The Order Relation and Trace Inequalities for. Hermitian Operators

Amusing Properties of Odd Numbers Derived From Valuated Binary Tree

A Quantum Gauss-Bonnet Theorem

Module 9. Lecture 6. Duality in Assignment Problems

Comparison of the Population Variance Estimators. of 2-Parameter Exponential Distribution Based on. Multiple Criteria Decision Making Method

For now, let us focus on a specific model of neurons. These are simplified from reality but can achieve remarkable results.

On the correction of the h-index for career length

The internal structure of natural numbers and one method for the definition of large prime numbers

Discussion 11 Summary 11/20/2018

NUMERICAL DIFFERENTIATION

THE ARIMOTO-BLAHUT ALGORITHM FOR COMPUTATION OF CHANNEL CAPACITY. William A. Pearlman. References: S. Arimoto - IEEE Trans. Inform. Thy., Jan.

), it produces a response (output function g (x)

FACTORIZATION IN KRULL MONOIDS WITH INFINITE CLASS GROUP

A 2D Bounded Linear Program (H,c) 2D Linear Programming

Maximizing the number of nonnegative subsets

THE SUMMATION NOTATION Ʃ

Foundations of Arithmetic

9 Derivation of Rate Equations from Single-Cell Conductance (Hodgkin-Huxley-like) Equations

An (almost) unbiased estimator for the S-Gini index

Lecture Notes Introduction to Cluster Algebra

Exponential Type Product Estimator for Finite Population Mean with Information on Auxiliary Attribute

High resolution entropy stable scheme for shallow water equations

1 GSW Iterative Techniques for y = Ax

The Quadratic Trigonometric Bézier Curve with Single Shape Parameter

Linear Regression Analysis: Terminology and Notation

Difference Equations

Information Geometry of Gibbs Sampler

Physics 5153 Classical Mechanics. D Alembert s Principle and The Lagrangian-1

Topic 23 - Randomized Complete Block Designs (RCBD)

Numerical Heat and Mass Transfer

Physics 181. Particle Systems

Fuzzy Boundaries of Sample Selection Model

Ballot Paths Avoiding Depth Zero Patterns

Complement of Type-2 Fuzzy Shortest Path Using Possibility Measure

Convexity preserving interpolation by splines of arbitrary degree

CHAPTER 17 Amortized Analysis

NP-Completeness : Proofs

6. Stochastic processes (2)

LINEAR REGRESSION ANALYSIS. MODULE IX Lecture Multicollinearity

U.C. Berkeley CS294: Beyond Worst-Case Analysis Luca Trevisan September 5, 2017

Boostrapaggregating (Bagging)

6. Stochastic processes (2)

Subset Topological Spaces and Kakutani s Theorem

A new construction of 3-separable matrices via an improved decoding of Macula s construction

U.C. Berkeley CS294: Spectral Methods and Expanders Handout 8 Luca Trevisan February 17, 2016

HMMT February 2016 February 20, 2016

BOUNDEDNESS OF THE RIESZ TRANSFORM WITH MATRIX A 2 WEIGHTS

Time-Varying Systems and Computations Lecture 6

Chapter 5. Solution of System of Linear Equations. Module No. 6. Solution of Inconsistent and Ill Conditioned Systems

Case Study of Markov Chains Ray-Knight Compactification

Power law and dimension of the maximum value for belief distribution with the max Deng entropy

REGULAR POSITIVE TERNARY QUADRATIC FORMS. 1. Introduction

Polynomial Regression Models

THE RING AND ALGEBRA OF INTUITIONISTIC SETS

Composite Hypotheses testing

Dr. Shalabh Department of Mathematics and Statistics Indian Institute of Technology Kanpur

Turing Machines (intro)

Linear, affine, and convex sets and hulls In the sequel, unless otherwise specified, X will denote a real vector space.

Double Layered Fuzzy Planar Graph

CHAPTER 4. Vector Spaces

2E Pattern Recognition Solutions to Introduction to Pattern Recognition, Chapter 2: Bayesian pattern classification

Valuated Binary Tree: A New Approach in Study of Integers

Using T.O.M to Estimate Parameter of distributions that have not Single Exponential Family

Stochastic Structural Dynamics

Compilers. Spring term. Alfonso Ortega: Enrique Alfonseca: Chapter 4: Syntactic analysis

Lagrangian Field Theory

Multilayer Perceptron (MLP)

20. Mon, Oct. 13 What we have done so far corresponds roughly to Chapters 2 & 3 of Lee. Now we turn to Chapter 4. The first idea is connectedness.

Bayesian predictive Configural Frequency Analysis

Physics 5153 Classical Mechanics. Principle of Virtual Work-1

Application of B-Spline to Numerical Solution of a System of Singularly Perturbed Problems

Online Appendix to: Axiomatization and measurement of Quasi-hyperbolic Discounting

Advanced Circuits Topics - Part 1 by Dr. Colton (Fall 2017)

On quasiperfect numbers

3.1 Expectation of Functions of Several Random Variables. )' be a k-dimensional discrete or continuous random vector, with joint PMF p (, E X E X1 E X

Dynamic Systems on Graphs

Markov Chain Monte Carlo Lecture 6

Graph Reconstruction by Permutations

Transcription:

The 3 rd Internatonal Conference on Mathematcs and Statstcs (ICoMS-3) Insttut Pertanan Bogor, Indonesa, 5-6 August 28 MODELING TRAFFIC LIGHTS IN INTERSECTION USING PETRI NETS 1 Deky Adzkya and 2 Subono 1 Magster student of Mathematcs Department, Insttut Teknolog Sepuluh Nopember Jl. Arf Rahman Hakm, Kampus ITS Sukollo, Surabaya 6111 Indonesa 2 Lecturer of Mathematcs Department, Insttut Teknolog Sepuluh Nopember Jl. Arf Rahman Hakm, Kampus ITS Sukollo, Surabaya 6111 Indonesa e-mal : 1 adzkyadeky@telkom.net, 2 subono23@telkom.net Abstract. Petr nets are a graphcal and mathematcal modelng tool for descrbng and studyng dscrete event system. An example of such system s traffc lghts n ntersecton. Ths paper starts wth a bref revew of some defntons and termnology used n Petr nets. It then proceeds wth modelngsngle traffc lghts. Then we contnue wth modelng traffc lghts n ntersecton. The ntersecton has two lanes and two traffc lghts. We generalze the process to desgn Petr nets for traffc lghts n ntersecton conssts of arbtrary lanes. These general Petr nets are wrtten n algorthm. Keywords: Petr net, traffc lghts, ntersecton 1. Introducton Petr net graph conssts of two types of nodes. Crcles represent places and bars represent transtons. Every arc n Petr net have weght. Traffc lghts s an example of dscrete event system because the state space s a dscrete set and the state transton mechansm s event drven. In ths paper we model traffc lghts n ntersecton usng Petr net. We buld Petr net for sngle traffc lghts frst. Then we use the result to buld Petr net for traffc lghts n ntersecton. The ntersecton dscussed here has two lanes (Hanzalek, 26). There s a traffc lght n each lane. If ntersecton has more than two lanes, the prevous Petr net cannot be used. The reason s number of places, transton and arcs n Petr net depends on number of lanes n ntersecton. Next we generalze the process to buld Petr net. The purpose s to desgn general procedure to buld Petr net for traffc lghts n ntersecton conssts of arbtrary lanes. Ths general procedure s wrtten n algorthm. The output of ths algorthm s Petr net and one of ts nput s number of lanes. 2. Bref revew of petr net In early 196s, C.A. Petr developed Petr net frst tme. Petr net s a tools to model Dscrete Event System. Petr net conssts of places, transtons and arcs. Arc connects place to transton and vce versa. Each arc n Petr net have weght. Ths weght represents number of arc connectng place and transton. If no weght s shown on an arc, we wll assume t to be 1. Arc weghts s defned as a functon from set of arcs to set of postve nteger. Defnton 1 (Cassandras, 1993). A Petr net s a four-tuple (P,T,A,w) where P represents fnte set of places, T s a fnte set of transtons, A s a set of arcs, a subset of the set P T T P and w s a weght functon, w : A 1,2,3, In Petr nets, events are related wth transtons. In order for a transton to occur, several condtons may have to be satsfed. Informaton related to these condtons s represented by tokens contaned n places. Tokens n place represented by dot or a number. Number of tokens assgned to each place n Petr net defnes a markng. A markng x of a Petr net s a functon x : P,1,2,. Thus, a markng n each place defnes a state vector that contans n nonnegatve nteger where n s number of places n Petr net.

Defnton 2 (Cassandras, 1993). A marked Petr net s a fve-tuple P, T, A, w, x where (P,T,A,w) s a Petr net and x s an ntal markng. We now come to the crucal pont of defnng how a transton (.e., an event) s enabled. A transton t T n a marked Petr net s sad to be enabled f the number of tokens n p s at least as large as the weght of the arc connectng p to t for all p I t where t I represents the set of nput places to transton t. When a transton s enabled, we say that t can fre. We now defne the state transton functon through whch frng of transtons causes a change n the markng of Petr net. Defnton 3 (Cassandras, 1993). The state transton functon, f :,1,2, n T,1,2, n, of a marked Petr net P, T, A, w, x s defned for a transton t T f and only f transton t s enabled. If f x,t s defned, then we set x' f x,t p xp wp, t wt, p 1, n,, where x ' (2.1) 3. Modelng sngle traffc lghts The Petr net for traffc lghts n ntersecton conssts of some parts where each part represent traffc lghts n a lane. These parts are smlar because number of place, transton and arc are same. The dfference between each part s n arc weght. Arc weght calculated from how long red, green and yellow lght, turned on. The man dea of ths secton s to buld Petr net for sngle traffc lghts. In ths paper, we dstngush between place and transton name by uppercase and lowercase letters. Place and transton name are wrtten n uppercase and lowercase letters respectvely. Fgure 3.1 Petr net of Smple Traffc Lghts Frst we dscuss a Petr net of smple traffc lghts. Ths Petr net has 3 places and 3 transtons as shown n Fgure 3.1. Place M, H and K each represent red, green and yellow traffc lght. We call these places as lght place. Transton mh s used to change lght that turn on from red to green. Transton mh, hk and km n Fgure 3.1 s defned as change transton for smplcty. The token s used to ndcate whch traffc lght s turn on. The nformaton about how long traffc lght n each lane turns on s not ncluded n ths Petr net. We have to modfy the Petr net n Fgure 3.1 so the prevous nformaton can be handled. Frst step s to change token means. Token not only ndcates whch lght (red, green or yellow) s turn on but also shows how long the lght turns on. Number of token at ntalzaton n place M, H and K each represent how long red, green and yellow traffc lght turns on respectvely. We need a mechansm to check whether the lght place s empty. When ths place s empty, t s tme to change lght that turns on. For traffc lght n each lane we add a place and a transton. Ths new place and transton are called buffer place and buffer transton respectvely. Lght place s empty f number of token n buffer place equal wth number of token n lght place at ntalzaton.

Fgure 3.2 Petr net of Traffc Lghts wth Watng Tmes Traffc lght conssts of red, green and yellow color. Red, green and yellow lght each turns on for 8, 6 and 4 tme steps as seen n Fgure 3.2. Three token n place BH means green traffc lght has been turned on for 3 tme steps. Three token n place H means green traffc lght wll turn on for the next 3 tme steps. At ths condton, transton hn s enabled. Frng ths transton three tmes wll transfer all token n place H to BH. There are no token n place H and K so green traffc lght has been turned off but yellow traffc lght has not been turned on. Ths condton s called dle tmes, that s a stuaton where all lghts s turn off. Fgure 3.3 Petr net of Traffc Lghts Wthout Idle Tmes We can avod dle tmes by ensure there are token at the lght place. When lght place has one token, t s tme to change lght that turn on. The processes are conssts of take all token n buffer place and one token n lght place also gve some token to other lght place. We have to decrease arc weght from buffer place to change transton by 1 and add arc from traffc lghts place to change transton wth weght 1. Idle tme occur f buffer transton fred when there s one token n traffc lghts place. In order to avod dle tme we have to make buffer transton not enabled when lght place has one token so t can not be fred. We ncrease arc weght from lght place to buffer place to 2 and add arc from buffer place to lght place wth weght 1. The result n ths secton s used to buld Petr net for traffc lghts n ntersecton. In the next secton we dscuss modelng traffc lghts n ntersecton usng Petr net. 4. Modelng traffc lghts n smple ntersecton Petr net for traffc lghts n ntersecton s more complcated than Petr net dscussed n prevous secton. Modelng traffc lghts n ntersecton usng Petr net s dvded nto 3 parts. Frst part s modelng traffc lght for each lane n ntersecton. The second part s connects place represents red lght to all transton n other lanes. Fnal part s desgn arc to change served lane. In ths secton, we dscuss modelng traffc lghts n ntersecton consst of 2 lanes usng Petr net. Green and yellow lght turn on each for 6 and 4 tme steps at all lane. Below s the model of smple ntersecton that dscussed n ths secton (Hanzalek, 26).

Fgure 4.1 Smple Intersecton Model There s a man dfference between Petr net dscussed n prevous secton and ths secton. We defne how long each lght (red, green and yellow) turn on when we buld Petr net for sngle traffc lght. In ths secton, red lght n a lane turns on as long as there s green or yellow traffc lght turn on at other lane. Ths makes red traffc lght only represented by sngle place as shown n Fgure 4.2. We call ths place as red place for smplcty. Fgure 4.2 Petr net of Traffc Lghts n Lane 1 Petr net n Fgure 4.2 represents traffc lghts wth green and yellow lght each turns on for 6 and 4 tme steps. Traffc lghts n other lane can be represented by Petr net wth same number of place, transton and arc wth Petr net n Fgure 4.2. The dfference between those Petr net s ther arc weght. Arc weght depends how long green and yellow lght turn on. Fgure 4.3 Arc Connected to Place Represents Red Traffc Lght Number of token n red place shows how long ths traffc lght turns on. When we fre transton n other lane number of token n red place should decreased by 1. In order to do that we add arc from red place to all transton n other lanes wth weght 1. In ths example, there are 4 transtons at lane 2 that s hk2, hn2, kn2 and km2. In the fnal part we have to consder arc used to change served lane. When there s one token n place represents yellow lght, frng transton km makes red traffc lght n ths lane turns on and green traffc lght n next served lane turns on. We have to add arc from transton km to red place n ths lane and place represents green traffc lght n next served lane. Arc weght s how long each lght turns on.

Fgure 4.4 Transton to Change Served Lane After the fnal part s fnshed, we can combne all the result n ths secton to draw Petr net for traffc lghts n ntersecton conssts of 2 lanes completely. Ths Petr net has 1 places and 8 transtons as shown n Fgure 4.5. Fgure 4.5 Petr net of Traffc Lghts n Intersecton Conssts of 2 lanes In the next secton we generalze the process dscussed n ths secton. The result s an algorthm to buld Petr net for ntersecton conssts of arbtrary lanes. 5. Modelng general ntersecton General ntersecton means ntersecton conssts of arbtrary lanes. The result s wrtten n algorthm because number of place and transton n Petr net depends on number of lanes n ntersecton. In ths algorthm, arc defned as 3-tuple where frst element represents source place, second element represents destnaton place and thrd element represents arc weght. We used ndex n place and transton name show ts lane. Input: th, tk N, Output: P, T, Aw, x Algorthm: P {}; T {} Aw {}; x zeros5,1 for 1 to do P P M,K,H,BK,BH; Aw Aw H,hn,2, hn,h,1, T T hn,hk,kn, km hn,bh,1, H,hk,1 Aw K,kn,2, kn,k,1, kn,bk,1, K,km,1 Aw BH,hk, th 1, hk,k, tk, BK,km, tk 1 Aw Aw end for

for 1 to do for 1 to and do Aw Aw M,hn,1, M,hk,1, M,kn,1, M,km,1 end for Aw Aw km,h 1, th 1, km,m, x 1 1 end for x 1 th 1 th tk th tk In the prevous algorthm, Petr net s dentfed by P, T, Aw, x where the defnton of P, T and x same wth Defnton 1. Notaton Aw defned as Aw A w where A and w has been defned n Defnton 1. 6. Conclusons and future work Petr net for traffc lghts n ntersecton consst of 2 lanes has 1 places and 8 transtons. Generally number of place and transton n the Petr net are 5 and 4 respectvely. Number of place s dmenson of state space. We can reduce number of place n Petr net wthout lose any nformaton. After reduced, number of place n the Petr net become 4. There are some analyss we can do to Petr net lke boundedness, conservaton and coverablty state. The analyss can not be derved from Petr net drectly but we must buld coverablty tree frst. Propertes of the Petr net are bounded, not conservatve and fnte coverable state. There are two type of Petr net, that s tmed and untmed. All Petr net dscussed n ths paper are untmed Petr net. We can buld tmed Petr net for ths or other problem. 7. References Cassandras, C.G., (1993), Dscrete Event Systems: Modellng and Performance Analyss, Aksen Assocates Incorporated Publshers, Boston. Hanzalek, Z., Kutl, M., dan Cervn, A., (26), Balancng the watng tmes n a smple traffc ntersecton model, IFAC.