Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Efficient Assignment of Many People To Many Locations?

by johndageek (Hermit)
on Feb 28, 2005 at 21:49 UTC ( [id://435202]=note: print w/replies, xml ) Need Help??


in reply to Efficient Assignment of Many People To Many Locations?

Just a left handed approach. I would select a point in a third dimension over the center of my sales rep grid, calculate the distance to each sales rep and store the results in an array as a cross reference.

e.g. dist from 3rd dim | map coordinates
20 | 0,0
15 | 1,2

sort this array by distance.

Now any destination you choose on the grid can be have it's distance calculated from the 3rd dimension point. A binary search of the sorted cross reference for distances equal to, or just above and below your destination distance should give you your top choices.

This assumes of course you have enough data to make the set up worth the effort and that the sales reps are based from the same place repeatedly. HTH!

Enjoy!
Dageek

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://435202]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (5)
As of 2024-03-28 22:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found