[IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)]...

8
Modeling and Simulation of Railway Traffic as a Hybrid System Venkatarangan M.l The Chinese University of Hong Kong Room 322, William M.W Mong Engineering Building Shatin NT, Hong Kong mjvrangaahoo.com Abstract- Purpose of the paper is to present a Model for the Railway traffic that consists of train arrivals and departures at different stations and also the people walking in stations, getting into trains and alighting. This is a good classical example of Hybrid system for which initially the existing models are looked at to discuss the drawbacks and the needs of models for this problem scenario. The model we consider here has been utilized to simulate the Railway traffic based on a schedule of the Train and People flow in the stations to analyze whether it can work without any conflicts, how it impacts the people movement and waiting, all in a single model and optimization of the schedule. With this, it is possible to calculate the ratio of the cost of running the train to the cost of people waiting and arrive at optimization for the scheduling of the train. All these are done with the assumed figures of people flow both on entry to the station till they get into the train and similarly the people flow from alighting the train till they walk out of the exits. Keywordsimulation and Modeng; Hybrid System I. INTRODUCTION When a Hybrid system problem is considered, it is always not straightforward to find the right model to be taken up for quick adaptation. Each of the hybrid system models would have certain positive aspects and draw backs considering different classes. Railway traffic is a typical case that is considered in this paper. Railway Traffic consists of train arrivals and departures at different stations and also in addition the people walking in stations, getting into trains and alighting. This is a good example of Hybrid system that has been considered in the work of this paper. The tenn 'Railway traffic' or simply 'Traffic' will mean the same in the entire paper. There are attempts made to model such system and simulate parts of this problem in different papers [2] and [6] but for different problems. In our work, we have considered a bigger system and problem to emphasize on the enhancements possible over the existing models. Paper [17] considers pedestrian movement alone, paper [2] considers the arrival and departure of train in a single transit station while paper [6] considers the train movement alone for simulation but in this paper, our interest is to consider all of them as a system which is very necessary as each of these sub-systems are interdependent and without it as a whole, we cannot arrive to the needed analysis and optimization. Aſter proposing the improved model considering certain important attributes needed for the problem, simulation is done using Prof Yam Yeung The Chinese University ofIong Kong Room 213, William M.W Mong Engineering Building Shatin, Hong Kong [email protected] MATLAB to bring out if there are any conflicts, analyze if there are any discomforts to the people in different stations and optimization of the train traffic based on these factors. The paper is organized as follows. Section II very briefly provides the motivation of the problem selection. Section III introduces the system and the problem description that is looked at. Section IV discussed briefly the suitability of the existing models while Section V presents the summary of the theory including mathematical equations and the model developed for analysis of the system. Section VI makes an attempt to explain the initial work done with the inferences about the Simulation output and the paper ends with conclusions. II. MOTIYATlON The railway system is always a motivational application since it involves careful tradeoffs of scheduling and costs. A paper published on Hybrid Petri nets based simulation in [2] triggered more thoughts to consider this problem definition and also to provide a amework in dealing with such problems. The paper provides an idea of how different models were looked at to decide on going forward with the proposition. The references looked at for solutions are primarily [2], [3], [6] and [17]. Other papers referred deal with a good theory of different models. III. SYSTEM AND PROBOLEM DEFINITION A. Transit Stations A railway line is considered to have multiple running trains which have a starting point P-S and a destination P-D as represented in Fig 1. The trains leave P-S and reach P-D in accordance with the schedule. The train would go through the stations P-2, P-3 . . . P-n-2, P-D and the time taken to move om one station to another is known but the wait time in each station is determined by the Train authority depending on the known floating crowd in each station. On moving via these stations, it will go through the sections S-1 followed by Place P-2, S-2 followed by P-3, S-3 followed by P-4 ...... S-n-2f followed by P-n-l to finally reach P-D. This makes the train line in one direction. The line is represented using the figure 2.

Transcript of [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)]...

Page 1: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

Modeling and Simulation of Railway Traffic as a Hybrid System

Venkatarangan M.l The Chinese University of Hong Kong

Room 322, William M.W Mong Engineering Building Shatin NT, Hong Kong

[email protected]

Abstract- Purpose of the paper is to present a Model for the

Railway traffic that consists of train arrivals and departures at

different stations and also the people walking in stations, getting

into trains and alighting. This is a good classical example of

Hybrid system for which initially the existing models are looked

at to discuss the drawbacks and the needs of models for this

problem scenario. The model we consider here has been utilized

