Uploaded by ro.ghotbi

Route Calibration Research Doc

advertisement
Route Calibration Research Doc
Michael Zhang, Roham Ghotbi, Trevor Wu
Add a source of material/citation at the beginning of each section (Finish by March
5th.)
Please explain the metrics for success of calibration. Explain how the calibration of the
models are done. Routing calibration.
Please fix notation inconsistencies!
We compiled this doc as a reference for calibrating Microsimulations in Aimsun and for
keeping track of the progress we have made in our research.
1
Introduction
1.1
Background on routing behavior
References: Aimsun Documentation and [3] (to be remove and add as bibtex entries)
Road traffic results from the mutual interactions between the decisions travelers make.
This document investigates the calibration of routing behaviours and routing choice to best
model traffic within traffic microsimulator Aimsun.
1.1.1
Dynamic user equilibrium, iterative assignment, one-shot assignment, pre-trip route guidance, en-route route guidance, experienced travel time, expected travel time, instantaneous travel
time
One of the common behavior assumptions of travelers is that they tend to choose the
available paths which have the least travel time between their origins and destinations,
building on the idea that travelers prefer to avoid consuming travel time, or other types
of cost used during traveling. However, due to congestion effect in the network, the travel
time of a route depends on the route choice made by other travelers, who are also trying
to use the least travel time route for their origin-destination path. When every traveler
succeeds in finding minimal-travel time route, or in other words when every route used for
each origin-destination pair has the same travel time/cost, user equilibrium has been
achieved. As the experienced travel time on a route depends on congestion of the route
in the future, finding dynamic user equilibrium is expensive: iteratively, simulator assigns
routes and derives link volumes and corresponding travel times and re-assigns routes to
satisfy this equilibrium condition. (For more information on Aimsun’s implementation of
Dynamic User Equilibrium, see Chapter 3). Simulation where iteratively route are assigned
1
cite
cite
and then entire simulation is run is called iterative assignment. On the other hand, the
simulator can assign the route to minimized expected/predicted travel time. In this case,
the simulator only assigns route and runs the simulation once. Such simulation is called
one-shot assignment. Instantaneous travel time can be used as expected travel time.
Instantaneous travel times take the snapshot travel time measured at the time that the
routes are generated, without considering congestion during subsequent time periods. In
contrast to instantaneous travel time, experienced travel time assumes that travelers are
willing to seek routes that minimize their experienced travel time instead of the route that
appears to be the best only at the departure.
In one-shot assignment, vehicles departing at different times are given a route that is
periodically updated in simulation based on expected travel times. If the vehicles strictly
follow the route guidance, such route guidance is called pre-trip route guidance. If
the vehicle can update their route during their trip, the route guidance is called en-route
route guidance.
Introduce stochastic route choice. Why do we need stochastic route choice?
1.1.2
Type of traffic simulations: macro/meso/micro
References: Aimsun Documentation
Theo: Review this.
Macroscopic Simulations Macroscopic simulations do not simulate individual vehicles
at all, only flow on the network. It takes data from the OD matrix and calculates the
load that will place on each segment of the network. Travel time is computed using a
shortest-paths algorithm.
Theo: Explain that macrosimulation is used to calibrate demand but not microsimulation.
Microscopic Simulations Microscopic Simulations model each individual vehicle and
iterate with fixed timesteps. Road segments and vehicles are initialized, then iteratively
loaded into the network. Then, the simulation loops through every road segment (entity)
and updates all vehicles in that segment and keeps track of which vehicles will change
segments. After it has iterated through every vehicle and segment, it then calculates the
vehicle’s new positions after ∆t, and increments the clock, and repeats the process iterating
through all segments and vehicles.
Definition 1 (Simulation time step).
Trevor: Define the time step with definition.
Microscopic Simulations also integrate behavioral models such as but not limited to:
car following, cruise control, lane changing, metering, and gaps.
Variables are defined as:
• ∆t = simulation step, default = 0.8 seconds
• trafficControl = Master Control Plan
2
cite
cite
cite
cite
cite
• entities = Aimsun Road Network
• vehicles = assigned by Initial K-Shortest Paths
Algorithm 1: Microscopic Simulation
Result: statistics
initialize entities, trafficControl, vehicles, ∆t, t;
t = 0;
while simulation not ended do
update trafficControl;
for entity in entities do
for vehicle in entity do
vehicle = update(vehicle, behaviorModels, state);
end
process vehicles leaving entity;
end
generate vehicle arrivals;
t = t + ∆t;
end
Mesoscopic Simulations A Mesoscopic simulation can be thought of as an ”in-between”
of Macroscopic and Microscopic simulations. Like a Microscopic simulation, a Mesoscopic
simulation simulates individual vehicles, but only when those vehicles enter or exit a road
section. Finer movements such as lane-changing are not within the scope of a Mesoscopic
simulation. It also does not simulate every timestep, only times where an event (an occurence which changes the state of the system) occurs. These events are defined as:
• Vehicle generation (new vehicle enters the network from a centroid)
• Vehicle system entrance
• Vehicle node movement (vehicle enters or leaves section)
• Change in traffic signal state
• Statistics Output
• Change in OD Matrix
When an event occurs, it is placed into a queue corresponding to a respective node, which
sorts it by time and importance. Aimsun then reads from this queue to generate the
Mesosimulation.
Assuming V vehicles, N nodes, and E events.
Step 1: Initialize network state: network status, vehicle positions, variables.
Step 2: Find next events: Estimate when certain events will happen and put them in a
queue. O(V + N )
Step 3: Iterate through queue and update network state accordingly. Update events in
queue if network state changes. O(N 2 )
3
Step 4: If t 6= tend return to step 3, if t = tend end simulation.
Trevor: Can you give an order of magnitude of number of events and number of iterations (step 2 and step 3)?
1.2
1.2.1
Aimsun specification for routing behaviors
Network and demand
Theo: To do
1.2.2
Route cost
To do. Make this specific to macro/meso/micro SRC, DUE.
Add formatting for another layer of sub sections
• Introduction/Overview R
• Link Attractiveness R
• K Initial Shortest Path Cost Function (1.2.2 OR 1.2.3) T
• Initial Cost Function T
• Dynamic Cost Function M
• User-Defined Link Cost Function M
Introduction
The network representation that is used by Aimsun for the Microscopic simulations
uses road sections and intersections to define the roads. The path computation algorithms
require a graph like Link-Node representation which also takes into account the turn movements at the end of each road section. Turn movement is defined as the direction at which
the road is splitting into(i.e left, right, straight). Therefore, the link that is used to connect
two nodes in the route choice calculations, will contain its road section and a turn movement. The conversion from the intersection-road section setup to Link-Node model splits
each road section to the same number of roads as there are turn movements at the end of
that section. For example if we have a road section that has a left turn, right turn and
straight movements at a intersection, the link-node conversion would turn the intersection
into a node with 3 input links. Each link will then be assigned a cost of traversal which will
contain the cost assigned to the specific turn at the end of that link. The cost calculations
are defined in greater detail in the the following sections.
The paths that are available for each Origin-Destination pair can be either defined by
the user, or calculated using a shortest path algorithm, which uses the concept of cost
to find the best possible routes. In other words, when we want to apply a shortest path
algorithm to a Link-Node network, each link is required to have a cost function(i.e. travel
4
time) that will provide the cost for that path during the calculation of the shortest route.
Depending on the choices made in the traffic assignment calculations, and whether simulated data(i.e. simulated travel time) is available or not, the costs could be calculated
through three types of cost functions. The functions are the K-initial shortest paths,
the Initial Cost Function, and the Dynamic Cost Function. In all of these cases,
there is a default function available, which represent the link travel time in seconds. This
default cost is composed of a the the road section travel time that the link is from, plus
the turn movement travel time associated with it. The tunr movement travel time is what
introduces the time penalty of the turn movement at the end of the link depending on what
kind of turn movement we have ad the end(left, right or straight).
Link Attractiveness
The links attractiveness are main building block that are used to calculate either the
Initial or the dynamic cost of the links across the network. The default value for the it
is based on the theoretical flow capacity of the section the link, the number of the lanes
of the section that are used for the turn movement at the end of the route link, and the
number of turn movements share for each lane. Note: Be careful not to mix link and lane
together. Link refers to the Lnik-Node representation of the network as is what connects
two nodes together where Lane refers to the lane of the street that is represented in the
Section-intersection representation setup.
In order to define the attractiveness of a link, we need to first define weight, and generic
attractiveness of a lane. For each lane, its weight denotes its contribution to the calculation
of the link attractiveness. By definition, a central lane makes a complete contribution to the
link attractiveness(weight = 1) where as the contribution of an exit lane is partial(weight
= 0.75). An exit lane is defined as any lane that, at the intersection, strictly diverges to a
road section that leads to another link. A lane that is shared between to sections(i.e goes
to multiple directions) is still considered a central lane.
(
1
W Li =
0.75
if ith lane is a central lane
if ith lane is an exitside lane
Using the weight of a lane, the generic attractiveness per lane in section s is defined as:
GCLs = P
Cs
i∈exitlane W Li
Where Cs is the attractiveness of section s which is essentially the capacity of the road
section itself. The attractiveness of a link j (composed by lanes from section s) is defined
as:
CLj =
X
k∈exitlanes of link j
GCLs ∗ W Lk
N T Sk
Where NTSk is the number of turn movements that lane k shares.
Please define N T Sk
Roham: Done
5
Initial Cost Function
The motivation for the Initial Cost Function is to provide a precomputed cost for each
path/vehicle before the simulation starts. That way, there is something to run the shortest
path algorithm on. We want to do this so that we can set up a sensible starting state for
the simulation.
The equation is defined as follows:
IniCostj,vt = T ravelT F Fj,vt + T ravelT F Fj,vt ∗ φ ∗ (1 − CLj /CLmax ) + τ ∗ U serDef Costss
Where:
• j is a link in the network
• s is a section, a part of a link s ∈ j
• IniCostj,vt is the initial cost of the vehicle type vt on link j
• T ravelT F Fj,vt is the free-flow travel time given a vehicle type vt on link j
• φ is a parameter that scales link attractiveness
• CLj is the link attractiveness of link j
• CLmax is the maximum link attractiveness
• τ is a parameter that scales the U serDef Costs
• U serDef Costss is defined by the user in a section s
T ravelT F Fj,vt is calculated differently based on whether we want to factor in the vehicle
type.
With vehicle type:
T ravelT F Fj,vt =
Lengths
Lengtht
+
min{Speedlimits ∗ θvt , M axSpeedvt } min{Spedlimitt ∗ θvt , M axSpeedvt }
• Lengths is the length of the section s, part of link j
• Speedlimits is the speed limit on section s
• θvt is a scaling factor, which indicates how fast the vehicle travels relative to the speed
limit
• M axSpeedvt is the maximum speed of vehicle type vt
• Lengtht is the length of the turn part of link j
• Speedlimitt is the speed limit at the turn
6
Without taking into account vehilce type:
T ravelT F Fj =
Lengtht
Lengths
+
Speedlimits Speedlimitt
K Initial Shortest Path Cost Function
Algorithm 2: K-Shortest Paths
Result: statistics
input: K-SP, I = (O-D pairs), A = Links;
initialize n = 1 (iteration no.), k = 1 (link no.);
for OD-Pair i ∈ I do
gi := demand for pair i;
InitialK-SP(k, i) := kth shortest path travel time between O-D pair i
calculated using InitialK-SP algorithm;
hik (n) := the flow on path hik at iteration n;
hik (n) = gi / InitialK-SP(k,i);
end
while k < K-SP do
for a ∈ A do
va := flow for each link a;
for O-D pair i ∈ I do
for path k ∈ Ki do
if link a ∈ path k then
i = 1;
δa,k
else
i = 0;
δa,k
end
i hi ;
va = δa,k
k
end
end
end
k = k + 1, n = n + 1;
λ = 1/(n − 1);
for OD-Pair i ∈ I do
hik (n) = hik (n − 1) + λ gi − hik (n − 1) ;
end
for l ∈ [1, k − 1] do
hil (n) = hil (n − 1) − λ hil (n − 1) ;
end
end
Where InitialK-SP is calculated using the initial cost function:
IniKCostj = SectionV DFj + T urningP enaltyj + τ ∗ U serDef Costs
• j is a link, and s is a section in j
7
• SectionV DFj is the delay on link j
• T urningP enaltyj adds the amount of time it takes to turn on the link given a certain
speed
• τ scaling factor for U serDef Costs
• U serDef Costs user defined cost for section s
The K Shortest Path algorithm is used by Aimsun to find the cost between the K-Shortest
paths between an O-D pair i.
K-SP is a parameter which we can calibrate. It determines the amount of shortest-path
trees to calculate for every centroid. When initializing, K shortest path trees are calculated
using Dijkstra’s Algorithm and the initial cost function. Otherwise, they are calculated using Dijkstra’s Algorithm on the dynamic cost function. If K-SP = 1, that means we only
calculate 1 shortest path tree.
Dynamic Cost Function
Dynamic Cost Function is used when simulated travel time data i available, therefore
it can only be used when simulation has started and data has been collected. Same with
the Initial Cost Function, there are two types of Dynamic Cost Functions, one is DynCostj
with all vehicle types for link j, and the other is DynCostj,vt with vehicle type vt for link
j.
The equation for DynCostj , a function of the mean travel time (in seconds), is defined
as follows:
DynCostj = EstimatedT ravelT imej +EstimatedT ravelT imej ×φ×(1−CLj /CLmax )+τ ×U serDef Costs
Where:
• EstimatedT ravelT imej is the estimated travel time of the link j calculated using the
below algorithm.
• φ is a parameter that scales “link attractiveness”
• CLj is a parameter that defines “link attractiveness”
• CLmax is the maximum link attractiveness
• τ is a parameter that scales the U serDef Costs
• U serDef Costss is the cost defined by the user in a section s plus cost of the turn in
link j
In situations which no vehicles have crossed a link, we have to distinguished between a
totally congestion link or an empty link. The following algorithm is applied to calculate
8
EstimatedT ravelT imej for link j:
Algorithm 3: EstimatedT ravelT imej
Flow = vehicles that have crossed link j;
if Flow 0 then
EstimatedT ravelT ime = T ravelT ime;
else
if there is any vehicle stopped then
EstimatedT ravelT ime = AvgT imeInSection;
else
EstimatedT ravelT ime = AverageSectionT ravelT ime;
end
end
EstimatedT ravelT ime = max(EstimatedT ravelT ime, T ravelT F F )
Where:
• AvgT imeInSection is the average waiting time for vehicles waiting in front of the
queue in section s
• AverageSectionT ravelT ime is the section travel time, which takes into account all
the turn movements that have as origin section s
• T ravelT F F is the travel time of link j in free flow condition.
The Dynamic Cost Function DynCostj,vt of link j of vehicle type vt is defined as:
DynCostj,vt = EstimatedT ravelT imej,vt +EstimatedT ravelT imej,vt ×φ×(1−CLj /CLmax )+τ ×U serDef Cos
Please explain motivations for link attractiveness.
Where:
• EstimatedT ravelT imej,vt is the estimated travel time of the link j with vehicle type
vt calculated using the below algorithm.
• φ is a parameter that scales “link attractiveness”
• CLj is a parameter that defines “link attractiveness”
• CLmax is the maximum link attractiveness
• τ is a parameter that scales the U serDef Costs
• U serDef Costss is the cost defined by the user in a section s plus cost of the turn in
link j
Similar to EstimatedT ravelT imej above, EstimatedT ravelT imej,vt have to first distinguished between a totally congestion link or an empty link. However, this time it also
takes into account whether this section s has reserved lanes for vehicle type vt, and
whether vt actually uses the reserved lane .The following algorithm is applied to calculate EstimatedT ravelT imej,vt for link j with vehicle type vt:
9
Algorithm 4: EstimatedT ravelT imej,vt
Flow(j,vt) = vehicles with vehicle type vt that have crossed link j;
if Flow(j,vt) 0 then
EstimatedT ravelT ime(j, vt) = T ravelT ime(j, vt);
else
if there is any vt stopped then
EstimatedT ravelT ime(j, vt) = AvgT imeIn(j, vt);
else
if j has reserved lanes for vehicle class cl then
if vt belongs to cl then
if F lowClass(j, cl) > 0 then
EstimatedT ravelT ime(j, vt) = T ravelT imeClass(j, cl);
else
if there is any vehicle belong to cl stopped then
EstimatedT ravelT ime(j, vt) = AvgT imeInClass(s, cl);
else
EstimatedT ravelT ime(j, vt) =
AverageSectionT ravelT ime(s, cl);
end
end
else
if F lowClass(j, not cl) > 0 then
EstimatedT ravelT ime(j, vt) = T ravelT imeClass(j, not cl);
else
if there is any vehicle not belonging to cl stopped then
EstimatedT ravelT ime(j, vt) = AvgT imeInClass(s, not cl);
else
EstimatedT ravelT ime(j, vt) =
AverageSectionT ravelT ime(s, not cl);
end
end
end
else
if F low(v = j) > 0 then
EstimatedT ravelT ime(j) = T ravelT ime(j);
else
if there is any vehicle stopped then
EstimatedT ravelT ime(j) = AvgT imeInSection(s);
else
EstimatedT ravelT ime(j) = AverageSectionT ravelT ime(s);
end
end
end
end
end
EstimatedT ravelT ime(j, vt) =
max(EstimatedT ravelT ime(j, vt), T ravelT F F (j, vt))
10
The above algorithm first distinguishes if a vehicle of type vt has crossed link j during
the last data gather period. If that’s the case, then the simulated mean travel time is take
as the current cost. If no vehicle type vt has crossed link j, we further distinguish different
cases of costs according to the following steps:
• AvgT imeIn(s, vt) is the average waiting for the first vehicle of vt in front of the queue
in the section
• If section s has reserved lanes for vt:
– if vt uses the reserved lane:
∗ T ravelT imeClass(j, cl) is the mean travel time of link j, aggregating all
vehicle types of vehicle class cl
∗ AvgT imeInClass(s, cl) is the average waiting time of first vehicle of cl in
front of the queue in s
∗ AverageSectionT ravelT ime(s, cl) is the average section travel time of all
vehicles of cl
– if vt does not use the reserved lane:
∗ T ravelT imeClass(j, not cl) is the mean travel time of link j, aggregating
all vehicle types not belonging to cl
∗ AverageT imeInClass(j, not cl) is the average waiting time for the first vehicle not belonging to cl in front of the queue in s
∗ AverageSectionT ravelT ime(s, not cl) is the average section travel time of
all vehicles not belonging to cl
• If section s does not have reserved lanes:
– T ravelT ime(j) is the mean travel time of link j, aggregating all vehicle types
– AvgT imeIn(s) is the average waiting time for the first vehicle in front of the
queue in s
– AverageSectionT ravelT ime(s) is the average section travel time for all vehicle
types
User-Defined Link Cost Function
The algorithms described above are all defined in terms of link travel time only - they
didn’t consider other influences, for instance toll pricing, or a combination of various link attributes. Therefore, Aimsun provides an “user-defined cost function” option to include these
attributes. In this option, users may combine various sets of parameters, constants, and
variables with common mathematical functions and operators (+, −, ∗, /, ln, log, exp, etc.).
The variables must be correspond to numerical attributes of an object in the model (links,
sections, turns, vehicle, etc.), and those values could be either:
• Fixed
– lengths
– theoretical capacities
– number of lanes
11
– etc.
• Change during the simulation
– link flows
– average link speeds
– average link travel times
– etc.
And same as the Dynamic Cost Functions, there are two types of user-defined cost functions
- basic cost functions (all vehicle types) and functions considering vehicle type . The
parameters of these two types of user-defined cost function includes:
• Basic cost function
– Section S is the section reference of the link
– Turn T is the turn reference of the link
• Cost function considering vehicle type
– Section S is the section reference of the link
– Turn T is the turn reference of the link
– Vehicle type V T is the vehicle type specified for the cost function
1.2.3
Set of routes
• Shortest Path Algorithm
• K Initial Shortest Path Cost Function (1.2.2 OR 1.2.3)
Why do we need OD routes, path assignment results and calculated shortest paths?
OD Routes (ODR) OD Routes (formerly known as User-defined routes) are the set of
paths predefined by the Aimsun user and then fed to the system. One can think of them
as a set of paths that drivers are most familiar with and might choose to take.
Path assignment results (PAR) Path assignment results are generally result of applying a static traffic assignment using a macro-simulation or a DTA based on Dynamic
user equilibrium using a micro/meso-scopic simulation. These paths correspond to the OD
routes with one major difference in comparison to the regular OD Routes defined above.
While the OD routes are just a set of links for Origin-Destination pairs, the paths derived
from and assignment result define paths fr om each link on the network to the destination.
This allows the traveller using the PAR path to recover in the case of losing a turn, where
the traveller using the regular OD route, won’t be able to reach the destination anymore.
For our purposes, we receive PARs as a result of running Aimsun macro-simulations,
and then we feed it to our system for the micro-simulations.
12
Calculated shortest paths Shortest paths are calculated by applying the shortest path
algorithm (Dijkstra’s algorithm
Roham: I meant in the Aimsun based ob the doc. Reworded
) to a network represented as links and nodes. Each link will have a cost defined for it
(i.e travel time). Depending on the choices made during the traffic assignment calculation,
the cost will be calculated based on the initial cost functions or dynamic cost functions.
Would be interesting to know if Aimsun memoizes shortest path.
Please explain how the cost is computed? I think it is weird that cost functions are
used in microsimulations. Are you sure that this is the case?
Roham: We have added a section in 1.2.2 explaining the costs functions
Explain here interval, num of intervals, fixed route and en-route rerouting percentage,
vehicle types if they are used in both SRC and DUE.
Maximum Paths per Interval The maximum paths to consider per interval parameter
defines the maximum number of different paths used in the path selection process applied
to the stochastic route-choice and DUE. This attribute is also known as “Max Routes”.
1.3
Routing behaviors calibration process
This needs to be better explained.
1.3.1
Needs for calibration
In order to match the model outputs with the observed traffic conditions in real-world
scenarios, model calibration is needed. Model calibration involves the identification of a set
of model inputs and parameters that results in model outputs that are reasonably close to
those field observations. The measured traffic data can represent a wide range of quantities,
including flow time, flow speed, link capacity, travel time, etc. Apart from adjusting the
parameters in travel time computation and the simulation environment in general, choice of
path assignment algorithm and its parameters are also important factors to consider during
the process of calibration.
1.4
Review of existing resources
Theo: Later this will need to be rewritten.
Our primary resource for navigating the calibration process is the documentation included with Aimsun, which provides explanations for Aimsun’s implementation of various
DTA models and their parameters. In addition to Aimsun’s documentation, we also looked
through established academic articles which explain traffic assignment from a more theoretical and in depth perspective.
• Dynamic Network Simulation with AIMSUN, [1].
• Stochastic Heuristic Dynamic Assignment Based on AIMSUN Microscopic Traffic
Simulator, [2].
13
Which
case???
• Dynamic Traffic Assignment: A Primer, [3].
We also extensively referenced Jose Alatorre’s document on Routing behavior calibration
experiments, which was compiled last semester.
Introduce the outline of the document here.
2
Stochastic Route Choice Model
Write small intro here.
Define somewhere the probability Pk (t) of using a path k ∈ Ki for the OD pair i ∈ I
during the time interval [t, t + ∆t].
2.1
Background on Stochastic Route Choice
I (Theo) have not sure that this is specific to SRC, it might be better to more in Aimsun specification for routing behaviors. At least definition 2 and 3 should be moved.
Reference: Aimsun Documentation
In Dynamic Traffic Assignment (DTA), Origin-Destination matrices are input as traffic
demand.
Theo: Define centroids?
Definition 2 (OD matrices). Each matrix, denoted as RC×C with C the set of centroids,
for a specific time period and vehicle type, would provide the number of trips from every
origin centroid to every other destination centroid.
When a vehicle is generated at its origin, it is assigned to one of the available paths
between its origin and destination.
Definition 3 (Available paths for one OD pair). For each OD pair, the available paths are
all the paths connecting the vehicle’s origin node to its destination node. These paths can
either be defined by the user, or calculated by applying a shortest path algorithm, utilizing
the link cost function (see Definition 5) associated with each link and node.
I (Theo) still do not understand this definition (definition 2). Why does user need to
define path, if all the paths are considered???
Are link cost functions used for macro/meso/micro SRC and DUE?? This is not clear
to me (Theo).
Michael: The new section 1.2.2 addresses link cost functions.
The choice of its path is based on the calculated shortest routes, utilizing the cost
function associated with each link along the paths.
Definition 4 (Link-node representation). In order to explicitly account for the turn movement at the end of a section, the road representation is converted into the link-node representation. Each road section is split into the same number of links as there are turn
movements at the end of the section. The cost assigned to each link is a function of travel
time of the section plus the travel time of the turn movement.
14
Definition 5 (Link cost function). In the link-node representation of the network, a link
cost function is associated with each link as the weight when calculating the shortest path
between a pair of nodes.
What is the link-node representation of the network?
Michael: Added the link-node representation above.
Definition 6 (Path cost). For an available path between an origin and destination node,
its path cost is the summation of all link cost functions of the links on the path. In Aimsun’s
default cost function setting, cost function represents the link travel time in seconds, which
composed of a section travel time plus the turn movement travel time (time penalty for turn
movement).
Are there turn penalty costs?
Michael: Added turn penalty costs in the path cost definition.
In the case of Stochastic Route Choice (SRC) model, to account for the dynamic change
of path costs due to congestion issues, vehicles has the mechanism for rerouting en route
based on the change of cost on the path. The interval for recomputing the cost of its path
is determined by the route choice time interval parameter.
Definition 7 (Interval and number of interval as Aimsun parameters for cost evaluation).
Given a interval ∆t ∈ R, for every simulation time slice [t, t + ∆t], the link cost function
for every link in the network – and therefore shortest paths for every OD pairs – would be
computed based on the average link travel times from the previous cycle(s) of simulation
[t − i∆t, t]. Whereas i – the number of previous cycle(s) take into account for this reevaluation – is defined as the number of interval - for instance, a value of 1 means the
link times are taken from the previous interval only.
This needs to be reword as algorithm 5 explains it.
Definition 8 (SRC simulation process).
Algorithm 5: SRC Simulation Process
initialize avgTime;
initialize initialSP = for each OD pair i using cost function CF ;
while demand d not all assigned do
simulate for ∆t;
t = t + ∆t;
for OD pair i in all OD pairs I do
avgTime = updateAvgLink(i, CF);
end
for OD pair i in all OD pairs I do
updateShortestePath(i, CF);
end
for vehicle v in all en-routed enabled vehicles Ver do
updateEnRoutePath(v, CF );
end
end
15
The SRC simulation process consists of the following steps:
Step 1: Calculate initial shortest path(s) for each OD pair using the defined cost functions.
Step 2: Simulate for a user-defined time interval assigning to the available routes the fraction of the trips between each OD pair for that time interval according to the
selected route choice model. Obtain the current average link travel time as a result
of the simulation. Average link travel time is the average time a vehicle needs to
cross the turn/link. This is the mean of all the single travel times of every vehicle
that has left the turn/link. For a vehicle i, the average travel time (in seconds) is
calculated as:
Here travel time is not computed with cost functions. I (Theo) really do not
understand how travel time, cost, cost functions and exit time - entrance time
relates????
Michael: Removed the incorrect Tavg formula - still need further explanation
Step 3: Taking account of the average link travel time, recalculate the optimal shortest
path.
Step 4: For vehicles that are dynamically allowed to update path en route, suggest a change
of route based on the new shortest paths.
Step 5: repeat Step 2.
2.1.1
Other parameters and definitions
This needs to be written down properly. Are this specific to SRC?
• Three types of paths:
1. OD Route POD : a route edited by the user and allocated to a specific trip in an
OD Matrix
2. Path assignment results PP AR : the result of a previous dynamic simulation or a
static assignment and contains one or more paths for each trip in an OD matrix
3. Route choice model PRM C : the paths depend on the congestion currently present
in the simulation
• Three types of vehicles following the three paths above:
1. OD Route VOD : vehicle following the OD Route
2. Path assignment results VP AR : vehicle following path assignment result
3. Route choice model VRM C : vehicle following route choice model
• Fixed route percentage: the percentage of vehicles in an OD pair to follow the fixed
route mode (see Definition 2.2)
• En-route rerouting percentage: the percentage of vehicles in an OD pair which are allowed to reroute en-route during the intervals based on re-computation of the shortest
paths.
16
2.2
Fixed-Route Mode
Reference: Aimsun Documentation
2.2.1
Overview
Theo: This needs to be put in equation. I (Theo) think that the paragraph is not correct, fixed-route does not relate to en-route vs. pre-trip, but to the fact that assigned
routes does not depend on time.
Michael: Reworded the paragraph to emphasis the time-independent characteristic of
fixed-route mode.
In Fixed Routes Mode, all vehicles in one OD pair are assigned to the same route,
disregarding their departure time. Within this mode, the shortest path are calculated at
the beginning of the simulation, and for the only once. During the simulation, vehicles
are generated at the origin centroids, and would reach the destination centroids by their
assigned paths determined before the simulation began. Also, there is no need to assign
route choice model, as there is no concept of alternative routes.
Depending on the type of cost function used for the initial shortest path calculations,
there are two alternative fixed route models, discussed in the following subsections.
2.2.2
Fixed-Route Under Free Flow Conditions
Theo: To reword.
Michael: Reworded for clearer understanding.
In the Fixed-Route Under Free Flow Conditions Model, the paths are calculated at the
beginning of a simulation, taking account the initial cost as the cost of each link. Therefore,
as the name suggests, the link costs are only calculated under the free flow condition. Notice
that even when there is a warm-up session defined, the initial cost is still used. Link cost
function is the only main parameter which can be calibrated in this model.
2.2.3
Fixed-Route Under Warm Up Period Traffic Conditions
Theo: To reword.
Michael: Reworded for clearer understanding.
The Fixed-Route Under Warm Up Period Traffic Conditions Mode works similarly with
the Free Flow Conditions Model. When no warm-up period is defined, the initial paths are
calculated at the beginning of the simulation using initial costs. However, when a warmup period is defined in this model, new initial paths are calculated using the defined cost
function (Dynamic Cost Function or User-Defined Cost Function) after the warm-up period
ends. Parameters which can be calibrated include the warm up period and the link cost
function.
17
2.3
2.3.1
User-defined Selection
Overview
Theo: To reword (for example ODR path is a non-sense, a set of PAR routes = a
PAR).
The user-defined selection determines the probability of use for ODR and PAR paths
(see section 1.2.3). For each OD route, the user determines the probability of usage, distinguishing per vehicle type (defined “Path Assignment” folder in OD matrix definition).
The user defines the probability of use of each OD Route and the probability of use of the
initial shortest path Satisfying the condition below:
N
X
P (ODRin , vt) +
n=1
P
X
P (ISP ip , vt) ≤ 1, i ∈ I
p=1
Where:
P (ODRin , vt)
vt): Probability the ODRin path is chosen by vehicle type vt
i
P (ISP p , vt)
vt): Probability the ISP ip path is chosen by vehicle type vt
If the user uses path assignment result, leading to a set of PAR paths, the condition below
needs to be satisfied.
M
X
P (P ARim , vt) = 1, i ∈ I
m=1
Can the probability be a function of the state of traffic?
What are i, I, n, p, ISP, N, P, M, m?
It seems that P AR is not well defined (it is defined before and after the simulation as
two different things; it should be two different objects).
2.3.2 Conclusion
The user is in control of hand assigning the probabilities and thus have a complete control
over the popularity of roads and how the traffic is assigned. Unlike the other route choice
models below, this model does not require any specific parameter but rather the actual set
of probabilities and the choice of paths(ODR or PAR)
Roham: These models(binomial, Proportional, logit , clogit) are defined to be used as
part of the dynamic route assignment. Maybe we should create subsection 2,4 for dynamic route assignment and put them there?
2.4
Binomial Model
Please make sure to well understand the model.
18
2.4.1
Overview
To be reword by referencing notes on binomial distribution.
Roham: Did reword a bit. Let me know if it is still not clear
In this model the binomial distribution, Binomial(k − 1, p), is used to find the probability of using each path where k is the number of the latest shortest paths that have
been calculated that we want to consider and p is the success probability of the binomial
distribution.
By definition of Binomial, is the probability of using each path p?
Roham: No, p simply dictates where the peak of the binomial distribution is located at
Success probability can be thought of the probability of getting heads if we were to flip
a coin for which its distribution is defined by Binomial(k − 1, p). This distribution could
lead to values ranging from 0 to k − 1 and the probability of achieving each index x ∈ 0 to
k − 1 is defined as:
What is a value?
Roham: Is this more clear?
Px =
k−1
px (1 − p)k−1−x
x
Imagine we have 3 paths (k = 3) and success probability of 0.9 (p = 0.9). Also assume
that the time interval to to recalculate the shortest path is 10 minutes and we are currently
at minute 35. Then the last 3 shortest paths that have been calculated are the paths
calculated at times 30(index 2), 20(index 1), and 10(index 0)Then the path assignments we
could have are 0, 1, 2 indexing to each available path from 0(oldest) to 2(newest). Then
using the Binomial probability formula above we will have:
There is an implicit indexing that will change completely the path assignment result.
How is the indexing chosen? What does it mean to be oldest or newest path???
Roham: Made the example more clear. Let me know if it still need revision
0
1
2
0
2
1
1
P0 =
0.9 (0.1) = 0.01, P1 =
0.9 (0.1) = 0.18, P2 =
0.90 (0.1)2 = 0.81
2
2
2
2.4.2
Expectations
First important feature of this model is that the paths age is the metric for this setup rather
than paths cost. In this model, age is defined as the time that specific shortest path was
calculated. The sooner(smaller) the time, the older the path. This could be useful in cases
where we want to mimic time-based awareness of travellers about new paths. Intuitively,
this allows us to have a route choice algorithm where we could dictate which routes are
more likely to be used, solely based on their age. In other words, small p would correspond
to higher probability for older paths and as p increases, the newer paths will be more
frequently chosen.
Great remark, but what is path age??
19
Roham: Redefined age
2.4.3
Conclusion
This model could be perhaps used in case where we want to focus on the time frame the
paths(When that specific shortest path was created) where calculated rather than the actual
cost.
What is the time frame of path computation?
Roham: Reworded the binomial parts and defined age, should be more clear now?
2.5
Proportional Model
Theo: Math needs to be more rigorous. This is the first model where time-dependant
travel time is considered. It should be introduced properly. I (Theo) wonder if this
model is agnostic about definition of link cost (link cost if an interface/abstract class).
2.5.1
Overview
This model calculate the probability of a given alternative path k ∈ Ki , in the following
form.
CPk −α
−α
l∈Ki CPl
Pk = P
Where:
• α increases the probability of switching to the path with the lower cost.
• Ki is the finite set of all alternative paths for the ith Origin-Destination pair.
This is the first time we introduce Ki . We should cross reference all things used
here.
• CPk is the cost of path k which is defined as:
X
CPk =
Costj
Link j∈pathk
Define the cost of a link. There is no notion of turn penalty function of junction delay function (this is strange). If the cost is time dependent, then the probability is also
time dependent. This should be shown in the equation.
Roham: Will be defined in the initial chapter that will explain the cost functions
2.5.2
Expectations
The Model should prefer the alternate path with the lower cost more aggressively(higher
probability) as the alpha factor increases.
20
2.5.3
Conclusion
Using this model, you are able adjust the effect that the small change in the travel time
may have in the driver’s decisions. In other words, as the alpha factor increases, the drivers
tend to care more for the smallest improvements in their travel time as opposed to lower
alpha factors, where the chances of them switching to the path that is slightly better is
lower.
What does it mean to switch path here. I was thinking that this was only about assigning paths not switching paths.
2.6
Logit Model
References Aimsun Documentation
Trevor: Define K-SP. Is C-logit with K-SP= 1 the same as free-route under free flow (in
case there is no en-route rerouting)?
2.6.1
K-SP
2.6.2
Overview
The multinomial logit model is a way to conduct Dynamic Traffic Assignment. The probability that a vehicle takes a certain path k is given by the following equation.
evk θ
vl θ
l∈Ki e
Pk = P
Where vk is the utility of path k, θ is a scale factor, l is a path in Ki and i is an OD pair.
Ki is computed using a shortest paths algorithm. vk is given by the equation.
vk = −tk
where tk is the travel time for path k.
If this is true, then we do not need to introduce vk .
The travel time is computed differently for mesoscopic and microscopic simulations. In
mesoscopic simulations, travel time is computed using congestion and free flow travel times.
In microscopic simulations, additional finer aspects of vehicle movements are also taken into
account.
2.6.3
Expectations
Increasing θ should result in a ”narrowing” (decreasing variance) of options as it paths with
higher utility are weighted more.
2.6.4
Conclusion
In order to calibrate the Microsimulation with a Stochastic Route Choice Logit model,
the variable we need to focus on is θ. We need to analyze the traffic patterns of Fremont
21
and figure out if Fremont drivers always pick the most optimal route and what kind of
randomness is involved in their decision making.
Time interval, number of interval, predefined path, percentage of OD route, percentage
of en-route can also be changed. This should have been explained before and reference
here.
2.7
C-Logit Model
References Aimsun Documentation.
The motivation for C-Logit model is to modify the Logit model in such a way that
discourages vehicles from picking paths that are very similar. The reason for this is that
the Logit model may oscillate between routes that overlap greatly whereareas we desire a
form of convergence.
2.7.1
Overview
Theo: Reword once Logit model has been reword.
The C-Logit model is one way Aimsun conducts Dynamic Traffic Assignment. The
probability that a vehicle takes a certain path k is given by the following equation.
Pk = P
eθ(vk −CFk )
θ(Vl −CFl )
l∈Ki e
Where Vk is the utility of taking path k, CFk is the cross-factor of route k, and θ is a scaling
factor.
!γ
X
Llk
CFk = β ∗ ln
1/2 1/2
Ll Lk
l∈Ki
• Llk is the amount of time (in hrs) needed to travel the links which overlap between
path l and path k.
• Ll and Lk are the amounts of time (in hrs) needed to travel path l and path k
respectively.
• β determines the importance of how much links overlap between paths.
• γ reduces the importance of the overlap of links
2.7.2
Expectations
• Increasing β should correspond with a greater CFk . This would result in the model
becoming more likely to choose the path with the least overlap.
• Increasing γ has the opposite effect of increasing β.
• Increasing θ should correspond with an increasing probability of taking the paths with
the greatest difference between Vk and CFk (in essence making it more ”certain”).
Depending on β and γ, this will either result in the C-Logit model choosing the paths
with greater utility or paths with lesser overlap.
22
2.7.3
Python Experiment
Currently, it has been difficult replicating the C-Logit model in Python because we haven’t
figured out the precise utility function Aimsun uses. Based on Aimsun’s documentation
and their ”ground truth” we could see the rate at which the choices narrowed when the
scale factor was increased. However, when running experiments, there does not seem to be
a huge improvement from increasing the scale factor.
2.7.4
Conclusion
In order to calibrate the Microsimulation with a Stochastic Route Choice C-Logit model,
the main variables we need to focus on are γ and θ. Ultimately we need to analyze the
traffic patterns of Fremont and figure out if (1) Fremont drivers are averse to choosing
”common” paths and (2) how likely they are to pick the path they deem optimal.
3
3.1
Dynamic User Equilibrium Model
Background
References Aimsun Documentation and [1]
The main premise of Dynamic User Equilibrium is to simulate driver behavior by assigning all drivers to paths such that no driver can reduce their travel time with another
route. At this point, it will be said to be in equilibrium (from Jose’s doc).
Where this comes from? It is not well defined.
I (Theo) am quite confused because Aimsun defines individual vehicles, not flow.
Is it really the set of all paths? This is really not clear to me.
Fraction of the OD demand, explain how the fraction is defined based on the OD matrices.
Use cross-references.
The equation states that the sum of all flows for any given OD pair at any time will
be equal to the demand for that OD pair at the time. It also states that flow cannot be
negative.
When the model reaches Dynamic User Equilibrium, it should satisfy this equation.
(
ui (t)
if hk (t) > 0
sk (t) =
∀k ∈ Ki
≥ ui (t) otherwise
ui (t) = min sk (t)
k∈Ki
Where sk (t) is the travel time on path k and ui (t) is defined as the minimum travel time
for any path for OD pair i. Microsimulation travel time is calculated by Aimsun using
formulas like the K-Shortest Paths algorithm, which would provide an estimate for every
single link in the network.
Define travel time.
23
What this is saying is that if there is any flow on path k at time t, then the travel time
on that path is equal to the minimum travel time for any path for that OD pair. Essentially,
the only paths that are taken by drivers are the minimum paths. [2]
3.2
DUE implementation in Aimsun
Make sure to well explain what can be calibrated.
3.2.1
Overview
This setup could portray the case where travellers have access to a reliable traffic information source such as a GPS, letting them reroute accordingly.
The sentence above is not correct, where does it come from?
Roham: It is from the first paragraph in the DUE doc in aimsun, they state ”behaving
accordingly” instead of reroute. Perhaps I misunderstood what they are saying. The
Whole paragraph is as follows: ”This formulation could correspond to the hypothetical scenarios on which ATMS and ATIS application will work and reliable traffic information/traffic prediction systems will become available to travellers, allowing them to
adjust their behaviours accordingly.”
Alternatively, this formulation could also be looked at as a scenario where the traveller
fills in the gaps in his knowledge about the expected traffic conditions on his path. For
instance a commuter who learns more about their path’s traffic as they drive on the day to
day basis from work to home and vise versa, learn over time that certain streets are simply
going to be better route options for them. Thus, as they drive back and forth daily, they
keep trying different paths, changing their route based on their experience until they can
no longer improve it.
I (Theo) do not understand the sentence above, can we split it into 3 sentences?
Roham: Reworded it it bit. Hope its more clear
The behavior mentioned above can be implemented as an iterative procedure in a microsimulation. This heuristic approach of updating the route iteratively in an effort to find
the best possible path would lead to a routing solution that could be interpreted as The
Dynamic User Equilibrium [1].
What does the sentence above mean?
Roham: Reworded, Is it more clear?
3.2.2 Heuristic approach
Explain why do we need the heuristic approach.
Roham: It is explained in the MSA section 3.2.3 the the heuristic approach is what
gives us the solution to the DUE mathematical definition
What is the parameter name for N in Aimsun?
24
The implementation in Aimsun Next replicates the simulation N times and link costs
for each link j is stored at every iteration for each time interval t, t + 1, . . . , L. Thus the link
costs of previous j − 1 iterations can be used to estimate the expected link cost at the j th
iteration. Let Sa j,l (v) be the current cost of link a with flow v, at iteration l of replication
j, then the average link costs for the future L − l time intervals, based on the experienced
link costs for the previous j − 1 replications is given by:
What is a? Is v ∈ Ω? The sentence above is very confusing: travel time at for iteration j is estimated using the average travel time over the previous replications. Define
notations S̄a and S̃a .
S̄aj,l+i (v) =
j−1
1 X m,l+i
Sa
(v)
j−1
∀i ∈ {1, ..., L − 1}
m=1
It seems that i is now the time, it was the OD pair before. Please fix.
which is then used to calculate the “forecasted” link cost for the link a as:
S̃aj,l+1 (v)
=
L−1
X
αi S̄aj,l+i (v)
i=0
i on the left hand side is not defined. This is pretty bad notation to have i on the right
hand side and on the left hand side with two different meanings.
Roham: Fixed, LHS i was a typo
Where as mentioned above, S̄aj,l+i (v), and S̃aj,l+1 (v) are the average, and the forecasted,
link costs for the link a respectively.
I understand that we do average over replications (or simulations) and over time. Why
doing both?
Where α is a weighting vector in the simplex of RL .
Thus, the resulting cost of the path k for the ith OD pair is:
We do not need to mention that path k is between the ith OD pair.
S̃k (hl+1 ) =
X
S̃a
j,l+1
(v)δak
a∈A
It seems that hl+1 = h(l + 1), but I might be wrong. Please correct me (Theo) or the
overleaf. Why not using l instead of l + 1?
where δak which is defined as the arc-path incidence matrix is 1 if the link a belongs to
path k and 0 otherwise. The path costs S̃k (hl+1 ) are then used as the arguments for the
route choice functions in order to split the demand at the iteration l + 1 among available
path s for the OD pair i.
What is the route choice function?
Roham: The Route choice models that we use to give the probability for the shortest
path, binomial, C-logit, etc.
25
The default implementation in the current version of Aimsun Next uses a simplified
version consisting of a link cost function defined as:
ck+1
= λckit + (1 − λ)c̃kit
it
k is now time iteration, it was l before. What is it, is c similar to S. I do not understand why we do not use c̃k+1
instead of c̃kit .
it
Where ck+1
is the cost using link i at time t at iteration k + 1, and ckit and c̃kit correspond
it
respectively to the expected and experienced link costs at this time interval from previous
iterations.
From notation it seems experienced and expected link costs (not expected and experienced).
Roham: Since there seems to be multiple notations across Aimsun, is there any preference upon which one to utilize?
3.2.3 Method of Successive Averages
State that this is the algorithm used by Aimsun to solve DUE.
How is this different than the Heuristic approach?
Roham: MSA is the huristic approach that would solve DUE
It can be shown that the DUE approach can be implemented in terms of solving the a
mathematical optimization model. This model can be written as a discretized variational
inequality below:
XX
t
∗
Trsp (t)[frsp (t) − frsp
(t)] ≥ 0
p∈R
Where:
R is the set of all available paths from r to s,
This was K before.
Trsp is the actual path cost from r to s,
This has been cit , Sp before. Explain how it depends on time.
frsp is the flow on the path p from the origin r to destination s.
This was hp before.
Roham: Is There a preference on which set of notations we should keep?
We can probably directly introduced the modified MSA to keep the shortest path computation easy and not introduced the “regular” MSA
Roham: Should I Remove this section then and restructure the whole paragraph
26
A variety of algorithms have been proposed to solve this variational inequality. The
Method of Successive Averages (MSA) which itself has multiple variations is one the procedures that has been used to find the solution for this problem. The MSA procedure
redistributes the flows among the available paths in an iterative procedure that at iteration
n, computes a new shortest path from origin r to destination s at time interval t, crs (t),
then the paths flows update process is: case(A):
n (t))
crs (t) is new shortest path (crs (t) ∈
/ Prs
(
n (t),
n (t) ∀ r, s, t
αn frsp
if p ∈ Prs
n+1
frsp
(t) =
(1)
(1 − αn )dnrs (t), if p = crs (t)
n+1
n
Let Prs
(t) = Prs
(t) ∪ crs (t)
case(B):
n (t))
crs (t) is shortest path already in the path-set(crs (t) ∈ Prs
(
n (t),
αn frsp
if p 6= crs (t) ∀ r, s, t
n+1
frsp (t) =
n
n
(1 − αn )drs (t) + αn frsp , if p = crs (t)
(2)
There is a typo: f n+1 on the RHS second line should be f n .
Roham: This is the typo I mentioned in the presentation that is repeated twice. During the presentation I remember you mentioned that it should be fine as the f n+1 was
calculated before in the case A and thus accessing it before assignment should be fine.
Maybe I misunderstood your point. I have changed to f n .
n+1
n
Let Prs
(t) = Prs
(t)
Where dnrs (t) is the demand(number of trips) from r to s at time interval t.
What allows to have different MSA schemes, are the values we let the weighting coefficients
(αn ’s) to take. The typical value is:
n
n+1
Another modified version of the MSA algorithm is described by Varia and Dhingra 2004,
where the weighting coefficient takes into account a variable step length which depends on
the current path travel times:
Please try to avoid subjectivity. Either you say “a modified MSA algorithm”, or define
what you mean by interesting.
αn =
Roham: Reworded
αn =
λk[e−Trsp (t) ]
P −T (t)
rsp
(n + 1)
]
p [e
[4], [5] are the same reference!
Roham: Fixed
27
The variant which is implemented by Aimsun, was proposed by Florian et al. [4] This
version modifies the MSA algorithm to keep bounded the number of alternative paths to
account for each origin-destination pair.
Please use citation. Florian et al. 2002 is not well defined. How do we know that this
is one of the most efficient computationally? Please remove or precise what efficient
means here.
Roham: DONE
Please make sure that Florian et al. 2002 is the correct citation for the modified MSA
algorithm.
Roham: DONE
This version, initializes the process based on an incremental loading scheme, distributing
the demand among the available shortest paths. The process is then repeated for a predetermined number of iterations after which no new paths are added and the corresponding
fraction of the demand is redistributed according to the MSA scheme. The modified MSA
works as follows:
Let K be the maximum number of iterations to compute new paths:
Case A: If n ≤ K, . . .
Case B: Otherwise (K < n ≤ N ), . . .
Please use Latex formatting.
Roham: DONE
Algorithm 6: Aimsun’s Method of Succesive Averages(MSA)
while n ≤ N do
if n ≤ K then
New shortest path is computed
n (t)
crs (t) ∈
/ Prs
1
n+1
n (t) ∀ (r, s) ∈ J , ∀t ∈ [0, T ]
frsp (t) = n+1
drs (t),
∀p ∈ Prs
else
The shortest path is computed from existing paths
n (t)
crs (t) ∈ Prs
n (t) then
if crs (t) ∈
/ Prs
n
n+1
n (t),
n (t) ∀ (r, s) ∈ J , ∀t ∈ [0, T ]
frsp (t) = n+1
αn frsp
∀p ∈ Prs
else
n
1
n
fn+1
rsp (t) = n+1 αn frsp (t) + n+1 drs (t)
end
end
end
Typo: f n+1 should be f n on the second line of the RHS.
Roham: Similar to the previous typo. I have changed it to f n
Where J is the set of all origin-destination pairs in the network.
This was I before.
28
Based on this definition, it is possible to resuse a shortest path from one iteration to
another as we stop generating new paths after K iterations. Thus, a proper implementation
of this algorithm requires the number of iterations n to be defined based on the OD pair
and the time interval.
I (Theo) do not understand the sentence above.
Roham: Reworded
There is also another modification of MSA available in Aimsun which is called WMSA.
2
This model which was proposed by Liu et al. [8], moves n+1
of the demand at every
1
iteration n rather than the n amount which is used by the MSA.
Which figure? Please use cross reference. Are just copy pasting Aimsun documentation??
Roham: Reworded, this paragraph was copied here to be read and reworded. Should be
fixed now
3.2.4
Convergence Criterion
Since all of the approaches mentioned above are heuristic in nature, we do not have a
formal proof of convergence for them. We can however get a sense of whether the model is
performing as a DUE or not using a Relative Gap function proposed by Janson [6]
Use references in bibtex here.
Roham: DONE
The function is defined as:
P P
t
Rgap(n)=
(r,s)∈J
n
p∈Prs (t) frsp (t)
P
P P
t
(r,s)∈J
n (t)
Trsp
−
n (t)
θrs
n (t)
drs (t)θrs
Where:
n (t) is the flow on path p from r to s at the time t in the iteration n.
frsp
n (t) is the experienced or instantaneous cost of path p from r to s,
Trsp
drs (t) is the the demand (trips) from r to s at time t.
n (t) is the the shortest path cost from r to s at the time t in the iteration n.
θrs
.
n (t) − θ n (t) is the the excess cost the traveller had experienced due
The difference Trsp
rs
to using a path p instead of the shortest path.
The overall ratio would then measure the total excess cost all the travellers had to go
through with respect to the most optimum path with minimum total cost if all travellers
had used the shortest path. We can then set a Relative Gap Matrix with different thresholds
for each OD pair. In the case where the value is set to zero for any pair, the default global
value for the Relative Gap would be used instead. The Global Relative Gap can be set in
the Dynamic Traffic Assignment tab of the experiment.
I (Theo) do not understand the sentence above.
Roham: Reworded
29
In case we have defined a relative gap matrix, the default value would be used for any
OD pair with the value zero set for them in the matrix. We can, however, if we want to set
two extra convergence criteria:
1. The system has converged if X percent of the sections get a flow change of less than
Y percent for at least N consecutive iterations.
Please described in maths.
2. The system has converged if X percent of the sections have their cost value change
less than Y percent in quantity for at least N consecutive iterations.
Please described in maths.
These two additional criteria are disabled by default in Aimsun and can be activated
individually from the Dynamic Traffic Assignment tab of the experiment editor if needed.
We should avoid using the DTA tab, but use the JSON file instead.
Roham: Should I just remove that sentence then?
4
Routing Calibration Choices and Results
To be done.
Here explain the model we choose and why, then explain how calibration is done and
show results in Aimsun, later this will come at the beginning of the document and SRC
and DUE section will be in annex
4.1
Choice of Model
After investigating all the behavior models in Aimsun, we settled on using the C-Logit
model to model route choices. Our main problem was the fact that certain routes seem to
have much higher traffic than the ground truth while other routes had little to no flow. The
C-Logit model would take into account the similarity of routes - which would discourage
the model from routing many vehicles onto very similar roads.
4.1.1
Stochastic Route Choice over Dynamic User Equilibrium
4.1.2
Choice of C-Logit Model
4.1.3
Issues with Model
The main outstanding issue is the poor distribution of vehicles across the model. Some
detectors in the model were reporting traffic counts nearly 10 times higher than the real
data, and other detectors were reporting nearly zero flow despite being located on busy
streets. This issue makes the model fit the real data poorly.
30
4.2
4.2.1
Methods and Results
Validation Data and Criteria
The Ground Truth Data is raw traffic data collected from traffic detectors all over Fremont
during 2019. Highway data is collected from PeMS, a database maintained by the California
Department of Transportation.
Simulations are evaluated using the R2 value derived from ordinary least squares regression.
Figure 1: Comparison plot between real data flow (blue) and simulated flow (black)
Two R2 values are considered – one which is generated by Aimsun and another which is
generated by the postprocessing notebook. The R2 value is a good metric for evaluating a
model because it shows the correlation between the model and the ground truth data. An
accurate model would ideally have a very high R2 , indicating a strong fit with the original
data.
31
4.2.2
Parameter Values
Parameter
Scale (θ)
Beta (β)
Gamma (γ)
Initial K-SP
Max Routes
Intervals
Interval Length
(min)
Capacity Weight
(φ)
User-Defined
Cost Weight (τ )
En-Route
Percentage
Fixed Percentage
Table ??: Calibration Control Parameters
Aimsun
Calibration Description
Default
Default
1
1
C-Logit Parameter that scales utility
0.15
0.15
C-Logit Parameter that scales cross-factor
1
1
C-Logit Parameter that reduces importance of overlap
1
5
Determines number of shortest paths to
start
3
5
Number of shortest paths considered at
each step
1
1
Number of past intervals to consider
15
2
How often drivers change their routes
0
0
0
0
100
100
0
0
Scales ”link attractiveness”, or the capacity of roads divided by turns
Scales importance of user defined weights,
defined for each segment
Percentage of vehicles allowed to reroute
en route
Percentage of vehicles that follow fixed
route
For the calibration baseline, some parameters were changed from Aimsun’s default to better
reflect driver decisions and initial assumptions. The interval length was decreased from 15
minutes to 2 minutes to better reflect real-time decision making. Max routes was increased
from 3 to 5 to give the C-Logit model more routes to consider and hopefully ”spread out”
the drivers more. Initial K-SP was increased from 1 to 5 to give each driver more starting routes, again to better model a distribution of travel decisions. As these parameters
slightly improved the R2 score in the notebook, they were used as the baseline for future
experiments (see next section for results).
Figure 2: Aimsun validation comparison between Aimsun default (left) and baseline (right)
32
Adjusting Max Routes
A high value of Max Routes should give each vehicle more choices in the routes they
take. However, in this network, increasing the Max Routes attribute decreased accuracy
and made the simulation run slower.
Adjusting Interval Length
Adjusting Beta (β)
Adjusting Scale Factor (θ)
4.2.3
Trial
0
1
2
3
4
5
6
7
8
9
4.2.4
Trial Results
Aimsun
Validation
0.7930
0.7805
0.7577
0.8025
0.7761
0.7912
0.7616
0.7937
0.7677
0.8008
Table ??: Trial Results
Postprocessing Change from Baseline
Score
0.4414
Aimsun Default
0.5053
Baseline
0.5766
Interval Length = 5
0.5463
Max Routes = 1
0.5020
Max Routes = 10
0.4914
Max Routes = 99
0.5858
Beta = 1
0.4642
Beta = 10
0.4022
Beta = 100
0.5825
Theta = 0
Calibration Process
The overall goal of our iterative calibration process is to tune a model where there is a
strong correlation between the simulation flow and the ground truth flow.
Set up
Many scripts were created to help replicate the Aimsun network and maintain consistency.
These scripts import the detectors, traffic control plans, master control plans, traffic management strategies, centroids, and meterings.
Create OD Data
Origin-Destination Data is the travel demand between each centroid. Cars ”spawn” at
origin centroids and ”despawn” at destination centroids. The OD Data calibration team
worked on tuning these numbers such that they resemble the travel demand inside Fremont.
Config JSON Files
33
Figure 3: Flowchart which shows our calibration process
Config JSON files are used to adjust experiment parameters without having to interact
with the GUI. They help maintain consistency across experiments and are faster to adjust.
They also help keep track of previous variable combinations.
Adjust Experiment Parameters
Experiment Parameters are first adjusted independently and their effects on the model’s
score are compared with the baseline.
Run Replication
The model is run on Aimsun for a period of 6 hours (2-8 PM) using a 100% demand
factor and the parameters chosen before. At the end of the simulation, Aimsun generates
a comprehensive sqlite file which collects the flow at all detectors. Aimsun also generates
its own validation plots based on real data files.
Post Processing
The sqlite file generated by Aimsun is loaded into a Jupyter notebook where visualizations can be generated and further analysis can be done. The postprocessing notebook
generates its own validation plots based on the real data files and also gives a score for
model fit.
34
Country List
ISO ALPHA 2 ISO ALPHA
Code
Code
AF
AFG
AX
ALA
AL
ALB
DZ
DZA
AS
ASM
AD
AND
AO
AGO
Country Name or
Area Name
Afghanistan
Aland Islands
Albania
Algeria
American Samoa
Andorra
Angola
test citing [7]
Add a conclusion if this is needed.
3
ISO
Code
004
248
008
012
016
020
024
numeric
References
[1] Jaime Barceló and Jordi Casas. Dynamic network simulation with AIMSUN. In Simulation approaches in transportation analysis, pages 57–98. Springer, 2005.
[2] Jaime Barceló and Jordi Casas. Stochastic heuristic dynamic assignment based on
aimsun microscopic traffic simulator. Transportation Research Record: Journal of the
Transportation Research Board, 1964:70–80, 2006.
[3] Yi-Chang Chiu, Jon Bottom, Michael Mahut, Alexander Paz, Ramachandran Balakrishna, Travis Waller, and Jim Hicks. Dynamic traffic assignment: A primer. Transportation Research E-Circular, 06 2011.
[4] Michael Florian, Michael Mahut, and Nicolas Tremblay. Application of a simulationbased dynamic traffic assignment model. European Journal of Operational Research,
189:1381–1392, 01 2002.
[5] Michael Florian, Michael Mahut, and Nicolas Tremblay. Application of a SimulationBased Dynamic Traffic Assignment Model, pages 1–22. Springer US, Boston, MA, 2005.
[6] Bruce N. Janson. Dynamic traffic assignment for urban road networks. Transportation
Research Part B: Methodological, 25(2):143–161, 1991.
[7] N. D. Kelley and B. J. Jonkman. Overview of the TurbSim stochastic inflow turbulence
simulator. NREL/TP-500-41137, Version 1.21, National Renewable Energy Laboratory, Golden, Colorado, 2003. Available at https://nwtc.nrel.gov/system/files/
TurbSimOverview.pdf.
[8] Henry X. Liu, Xiaozheng He, and Bingsheng He. Method of successive weighted averages
(mswa) and self-regulated averaging schemes for solving stochastic user equilibrium
problem. Networks and Spatial Economics, 9(4):485, Jun 2007.
35
Download