Ask HN: Algorithm for Scheduling appointments by location
Is there a good general purpose algorithm that can be used to schedule appointments given time and location constraints. Say someone wants me to come to their house to fix a computer at a certain time on a particular day and their neighbor also needs a computer fixed and is flexible with time. The algorithm would work it out to show the neighbor that I am near by and available on a certain time slot. Another potential client that is 50 miles away wants to schedule something close to the same time slots, but the algorithm considers they are much farther away and offers them a time slot much later in the day.
3 comments
[ 7.2 ms ] story [ 20.0 ms ] threadIn my experience, the most important part of doing network analysis is to have a "topology model" for your road network data. It contains the information necessary to model turns, drive-time, traffic signals, etc.
Anyway, I used to know the 1000 ft view of the math behind this stuff but not anymore. If, however, you're trying to build it into an application - there are solutions like pgRouting https://github.com/pgRouting/pgrouting which utilizes PostGIS (PostgreSQL), ESRI's Network Analyst ($$), and Google Maps Directions API. These all leverage some underlying topology data like Open Street Map to do routing and figure out the subsequent times/schedule to get from point to point to point...
Hope this helps!