to simulate the Railway traffic based on a schedule of the Train

and People flow in the stations to analyze whether it can work without any conflicts, how it impacts the people movement and

waiting, all in a single model and optimization of the schedule.

With this, it is possible to calculate the ratio of the cost of running

the train to the cost of people waiting and arrive at optimization

for the scheduling of the train. All these are done with the

assumed figures of people flow both on entry to the station till

they get into the train and similarly the people flow from

alighting the train till they walk out of the exits.

Keywords-Simulation and Modeling; Hybrid System

I. INTRODUCTION

When a Hybrid system problem is considered, it is always not straightforward to find the right model to be taken up for quick adaptation. Each of the hybrid system models would have certain positive aspects and draw backs considering different classes. Railway traffic is a typical case that is considered in this paper.

Railway Traffic consists of train arrivals and departures at different stations and also in addition the people walking in stations, getting into trains and alighting. This is a good example of Hybrid system that has been considered in the work of this paper. The tenn 'Railway traffic' or simply 'Traffic' will mean the same in the entire paper. There are attempts made to model such system and simulate parts of this problem in different papers [2] and [6] but for different problems. In our work, we have considered a bigger system and problem to emphasize on the enhancements possible over the existing models. Paper [17] considers pedestrian movement alone, paper [2] considers the arrival and departure of train in a single transit station while paper [6] considers the train movement alone for simulation but in this paper, our interest is to consider all of them as a system which is very necessary as each of these sub-systems are interdependent and without it as a whole, we cannot arrive to the needed analysis and optimization. After proposing the improved model considering certain important attributes needed for the problem, simulation is done using

Prof Yam Yeung The Chinese University ofI-Iong Kong

Room 213, William M.W Mong Engineering Building Shatin, Hong Kong

[email protected]

MATLAB to bring out if there are any conflicts, analyze if there are any discomforts to the people in different stations and optimization of the train traffic based on these factors.

The paper is organized as follows. Section II very briefly provides the motivation of the problem selection. Section III introduces the system and the problem description that is looked at. Section IV discussed briefly the suitability of the existing models while Section V presents the summary of the theory including mathematical equations and the model developed for analysis of the system. Section VI makes an attempt to explain the initial work done with the inferences about the Simulation output and the paper ends with conclusions.

II. MOTIY A TlON

The railway system is always a motivational application since it involves careful tradeoffs of scheduling and costs. A paper published on Hybrid Petri nets based simulation in [2] triggered more thoughts to consider this problem definition and also to provide a framework in dealing with such problems. The paper provides an idea of how different models were looked at to decide on going forward with the proposition. The references looked at for solutions are primarily [2], [3], [6] and [17]. Other papers referred deal with a good theory of different models.

III. SYSTEM AND PROBOLEM DEFINITION

A. Transit Stations

A railway line is considered to have multiple running trains which have a starting point P-S and a destination P-D as represented in Fig 1. The trains leave P-S and reach P-D in accordance with the schedule. The train would go through the stations P-2, P-3 . . . P-n-2, P-D and the time taken to move from one station to another is known but the wait time in each station is determined by the Train authority depending on the known floating crowd in each station. On moving via these stations, it will go through the sections S-1 followed by Place P-2, S-2 followed by P-3, S-3 followed by P-4 . . .... S-n-2f followed by P-n-l to finally reach P-D. This makes the train line in one direction. The line is represented using the figure 2.

Page 2: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

5-3

� 5-4 " "

" "

Figure 1 Representation of Railway Line

B. Station Places

SIJIIonN St;jtlon�l

Figure 2 Representation of Railway Line

Destination /Stint

Every station is comprised of places to enter and exit which are referred as Station entry and Station exit. Platform Places to enter and exit the train are referred as Platform entry and Platform exit respectively. People come through input gates, enter the station place and then enter the platform entry place to wait for the train. People who come out of the train to platform exit place will go out to station exit place and finally exit via the outflow gate. Fig 2 shows the simplified diagram for trains travelling in opposite directions. In the figure is shown the common platform for trains in both forward and backward directions. It is possible that the platform place may be different for both the forward and backward trains.

C. Problem Definition

The Simulation model will need to have the following inputs structurally: 1) Schedule of the train leaving from the starting point that includes the frequency of train. 2) Time to travel between the stations 3) Time parked in each station 4) Simulated input for people arrivals in each station with programmed destinations and this is for every station in the

network. Also included the time required for the passengers to walk till the train from the Station entry which would be accounted as part of the people flow rate between places.

