# Simulation-Based Dynamic Passenger Flow Assignment Modelling for a Schedule-Based Transit Network

Authors: Xiangming Yao; Baomin Han; Dandan Yu; Hui Ren
Journal: Discrete Dynamics in Nature and Society
 (2017)

---

## Abstract

The online operation management and the offline policy evaluation in complex transit networks require an effective dynamic traffic assignment (DTA) method that can capture the temporal-spatial nature of traffic flows. The objective of this work is to propose a simulation-based dynamic passenger assignment framework and models for such applications in the context of schedule-based rail transit systems. In the simulation framework, travellers are regarded as individual agents who are able to obtain complete information on the current traffic conditions. A combined route selection model integrated with pretrip route selection and entrip route switch is established for achieving the dynamic network flow equilibrium status. The train agent is operated strictly with the timetable and its capacity limitation is considered. A continuous time-driven simulator based on the proposed framework and models is developed, whose performance is illustrated through a large-scale network of Beijing subway. The results indicate that more than 0.8 million individual passengers and thousands of trains can be simulated simultaneously at a speed ten times faster than real time. This study provides an efficient approach to analyze the dynamic demand-supply relationship for large schedule-based transit networks.


---

## Body

## 1. Introduction

Urban rail transit has developed rapidly in China during the last ten years. By the end of 2015, there were 26 cities operating the rail transit with a total length of 3,618 km [1]. With the travel demand growing radically, some intractable issues emerge for the operation management, such as the recurrent congestion in peak hours and the train schedule construction for the travel demand under extremely unbalanced conditions. It has been conjectured that the development of Dynamic Traffic Management Systems (DTMS) can be a feasible approach for addressing these prominent problems. However, assessing the benefits and influences of such systems are difficult as these strategies are highly dependent on the travel behavior of individual passenger in response to travel information and control actions. Hence, it is necessary to develop useful methods and tools for assessing the DTM policies and control strategies.Dynamic traffic assignment (DTA) models are regarded as a valuable tool to evaluate the DTM performance for its capabilities in capturing the dynamic nature of traffic flows and describing the formation and propagation of traffic congestions. DTA models can be divided into two categories: the mathematic-based DTA models and simulation-based DTA models. Mathematic-based DTA models, such as optimization programmes [2], variational inequalities [3], and optimal control [4], have solid theory foundations and perfect analyzability. However, few of them are implemented in real-world traffic networks because of their limitations in computation efficiency and complex parameter requirements. Simulation-based DTA models are considered more suitable for real-world applications [5, 6]. There have been several DTA simulators developed and applied to road networks, such as DYNAMIT (https://its.mit.edu/software/dynamit) and DYNASMART (http://mctrans.ce.ufl.edu/featured/dynasmart/). Unfortunately, the previous models and tools are mainly developed for road traffic networks. The traffic flow characteristics in transit system are much different within road traffic, where the passenger flows are highly nonlinear. Hence, DTA models in road traffic systems are not suitable for transit system. The DTA tools for the specific schedule-based rail transit networks are underdeveloped.In the sphere of transit assignment, the DTA models also can be divided into two categories, the frequency-based models and the schedule- or timetable-based models [7]. Frequency-based approaches consider services in terms of sets of lines, where the run scheduled times are not considered explicitly, while the schedule-based approach refers to services in terms of runs, using the real vehicle arrival/departure time to obtain attributes that can be explicitly considered in the run choice. With the development of transit modelling, the DTA approaches have gradually changed from frequency-based models to schedule-based models. The capacity limitation of vehicles is a critical point that should be considered in transit systems, because passengers can only travel through sections by trains that have strict capacity constraints. However, previous approaches, whether frequency- or schedule-based, have mainly focused on line capacities not vehicle capacities [8]. The “fail-to-board probabilities” is usually used to describe the approximate congestion conditions of vehicles [9, 10]. In this work, the train is seen as an individual agent and its capacity constraints can be strictly described by limiting the number of boarding passengers. Therefore, queuing processes for passengers waiting on platforms can be captured. For the schedule-based transit assignment models, the space-time or diachronic graph is usually used to represent the transit services network, which contains the service, demand, and access/egress subgraphs [11–14]. However, this kind of space-time network is extremely complex when transit lines and transit services (train runs) are large. It is difficult to find a shortest path quickly in the networks. In order to enhance the computation efficiency of the DTA models, a two-stage path choice process is constructed in this work. First, search the k shortest paths for each OD pair without considering the passenger flows and train services. This process seeks to establish the interrelationship between links and ODs. Second, update the cost of each route with the simulation clock advancing by considering the real-time passenger flows and services. When passengers enter the transit system, they can choose the “best” path immediately through the current traffic conditions. The two-stage path choice process has high efficiency because the speed for updating route cost is much quicker than searching a new route.This work aims to propose an efficient and practical simulation-based DTA framework and models for the schedule-based rail transit network. The characteristics of the proposed approaches include (1) describing the travel behavior at the level of individual passengers and presenting the detail travel processes for passengers travelling through the network, such as walking within the station, waiting, transferring, boarding, and alighting; (2) integrating the pretrip and enroute path choice behavior together, which not only allows describing the route selection processes in normal conditions but also enables to capture the enroute switch behavior under exceptional conditions; (3) the capacity which is considered by the accurate train load capacity instead of the line capacity and the train runs which can adapt to different types of timetable; (4) the simulation models having high computational efficiency for large scale (large number of passengers and trains) rail transit networks.The remainder of the paper is organized as follows. The simulation-based modelling framework for DTA in the schedule-based transit network is given first. Following are the major models under the simulation framework, mainly including passenger generation, route selection, and network-loading models. Then, model implementation in the Beijing subway networks are presented in Section4. Finally, Section 5 presents the conclusion and future works.


## 2. Modelling Framework

Generally, any simulation-based DTA systems consist of two critical components: a route selection module and a network-loading module [16]. The route selection module describes the principle for travellers choosing their route and then determines the macroscopical flow status on the network. The network-loading module attempts to represent the temporal-spatial evolution of traffic flows on the network after the routes of passengers are determined. Figure 1 presents the simulation-based DTA framework and model structure for a schedule-based transit network, where the major parts are highlighted.Figure 1
Simulation-based DTA framework and model structure for a schedule-based transit system.In the simulation framework, travellers are regarded as individual agents who can obtain the current traffic conditions on the network and always select the best path. Trains are operated strictly with the preset timetable, which allows considering the strict arrival/departure time. The simulation processes for obtaining the macroscopical network flow status are to describe the whole travel procedures of all individual passengers in microscopic view, such as egress/access, waiting for the train, and transferring through passageways. The detailed introduction of these two critical components is provided in the next section. Additionally, the network structure and the travel demand generation that produces the input for DTA models are important and will also be introduced in Section3.


### 2.1. Route Selection Module

There are several types of route choice models for different applications, such as equilibrium-based or information-based, pretrip or enroute, and within-day or day-to-day. Detail descriptions of passenger choice models can infer to the review of Szeto and Wong [17]. In this work, the within-day dynamic user equilibrium (DUE) is used to describe the principle for traveller route choice, which can be seen as follows: when travelling, travellers should always select their “best” path at each decision point, and the cost of used routes is no larger than the unused routes. In a rail transit network, passengers usually have no secondary route when they are at the enroute decision points (transfer stations) because of the low connectivity of the network. Hence, the pretrip user equilibrium principle can be suitable in normal conditions. However, passengers should change their routes in some special conditions, such as switching their routes when they cannot go to the end for incidents. In order to enhance the capability of models in describing the passengers routing behavior under different situations, a combined route selection method which integrated the pretrip and enroute models is used in this work. The pretrip route selection model which follows the dynamic user equilibrium is established under normal conditions. Moreover, the enroute path switch model based on a bounded rational rule is applied for special situations. This combined model is consistent well with the path selection behaviors of rail transit passengers.Though the rail transit network has low connectivity, there may also exist alternative route in an OD pair. Thek-shortest paths are used to describe the discrepancy in route choice behavior of different passengers. How to find the “best” route immediately for each traveller is of great influence on the computation efficiency of a simulation system. For a large-scale network, it is almost impossible to search the routes online. A two-stage path choice process is established in this work, which contains (1) initial k-shortest paths search and (2) the real-time route cost update. The process of initial k-shortest paths search is to establish the interconnections between links and OD paths, and the route cost updating procedure aims to describe the real-time traffic conditions on the network. The route cost will be refreshed in a small preset time interval (such as two minutes). When a passenger enters the station, he/she can choose the “best” path quickly by considering the approximate real-time traffic conditions. Hence, the flow state of the network is not a rigorous but an approximate user equilibrium status.


### 2.2. Network-Loading Module

Once the traveller’s route is determined, the network-loading module is to simulate the movement of travellers through the network, with the output of dynamic flow distributions of nodes (stations/platforms) and sections (trains). In this work, the continues-time-driven simulation approach is utilized to simulate the processes of all passengers moving on the network. The network-loading module contains three major components: (1) passenger walking within the station, such as access, egress, and transfer; (2) train movement operation; and (3) interactions between passengers and trains on platforms. The detailed description of these components will be presented in Section3.


## 2.1. Route Selection Module

There are several types of route choice models for different applications, such as equilibrium-based or information-based, pretrip or enroute, and within-day or day-to-day. Detail descriptions of passenger choice models can infer to the review of Szeto and Wong [17]. In this work, the within-day dynamic user equilibrium (DUE) is used to describe the principle for traveller route choice, which can be seen as follows: when travelling, travellers should always select their “best” path at each decision point, and the cost of used routes is no larger than the unused routes. In a rail transit network, passengers usually have no secondary route when they are at the enroute decision points (transfer stations) because of the low connectivity of the network. Hence, the pretrip user equilibrium principle can be suitable in normal conditions. However, passengers should change their routes in some special conditions, such as switching their routes when they cannot go to the end for incidents. In order to enhance the capability of models in describing the passengers routing behavior under different situations, a combined route selection method which integrated the pretrip and enroute models is used in this work. The pretrip route selection model which follows the dynamic user equilibrium is established under normal conditions. Moreover, the enroute path switch model based on a bounded rational rule is applied for special situations. This combined model is consistent well with the path selection behaviors of rail transit passengers.Though the rail transit network has low connectivity, there may also exist alternative route in an OD pair. Thek-shortest paths are used to describe the discrepancy in route choice behavior of different passengers. How to find the “best” route immediately for each traveller is of great influence on the computation efficiency of a simulation system. For a large-scale network, it is almost impossible to search the routes online. A two-stage path choice process is established in this work, which contains (1) initial k-shortest paths search and (2) the real-time route cost update. The process of initial k-shortest paths search is to establish the interconnections between links and OD paths, and the route cost updating procedure aims to describe the real-time traffic conditions on the network. The route cost will be refreshed in a small preset time interval (such as two minutes). When a passenger enters the station, he/she can choose the “best” path quickly by considering the approximate real-time traffic conditions. Hence, the flow state of the network is not a rigorous but an approximate user equilibrium status.


## 2.2. Network-Loading Module

Once the traveller’s route is determined, the network-loading module is to simulate the movement of travellers through the network, with the output of dynamic flow distributions of nodes (stations/platforms) and sections (trains). In this work, the continues-time-driven simulation approach is utilized to simulate the processes of all passengers moving on the network. The network-loading module contains three major components: (1) passenger walking within the station, such as access, egress, and transfer; (2) train movement operation; and (3) interactions between passengers and trains on platforms. The detailed description of these components will be presented in Section3.


## 3. Traffic Simulation Modelling

### 3.1. Network and Train Schedule

The rail transit network is represented by a directed graphG=(N,A,L), where N is the node set, A is the link set, and L is the set of transit lines. The nodes consist of two types: source and sink nodes (entrance and exit gates) for passenger arriving and leaving, and transit nodes (platforms) for train stopping. A station is composed of several interconnected nodes including the source/sink nodes and the transit nodes. According to the connected node type, the links connecting two neighbouring nodes are divided into two types. The first one is the walk link for passenger walking and transferring and the second one is the transit link for a train running between two stations. A transit line is a fixed path along which vehicles periodically run, corresponding to the train route. Note that more than one transit line may exist on a physical line, such as for long and short train routes. Figure 2 presents the topology structure for rail transit networks.Figure 2
Topology structure for a rail transit network.Letl in L be a transit line where Nl is a set of transit nodes and Al is a set of links,l=(Nl,Al). Denote nl,i and al,j as the ith transit node and jth transit link in the transit line l, al,im is the arrival time for vehicle m at ith transit node (station), and dl,im is the departure time for vehicle m at ith transit node. The timetable Tl,m for vehicle m running on transit line l can be represented by groups of arrival time al,im and departure time dl,im, Tl,m={al,im,dl,im}. The dwell time tl,im for vehicle m is given as (1). The relationship among arrival time, departure time, and link running time is shown in (2). Table 1 provides an example of a train schedule (timetable).(1)tl,im=dl,im-al,im(2)al,i+1m=dl,im+hl,j,where hl,j is the time for a vehicle running through linkj and link j connects nodes nl,i and nl,i+1.Table 1
An example of a train schedule.
Train ID Transit line Transit stop Arrival time Departure time Formation(trains) Capacity(passengers/train) 1_001 1 0103 06:00:00 06:01:00 6 240 1_001 1 0104 06:02:30 06:03:30 6 240 1_001 1 0105 06:04:40 06:05:20 6 240 ⋮ ⋮ ⋮ ⋮ ⋮ ⋮ ⋮


### 3.2. Individual Passenger Generation

There are two types of traffic demand information which can be used as input for generating individual passengers in the DTA simulation system. The first one is the time-dependent origin-destination (OD) matrixes that are usually for online traffic management applications. The method of dynamic OD estimation and prediction can be inferred to the works of Yao et al. [18, 19]. The second one is the automatic fare collection (AFC) data that is primarily for offline policy evaluations. The generation processes in the simulation system should be as consistent as possible with the actual passenger flow characteristics in arrival time and spatial distributions. When a passenger is generated, the origin station, destination station, and departure time (arrival station time) should be produced.


#### 3.2.1. Generation from Time-Dependent O-D Tables

LetN- be the set of source and sink nodes, N-⊆N, Vrst is the travel demand from station r to s during time interval t, and TOD is the time duration of the OD table. The OD table in time interval t can be described as [Vrst]N-×N-, r∈N-, s∈N-. Suppose that passengers arrive uniformly if the time span TOD is very short, for example, no more than five minutes. Then the passenger arriving rate μrt of source node r (belonging to station r) in time interval t can be calculated as(3)μrt=∑sN-VrstTOD.The number of passengers arriving at noder during a simulation time step is(4)fr=Δt×μrt,where Δt represents the time step of the simulation clock and [] represents the down rounding computation.However, while the simulation time step is very small (such as 1 second), there may not be a single passenger arriving at the station in a simulation step. Referring to other related simulation works [20], we assume that the time intervals between two consecutive passengers follow the negative exponential distributions. Hence, the probability of a passenger arriving in time t′ is as follows:(5)pt′-t′′=urte-t′-t′′urt,where t′′ represents the arrival time of the previous passenger.When a passenger is generated at stationr, his/her destination can be determined from the trip distribution fractions calculated from the O-D tables. The probability of selecting node s as the destination station is(6)ps=Vrst∑sN-Vrst.


#### 3.2.2. Generation from Automatic Fare Transaction Records

The AFC system has been used widely in public transport and records accurate trip information for each passenger, including origin and destination stations, check-in and check-out times, and card type. The AFC data provides a new and massive data source for traffic planning and management. When the AFC records are used as the input for the simulation system, the passenger agents can be generated accurately whose arrival patterns follow the nature of the actual travel demand. Unfortunately, it can only be used to analyze the historical traffic status or evaluate the traffic policies corresponding to offline applications. Table2 presents the data structure of the AFC record information used for generating passengers.Table 2
Data structure of AFC record information.
Fields Description AFC_ID The trade ID in the AFC system TRIP_ORIGIN_LOCATION The trip origin station CURRENT_LOCATION The trip destination station ENTER_TIME The ticket check-in time (departure time) DEAL_TIME The ticket check-out time (arrival time)


### 3.3. Route Selection

For the particular structure of the rail transit network, passengers can only change their route at transfer stations, and usually they are unable to choose a secondary route once they start their trip. Hence, in this work, a combined route selection procedure is used to achieve the dynamic network equilibrium conditions: passengers follow the predetermined equilibrium principles under normal circumstances, and a bounded rational rule is adopted for passenger route changes under emergencies. The advantages of the combined route selection model are (1) high computational efficiency, (2) conformance to the route choice behavior for rail transit travellers, and (3) ability to capture the behavior change under special conditions.


#### 3.3.1. Equilibrium-Based Pretrip Path Choice

Assume that all travellers can obtain all of the information on the current traffic conditions and each traveller will select the best (usually the lowest cost) path. The travel pattern of pretrip dynamic equilibrium is defined as follows: for all travellers who leave their origin at any time in any O-D pair, the costs of any used routes are equal and minimal and smaller or equal to the cost of unused routes. The route cost is represented by a generalized cost function which is composed of four parts: (1) access and egress walk time; (2) on-board time; (3) waiting time; and (4) transfer time.The walk time contains access and egress walk time, which is calculated by the distance corresponding to the walk link and the average walking speed of travellers. The total walk timeWwalk can be represented as(7)Wwalk=wwalkin+wwalkout,where wwalkin represents the access walk time and wwalkout is the egress walk time.Normally, the on-board time for passengers travelling through sections is constant, which can be fixed with the train schedules. DefineWin as the total on-board time of passengers travelling through all sections within a route. The waiting time includes three components: (1) waiting time at the origin station; (2) waiting time at the transfer station if a transfer is required; and (3) the delay waiting time due to overloaded trains. The average waiting time at an origin/transfer station is equal to half of the train headway time corresponding to travel line. However, the rail transit system has strict capacity restraints; some passengers cannot board the first train that arrives because it is overloaded. This delayed waiting time should be considered if there is no sufficient capacity. Assume that passengers who fail to board the first arriving train will wait for the next train. Thus, the total waiting time Wwait can be represented as(8)Wwait=wwaitori+δ·wwaittrans+α·wwaitdelay,where wwaitori represents the waiting time at the origin station; wwaittrans is the waiting time at the transfer station; δ=1 if there is transfer, otherwise, δ=0; and a is the weighted factor for delay waiting time wwaitdelay.When a passenger is unable to board the first train, he/she needs to wait the headway time for the next train. The delay time changes greatly for different stations and should be frequently updated with the simulation clock. The delay waiting time is formulated as(9)wwaitdelay=hlp′∗3/2+p′′∗1/2p′+p′′-12,where p′ is the number of passengers who are delayed; p′′ represents the numbers of passengers who are able to board the first train; and hl is the headway time of the transit line l.DefineKrs as a set of the k shortest routes in the O-D pair (r,s), krs represents a route, and krs∈Krs; Wkrs is the generalized cost of route krs. The time-dependent generalized cost Wkrs of route krs during time step t can be formulated as follows:(10)Wkrst=μz·Wwalkkrs+μa·Winkrs+μb·Wwaitkrst+δ·μt·Wtransferkrs,where μz, μa, μb, and μt are the weighted factors for the cost corresponding to different travel processes and Wtransferkrs represents the total transfer walk time in route krs. These weighted factors can be estimated by the maximum likelihood method through travel surveys.There is no doubt that passengers are unable to know the exact cost of each route but merely estimate the cost based on their experiences and make trade-off decisions. The deviation between the practical travel time and the perceived time makes a difference in route choice. In this work, the Multinomial Logit (MNL) model which has been a popular method for the probabilistic choice is used to describe the uncertainty in the route selection. Suppose the deviations follow theGumbel distributions. Then the probability for a passenger selecting the route krs during simulation time t can be described as (11)pkrs=exp⁡Wkrst/Wkrsmint⁡∑krsKrsexp⁡Wkrst/Wkrsmint⁡,where Wkrsmin(t) represents the minimum cost of all alternative paths in the O-D pair(r,s).To improve the simulation efficiency, the initialk shortest paths of all O-D pairs will be searched and stored in the initialization procedure without considering passenger flows. The route cost will be updated in a preset short time interval (such as two minutes) with the simulation clock running. Therefore, passengers could choose the best path when they start at the origin station, according to the approximate real-time traffic conditions.


#### 3.3.2. Rule-Based Enroute Path Switch

Because of unexpected events such as incidents and disturbances, the cost of the originally selected route could significantly change after the passenger leaves the origin station. The influenced passengers must switch their routes or cancel their trips, as shown in Figure3. Hence, the behavior change of passengers in response to special conditions should be added to the simulation framework. Based on the bounded rational model proposed by Mahmassani [21], a modified model is constructed to describe the switch rule. If the gains from a route change satisfy and suffice for a specific value, passengers should switch their routes; if the cost of an alternative route exceeds the highest expected value, passengers will cancel their trip and choose other travel modes; otherwise, passengers should keep on waiting for the traffic recover. The switching rule is formulated as(12)δ=1,ifTTCk-TTAk>max⁡TTCk·γ,Smin-1,ifTTAk>λ·TTC′k0,otherwise,where δ represents an indicator variable equal to 1 when a passenger switches from the current route to the alternate, −1 when the passenger cancels the rail transit travel, and 0 if the current path is maintained. TTCk is the current travel cost of the original route from decision node k to the destination, and TTC′k represents the historical travel cost of the original route from decision node k to the destination; TTAk is the travel cost of the alternative route from the decision node to the destination; γ and λ are the relative difference threshold values; in this work, γ=0.3 and λ=2.0; and Smin is the absolute minimum travel cost advantage needed for a route switch. The values of γ and λ can be estimated from traffic survey and disparate for different transit systems.Figure 3
An example of a route switch procedure.From the example shown in Figure3, it can be found that the event locations are important for a passenger behavior change. In case 1, passengers at decision node k can switch to the alternative route if the travel cost satisfies the condition in (12). However, passengers have to cancel their travel in case 2. Note that although the train movement in our framework is operated strictly by the timetable, the influence of special events can also be evaluated by inputting different train schedules under the same travel demand.


### 3.4. Network Loading

The function of network loading is to move the individual passengers through the network, producing the output of the time-varying node and link flows. Compared to the network-loading processes for an urban road network, the differences for rail transit include the following: (1) travellers can only move through sections by train, (2) the travel time for transit links (sections) does not change for congestion, and (3) the passenger boarding and alighting interaction is complex; travellers may fail to get on a train that has reached its capacity. For a rail transit system, the network-loading processes contain three major components: passenger walking within the station, train movement control, and the interaction of passenger boarding and alighting.


#### 3.4.1. Queue-Based Model for Passenger Walking and Waiting

There are several microscopic models for simulating the pedestrian walk behavior in a station, such as the cellular automata model [22] and the social force model [23]. However, these models require high computational resources and are not suitable for large-scale network simulation. To offer a computationally efficient traffic simulator, this work uses a simplified queue-based model to describe the walking and waiting behavior for passengers within stations.Define a walk link (access or egress) as a route for passengers walking from the gate to the platform or back and transfer link as a route from one platform to another. Then, a station can be represented by interconnected walk links, transfer links, platform nodes, and gate nodes. To capture the passenger flow congestion, virtual stack queues related to the walk links were constructed and named entrance queues and exit queues, as shown in Figure4. The stack queue has no storage capacity limitation. Here, the pass capacity of the link is used to capture the queuing processes of passengers. The pass capacity of a walk link is set to be the minimum pass capacity of all key points within the route, such as gates and downstairs, which can be calculated by referring to the station design handbook. A more realistic queue with spatial storage capacity is constructed for the platform node, which attempts to capture the passenger waiting process for trains. The storage capacity can be fixed by the width and length of the platforms and the congestion passenger density. The connection between physical spatial queues and virtual stack queues can be further reviewed in the work of Hurdle and Son [24].Figure 4
Passenger queues for passenger walking within a station.Newell’s simplified model based on cumulative inflow and outflow counts is used to capture the passenger congestion formation and dissipation procedures in queues [15], which is illustrated in Figure 5. Entering the station process can be used as an example to describe the passenger queuing procedure. For a passenger p added to the entrance queue, his/her arrival time is ta(p), and the departure time will be t′(p), t′p=tap+FFWT under free flow conditions. The free flow walk time (FFWT) can be computed by the link distance and average walking speed. When the simulation clock advances to t′(p), if the outflow capacity (platform storage capacity) is available and passenger p is at the end of the entrance queue, this passenger can move to the platform waiting queue for trains; otherwise, this passenger must stay in the entrance queue and wait for available outflow capacity. The congestion delay time (CDT) for passenger is tdp-t′p.Figure 5
Illustration of cumulative passenger arrival (A), departure curve (D), and cumulative passenger count in the queue (V) [15].DefineM as the number of entrance queues in a station; m as the index of entrance queues, m∈M; Cmpass as the unit pass capacity of queue m during a simulation interval; Cstore as the storage capacity of the platform; qp,t as the number of passengers on platform in time t; qm,t as the number of passengers ready to depart from queue m at time t; and qm,ttrans as the transfer flow from the entrance queue to the wait queue. Based on these definitions, the calculation procedure for a passenger entering the station is shown in Algorithm 1.Algorithm 1:Calculation algorithm for a passenger entering the station.
For simulation timet For each entrance queue m=1 to M Step1. Calculate qm,t by checking the time t with the expected departure time t′ for each passenger in the entrance queue Step2. Calculate transfer flow qm,ttrans, qm,ttrans=min⁡{qm,t,Cmpass,Cstore-qp,t-1}⁡ Step3. Transfer passengers from the entrance queue to the wait queue qp,t=qp,t-1+qm,ttrans End EndThe egressing and transferring processes are similar to the entering procedures. Additionally, the number of boarding passengers determines the outflows of the wait queue on the platform. Then, the status of the wait queue changes in a discrete nonlinear way, which will be described in next section.


#### 3.4.2. Train Movement Control

According to the report from Beijing Mass Transit Railway Operation Corporation Limited, the average punctuality rate of trains is more than 99.7%. It is reasonable to assume that trains run strictly with the scheduled timetables. The train is generated at the first station of the transit line. Suppose that a train runs on transit linel. The section al,j of transit line l connects the nodes nl,i and nl,i+1, nl,i=(xni,yni) and nl,i+1=(xni+1,yni+1), where (x,y) represents the node location. Figure 6 shows the schematic diagram for updating the train position. The train location can be calculated as follows:(13)xt=xt-1+xli+1-xlihl,jΔtyt=yt-1+yli+1-ylihl,jΔt,where (xt,yt) represents the train position in time t and Δt and hl,j have same meanings as before.Figure 6
Schematic diagram for train position calculation.The train position within a transit link can be computed by the coordinate transition from the corresponding start and end node locations. If a train stops at a platform for passengers to board and alight, the train position will not be updated until it departs. The train movement may be disturbed for emergencies, such as incidents and congestion, which means the train operating processes should be controlled dynamically. However, controlling the train operating processes from the microscopic view is complicated and challenging. Future works are in progress to incorporate the dynamic train control process based on the moving block train control system into our framework.


#### 3.4.3. Boarding and Alighting Interaction

Figure7 presents the interaction flowchart of passenger boarding and alighting when a train arrives. The interaction follows the principle of “first-alight-then-board.” Assume that the preset dwell time is sufficient for passenger boarding and alighting and the passengers who fail to board the first train will wait for the next train.Figure 7
Interaction flowchart for passenger boarding and alighting.When a train arrives at a station, all of the passengers on the train should decide whether to continue riding or alight, according to their O-D and preselected route. For each passenger, if the stop is (a) the destination station or (b) the transfer station, the passenger should alight from the train. After passenger alighting has finished, the passengers waiting on the platform should determine whether or not to board. Because different transit lines may share the same station, it is important for passengers to board the correct train. Passengers who can board the train should satisfy the following:(i)
The next stop of the train is the same as the next stop for the passenger to make sure the train is going the correct direction.(ii)
The train will stop at the target stations for passengers, which represents the destination station or enroute transfer stations.(iii)
The train has sufficient capacity for the boarding passengers.Suppose a train numberedm arrives at the station i. Define Cm as the train loading capacity,Pmi-1 as the number of passengers on the train when the train departs from the previous station ni-1, Iim as the number of passengers waiting on the platform, and Oim as the number of passengers needing to alight. Using these definitions, the number of passengers who can board is(14)Ii′m=min⁡Cm-Pmi-1-Oim,Iim,where Ii′m represents the number of passengers who can board. If Ii′m<Iim, some passengers should wait for the next train, and the delayed passengers Sim are(15)Sim=Iim-Ii′m.


## 3.1. Network and Train Schedule

The rail transit network is represented by a directed graphG=(N,A,L), where N is the node set, A is the link set, and L is the set of transit lines. The nodes consist of two types: source and sink nodes (entrance and exit gates) for passenger arriving and leaving, and transit nodes (platforms) for train stopping. A station is composed of several interconnected nodes including the source/sink nodes and the transit nodes. According to the connected node type, the links connecting two neighbouring nodes are divided into two types. The first one is the walk link for passenger walking and transferring and the second one is the transit link for a train running between two stations. A transit line is a fixed path along which vehicles periodically run, corresponding to the train route. Note that more than one transit line may exist on a physical line, such as for long and short train routes. Figure 2 presents the topology structure for rail transit networks.Figure 2
Topology structure for a rail transit network.Letl in L be a transit line where Nl is a set of transit nodes and Al is a set of links,l=(Nl,Al). Denote nl,i and al,j as the ith transit node and jth transit link in the transit line l, al,im is the arrival time for vehicle m at ith transit node (station), and dl,im is the departure time for vehicle m at ith transit node. The timetable Tl,m for vehicle m running on transit line l can be represented by groups of arrival time al,im and departure time dl,im, Tl,m={al,im,dl,im}. The dwell time tl,im for vehicle m is given as (1). The relationship among arrival time, departure time, and link running time is shown in (2). Table 1 provides an example of a train schedule (timetable).(1)tl,im=dl,im-al,im(2)al,i+1m=dl,im+hl,j,where hl,j is the time for a vehicle running through linkj and link j connects nodes nl,i and nl,i+1.Table 1
An example of a train schedule.
Train ID Transit line Transit stop Arrival time Departure time Formation(trains) Capacity(passengers/train) 1_001 1 0103 06:00:00 06:01:00 6 240 1_001 1 0104 06:02:30 06:03:30 6 240 1_001 1 0105 06:04:40 06:05:20 6 240 ⋮ ⋮ ⋮ ⋮ ⋮ ⋮ ⋮


## 3.2. Individual Passenger Generation

There are two types of traffic demand information which can be used as input for generating individual passengers in the DTA simulation system. The first one is the time-dependent origin-destination (OD) matrixes that are usually for online traffic management applications. The method of dynamic OD estimation and prediction can be inferred to the works of Yao et al. [18, 19]. The second one is the automatic fare collection (AFC) data that is primarily for offline policy evaluations. The generation processes in the simulation system should be as consistent as possible with the actual passenger flow characteristics in arrival time and spatial distributions. When a passenger is generated, the origin station, destination station, and departure time (arrival station time) should be produced.


### 3.2.1. Generation from Time-Dependent O-D Tables

LetN- be the set of source and sink nodes, N-⊆N, Vrst is the travel demand from station r to s during time interval t, and TOD is the time duration of the OD table. The OD table in time interval t can be described as [Vrst]N-×N-, r∈N-, s∈N-. Suppose that passengers arrive uniformly if the time span TOD is very short, for example, no more than five minutes. Then the passenger arriving rate μrt of source node r (belonging to station r) in time interval t can be calculated as(3)μrt=∑sN-VrstTOD.The number of passengers arriving at noder during a simulation time step is(4)fr=Δt×μrt,where Δt represents the time step of the simulation clock and [] represents the down rounding computation.However, while the simulation time step is very small (such as 1 second), there may not be a single passenger arriving at the station in a simulation step. Referring to other related simulation works [20], we assume that the time intervals between two consecutive passengers follow the negative exponential distributions. Hence, the probability of a passenger arriving in time t′ is as follows:(5)pt′-t′′=urte-t′-t′′urt,where t′′ represents the arrival time of the previous passenger.When a passenger is generated at stationr, his/her destination can be determined from the trip distribution fractions calculated from the O-D tables. The probability of selecting node s as the destination station is(6)ps=Vrst∑sN-Vrst.


### 3.2.2. Generation from Automatic Fare Transaction Records

The AFC system has been used widely in public transport and records accurate trip information for each passenger, including origin and destination stations, check-in and check-out times, and card type. The AFC data provides a new and massive data source for traffic planning and management. When the AFC records are used as the input for the simulation system, the passenger agents can be generated accurately whose arrival patterns follow the nature of the actual travel demand. Unfortunately, it can only be used to analyze the historical traffic status or evaluate the traffic policies corresponding to offline applications. Table2 presents the data structure of the AFC record information used for generating passengers.Table 2
Data structure of AFC record information.
Fields Description AFC_ID The trade ID in the AFC system TRIP_ORIGIN_LOCATION The trip origin station CURRENT_LOCATION The trip destination station ENTER_TIME The ticket check-in time (departure time) DEAL_TIME The ticket check-out time (arrival time)


## 3.2.1. Generation from Time-Dependent O-D Tables

LetN- be the set of source and sink nodes, N-⊆N, Vrst is the travel demand from station r to s during time interval t, and TOD is the time duration of the OD table. The OD table in time interval t can be described as [Vrst]N-×N-, r∈N-, s∈N-. Suppose that passengers arrive uniformly if the time span TOD is very short, for example, no more than five minutes. Then the passenger arriving rate μrt of source node r (belonging to station r) in time interval t can be calculated as(3)μrt=∑sN-VrstTOD.The number of passengers arriving at noder during a simulation time step is(4)fr=Δt×μrt,where Δt represents the time step of the simulation clock and [] represents the down rounding computation.However, while the simulation time step is very small (such as 1 second), there may not be a single passenger arriving at the station in a simulation step. Referring to other related simulation works [20], we assume that the time intervals between two consecutive passengers follow the negative exponential distributions. Hence, the probability of a passenger arriving in time t′ is as follows:(5)pt′-t′′=urte-t′-t′′urt,where t′′ represents the arrival time of the previous passenger.When a passenger is generated at stationr, his/her destination can be determined from the trip distribution fractions calculated from the O-D tables. The probability of selecting node s as the destination station is(6)ps=Vrst∑sN-Vrst.


## 3.2.2. Generation from Automatic Fare Transaction Records

The AFC system has been used widely in public transport and records accurate trip information for each passenger, including origin and destination stations, check-in and check-out times, and card type. The AFC data provides a new and massive data source for traffic planning and management. When the AFC records are used as the input for the simulation system, the passenger agents can be generated accurately whose arrival patterns follow the nature of the actual travel demand. Unfortunately, it can only be used to analyze the historical traffic status or evaluate the traffic policies corresponding to offline applications. Table2 presents the data structure of the AFC record information used for generating passengers.Table 2
Data structure of AFC record information.
Fields Description AFC_ID The trade ID in the AFC system TRIP_ORIGIN_LOCATION The trip origin station CURRENT_LOCATION The trip destination station ENTER_TIME The ticket check-in time (departure time) DEAL_TIME The ticket check-out time (arrival time)


## 3.3. Route Selection

For the particular structure of the rail transit network, passengers can only change their route at transfer stations, and usually they are unable to choose a secondary route once they start their trip. Hence, in this work, a combined route selection procedure is used to achieve the dynamic network equilibrium conditions: passengers follow the predetermined equilibrium principles under normal circumstances, and a bounded rational rule is adopted for passenger route changes under emergencies. The advantages of the combined route selection model are (1) high computational efficiency, (2) conformance to the route choice behavior for rail transit travellers, and (3) ability to capture the behavior change under special conditions.


### 3.3.1. Equilibrium-Based Pretrip Path Choice

Assume that all travellers can obtain all of the information on the current traffic conditions and each traveller will select the best (usually the lowest cost) path. The travel pattern of pretrip dynamic equilibrium is defined as follows: for all travellers who leave their origin at any time in any O-D pair, the costs of any used routes are equal and minimal and smaller or equal to the cost of unused routes. The route cost is represented by a generalized cost function which is composed of four parts: (1) access and egress walk time; (2) on-board time; (3) waiting time; and (4) transfer time.The walk time contains access and egress walk time, which is calculated by the distance corresponding to the walk link and the average walking speed of travellers. The total walk timeWwalk can be represented as(7)Wwalk=wwalkin+wwalkout,where wwalkin represents the access walk time and wwalkout is the egress walk time.Normally, the on-board time for passengers travelling through sections is constant, which can be fixed with the train schedules. DefineWin as the total on-board time of passengers travelling through all sections within a route. The waiting time includes three components: (1) waiting time at the origin station; (2) waiting time at the transfer station if a transfer is required; and (3) the delay waiting time due to overloaded trains. The average waiting time at an origin/transfer station is equal to half of the train headway time corresponding to travel line. However, the rail transit system has strict capacity restraints; some passengers cannot board the first train that arrives because it is overloaded. This delayed waiting time should be considered if there is no sufficient capacity. Assume that passengers who fail to board the first arriving train will wait for the next train. Thus, the total waiting time Wwait can be represented as(8)Wwait=wwaitori+δ·wwaittrans+α·wwaitdelay,where wwaitori represents the waiting time at the origin station; wwaittrans is the waiting time at the transfer station; δ=1 if there is transfer, otherwise, δ=0; and a is the weighted factor for delay waiting time wwaitdelay.When a passenger is unable to board the first train, he/she needs to wait the headway time for the next train. The delay time changes greatly for different stations and should be frequently updated with the simulation clock. The delay waiting time is formulated as(9)wwaitdelay=hlp′∗3/2+p′′∗1/2p′+p′′-12,where p′ is the number of passengers who are delayed; p′′ represents the numbers of passengers who are able to board the first train; and hl is the headway time of the transit line l.DefineKrs as a set of the k shortest routes in the O-D pair (r,s), krs represents a route, and krs∈Krs; Wkrs is the generalized cost of route krs. The time-dependent generalized cost Wkrs of route krs during time step t can be formulated as follows:(10)Wkrst=μz·Wwalkkrs+μa·Winkrs+μb·Wwaitkrst+δ·μt·Wtransferkrs,where μz, μa, μb, and μt are the weighted factors for the cost corresponding to different travel processes and Wtransferkrs represents the total transfer walk time in route krs. These weighted factors can be estimated by the maximum likelihood method through travel surveys.There is no doubt that passengers are unable to know the exact cost of each route but merely estimate the cost based on their experiences and make trade-off decisions. The deviation between the practical travel time and the perceived time makes a difference in route choice. In this work, the Multinomial Logit (MNL) model which has been a popular method for the probabilistic choice is used to describe the uncertainty in the route selection. Suppose the deviations follow theGumbel distributions. Then the probability for a passenger selecting the route krs during simulation time t can be described as (11)pkrs=exp⁡Wkrst/Wkrsmint⁡∑krsKrsexp⁡Wkrst/Wkrsmint⁡,where Wkrsmin(t) represents the minimum cost of all alternative paths in the O-D pair(r,s).To improve the simulation efficiency, the initialk shortest paths of all O-D pairs will be searched and stored in the initialization procedure without considering passenger flows. The route cost will be updated in a preset short time interval (such as two minutes) with the simulation clock running. Therefore, passengers could choose the best path when they start at the origin station, according to the approximate real-time traffic conditions.


### 3.3.2. Rule-Based Enroute Path Switch

Because of unexpected events such as incidents and disturbances, the cost of the originally selected route could significantly change after the passenger leaves the origin station. The influenced passengers must switch their routes or cancel their trips, as shown in Figure3. Hence, the behavior change of passengers in response to special conditions should be added to the simulation framework. Based on the bounded rational model proposed by Mahmassani [21], a modified model is constructed to describe the switch rule. If the gains from a route change satisfy and suffice for a specific value, passengers should switch their routes; if the cost of an alternative route exceeds the highest expected value, passengers will cancel their trip and choose other travel modes; otherwise, passengers should keep on waiting for the traffic recover. The switching rule is formulated as(12)δ=1,ifTTCk-TTAk>max⁡TTCk·γ,Smin-1,ifTTAk>λ·TTC′k0,otherwise,where δ represents an indicator variable equal to 1 when a passenger switches from the current route to the alternate, −1 when the passenger cancels the rail transit travel, and 0 if the current path is maintained. TTCk is the current travel cost of the original route from decision node k to the destination, and TTC′k represents the historical travel cost of the original route from decision node k to the destination; TTAk is the travel cost of the alternative route from the decision node to the destination; γ and λ are the relative difference threshold values; in this work, γ=0.3 and λ=2.0; and Smin is the absolute minimum travel cost advantage needed for a route switch. The values of γ and λ can be estimated from traffic survey and disparate for different transit systems.Figure 3
An example of a route switch procedure.From the example shown in Figure3, it can be found that the event locations are important for a passenger behavior change. In case 1, passengers at decision node k can switch to the alternative route if the travel cost satisfies the condition in (12). However, passengers have to cancel their travel in case 2. Note that although the train movement in our framework is operated strictly by the timetable, the influence of special events can also be evaluated by inputting different train schedules under the same travel demand.


## 3.3.1. Equilibrium-Based Pretrip Path Choice

Assume that all travellers can obtain all of the information on the current traffic conditions and each traveller will select the best (usually the lowest cost) path. The travel pattern of pretrip dynamic equilibrium is defined as follows: for all travellers who leave their origin at any time in any O-D pair, the costs of any used routes are equal and minimal and smaller or equal to the cost of unused routes. The route cost is represented by a generalized cost function which is composed of four parts: (1) access and egress walk time; (2) on-board time; (3) waiting time; and (4) transfer time.The walk time contains access and egress walk time, which is calculated by the distance corresponding to the walk link and the average walking speed of travellers. The total walk timeWwalk can be represented as(7)Wwalk=wwalkin+wwalkout,where wwalkin represents the access walk time and wwalkout is the egress walk time.Normally, the on-board time for passengers travelling through sections is constant, which can be fixed with the train schedules. DefineWin as the total on-board time of passengers travelling through all sections within a route. The waiting time includes three components: (1) waiting time at the origin station; (2) waiting time at the transfer station if a transfer is required; and (3) the delay waiting time due to overloaded trains. The average waiting time at an origin/transfer station is equal to half of the train headway time corresponding to travel line. However, the rail transit system has strict capacity restraints; some passengers cannot board the first train that arrives because it is overloaded. This delayed waiting time should be considered if there is no sufficient capacity. Assume that passengers who fail to board the first arriving train will wait for the next train. Thus, the total waiting time Wwait can be represented as(8)Wwait=wwaitori+δ·wwaittrans+α·wwaitdelay,where wwaitori represents the waiting time at the origin station; wwaittrans is the waiting time at the transfer station; δ=1 if there is transfer, otherwise, δ=0; and a is the weighted factor for delay waiting time wwaitdelay.When a passenger is unable to board the first train, he/she needs to wait the headway time for the next train. The delay time changes greatly for different stations and should be frequently updated with the simulation clock. The delay waiting time is formulated as(9)wwaitdelay=hlp′∗3/2+p′′∗1/2p′+p′′-12,where p′ is the number of passengers who are delayed; p′′ represents the numbers of passengers who are able to board the first train; and hl is the headway time of the transit line l.DefineKrs as a set of the k shortest routes in the O-D pair (r,s), krs represents a route, and krs∈Krs; Wkrs is the generalized cost of route krs. The time-dependent generalized cost Wkrs of route krs during time step t can be formulated as follows:(10)Wkrst=μz·Wwalkkrs+μa·Winkrs+μb·Wwaitkrst+δ·μt·Wtransferkrs,where μz, μa, μb, and μt are the weighted factors for the cost corresponding to different travel processes and Wtransferkrs represents the total transfer walk time in route krs. These weighted factors can be estimated by the maximum likelihood method through travel surveys.There is no doubt that passengers are unable to know the exact cost of each route but merely estimate the cost based on their experiences and make trade-off decisions. The deviation between the practical travel time and the perceived time makes a difference in route choice. In this work, the Multinomial Logit (MNL) model which has been a popular method for the probabilistic choice is used to describe the uncertainty in the route selection. Suppose the deviations follow theGumbel distributions. Then the probability for a passenger selecting the route krs during simulation time t can be described as (11)pkrs=exp⁡Wkrst/Wkrsmint⁡∑krsKrsexp⁡Wkrst/Wkrsmint⁡,where Wkrsmin(t) represents the minimum cost of all alternative paths in the O-D pair(r,s).To improve the simulation efficiency, the initialk shortest paths of all O-D pairs will be searched and stored in the initialization procedure without considering passenger flows. The route cost will be updated in a preset short time interval (such as two minutes) with the simulation clock running. Therefore, passengers could choose the best path when they start at the origin station, according to the approximate real-time traffic conditions.


## 3.3.2. Rule-Based Enroute Path Switch

Because of unexpected events such as incidents and disturbances, the cost of the originally selected route could significantly change after the passenger leaves the origin station. The influenced passengers must switch their routes or cancel their trips, as shown in Figure3. Hence, the behavior change of passengers in response to special conditions should be added to the simulation framework. Based on the bounded rational model proposed by Mahmassani [21], a modified model is constructed to describe the switch rule. If the gains from a route change satisfy and suffice for a specific value, passengers should switch their routes; if the cost of an alternative route exceeds the highest expected value, passengers will cancel their trip and choose other travel modes; otherwise, passengers should keep on waiting for the traffic recover. The switching rule is formulated as(12)δ=1,ifTTCk-TTAk>max⁡TTCk·γ,Smin-1,ifTTAk>λ·TTC′k0,otherwise,where δ represents an indicator variable equal to 1 when a passenger switches from the current route to the alternate, −1 when the passenger cancels the rail transit travel, and 0 if the current path is maintained. TTCk is the current travel cost of the original route from decision node k to the destination, and TTC′k represents the historical travel cost of the original route from decision node k to the destination; TTAk is the travel cost of the alternative route from the decision node to the destination; γ and λ are the relative difference threshold values; in this work, γ=0.3 and λ=2.0; and Smin is the absolute minimum travel cost advantage needed for a route switch. The values of γ and λ can be estimated from traffic survey and disparate for different transit systems.Figure 3
An example of a route switch procedure.From the example shown in Figure3, it can be found that the event locations are important for a passenger behavior change. In case 1, passengers at decision node k can switch to the alternative route if the travel cost satisfies the condition in (12). However, passengers have to cancel their travel in case 2. Note that although the train movement in our framework is operated strictly by the timetable, the influence of special events can also be evaluated by inputting different train schedules under the same travel demand.


## 3.4. Network Loading

The function of network loading is to move the individual passengers through the network, producing the output of the time-varying node and link flows. Compared to the network-loading processes for an urban road network, the differences for rail transit include the following: (1) travellers can only move through sections by train, (2) the travel time for transit links (sections) does not change for congestion, and (3) the passenger boarding and alighting interaction is complex; travellers may fail to get on a train that has reached its capacity. For a rail transit system, the network-loading processes contain three major components: passenger walking within the station, train movement control, and the interaction of passenger boarding and alighting.


### 3.4.1. Queue-Based Model for Passenger Walking and Waiting

There are several microscopic models for simulating the pedestrian walk behavior in a station, such as the cellular automata model [22] and the social force model [23]. However, these models require high computational resources and are not suitable for large-scale network simulation. To offer a computationally efficient traffic simulator, this work uses a simplified queue-based model to describe the walking and waiting behavior for passengers within stations.Define a walk link (access or egress) as a route for passengers walking from the gate to the platform or back and transfer link as a route from one platform to another. Then, a station can be represented by interconnected walk links, transfer links, platform nodes, and gate nodes. To capture the passenger flow congestion, virtual stack queues related to the walk links were constructed and named entrance queues and exit queues, as shown in Figure4. The stack queue has no storage capacity limitation. Here, the pass capacity of the link is used to capture the queuing processes of passengers. The pass capacity of a walk link is set to be the minimum pass capacity of all key points within the route, such as gates and downstairs, which can be calculated by referring to the station design handbook. A more realistic queue with spatial storage capacity is constructed for the platform node, which attempts to capture the passenger waiting process for trains. The storage capacity can be fixed by the width and length of the platforms and the congestion passenger density. The connection between physical spatial queues and virtual stack queues can be further reviewed in the work of Hurdle and Son [24].Figure 4
Passenger queues for passenger walking within a station.Newell’s simplified model based on cumulative inflow and outflow counts is used to capture the passenger congestion formation and dissipation procedures in queues [15], which is illustrated in Figure 5. Entering the station process can be used as an example to describe the passenger queuing procedure. For a passenger p added to the entrance queue, his/her arrival time is ta(p), and the departure time will be t′(p), t′p=tap+FFWT under free flow conditions. The free flow walk time (FFWT) can be computed by the link distance and average walking speed. When the simulation clock advances to t′(p), if the outflow capacity (platform storage capacity) is available and passenger p is at the end of the entrance queue, this passenger can move to the platform waiting queue for trains; otherwise, this passenger must stay in the entrance queue and wait for available outflow capacity. The congestion delay time (CDT) for passenger is tdp-t′p.Figure 5
Illustration of cumulative passenger arrival (A), departure curve (D), and cumulative passenger count in the queue (V) [15].DefineM as the number of entrance queues in a station; m as the index of entrance queues, m∈M; Cmpass as the unit pass capacity of queue m during a simulation interval; Cstore as the storage capacity of the platform; qp,t as the number of passengers on platform in time t; qm,t as the number of passengers ready to depart from queue m at time t; and qm,ttrans as the transfer flow from the entrance queue to the wait queue. Based on these definitions, the calculation procedure for a passenger entering the station is shown in Algorithm 1.Algorithm 1:Calculation algorithm for a passenger entering the station.
For simulation timet For each entrance queue m=1 to M Step1. Calculate qm,t by checking the time t with the expected departure time t′ for each passenger in the entrance queue Step2. Calculate transfer flow qm,ttrans, qm,ttrans=min⁡{qm,t,Cmpass,Cstore-qp,t-1}⁡ Step3. Transfer passengers from the entrance queue to the wait queue qp,t=qp,t-1+qm,ttrans End EndThe egressing and transferring processes are similar to the entering procedures. Additionally, the number of boarding passengers determines the outflows of the wait queue on the platform. Then, the status of the wait queue changes in a discrete nonlinear way, which will be described in next section.


### 3.4.2. Train Movement Control

According to the report from Beijing Mass Transit Railway Operation Corporation Limited, the average punctuality rate of trains is more than 99.7%. It is reasonable to assume that trains run strictly with the scheduled timetables. The train is generated at the first station of the transit line. Suppose that a train runs on transit linel. The section al,j of transit line l connects the nodes nl,i and nl,i+1, nl,i=(xni,yni) and nl,i+1=(xni+1,yni+1), where (x,y) represents the node location. Figure 6 shows the schematic diagram for updating the train position. The train location can be calculated as follows:(13)xt=xt-1+xli+1-xlihl,jΔtyt=yt-1+yli+1-ylihl,jΔt,where (xt,yt) represents the train position in time t and Δt and hl,j have same meanings as before.Figure 6
Schematic diagram for train position calculation.The train position within a transit link can be computed by the coordinate transition from the corresponding start and end node locations. If a train stops at a platform for passengers to board and alight, the train position will not be updated until it departs. The train movement may be disturbed for emergencies, such as incidents and congestion, which means the train operating processes should be controlled dynamically. However, controlling the train operating processes from the microscopic view is complicated and challenging. Future works are in progress to incorporate the dynamic train control process based on the moving block train control system into our framework.


### 3.4.3. Boarding and Alighting Interaction

Figure7 presents the interaction flowchart of passenger boarding and alighting when a train arrives. The interaction follows the principle of “first-alight-then-board.” Assume that the preset dwell time is sufficient for passenger boarding and alighting and the passengers who fail to board the first train will wait for the next train.Figure 7
Interaction flowchart for passenger boarding and alighting.When a train arrives at a station, all of the passengers on the train should decide whether to continue riding or alight, according to their O-D and preselected route. For each passenger, if the stop is (a) the destination station or (b) the transfer station, the passenger should alight from the train. After passenger alighting has finished, the passengers waiting on the platform should determine whether or not to board. Because different transit lines may share the same station, it is important for passengers to board the correct train. Passengers who can board the train should satisfy the following:(i)
The next stop of the train is the same as the next stop for the passenger to make sure the train is going the correct direction.(ii)
The train will stop at the target stations for passengers, which represents the destination station or enroute transfer stations.(iii)
The train has sufficient capacity for the boarding passengers.Suppose a train numberedm arrives at the station i. Define Cm as the train loading capacity,Pmi-1 as the number of passengers on the train when the train departs from the previous station ni-1, Iim as the number of passengers waiting on the platform, and Oim as the number of passengers needing to alight. Using these definitions, the number of passengers who can board is(14)Ii′m=min⁡Cm-Pmi-1-Oim,Iim,where Ii′m represents the number of passengers who can board. If Ii′m<Iim, some passengers should wait for the next train, and the delayed passengers Sim are(15)Sim=Iim-Ii′m.


## 3.4.1. Queue-Based Model for Passenger Walking and Waiting

There are several microscopic models for simulating the pedestrian walk behavior in a station, such as the cellular automata model [22] and the social force model [23]. However, these models require high computational resources and are not suitable for large-scale network simulation. To offer a computationally efficient traffic simulator, this work uses a simplified queue-based model to describe the walking and waiting behavior for passengers within stations.Define a walk link (access or egress) as a route for passengers walking from the gate to the platform or back and transfer link as a route from one platform to another. Then, a station can be represented by interconnected walk links, transfer links, platform nodes, and gate nodes. To capture the passenger flow congestion, virtual stack queues related to the walk links were constructed and named entrance queues and exit queues, as shown in Figure4. The stack queue has no storage capacity limitation. Here, the pass capacity of the link is used to capture the queuing processes of passengers. The pass capacity of a walk link is set to be the minimum pass capacity of all key points within the route, such as gates and downstairs, which can be calculated by referring to the station design handbook. A more realistic queue with spatial storage capacity is constructed for the platform node, which attempts to capture the passenger waiting process for trains. The storage capacity can be fixed by the width and length of the platforms and the congestion passenger density. The connection between physical spatial queues and virtual stack queues can be further reviewed in the work of Hurdle and Son [24].Figure 4
Passenger queues for passenger walking within a station.Newell’s simplified model based on cumulative inflow and outflow counts is used to capture the passenger congestion formation and dissipation procedures in queues [15], which is illustrated in Figure 5. Entering the station process can be used as an example to describe the passenger queuing procedure. For a passenger p added to the entrance queue, his/her arrival time is ta(p), and the departure time will be t′(p), t′p=tap+FFWT under free flow conditions. The free flow walk time (FFWT) can be computed by the link distance and average walking speed. When the simulation clock advances to t′(p), if the outflow capacity (platform storage capacity) is available and passenger p is at the end of the entrance queue, this passenger can move to the platform waiting queue for trains; otherwise, this passenger must stay in the entrance queue and wait for available outflow capacity. The congestion delay time (CDT) for passenger is tdp-t′p.Figure 5
Illustration of cumulative passenger arrival (A), departure curve (D), and cumulative passenger count in the queue (V) [15].DefineM as the number of entrance queues in a station; m as the index of entrance queues, m∈M; Cmpass as the unit pass capacity of queue m during a simulation interval; Cstore as the storage capacity of the platform; qp,t as the number of passengers on platform in time t; qm,t as the number of passengers ready to depart from queue m at time t; and qm,ttrans as the transfer flow from the entrance queue to the wait queue. Based on these definitions, the calculation procedure for a passenger entering the station is shown in Algorithm 1.Algorithm 1:Calculation algorithm for a passenger entering the station.
For simulation timet For each entrance queue m=1 to M Step1. Calculate qm,t by checking the time t with the expected departure time t′ for each passenger in the entrance queue Step2. Calculate transfer flow qm,ttrans, qm,ttrans=min⁡{qm,t,Cmpass,Cstore-qp,t-1}⁡ Step3. Transfer passengers from the entrance queue to the wait queue qp,t=qp,t-1+qm,ttrans End EndThe egressing and transferring processes are similar to the entering procedures. Additionally, the number of boarding passengers determines the outflows of the wait queue on the platform. Then, the status of the wait queue changes in a discrete nonlinear way, which will be described in next section.


## 3.4.2. Train Movement Control

According to the report from Beijing Mass Transit Railway Operation Corporation Limited, the average punctuality rate of trains is more than 99.7%. It is reasonable to assume that trains run strictly with the scheduled timetables. The train is generated at the first station of the transit line. Suppose that a train runs on transit linel. The section al,j of transit line l connects the nodes nl,i and nl,i+1, nl,i=(xni,yni) and nl,i+1=(xni+1,yni+1), where (x,y) represents the node location. Figure 6 shows the schematic diagram for updating the train position. The train location can be calculated as follows:(13)xt=xt-1+xli+1-xlihl,jΔtyt=yt-1+yli+1-ylihl,jΔt,where (xt,yt) represents the train position in time t and Δt and hl,j have same meanings as before.Figure 6
Schematic diagram for train position calculation.The train position within a transit link can be computed by the coordinate transition from the corresponding start and end node locations. If a train stops at a platform for passengers to board and alight, the train position will not be updated until it departs. The train movement may be disturbed for emergencies, such as incidents and congestion, which means the train operating processes should be controlled dynamically. However, controlling the train operating processes from the microscopic view is complicated and challenging. Future works are in progress to incorporate the dynamic train control process based on the moving block train control system into our framework.


## 3.4.3. Boarding and Alighting Interaction

Figure7 presents the interaction flowchart of passenger boarding and alighting when a train arrives. The interaction follows the principle of “first-alight-then-board.” Assume that the preset dwell time is sufficient for passenger boarding and alighting and the passengers who fail to board the first train will wait for the next train.Figure 7
Interaction flowchart for passenger boarding and alighting.When a train arrives at a station, all of the passengers on the train should decide whether to continue riding or alight, according to their O-D and preselected route. For each passenger, if the stop is (a) the destination station or (b) the transfer station, the passenger should alight from the train. After passenger alighting has finished, the passengers waiting on the platform should determine whether or not to board. Because different transit lines may share the same station, it is important for passengers to board the correct train. Passengers who can board the train should satisfy the following:(i)
The next stop of the train is the same as the next stop for the passenger to make sure the train is going the correct direction.(ii)
The train will stop at the target stations for passengers, which represents the destination station or enroute transfer stations.(iii)
The train has sufficient capacity for the boarding passengers.Suppose a train numberedm arrives at the station i. Define Cm as the train loading capacity,Pmi-1 as the number of passengers on the train when the train departs from the previous station ni-1, Iim as the number of passengers waiting on the platform, and Oim as the number of passengers needing to alight. Using these definitions, the number of passengers who can board is(14)Ii′m=min⁡Cm-Pmi-1-Oim,Iim,where Ii′m represents the number of passengers who can board. If Ii′m<Iim, some passengers should wait for the next train, and the delayed passengers Sim are(15)Sim=Iim-Ii′m.


## 4. Model Implementation

### 4.1. Simulator Description

A simulator based on the proposed models was developed in the C# programming language using object-oriented and continuous time-driven approaches. The tool was executed on an Intel PC under Windows 7 with a 3.8 GHz CPU and 4 G RAM. Figure8 shows the main interface of the simulator.Figure 8
Main interface of the simulation system.The Beijing rail transit, one of the busiest transit systems in the world, is applied to test the models and simulator. It consists of 344 stations and 18 lines with a total length of 631 kilometres in 2016. The ridership is approximately 10 million trips (each transfer is counted as an additional trip) and 7,539 trains operate daily. The minimum train headway time in peak hours reaches 103 seconds [25].The headway and dwell times are measured in seconds in the operation of rail transit. Hence, the time step of the simulation clock is set to be 1 second and the triggering time for iteration is 100 milliseconds, which is ten times faster than the real time. Test results show that (1) the traffic flow status for a large-scale transit network can be simulated with high efficiency and only 120 minutes is needed to simulate a whole day (from 5:00 to 24:00) and (2) more than 1,000 trains and 0.8 million individual passengers can be simulated simultaneously. The main capabilities of the tool include the following:(i)
Modelling the complex routing behavior integrated with the pretrip route selection and enroute switch processes for rail transit travellers.(ii)
Modelling the train movement for different types of train schedules, such as long and short train routes and a variable number of train units.(iii)
Representing dynamics of network flows at multiple levels (network, line, station, section, train, and platform) and for any time span.(iv)
Tracking the target passengers for behavior changes under special conditions.(v)
Outputting statistical results of passenger flows in any preset time span, such as train load volume, station access, and egress and transfer flows.


### 4.2. Model Verification

A weekday (Wednesday) in April 2016 is used as the analysis day. The simulation time is from 5:00 to 24:00, and the AFC records from the Beijing Municipal Commission of Transport are utilized as the traffic demand inputs, with a total of 5,425,015 trips (without considering transfers). Because the real train running records cannot be obtained, the scheduled timetable is applied for train operations. A travel survey is taken to estimate the value of parameters in the MNL route choice model, which is shown in Table3.Table 3
Information of parameters.
Parameter Value Description μ z 0.21 Weight for egress/access walk time μ a 0.14 Weight for on-board time μ b 0.28 Weight for wait-for-train time μ t 0.37 Weight for transfer walk time SUM 1.00There are two indicators used to quantify the model accuracy. The first one is the average relative deviationARDt between the simulated travel time and the actual travel time for each passenger, as shown in (16). The other one is the average relative deviation ARDq between the simulated section flows and the flows from the official revenue clearance centre, which is calculated by (17).(16)ARDt=∑p=1Ptp-t′p/t′pP∗100%,where tp means the simulated travel time for passengerp; t′p is the practical travel time from the AFC record; and P is the number of tested passengers. (17)ARDqt=∑k=1Kqkt-q′kt/q′ktK∗100%,where qk(t) represents the simulated section flow for section k during time interval t; q′k(t) is the assignment section flow from the revenue clearance centre; and K is the number of sections.Figure9 presents the ARDt distributions from 80,000 randomly selected travellers. We can observe that the deviation for most of the passengers is about 5%～25%. The main reasons for deviation are the random variable influence in the MNL-based model that causes the wrong route choice and the different walking speed for passengers when they go through the passageways. However, the weighted average relative deviation is about 17%, which are still acceptable for a real-world application.Figure 9
Deviations of travel time for tested passengers.Figure10 provides the time-dependent ARDq deviations from 05:00 a.m. to 12:00 a.m. We can find that most of the deviations are less than 6%. Therefore, it can be concluded that the proposed models have an acceptable accuracy and are suitable for DTA application in the schedule-based rail transit networks.Figure 10
Time-dependent deviations of section flows.


### 4.3. Simulator Applications

Two case studies are presented to show the capabilities of the simulator. The first one shows the descriptive capability for describing the spatial-temporal passenger flow patterns, and the second one provides the evaluation capability for the event influence.


#### 4.3.1. Dynamics of Passenger Flows

The descriptive capability for dynamic flow status is the fundamental and core function of DTA models and simulators. The same traffic demand input and train schedules used in the model verification are applied in this case study. The simulation time is from 5:00 to 24:00. Part of time-dependent transport capacities for each line are given in Table4.Table 4
Transport capacity for each line from 5:00 a.m. to 12:00 a.m. (passengers/hour).
Line 5:00–6:00 6:00–7:00 7:00–8:00 7:00–8:00 8:00–9:00 9:00–10:00 10:00–11:00 11:00–12:00 Line 1 25920 31680 40320 40320 40320 25920 27360 25920 Line 2 14400 25920 40320 40320 28800 18720 18720 20160 Line 4 23040 30240 43200 30240 30240 23040 21600 21600 Line 5 14400 24480 38880 38880 25920 18720 18720 18720 Line 6 14400 19200 32640 34560 34560 14400 23040 17280 Line 7 7680 21120 28800 28800 26880 14400 17280 21120 Line 8 5760 12960 21600 25920 21600 14400 14400 12960 Line 9 8640 17280 24480 24480 17280 14400 15840 17280 Line 10 7200 24480 37440 33120 34560 18720 18720 18720 Line 13 17280 28800 30240 34560 14400 17280 14400 10080 Line 14 7440 14880 13020 14880 13020 14880 14880 13020 Line 15 4320 11520 17280 17280 15840 11520 11520 11520 Line BT 2880 15840 28800 28800 21600 12960 12960 12960 Line DX 23040 30240 43200 30240 30240 23040 21600 21600 Line FS 7200 12960 14400 12960 11520 11520 11520 11520 Line YZ 8640 14400 14400 14400 14400 8640 8640 8640 Line CP 1440 10080 14400 14400 14400 7200 7200 7200 Line JC 0 2520 4200 4200 5880 5040 5040 5040In Beijing rail transit, the direction for lines is defined as the up direction is from east to west and from south to north for straight lines and counterclockwise for the circle lines; the down direction represents the opposite directions. Figure11 shows the dynamic network passenger flow status during morning peak hours (7:00–9:00), where R means the capacity utilization rates which corresponds to different colours. We can see that the up direction of Line 1 and the down direction of Lines 5 and 6 and BT are the most congested lines in the Beijing subway during the morning peak hours. To maintain safe transit operations, a forced inflow control measure is widely used in the Beijing rail transit, which limits the number of passengers entering the stations. Most of the controlled stations are located on these congested lines.Figure 11
Dynamic passenger flow status during the morning peak hours (7:00~9:00).
(a)
7:00~7:30 (b)
7:30~8:00 (c)
8:00~8:30 (d)
8:30~9:00A significant amount of passenger flow information for different levels can be output by the simulator, such as platform, train, line, and network. Figure12 shows the passenger density on the down direction platform of the Tiantongyuan (TTY) station every 30 seconds. The TTY station is one of the most congested stations on Line 5. We can find that the maximum passenger density is as high as 3.0 passengers per square metres, which almost reaches the maximum safe density for platforms. The platform passenger density can be used to support train schedule regulation decisions and transport capacity allocations.Figure 12
Passenger flow density on the down direction platform of the TTY station.Figure13 presents the time-varying section flows in the up direction of Line 1. The maximum section flow of the lines is the key parameter for calculating the train headway time. We can see that the pivotal sections of Line 1 are sections 6 to 11; nearly 120,000 passengers travel across these sections in the morning.Figure 13
Time-varying section flows in the up direction of Line 1.Figure14 presents the network inflows, outflows, and passengers loading distribution every 30 minutes. There is no doubt that the reason for these two sharp peaks in the morning and evening is commuter travelling. The imbalanced travel demand makes it difficult for transport organizations and capacity utilization. We can find that the peak of the network load is approximately 500,000 passengers, which is less than the maximum capacity of the simulator. Hence, the developed simulator is efficient enough for large-scale transit network applications.Figure 14
Time-varying network passenger flows.


#### 4.3.2. Special Events Evaluation

The traffic management for special events such as concerts, large conferences, and sports events is a difficult task for transport corporations. Generally, the transport schedules should be adjusted for the mass traffic flows caused by these events. However, precise quantitative empirical data are usually insufficient due to the lack of observation data and analysis tools. In rail transit systems, the detailed trip records of each traveller can be stored in the AFC system. However, it is also impossible to determine which passenger is part of the event audience. Considering the high regularity of rail transit passengers, a comparison method between the event day and the corresponding weekday of the previous week is used to evaluate the traffic influence of special events.A football game held in Worker’s Stadium on 23 April 2016, starting at 19:35 and ending at 21:40, is used as our case study. The Worker’s Stadium is one the most important centres for entertainment and sports in Beijing, and it can accommodate approximately 150,000 people. The location of the Stadium is shown in Figure15. The Dongsishitiao (DSST) Station is the nearest railway station to the Worker’s Stadium, so it is the most used station for passengers going to the stadium. In this study, the comparison day of the previous week is 16 April 2016.Figure 15
Location of the Worker’s Stadium (source:http://map.baidu.com/).Figure16 shows the time-varying inflow and outflow distributions of the DSST station. It can be clearly observed that (1) there is a high arrival peak flow (station outflow) before the game, with the peak time at 18:30; (2) there is also a high departure peak flow (station inflow) after the game, with the peak at 22:00; and (3) the number of departure passengers entering the DSST station is as much as four times than the normal day, and the departure peak is much higher than the arrival flow. If there is no additional transport capacity added to support these mass flows, congestion and safety issues may emerge for the event stations.Figure 16
Time-dependent inflows and outflows of the DSST Station.The number of extra section flows is used as the evaluation indicator for the event influence, which equals the section flows in an event day minus the flows in a normal day. After simulating the traffic status of two comparison days, the time-dependent extra section flow distribution after the event ends is shown in Figure17. V means the number of flows, which also corresponds to different colours. The red colour means the extra section flow is over 800 passengers, and the other colours represent smaller numbers of passengers. It can be found that (1) an outward evacuation process exists after the sports game ends, with a peak 20 minutes later; (2) the extra section flow (event flow) mainly travels through Lines 2, 6, and 1; hence, the train schedule adjustment should be made for these lines; and (3) fifty minutes later the event flows almost disappear from the network.Figure 17
Extra section flow distributions after the event ends.
(a)
21:00~21:30 (b)
21:30~22:00 (c)
22:00~22:30 (d)
22:30~23:00The maximum section flow in a line determines the train headway time. Table5 gives the maximum section flows for the most influenced lines, as shown in Figure 17. We can determine that (1) the most influenced line is Line 2 and the influenced time is from 21:30–22:30 and (2) the most influenced time for the network is 22:00–22:30. Hence, some regulatory measures should be made for transporting these additional event flows, such as reducing headway time or running a short route train for these influenced sections.Table 5
Comparison results between the event day and a normal day.
Maximum section flow in a normal day(person) Maximum section flow in an event day(person) Rate of increase(%) Line 1 Line 2 Line 5 Line 6 Line 1 Line 2 Line 5 Line 6 Line 1 Line 2 Line 5 Line 6 21:00–21:30 4985 2525 4709 4857 4694 2538 4884 4525 −5.84 0.51 3.72 −6.84 21:30–22:00 4363 2562 4582 4435 4303 3815 4611 6087 −1.38 48.91 0.63 37.25 22:00–22:30 4056 1842 3948 3942 4671 3335 4597 4732 15.16 81.05 16.44 20.04 22:30–23:00 3045 1360 3165 3405 3112 1205 3506 3839 2.20 −11.40 10.77 12.75


## 4.1. Simulator Description

A simulator based on the proposed models was developed in the C# programming language using object-oriented and continuous time-driven approaches. The tool was executed on an Intel PC under Windows 7 with a 3.8 GHz CPU and 4 G RAM. Figure8 shows the main interface of the simulator.Figure 8
Main interface of the simulation system.The Beijing rail transit, one of the busiest transit systems in the world, is applied to test the models and simulator. It consists of 344 stations and 18 lines with a total length of 631 kilometres in 2016. The ridership is approximately 10 million trips (each transfer is counted as an additional trip) and 7,539 trains operate daily. The minimum train headway time in peak hours reaches 103 seconds [25].The headway and dwell times are measured in seconds in the operation of rail transit. Hence, the time step of the simulation clock is set to be 1 second and the triggering time for iteration is 100 milliseconds, which is ten times faster than the real time. Test results show that (1) the traffic flow status for a large-scale transit network can be simulated with high efficiency and only 120 minutes is needed to simulate a whole day (from 5:00 to 24:00) and (2) more than 1,000 trains and 0.8 million individual passengers can be simulated simultaneously. The main capabilities of the tool include the following:(i)
Modelling the complex routing behavior integrated with the pretrip route selection and enroute switch processes for rail transit travellers.(ii)
Modelling the train movement for different types of train schedules, such as long and short train routes and a variable number of train units.(iii)
Representing dynamics of network flows at multiple levels (network, line, station, section, train, and platform) and for any time span.(iv)
Tracking the target passengers for behavior changes under special conditions.(v)
Outputting statistical results of passenger flows in any preset time span, such as train load volume, station access, and egress and transfer flows.


## 4.2. Model Verification

A weekday (Wednesday) in April 2016 is used as the analysis day. The simulation time is from 5:00 to 24:00, and the AFC records from the Beijing Municipal Commission of Transport are utilized as the traffic demand inputs, with a total of 5,425,015 trips (without considering transfers). Because the real train running records cannot be obtained, the scheduled timetable is applied for train operations. A travel survey is taken to estimate the value of parameters in the MNL route choice model, which is shown in Table3.Table 3
Information of parameters.
Parameter Value Description μ z 0.21 Weight for egress/access walk time μ a 0.14 Weight for on-board time μ b 0.28 Weight for wait-for-train time μ t 0.37 Weight for transfer walk time SUM 1.00There are two indicators used to quantify the model accuracy. The first one is the average relative deviationARDt between the simulated travel time and the actual travel time for each passenger, as shown in (16). The other one is the average relative deviation ARDq between the simulated section flows and the flows from the official revenue clearance centre, which is calculated by (17).(16)ARDt=∑p=1Ptp-t′p/t′pP∗100%,where tp means the simulated travel time for passengerp; t′p is the practical travel time from the AFC record; and P is the number of tested passengers. (17)ARDqt=∑k=1Kqkt-q′kt/q′ktK∗100%,where qk(t) represents the simulated section flow for section k during time interval t; q′k(t) is the assignment section flow from the revenue clearance centre; and K is the number of sections.Figure9 presents the ARDt distributions from 80,000 randomly selected travellers. We can observe that the deviation for most of the passengers is about 5%～25%. The main reasons for deviation are the random variable influence in the MNL-based model that causes the wrong route choice and the different walking speed for passengers when they go through the passageways. However, the weighted average relative deviation is about 17%, which are still acceptable for a real-world application.Figure 9
Deviations of travel time for tested passengers.Figure10 provides the time-dependent ARDq deviations from 05:00 a.m. to 12:00 a.m. We can find that most of the deviations are less than 6%. Therefore, it can be concluded that the proposed models have an acceptable accuracy and are suitable for DTA application in the schedule-based rail transit networks.Figure 10
Time-dependent deviations of section flows.


## 4.3. Simulator Applications

Two case studies are presented to show the capabilities of the simulator. The first one shows the descriptive capability for describing the spatial-temporal passenger flow patterns, and the second one provides the evaluation capability for the event influence.


### 4.3.1. Dynamics of Passenger Flows

The descriptive capability for dynamic flow status is the fundamental and core function of DTA models and simulators. The same traffic demand input and train schedules used in the model verification are applied in this case study. The simulation time is from 5:00 to 24:00. Part of time-dependent transport capacities for each line are given in Table4.Table 4
Transport capacity for each line from 5:00 a.m. to 12:00 a.m. (passengers/hour).
Line 5:00–6:00 6:00–7:00 7:00–8:00 7:00–8:00 8:00–9:00 9:00–10:00 10:00–11:00 11:00–12:00 Line 1 25920 31680 40320 40320 40320 25920 27360 25920 Line 2 14400 25920 40320 40320 28800 18720 18720 20160 Line 4 23040 30240 43200 30240 30240 23040 21600 21600 Line 5 14400 24480 38880 38880 25920 18720 18720 18720 Line 6 14400 19200 32640 34560 34560 14400 23040 17280 Line 7 7680 21120 28800 28800 26880 14400 17280 21120 Line 8 5760 12960 21600 25920 21600 14400 14400 12960 Line 9 8640 17280 24480 24480 17280 14400 15840 17280 Line 10 7200 24480 37440 33120 34560 18720 18720 18720 Line 13 17280 28800 30240 34560 14400 17280 14400 10080 Line 14 7440 14880 13020 14880 13020 14880 14880 13020 Line 15 4320 11520 17280 17280 15840 11520 11520 11520 Line BT 2880 15840 28800 28800 21600 12960 12960 12960 Line DX 23040 30240 43200 30240 30240 23040 21600 21600 Line FS 7200 12960 14400 12960 11520 11520 11520 11520 Line YZ 8640 14400 14400 14400 14400 8640 8640 8640 Line CP 1440 10080 14400 14400 14400 7200 7200 7200 Line JC 0 2520 4200 4200 5880 5040 5040 5040In Beijing rail transit, the direction for lines is defined as the up direction is from east to west and from south to north for straight lines and counterclockwise for the circle lines; the down direction represents the opposite directions. Figure11 shows the dynamic network passenger flow status during morning peak hours (7:00–9:00), where R means the capacity utilization rates which corresponds to different colours. We can see that the up direction of Line 1 and the down direction of Lines 5 and 6 and BT are the most congested lines in the Beijing subway during the morning peak hours. To maintain safe transit operations, a forced inflow control measure is widely used in the Beijing rail transit, which limits the number of passengers entering the stations. Most of the controlled stations are located on these congested lines.Figure 11
Dynamic passenger flow status during the morning peak hours (7:00~9:00).
(a)
7:00~7:30 (b)
7:30~8:00 (c)
8:00~8:30 (d)
8:30~9:00A significant amount of passenger flow information for different levels can be output by the simulator, such as platform, train, line, and network. Figure12 shows the passenger density on the down direction platform of the Tiantongyuan (TTY) station every 30 seconds. The TTY station is one of the most congested stations on Line 5. We can find that the maximum passenger density is as high as 3.0 passengers per square metres, which almost reaches the maximum safe density for platforms. The platform passenger density can be used to support train schedule regulation decisions and transport capacity allocations.Figure 12
Passenger flow density on the down direction platform of the TTY station.Figure13 presents the time-varying section flows in the up direction of Line 1. The maximum section flow of the lines is the key parameter for calculating the train headway time. We can see that the pivotal sections of Line 1 are sections 6 to 11; nearly 120,000 passengers travel across these sections in the morning.Figure 13
Time-varying section flows in the up direction of Line 1.Figure14 presents the network inflows, outflows, and passengers loading distribution every 30 minutes. There is no doubt that the reason for these two sharp peaks in the morning and evening is commuter travelling. The imbalanced travel demand makes it difficult for transport organizations and capacity utilization. We can find that the peak of the network load is approximately 500,000 passengers, which is less than the maximum capacity of the simulator. Hence, the developed simulator is efficient enough for large-scale transit network applications.Figure 14
Time-varying network passenger flows.


### 4.3.2. Special Events Evaluation

The traffic management for special events such as concerts, large conferences, and sports events is a difficult task for transport corporations. Generally, the transport schedules should be adjusted for the mass traffic flows caused by these events. However, precise quantitative empirical data are usually insufficient due to the lack of observation data and analysis tools. In rail transit systems, the detailed trip records of each traveller can be stored in the AFC system. However, it is also impossible to determine which passenger is part of the event audience. Considering the high regularity of rail transit passengers, a comparison method between the event day and the corresponding weekday of the previous week is used to evaluate the traffic influence of special events.A football game held in Worker’s Stadium on 23 April 2016, starting at 19:35 and ending at 21:40, is used as our case study. The Worker’s Stadium is one the most important centres for entertainment and sports in Beijing, and it can accommodate approximately 150,000 people. The location of the Stadium is shown in Figure15. The Dongsishitiao (DSST) Station is the nearest railway station to the Worker’s Stadium, so it is the most used station for passengers going to the stadium. In this study, the comparison day of the previous week is 16 April 2016.Figure 15
Location of the Worker’s Stadium (source:http://map.baidu.com/).Figure16 shows the time-varying inflow and outflow distributions of the DSST station. It can be clearly observed that (1) there is a high arrival peak flow (station outflow) before the game, with the peak time at 18:30; (2) there is also a high departure peak flow (station inflow) after the game, with the peak at 22:00; and (3) the number of departure passengers entering the DSST station is as much as four times than the normal day, and the departure peak is much higher than the arrival flow. If there is no additional transport capacity added to support these mass flows, congestion and safety issues may emerge for the event stations.Figure 16
Time-dependent inflows and outflows of the DSST Station.The number of extra section flows is used as the evaluation indicator for the event influence, which equals the section flows in an event day minus the flows in a normal day. After simulating the traffic status of two comparison days, the time-dependent extra section flow distribution after the event ends is shown in Figure17. V means the number of flows, which also corresponds to different colours. The red colour means the extra section flow is over 800 passengers, and the other colours represent smaller numbers of passengers. It can be found that (1) an outward evacuation process exists after the sports game ends, with a peak 20 minutes later; (2) the extra section flow (event flow) mainly travels through Lines 2, 6, and 1; hence, the train schedule adjustment should be made for these lines; and (3) fifty minutes later the event flows almost disappear from the network.Figure 17
Extra section flow distributions after the event ends.
(a)
21:00~21:30 (b)
21:30~22:00 (c)
22:00~22:30 (d)
22:30~23:00The maximum section flow in a line determines the train headway time. Table5 gives the maximum section flows for the most influenced lines, as shown in Figure 17. We can determine that (1) the most influenced line is Line 2 and the influenced time is from 21:30–22:30 and (2) the most influenced time for the network is 22:00–22:30. Hence, some regulatory measures should be made for transporting these additional event flows, such as reducing headway time or running a short route train for these influenced sections.Table 5
Comparison results between the event day and a normal day.
Maximum section flow in a normal day(person) Maximum section flow in an event day(person) Rate of increase(%) Line 1 Line 2 Line 5 Line 6 Line 1 Line 2 Line 5 Line 6 Line 1 Line 2 Line 5 Line 6 21:00–21:30 4985 2525 4709 4857 4694 2538 4884 4525 −5.84 0.51 3.72 −6.84 21:30–22:00 4363 2562 4582 4435 4303 3815 4611 6087 −1.38 48.91 0.63 37.25 22:00–22:30 4056 1842 3948 3942 4671 3335 4597 4732 15.16 81.05 16.44 20.04 22:30–23:00 3045 1360 3165 3405 3112 1205 3506 3839 2.20 −11.40 10.77 12.75


## 4.3.1. Dynamics of Passenger Flows

The descriptive capability for dynamic flow status is the fundamental and core function of DTA models and simulators. The same traffic demand input and train schedules used in the model verification are applied in this case study. The simulation time is from 5:00 to 24:00. Part of time-dependent transport capacities for each line are given in Table4.Table 4
Transport capacity for each line from 5:00 a.m. to 12:00 a.m. (passengers/hour).
Line 5:00–6:00 6:00–7:00 7:00–8:00 7:00–8:00 8:00–9:00 9:00–10:00 10:00–11:00 11:00–12:00 Line 1 25920 31680 40320 40320 40320 25920 27360 25920 Line 2 14400 25920 40320 40320 28800 18720 18720 20160 Line 4 23040 30240 43200 30240 30240 23040 21600 21600 Line 5 14400 24480 38880 38880 25920 18720 18720 18720 Line 6 14400 19200 32640 34560 34560 14400 23040 17280 Line 7 7680 21120 28800 28800 26880 14400 17280 21120 Line 8 5760 12960 21600 25920 21600 14400 14400 12960 Line 9 8640 17280 24480 24480 17280 14400 15840 17280 Line 10 7200 24480 37440 33120 34560 18720 18720 18720 Line 13 17280 28800 30240 34560 14400 17280 14400 10080 Line 14 7440 14880 13020 14880 13020 14880 14880 13020 Line 15 4320 11520 17280 17280 15840 11520 11520 11520 Line BT 2880 15840 28800 28800 21600 12960 12960 12960 Line DX 23040 30240 43200 30240 30240 23040 21600 21600 Line FS 7200 12960 14400 12960 11520 11520 11520 11520 Line YZ 8640 14400 14400 14400 14400 8640 8640 8640 Line CP 1440 10080 14400 14400 14400 7200 7200 7200 Line JC 0 2520 4200 4200 5880 5040 5040 5040In Beijing rail transit, the direction for lines is defined as the up direction is from east to west and from south to north for straight lines and counterclockwise for the circle lines; the down direction represents the opposite directions. Figure11 shows the dynamic network passenger flow status during morning peak hours (7:00–9:00), where R means the capacity utilization rates which corresponds to different colours. We can see that the up direction of Line 1 and the down direction of Lines 5 and 6 and BT are the most congested lines in the Beijing subway during the morning peak hours. To maintain safe transit operations, a forced inflow control measure is widely used in the Beijing rail transit, which limits the number of passengers entering the stations. Most of the controlled stations are located on these congested lines.Figure 11
Dynamic passenger flow status during the morning peak hours (7:00~9:00).
(a)
7:00~7:30 (b)
7:30~8:00 (c)
8:00~8:30 (d)
8:30~9:00A significant amount of passenger flow information for different levels can be output by the simulator, such as platform, train, line, and network. Figure12 shows the passenger density on the down direction platform of the Tiantongyuan (TTY) station every 30 seconds. The TTY station is one of the most congested stations on Line 5. We can find that the maximum passenger density is as high as 3.0 passengers per square metres, which almost reaches the maximum safe density for platforms. The platform passenger density can be used to support train schedule regulation decisions and transport capacity allocations.Figure 12
Passenger flow density on the down direction platform of the TTY station.Figure13 presents the time-varying section flows in the up direction of Line 1. The maximum section flow of the lines is the key parameter for calculating the train headway time. We can see that the pivotal sections of Line 1 are sections 6 to 11; nearly 120,000 passengers travel across these sections in the morning.Figure 13
Time-varying section flows in the up direction of Line 1.Figure14 presents the network inflows, outflows, and passengers loading distribution every 30 minutes. There is no doubt that the reason for these two sharp peaks in the morning and evening is commuter travelling. The imbalanced travel demand makes it difficult for transport organizations and capacity utilization. We can find that the peak of the network load is approximately 500,000 passengers, which is less than the maximum capacity of the simulator. Hence, the developed simulator is efficient enough for large-scale transit network applications.Figure 14
Time-varying network passenger flows.


## 4.3.2. Special Events Evaluation

The traffic management for special events such as concerts, large conferences, and sports events is a difficult task for transport corporations. Generally, the transport schedules should be adjusted for the mass traffic flows caused by these events. However, precise quantitative empirical data are usually insufficient due to the lack of observation data and analysis tools. In rail transit systems, the detailed trip records of each traveller can be stored in the AFC system. However, it is also impossible to determine which passenger is part of the event audience. Considering the high regularity of rail transit passengers, a comparison method between the event day and the corresponding weekday of the previous week is used to evaluate the traffic influence of special events.A football game held in Worker’s Stadium on 23 April 2016, starting at 19:35 and ending at 21:40, is used as our case study. The Worker’s Stadium is one the most important centres for entertainment and sports in Beijing, and it can accommodate approximately 150,000 people. The location of the Stadium is shown in Figure15. The Dongsishitiao (DSST) Station is the nearest railway station to the Worker’s Stadium, so it is the most used station for passengers going to the stadium. In this study, the comparison day of the previous week is 16 April 2016.Figure 15
Location of the Worker’s Stadium (source:http://map.baidu.com/).Figure16 shows the time-varying inflow and outflow distributions of the DSST station. It can be clearly observed that (1) there is a high arrival peak flow (station outflow) before the game, with the peak time at 18:30; (2) there is also a high departure peak flow (station inflow) after the game, with the peak at 22:00; and (3) the number of departure passengers entering the DSST station is as much as four times than the normal day, and the departure peak is much higher than the arrival flow. If there is no additional transport capacity added to support these mass flows, congestion and safety issues may emerge for the event stations.Figure 16
Time-dependent inflows and outflows of the DSST Station.The number of extra section flows is used as the evaluation indicator for the event influence, which equals the section flows in an event day minus the flows in a normal day. After simulating the traffic status of two comparison days, the time-dependent extra section flow distribution after the event ends is shown in Figure17. V means the number of flows, which also corresponds to different colours. The red colour means the extra section flow is over 800 passengers, and the other colours represent smaller numbers of passengers. It can be found that (1) an outward evacuation process exists after the sports game ends, with a peak 20 minutes later; (2) the extra section flow (event flow) mainly travels through Lines 2, 6, and 1; hence, the train schedule adjustment should be made for these lines; and (3) fifty minutes later the event flows almost disappear from the network.Figure 17
Extra section flow distributions after the event ends.
(a)
21:00~21:30 (b)
21:30~22:00 (c)
22:00~22:30 (d)
22:30~23:00The maximum section flow in a line determines the train headway time. Table5 gives the maximum section flows for the most influenced lines, as shown in Figure 17. We can determine that (1) the most influenced line is Line 2 and the influenced time is from 21:30–22:30 and (2) the most influenced time for the network is 22:00–22:30. Hence, some regulatory measures should be made for transporting these additional event flows, such as reducing headway time or running a short route train for these influenced sections.Table 5
Comparison results between the event day and a normal day.
Maximum section flow in a normal day(person) Maximum section flow in an event day(person) Rate of increase(%) Line 1 Line 2 Line 5 Line 6 Line 1 Line 2 Line 5 Line 6 Line 1 Line 2 Line 5 Line 6 21:00–21:30 4985 2525 4709 4857 4694 2538 4884 4525 −5.84 0.51 3.72 −6.84 21:30–22:00 4363 2562 4582 4435 4303 3815 4611 6087 −1.38 48.91 0.63 37.25 22:00–22:30 4056 1842 3948 3942 4671 3335 4597 4732 15.16 81.05 16.44 20.04 22:30–23:00 3045 1360 3165 3405 3112 1205 3506 3839 2.20 −11.40 10.77 12.75


## 5. Conclusions

A simulation-based DTA framework and models for the schedule-based rail transit network were proposed in this work. The dynamic equilibrium status of network flows is achieved by integrating the pretrip equilibrium and enroute path switch models, which is consistent with the route choice behavior in rail transit system. A queue-based method for describing the passenger flow stream within stations makes it possible to simulate the passenger travelling processes at a disaggregate level. A simulator based on the proposed models was developed in the C# programming language using object-oriented and continuous time-driven approaches. The Beijing rail transit network and AFC transaction data are applied to verify the simulation models and tool. The results indicate that an acceptable accuracy and high computational efficiency can be obtained for capturing the dynamics of passenger flow in a large-scale transit network.The DTA is an essential foundation for the development of dynamic operations management systems. This research focuses on the descriptive capability for describing spatial-temporal flow patterns on the network. Moreover, based on different travel demand inputs, the simulation-based DTA models and tools can be applied to estimate the online traffic flow status and predict future traffic states for short-term management applications. To further improve our models, the dynamic train running control in the microscopic view should be added to the simulation framework.



---

*Source: 2890814-2017-02-13.xml*