Boston Green Line Simulator

By: Moisés Bensadón



This is a simulation of the MBTA Green Line based on massdot opendata exported from 2022 and 2023. There are a total of 69 stations each with 2 corresponding `stop_id` so the natural implementation was to create two identical graphs, each corresponding to one direction, and connecting them at turn around points.

To simplify modeling this as a DES a couple assumptions are made (at least for now):

1. Trains will not break down (I know it's the green line but let's be optimistic)

2. Passenger congestion is not modeled. i.e. we assume a train takes all passengers it can.

3. Trains will not wait for passengers to board.

Now in terms of the set of feasible actions that can be taken upon a train arrival, we have the following possible actions:

1. Continue, schedule an arrival @ current_time + travel_time

2. Wait for next train to arrive at the same station, schedule a departure @ next_train.arrival_time

3. Turn around and go back to the other direction, schedule a departure from the opposite stop_id @ current_time + turnaround_time

4. Skip a station, if and only if a train with the same destination is less than 1 minute behind, schedule an arrival at the following stop @ current_time + travel_time + next_stop.travel_time

Goal: This project aims to find an ideal policy for directing trains along the Green Line, upon each arrival it will evaluate the 4 actions it can take and pick the one that minimizes the weighted* cummulative wait time accross all stations.

* The weight is based on the number of routes that service each stop so as to avoid partitioning of the train routes into shared sections. The goal of this project is not to redesign the routes rather to direct train traffic optimally.



Future Additions:

1. Take into account passenger congestion (MBTA has an API for payment data)

2. Take into account train breakdowns (MBTA has an API for train locations)



Sources:

1. Improving Service on the MBTA Green Line Through Better Operations Control by Nigel H. M. Wilson, Richatd A. Macchi, Robert E. Fellows, and Anthohy A. Deckoff

2. Improving high-frequency transit reliability: a case study of the MBTA Green Line through simulation and field experiments of real-time control strategies by Joshua Javier Fabian

3. MBTA Open Data Portal: https://mbta-massdot.opendata.arcgis.com/search?tags=rapid%2520transit

4. Michael Barry, Brian Card: https://mbtaviz.wordpress.com/2014/07/25/website-source-announcement/