Hi all, I have seen a few delivery and task tracker templates but I haven’t found anything with the capability to optimize a list off addresses for the fastest route. I’m sure this should be possible with Glides distance function but not 100% sure how to do it. Basically if I have a long list of addresses, I just want to sort them into an optimal order to create the fastest route. Has anyone seen this done on Glide?
Note - I have coded a script in App Scripts and Google Sheets to do this using the Google Maps API but they limit your API calls to where my formula is being restricted.
You can sort an inline list by distance, but…
Distance alone isn’t a good way to optimize a route. What if you have one address to the West that is the closest. Then the next closest is to the East of your start point. Then the next was is back to the West of your start point? You end up going back and forth and doubling your distance traveled instead of delivering to all points the the West at one time, before traveling to all points to the East.
Now, you could travel to the closest point, check off that delivery to remove it from you list, then show the next closest point from that current location, but in the long run, I still don’t think it’s going to be optimized. You’ll still end up zig zagging all over instead of following the most efficient route.
Google has much more complicated algorithms that calculate road distance, speed, traffic to find optimal routes along several different roads. Distance alone just isn’t going to cut it. You would save a lot more money paying google for the their calculated efficient routes, than you would paying for the the extra fuel, due to relying solely on distance calculation to find the best route.
I fully agree with this. I studied Logistics & Supply Chain Management as my university major. Many of my colleagues used Google’s algorithm when they did their thesis, related to optimal route to delivery goods with the additional constraint of time window. Google does offer pretty good service for this.
And yeah, it’s not straightforward.