As a programmer, if I have a linear solver available. How can I formulate the following problem as a set of constrains / decisions / goals for the linear solver?
I have a matrix of say 10*10, so 100 points (potential depots).
I randomly select 10 of those points as "Customers".
Now I would like to "solve" the point(s) totalling the shortest distance from the 10 "Customers" and I would like the coordinates of that point.
One "depot" point is so easy it doesn't need a solver, however solving the two "depot" points that combine to give the shortest distances to all the "customers" is tough, so needs a solver.
I can use the K-means to do this, however I would like to know if and how I can use a linear solver to do the same thing.
أكثر...
I have a matrix of say 10*10, so 100 points (potential depots).
I randomly select 10 of those points as "Customers".
Now I would like to "solve" the point(s) totalling the shortest distance from the 10 "Customers" and I would like the coordinates of that point.
One "depot" point is so easy it doesn't need a solver, however solving the two "depot" points that combine to give the shortest distances to all the "customers" is tough, so needs a solver.
I can use the K-means to do this, however I would like to know if and how I can use a linear solver to do the same thing.
أكثر...