The problem is to analyze the following: 1) Number of people in different places based on different models for people flow 2) Waiting time of people in the platform 3) Number of people in trains at different stations.

The expected output from this modeling and simulation must be the following: 1) Analysis of the properties of the model 2) Understand the behavior of the possible discomforts and crowd at different stations 3) How the schedule could impact this behavior. 4) Optimization of the train schedule considering traffic peak, cost of running the train and waiting time of the people.

IV. SUITABILITY OF THE EXISTING MODELS

A. Hybrid Automata The Hybrid Automata is a model which describes the

evolution in time of the values of a set of discrete and continuous state variables. This is only for autonomous systems that have no inputs and outputs. The railway system problem has inputs and hence this is not a suitable model to consider.

B. Hybrid Petri Net Petri Nets are usually used to model discrete systems with

the marking of a place that may correspond to either Boolean state of device or to an integer. When the Petri net contains a large number of tokens which would be the case for modeling this railway traffic, the number of reachable state explodes and is a limitation. Hybrid Petri Net is the extension of the Petri Net that is successfully applied for modeling, performance evaluation and manufacturing systems and recently the transportation systems as well. As proposed by Rene David and Hassane Alia in [4], this model will be suitable as worked out by [2] but it would be difficult to apply when we have to view the complete Railway line as a model, carrying people and train tokens. There is no concept of different data set to deal with train movement, people movement with different stations and also having concurrent transitions which is very much needed.

C. Color Petri Net (CPN)

ePN modeling and tools enables a good representation of people and trains as different color sets but this problem will need multiple colors based on the destinations. We would need transitions to be triggered with all color tokens moving and there is very much a need to have simultaneous multiple transitions getting triggered at the same time. ePN tools do not address the Petri net places with time.

D. Switching System Models

Switching systems model are mostly for hybrid time invariant systems that are viewed as autonomous and is a model where a differential equation needs to be selected depending on the switching signal. In our problem case, the switching happens on different discrete system triggers but the

Page 3: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

continuous systems are not classical cases of differential equations.

E. Specific needs of the model

There are specific needs for the model to address the problem defined while some of the existing models examined fail to address them effectively: 1) Triggers of two or more transitions at the same time is needed with an order that is needed 2) Need different data sets - tokens for train, tokens for people movement with different destinations as they all remain at the same time in places. 3) The movement of train itself and the people in train move together between stations that are discrete while the flow of people towards arriving train and leaving trains towards exits is continuous; hence we need discrete places as well as continuous places to be considered. 4) Continue using the incidence matrix from Petri Nets and programming concept like CPN.

V. PROPOSED MODEL

The model description is considered in different parts and is shown in Fig 3: 1) Model description of train movement 2) Model description of people flow from one station to other 3) Model description of people flow within stations which comprises of continuous flow model communicating with the discrete model. It is very important to note that this modeling will comprise of continuous system which requires only integers and does not need real numbers.

A. Train movement

The train movement is purely a discrete system based Petri net which starts at P-s and reaches the destination P-d. Tl is fired whenever a train is to arrive at the start P-s and this will be based on the schedule of the train. P-s, P-2, P-3, P-4, P-5, P-6, P-7 and P-d are platform places while S-I, S-2, S-3, S-4, S-5, S-6 and S-7 are the travel places for trains which are

(1) [Tr + d3+d4 ... d8)

between the platform places. P-l is same as P-s, P-d is same as P-8 but P-s and P-d are used to indicate they are the start and destination places. The train movement can be modeled with the incidence matrix shown in Table l. The timing behavior is modeled using the P-timed places. The P-timed places tstransit, t2transit till tldtransit represent how long the train waits at each Platform. The P-timed places sIt, s2t till s7t represents the time taken to travel between the platform places and this is referred as section place timings. tlarr timing represents the frequency of time of arrival of the train at the start platform and this is fired at tlarr but tlarr is a variable and need not be fixed.

1) incidence Matrix and Resultant matrix The resultant marking can be always found using

Equation 1 M = W. S + MO

Where M is the new marking after the firing S

MO is the initial marking of dimension [px 1]

W is the Incidence matrix [pxT]

S is the Trigger matrix that of dimension [Txl]

P is the number of places in the model

T is the number of triggers in the model

Refer [13] for the basics of the Petri Nets. In the model shown in Figure 3, only one direction is been shown to keep it simple for Simulations and discussions in this paper.

2) Marking and Properties of Petri Net with train

movement The train movement across the stations is purely a discrete

