Changes

Jump to: navigation, search

Algorithm

386 bytes added, 21 March
m
Traffic
The RouteXL When you hit the [[Find route]] button the route planning algorithm uses travel times and a optimization method to sort your locationsis launched. The algorithm minimizes total travel time to find the fastest route (less hours/minutes). It does not minimize total distance as such, so our routes may not be the shortest route (less miles/kilometers). The algorithm uses travel times and a optimization method to sort your locations in the optimal order.
== Travel times ==
Learn more: https://www.openstreetmap.org/
We update the data on our servers every 1-2 months, which means that updates to the streets street network made in OpenStreetMap takes take some time to become visible in the routes of RouteXL.
=== Traffic ===
The travel times do not incorporate actual live or forecasted traffic. So our routes are not corrected for traffic on the road. There are some ways to adjust the routes for traffic:
* You can set [[Edit location|time windows]] for your stops, which can be used to visited certain places during specific hours. E.g. you could set a ready time at 10AM to visit some address after morning rush hours.
== Optimization ==
Routing multiple addresses is quite a puzzle. With 20 First, you'll need a distance matrix for all destinations the from-to . Or better: travel times matrix has roughly 20 x 20 = 400 elements. Each element represents one route between two points. To sort 20 destinations , as the algorithm first needs to calculate 400 individual routesminimizes total travel time. No wonder route optimization is much more time consuming than simple A-to-B routing!
The number of possible routes to visit With 20 destinations is even larger than that. The first pick can be any of the travel times matrix has roughly 20 destinations, so there are x 20 possible choices for the first stop= 400 elements. For the second there are 19 choices leftEach element represents one route between two points. That means there are To sort 20 x 19 = 380 combinations for destinations the algorithm first two stopsneeds to calculate 400 individual routes. There are 18 choices for the third stop after that, making 20 x 19 x 18 combinations. And so on. For the full No wonder route there are approximately 20 x 19 x 18 x ... x 3 x 2 x 1 = 2,432,902,008,176,640,000 combinationoptimization is much more time consuming than simple A-to-B routing.
Secondly, the number of possible routes to visit 20 destinations is even larger than that. The first pick can be any of the 20 destinations, so there are 20 possible choices for the first stop. For the second there are 19 choices left. That means there are 20 x 19 = 380 combinations for the first two stops. There are 18 choices for the third stop after that, making 20 x 19 x 18 combinations. And so on. For the full route with 20 stops there are approximately 20 x 19 x 18 x 17 x 16 x 15 x 14 x 13 x 12 x 11 x 10 x 9 x 8 x 7 x 6 x 5 x 4 x 3 x 2 x 1 = 2,432,902,008,176,640,000 combinations! Mathematicians call route optimization a "hard" problem and there is no final one-size-fits-all solution available. They even have a name for it: the ''The Travelling Salesman Problem'' (TSP). Indeed, humans can fly to the moon, but in math there is no ultimate answer solution to this routing problem.
Learn more: https://en.wikipedia.org/wiki/Travelling_salesman_problem
However, Operations Research researchers however have found some very good approximation methods. Our algorithm is an effective implementation that finds the optimal route in most cases. But it is an algorithm for matter of speed that does not guarantee optimality.
=== Runtime ===

Navigation menu