Upload
storm-meadows
View
112
Download
2
Embed Size (px)
Citation preview
SEATTLE’S SNOWPLOWS THE POSTMAN PROBLEM
University of Washington MATH 381
PROBLEM STATEMENT
The City of Seattle has hired us to find an efficient way to route snowplows around downtown
Why does this matter?
DIRECTOR: GRACE CRUNICAN
WE KNOW WHAT HAPPENS WHEN IT SNOWS IN SEATTLE
DIRECTOR: GRACE CRUNICAN
PROBLEM STATEMENT
This problem goes beyond funny news reels
The City of Seattle has hired us to find an efficient way to route snowplows around downtown
The natural follow up question: what does it mean to be efficient?
DIRECTOR: GRACE CRUNICAN
GIVEN ASSUMPTIONS
The plow is based at a location of your choosing
Plow(s) begin and end their route at the home base location
One way streets are plowed in one direction
Two way streets are plowed in both directions
PROBLEM STATEMENT
Rather than search for a single “perfect” solution, find a model that is efficient
Efficiency: the minimization of wasted driving of snowplows Saves labor costs and fuel Allows for faster removal of snow Overall public safety
SPECIFICATIONS / ASSUMPTIONS MADE Specs: Make a (big!) graph of downtown Seattle Assure that distances are accurate
Assumptions: Traffic – for simplicity, assume traffic is constant There are usually fewer cars out when snowplows are up and running, making this assumption justifiable
THE CHALLENGE
One way streets prevent us from completing a simple Eulerian circuit
We need a model that can account for one-way streets, and traverses all edges (twice for 2-ways, once for one-ways)
Key insight : note that you may consider one-way streets as a single directed edge, and two-way streets as two directed edges
MATHEMATICAL MODEL
In graph theory terms, we want to find a minimum length closed walk that traverses each edge at least once
This is problem is known as the ‘Postman Problem’ or ‘Route inspection problem’
SOURCE: HTTP://XLINUX.NIST.GOV/DADS//HTML/CHINESEPOSTMAN.HTML
How to start at any vertex and hit every edge while minimizing the number of repeated edges?
POSTMAN PROBLEM
Alan Goldman of the U.S. National Bureau of Standards first coined the name ‘Chinese Postman Problem’
Studied by Chinese mathematician Kwan Mei-Ko in 1960 to address the problem of a rural postman attempting to most efficiently complete his delivery route
Chinese paper was translated into English in 1962
SOURCE: HTTP://XLINUX.NIST.GOV/DADS//HTML/CHINESEPOSTMAN.HTML
THE ALGORITHM
SOURCE: HTTP://WWW3.CS.STONYBROOK.EDU/~ALGORITH/IMPLEMENT/CPP/DISTRIB/SPAECPP.PDF
THE ALGORITHM, EXPLAINED
Construct a shortest distance matrix e.g.: row i., column j is the shortest distance from vertex i to vertex j
Floyd-Warshall’s algorithm
Find the vertices with an ‘excess’ of outgoing/ingoing paths (e.g. the start of a one-way) from the vertices with an ‘deficit’ of incoming paths
The Postman Tour must walk extra paths to ‘join up’ these unbalanced vertices
The optimal tour will take a combination of extra paths with minimal ‘cost’ (i.e. least distance)
CLIP: THE ALGORITHM IN ACTION
PREPARING INPUT: GRAPHING DOWNTOWN 1. Take a large cross-section of Downtown Seattle via Google
Maps.
PREPARING INPUT: GRAPHING DOWNTOWN 1. Take a large cross-section of Downtown Seattle via Google
Maps.
PREPARING INPUT: GRAPHING DOWNTOWN 2. Convert it to black and white to distinguish the streets.
PREPARING INPUT: GRAPHING DOWNTOWN 2. Convert it to black and white to distinguish the streets.
PREPARING INPUT: GRAPHING DOWNTOWN 3. Extract streets and use intersections to create nodes.
PREPARING INPUT: GRAPHING DOWNTOWN 3. Extract streets and use intersections to create nodes.
PREPARING INPUT: GRAPHING DOWNTOWN 4. Use a built-in Mathematica function to convert this image into a
weighted undirected graph. • The weights are proportional to the streets’ distances.
5. Transform each undirected edge into two opposing directed edges, each with the same weight as the original edge.
6. Account for one-way streets by removing the extra edges created in the previous step.
• The red edges correspond to one-way streets. • Note that this is only an approximation of downtown Seattle’s streets.
PREPARING INPUT: GRAPHING DOWNTOWN
PREPARING INPUT: GRAPHING DOWNTOWN 7. Created a function to map our graph’s edge weights to the
physical distances of their corresponding streets (obtained via Google Maps).
PREPARING INPUT: A COUPLE OF COMPLICATIONS 1. One way streets were added manually
2. Interstate 5 was manually removed as it is not part of the domain of the problem
MATHEMATICAL SOLUTION
Observations
1. Graph edited to convert two-way streets (gray) into two distinct di-edges, and one-way streets into one-directional di-edges (in red)
2. It is possible to obtain marginally different solutions by choosing a different starting point
3. Similarly, one may accommodate additional vehicles by partitioning the graph and running the algorithm for each sub-graph
MATHEMATICAL SOLUTION
Color corresponds to the number of road traversals: Purple: once Gold: twice Red: thrice
HOW MUCH?
The optimization condition minimizes the extra distance that is needed to cover all of the streets
Quantifying cost (marginal and total, in both time and $) is a matter of assumption / data
Example: A safe assumption for the speed of a snowplow is 30km/hr ≈ 18.64 mi/hr (safe low end speed for snowplow), would give a slight overestimate on the time cost
SOURCE: HTTP://WWW.HIGHWAYS.GOV.SK.CA/ADX/ASPX/ADXGETMEDIA.ASPX?DOCID=759,104,81,1,DOCUMENTS&MEDIAID=6221&FILENAME=SNOW+PLOW+SAFETY+FACT+SHEET+2011-12.PDF
HOW MUCH TIME?
Example: Find the total time cost of having 1 snowplow make one run through downtown Seattle: 179.915mi • Simply multiply the total ‘cost’ (in terms of distance) by 1hr/18.64km to obtain 9.652 hours for one snowplow to clear downtown
• Extra information: The total distance of the streets (double weight for two way) 171.337 mi
• ‘Wasted driving’ total: 8.578 mi • Efficiency of route: 1.05
FUTURE OPTIMIZATIONS
1. Incorporating live data on traffic to more accurately weigh the ‘cost’ of clearing a given street (helps particularly to partition the routes for more than one snowplow)
2. Collect more accurate data for estimating costs; e.g. data on the average speed of snowplows, the costs / benefits of adding additional snowplows
3. Implementing code to account for DoT policy (certain streets are given priority, some only require one lane on each side of the street to be plowed)
FUTURE OPTIMIZATIONS
4. Exploiting further mathematical properties of the graph, such as the fact that it is planar (since every intersection is interpreted as a vertex, so no edges intersect).
• E.g., using the A* algorithm instead, the obvious choice of an admissible heuristic being the Euclidean distance between vertices.
5. Account for the finer details that would affect real operational costs and time; e.g., idling due to stoplights, acceleration/deceleration over streets of varying lengths and incline gradients, etc.
FUTURE OPTIMIZATIONS
HTTP://WWW.SEATTLE.GOV/TRANSPORTATION/DOCS/WW2015MAP.PDF
THE END