system. If we do not consider the people movement in the train and consider the tokens exclusively for the movement of train and analyze, it has the following properties.

(1) (Tr>d8)

lB'

[Te=1Tr); (OTr+""", <12)

T-ptfcnt -1 � v19n2

,---------, f v1en2

v1en1 : (v1en1_<I2) d2+ 2' (viani_d3) d3 +... � try.1

-+ (v1on1_d8) dB U n

v1en2 = (v1en2_d2) d2+ (v1en2_d3) d3 +... v1en1 + (v1.n2_dB) dB

T_cntry-1

,-�' �x2 T_oxlt-2

v2cn1 :;;; (v2cn1_d3) d3+ (v2enCd4) d4 + ...

+ (v2en1_d8) dB v2on2' (v2on2_d3)

d3+ (v2en2_d4) d4 + ... + (v1en2_dB) dB

v2ex1 : (v2ex1_d2) d2

v2ex2 : (v2ex2_d2) d2

Figure 3 Modeling based on Petri Net

v8ex2 : (v1!ex2_dB) d8

Page 4: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

Table 1 Incidence matrix for Train Movement: W = W+ - W­T1 T1' T2 T2' n n' n n' TS TS' T6 T6' T7 T7' T8 T8'

1 -1 () () () () () (} () 1 -1 () () (} (} (} () (} 1 -1 () () (} (} () () () 1 -1 (} (} (} () (} (} () 1 -1 (} (} () (} (} () () 1 -1 (} () (} (} () () (} 1 -1 () (} (} () () (} (} 1 () (} (} () () (} (} (} () (} () () () (} (} (} () (} (} () () (} (} (} () (} (} () () (} (} (} () (} (} () () (} (} (} () () (} () () () () (} () () () () () (} (} (}

() () () () () () () () () () () (} () () () () () () () (} () () () (} () () () (}

-1 () () (} 1 -1 () (} () 1 -1 () () () 1 -1 () () () 1 () () () (} () () () () () () () ()

() () () () (} () () () (} () (} () (} () (} () (} () () () (} ()

-1 () 1 -1 (} 1 () ()

() () () () () () () () () () () () ()

-1 ()

() (} (} (} (} (} (} (} (} (} (} (} (} ()

-1

P-s 5-1 P-2 5-2 P-3 5-3 P--4 5-4 P-S 5-S P-6 S-6 P-7 5-7 P-d

a) The number of train tokens cannot exceed one anytime. There cannot be more than one train in a station or a place.

b) The train leaves any of the platform places P-s, P-2, P-3, P-4, P-5, P-6 and P-7 only when there is no train in the respective next platform places P-I, P-2, P-3, P-4, P-5, P-6, P-7 and P-s has left that place respectively. This is modeled with inhibitors on transitions TI', T2', T3', T4', T5', T6', T7'. A train at platform place P-n shall leave the place at time t, only when the train at platform place P-n+ I has left at t-.

c) The Petri net will always be live since the firing in the net continues as long as tlarr is a value which fires the token to P-s provided no token is in P-s.

3) People movement in the train across the stations The incidence matrix in Table I is good to model the train

movement and comes from the Petri net basics. The incidence matrix also enables us to get all the reachable markings. It does not model the flow of people since it does not incorporate tokens of separate groups based on the destination. It can very well be modeled using the Color Petri Nets with tokens representing color sets to signifY both the number and the destination say: (n, destination). But the firing control, especially on the arcs Ti-arrI, TI-arr2 etc. can be controlled using the actions like, if destination of the token is say P-n, then fire, otherwise not. But this remains as semantics as needed for the programming tool and on paper the description needs to be read. But the disadvantage is that it may not exactly help us to build a mathematical equation. From this point of view, there are new arcs defined which are called channel arcs that are defined and explained in next sections.

B. Channel Arc Transition

The need for this is to enable the firing of the transition that moves the people from platform to train on arrival of train and the train continues on the track.

Definition I: Let N=(P, T, B, F, MO) be a Petri net where P and T are two disjoint sets called places and transitions; B and F are two

functions fTOm PxT to N called backward and forward incidence functions, MO is a function from P to N called the initial marking. There is a new transition set Tc defined which will have the form: (Te) : (Tr).

0(Te):(Tr)

Figure 4 Representation of a Channel Arc Transition

Tr - Data set token numbers to be removed from the place when transition is fired. Te - Data set to be available in place for transition to fire. This is the symbolic form of the data set.

Definition 2:

A channel arc transition Tc is enabled in M(t) iff Vp € P:M(p) >= B(p, t) leading to that it can be fired to a new marking M'.

Channel arcs are the arcs which allow the firing based on a channeling mechanism. Instead of having a weight of I or a finite number 'n' for arcs, the idea is to define the weights to control the enabling based on the color of the tokens or based on the dataset. The channel arcs are represented with an oval shape on the arcs defined from basic Petri nets as explained with the help of Fig 5 and Fig 6.

(To=N1 d1 or N2 d2 or N3 d3): (Tr=Ds) (Te=N1 d1 and N2 d2 and N3 d3): (Tr= Os)

Figure 5 Channel Filter Arc Representation

This channel filter arcs are the arcs which has a weight of two forms AND and OR. First form is AND:

(NI dI) and (N2 d2) and (N3 d3)

This means, the place to which the arc is an output must have NI tokens of dataset dI, N2 tokens of dataset d2, N3 tokens of dataset d3 etc. to satisfY the firing condition of the transition to which this arc is connected as an input. When the firing takes place, the tokens that will be removed fTOm the place will be Ds.

The other form of weight indication is: (NIdI) or (N2 d2) or (N3 d3). In this form, if any of the condition is satisfied then the firing condition is satisfied.

1) Enable Arcs

Figure 6 Channel Enable arc

Fig 6 shows arcs that act as an enabler when at least one token of the dataset 'd' is available while on firing, no token is removed.

(Te):(Tr)

Page 5: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

The next sections explain how these channel arc transitions are used in the proposed model Fig 3.

C. More details about the model

entry., .L on,

T_entry.1

v1on1 -(v1on1_d2) d2+ (v1enCd3) d3

v1en2 = (v1en2_d2) d2+ (v1Gn2_d3) d3

(')(Tr+d3)

P_S nE2.J:

v x,

• lox T_exi oJ

Figure 7 Model representing three stations using channel arcs

Fig 7 is a simplified form applied for lesser number of places and is a subset of Fig 3 to explain the basic concepts behind.

1) Descrete Events At P-s, there is an outgoing channel arc with weight (O)Tr

to the transition T _land-I. Also, T _land-l has an incoming arc from the place P _PlfEntry-i. The transition T _land-l will be fired when there is a token with dataset Tr in P-s which represents train and a token available in P _PlfEntry-i. But the '0' in Tr represents that no token will be removed from P-s when T-land-l is fired but all the tokens will be removed from P _PlfEntry-i. At P-2, the arcs to and from T _land-2 has the same significance as explained. At P-2, there is an outgoing channel arc to T_arr-2 which has weight d2. This means, the tokens with data set d2 will be removed from P-2 and added to P _PlfExit-2 since there is an outgoing arc from P _PlfExit-2 to T_arr-2 . The same explanation holds good for the channel arc from P-d.

2) Continuous Events The continuous transitions T-entry-l, T�lfentry-l,

T _ entry-2, T �lfentry-2, T �lfexit-2, T _ exit-2, T �lfexit-3, T _ exit-3 all give rise to continuous flow of people with the flow rate of vi en 1, vlen2, v2enl, v2en2, v2ex2, v2ex3, v3exl and v3ex2 respectively.

vienI: Signifies the people flow into the Station. It is represented using the tokens of dataset d2 (destination is P-2) and d3 (destination P-3 or P-d).

Equation 2: vieni = vIenI_d2*d2 + vIen2_d3 * d3

vIenI_d2 and vIen2_d2 represents the number of people entering in a specific amount of time and intends to reach destination P-2 and P-s.

vIen2: signifies the people flow from Station Place into the Platform place. It is represented using the tokens of dataset d2 (destination is P-2) and d3 (destination P-3 or P-d).

Equation 3: vlen2 = vlen2_d2*d2 + vlen2_d3 * d3

vlen2_d2 and vlen2_d3 represents the number of people in a specific amount of time entering and intends to reach destination P-2 and P-s respectively.

v2eni and v2en2 is same as vlenl and vlen2 except that it is for Station and Platform places in 2nd station.

v2exI: is the people flow from Platform Place to Station Place.

v2ex2: is the people flow from Station Place to going out of Station at the exits .

v3exi and v3ex2 is same as v2exl and v2ex2 except that it is for Station and Platform place number in 3rd station.

It is also possible to consider the flow rates for the people flow for entry and exit from train on arrival of the train. But it is intentionally not considered here as this rate is very high and all the people in platform will be able to board and come out of the train before it departs.

Mathematically, the incidence matrix considering Train as well as the people flow for the model shown in Fig 7 is as shown in Table 2. Number of places in total is 13 and the number of triggers is 19 making the incidence matrix of dimension 13x19. 'max' within the table signifies that all the tokens from the places will be removed or added. The new marking of the place will be calculated based on Equation 1.

D. People movement within a station

Station entry places: P _ StnEntry-l, P _StnEntry-2

Station exit places: P _ StnExit-2, P _ StnExit-3

Platform entry places: P ]lfEntry-l, PlfEntry-2

Platform exit places P _PlfExit-2, P _PlfExit-2

Some example of marking changes on different transition firing is shown in Table 3.

With initial marking as all zeroes, the table 3 shows the change in markings on different triggers. Values considered in the example are: vlenl_dl=lO, vlenl_d2=1O, vlen2_dl=8 and vlen2_d2=8. T_entry-l, T_entry-2, T�lfentry-l, T�lfentry-2 are the triggers that can occur at the same time but the ordering of trigger is extremely important.

Page 6: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

Table 2 Incidence Matrix

P SlnEntry-l

PPlEntry-l

P StnEntry-2

PPI'Entry-2

(1)Tr+(max) (-1)Tr+(-(d2+d3) max)(d2+d3)

(1)Tr+ :�1)Tr+ 0 (max)d3 maxjd3

(1)Tr+ (max) (-1)Tr 0

d3 v1en1_d2'd2 (·v1en2_d2),d2 +v1en1_d3'd + 3 (·v1en2 d3)"d3

v1en2_d2'd2

v1en2 d3-d3

Table 3 Plaee marking for entry plaees on train arrival n,

T..J>Ifentry.1, T...,PIfentry-l, _�-:':���'''''''' _T�:��:;,

2,.. _Tl':��?'1'�'''''' -T_land-1 .... r-__ --;T-entry-2 T_enlry.2

(-max)dl + (-max)d2

P-, (1)Tr (1) Tr -+ 16"d2 -+- 16-d3

5_1

P-2

5-2

P-d

P StnEntry.1

P PlfEntry.1

P StnEntry.2

P PlfEntry-2

P PlfExit.2

P StnExit-2

P PlfExit·3

P Exit-3

10"d2·'O"d3

10 dJ

12"d2.'2"d3 14"d2+14"d3

8"d2+8"d3

12"d3

S"d3

16"d2+16"d3

14"d3

16"d3

14"d2·14"d3

14"d3

16"d3

The platform entry place and platform exit place are physically the same in real world since the arriving and boarding passengers share the common place but it is referred separately in the modeling to keep track of the people as separate entities. The station exit place is one from where the people go out through the output gates. Please note that the starting station has P-s has only entries while the destination station P-d has only exits.

Each railway station has a periodic operation which starts on the arrival of the train. The train is halted for a period of tstransit, t2transit and tdtransit in each platform after which the transition T1', T2' and T3' is fired respectively. The passengers board from P _PltEntry places and arrive in P ]ltExit places.

Table 4 is an example to show the triggers which shows the marking changes on the exit places P _PltExit-2, P _ StnExit-2 when the train arrives and fires transition T_arr-1, followed by

(·maxjd2

(max)d2 (-v2ex1 d2)'d2 (·v2exZ_d2)

o (v2ex1 d2)'d2 '<12

(-max)d2

..

(-o (v2ex1_d2)"d2 v2ex2_d2)'d2

T-'and-1 for people to enter the train. v2ex1_d2=v2ex2_d2=40 in the example.

The transitions T_arr-1, T_arr-2, T_arr-3 etc. occurs on the train arrival for the people to exit the train and is clearly a discrete event. Only one data set of tokens pertaining to that destination are removed from Platform and Station places destination as the people exit from trains and till they exit Station Place.

Table 4 Place marking for exit places on train arrival

5-1

P� (l)Tr + 80-d2 + BOd3 {l)Tr+BO'd3 (l)Tr+ 184'd3

p�

P StnEntry.1 36"d2+36"d3 36"d2+36"d3 36"d2+36*d3

P PlfEntry.l 24'd2+24'd2 24-d2+24'd2 24'd2+24'd2

P StnEntry.l 36"d3 36*d3 36"d3

P PlfEntry.2 104"d3 lQ4"d3 P PIExit.2 80"d2 40"d2

P Str£xit·2 40'd2

P PIExit·3

P Exit·3

VI. SIMULA TION OF MODEL AND OUTPUT ANALYSIS

A. Inputs to the Simulation

The inputs to the model were: 1) Number of stations to be considered 2) Scheduling of the train based on which the train arrives in the first station. 3) Programming the net to include the waiting time in each platform and travel time between platforms 4) Inflow rate via the gates to enter the station, the inflow rate to enter platform place from station place and. 5) exit flow rate from platform to the station place and finally to exit the station place to go out.

Page 7: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

The flow rates can be independently different numbers for each station and platform.

Following inputs were made use of for the simulation as an example:

1) 8 stations were considered as in Fig 3 leading to an incidence matrix of dimension (43x58) that is 43 places and 58 triggers.

2) Train will enter the first station at a frequency of 15 minutes and can be changed to check the impact on the network.

3) TainDwellTimeAndTravelTime = [2 2 3 3 3 2 3 2 3 1 4 2 3 6 7] is considered which signifies tstransit, sltransit, t2transit, s2transit etc. upto tdtransit.

4) Inflow rate was considered at the rate of 10 per minute for each data set for entry to Station from outside. This means,

vlenl dl=vl enl d2=vl enl d3= . . . vl enl d8 . . . =10. - - - - - - -

v2enl d2=v2 enl d3=v2 enl d4 . . . =v2 enl d8 = W . . ... etc. Similarly, the inflow rate considered is 8 per minute for each data set from Station to Platform. people/minute etc. as the number of data set from each station will not be the same.

5) Outflow rate is only for set of data set on exit place as people pertaining to that station will exit. v2_exl_d2=v3_exl_d3= . . .. =v8_exl_d8 = 30 people per minute. v2_exl_d2=v3_exl_d3= . . .. =v8_exl_d8=50 people per minute.

vlen2 dl=vl en2 d2=vl en2 d3= . . . vl en2 d8 . . . =8. - - - - - - -

v2enl d2=v2 enl d3=v2 en2 d4 . . . =v2 en2 d8 = 8 . . ... etc.

However, the total people flow rate to entry in stationl will be 10*7=70 people/minute; station2 will be 10*6=60 people/minute.

B. Outputs and inferences from the Simulation

There were 2 plots taken, one at a frequency of 10 minutes and the other plot at a frequency of 15 minutes with all other parameters remaining constant for a qualitative analysis. Refer Fig 10 and Fig 11 for the details

Following analysis can be derived from the output when we have fed the real data into the network:

1) The places in the Petri net are considered to be k-bounded. The number of train tokens does not exceed 1 with the selected parameters. There cannot be more than one train in a station. The number of people in the train at any point of time does not exceed the value of considered 'k' value which depends on the capacity of the train and the simulated output can be used as a measure to find out whether the frequency and waiting times of train in each platform meets this requirement.

2) The station entry and exit places, platform entry and exit places are also considered to be k-bounded. The number of people must not exceed the capacity of these places to determine whether it leads to an uncomfortable feeling to the passengers. This also calls for design to suite the capacity.

3) The plots show two important parameters that are to be considered for the optimization: a) Ratio of the instant cost of running train to the instant waiting time of the people b) Ratio of the accumulated cost of running trains to the accumulated waiting time of the people. If there is a reference that needs to be maintained for these parameters, there is a tradeoff on the parameters: a) Frequency of the train b) Waiting time of the train in the platforms between arrival and departure c) Capacity of the places.

':! :: 1 <t-> rl C2:1 ;r(--�-=�i�L��--�----�--�--�--'Qj �j � �� ,�Gj ��

, - CI:1 :'L �----7- � - --!---!- rs'

". _ .!. .!._J _, __ .\ __ � __

Figure 8 Plots of outputs, train frequency at P-s: 10 minutes

Figure 8 and 9 plots have the following outputs:

1) Arrival and departure of trains in different platforms. Value of 1 shows that the train is available P-s, value of 2 shows that the train is available P-2 etc.

2) Accumulated and instantaneous waiting time of passengers in minutes.

3) Accumulated cost of running the trains

4) Instantaneous cost of running the trains

5) Ratio of accumulated and instantaneous costs of running train to accumulated and instantaneous waiting time of people.

Costs are simply number of trains running. Ratio is simply number of trains divided by waiting time in minutes but multiplying by 10000 for plotting purposed.

When the frequency of the train is lowered to 15 minutes, the waiting time of the passengers increases and is higher initially as compared to 10 minute frequency. The ratio of the cost of running train to waiting time of passengers is higher when the frequency is 10 minutes.

I. CONCLUSIONS

The model and simulation gives a framework on how the railway system problem can be considered to build mathematical equations using matrices and find different reachable markings. If the model and simulation is prepared to take details of network including all other parameters of the railway network, it would enable and provide inputs for many design parameters to be considered for Railways stations­design of the capacity of the platforms and different places in station, frequency of the trains considering different flow rates.

Page 8: [IEEE 2014 8th Annual IEEE Systems Conference (SysCon) - Ottawa, ON, Canada (2014.03.31-2014.04.3)] 2014 IEEE International Systems Conference Proceedings - Modeling and simulation

Train Arrival and Departure Train Arrival and Departure Train Arrival and Departure

in P-6 (Platform6) }m ro s (PI"Ss\ t/�2 (p:o

:

m� � � o w � � a � M 80

---C"' 01 80

01 80

°1 80 ::[ : Q) 1 0�--------�1�0 ----��-=�2�0������3�0�=========4�0===========5�0===========6�0�--------�70----------�8'0

Figure 9 Plots of outputs, train frequency at P-s: 15 minutes

REFERENCES

[I] Modeling, Analysis and Design of Hybrid Systems, 2002. Lecture Notes in Control and Information Science. Springer Volume 279 2002 ISBN: 978-3-540-43812-0. Sebastian Engell, Goran Frehse and Eckehard Schnieder.

[2] Simulation of Railway stations based on Hybrid Petri Nets. 2006. In 2nd IFAC Conf. on Analysis and Design of Hybrid Systems (Alghero, Italy), Feth, Said, Abdella. 7-9 June 2006.

http://www.diee.unica.it/-adhs06/CD/P APERS/w A2.4 .pdf

[3] Coloured Petri Nets and CPN Tools for Modelling and Validation of Concurrent Systems. Kurt Jensen and Lars Michael and Lisa Wells. http://wiki.daimi.au.dk/cpntools/_files/cpntoolssttt07.pdf

[4] Discrete, Continuous and Hybrid Nets, 2005 edition. Springer. ISBN 3-540-22480-7. Rene David and Hassane Alia.

[5] Petri Net Theory and the modeling of systems. Publication: June 1981 ISBN 0136619835 James L. Peterson.

[6] Train Traffic Simulation with Coloured Petri Nets and Schedule Optmisation, 2005. ISSN 1392 - 1215 ELEKTRON1KA IR ELEKTROTECHNIKA. 2005. Nr. 3(59) S. Bartkevicius, V.Bagdonas, M.Juraska and K. Sarkauskas.

[7] Modelling and Analysis of Hybrid Supervisory Systems. A Petri Net approach. 2007. ISBN 978-1-84628-650-6. Emilia Villani, Paulo E. Miyagi and Robert Valette.

[8] Lecture notes on Hybrid systems. 2004. John Lygeros. http://robotics.eecs.berkeley.edu/-sastry/ee291 e/lygeros. pdf

[9] Analysis of Railway stations by means of Interval time color Petri nets, Real Time systems 9, 241-263, and 1995.

[10] A deadlock prevention method for railway networks using monitors for colored Petri nets. Systems, IEEE International conference. Publication Date: 5-8 Oct. 2003 Volume: 2, On page(s): 1866- 1873 vol.2 ISSN: 1062-922X, ISBN: 0-7803-7952-7

[11] A Premier in Petri Net Design W. Resig, ISBN 3-540-52044-9

[12] Petri Net Properties, Analysis and Applications. Invited Paper IEEE 77, 1989,541-580. Tadau, Murata.

[13] A brief introduction to colored Petri nets, Lecture notes in computer science, 1997,203-208.

http://www.daimi.au.dk/-kjensen/papers_books/briefpdf

[14] Petri Net on Wikipedia about http://en.wikipedia.orgiwiki/Petri_net

[15] Modeling Passenger flows at a transport interchange using Petri nets. Proceedings of the institution of Mechanical Engineers. Part F: Journal of Rail and Rapid Transit 217 (2) 2003 125-134. R.Takagi, c.J. Goodman, C. Roberts

[16] Lecture notes - Hybrid Systems. Oct 27, 2004. Thomas Bak, Roozbeh Izadi-Zamanabadi, (with input from class)

http://www.control.aau.dk/-tb/HS/hs.pdf

[17] Hybrid Dynamical Systems. IEEE Control Systems Magazine, April 2009. Rafal Goebel, Richardo G. Sanfelice and Andrew R. Teel.