I am creating an application based on the search for a “convenient meeting point”, given the set of places.
Currently, I define "comfortable" as "minimizing the overall trip distance." This is another problem associated with finding a centroid, as shown in the following example (using Cartesian coordinates rather than latitude and longitude for convenience):
- A is at (0,0)
- B is at (0,0)
- C is at (0.12)
The location of the minimum total stroke for these points is (0,0) with a total distance of 12; the centroid is at (0.4) with a total displacement distance of 16 (4 + 4 + 8).
If the location is limited by the fact that it is at one of the points, the problem becomes simpler, but this is not the limitation that I intend to have (unlike, for example, this otherwise similar question ).
What I cannot do is come up with some kind of algorithm to solve this problem - suggestions are welcome!
algorithm coordinates distance
Kristian Glass Jan 03 '12 at 20:19 2012-01-03 20:19
source share