This uses polygon length function to calculate its circumference. The underlying sorting of the coordinates uses polar coordinates, since that is how they are being randomly generated. By first sorting over the degrees and the distances.

For most instances this is a pretty good estimate, though in some case a self-intersecting polygon can be created, which hints that there is a more optimized polygon.

Further this problem is a typical 'travelling salesman problem' which can be solved via various algorithms.

Though before considering such optimization issues, there is the main question if the randomly generated POI is even accessible to the public.

In the case one is a pedestrian, one could use to gather information if any highways exist in the proximity to the POI and then find the one that is the closest and permissive to pedestrians. Then move the POI to that location.

This example only works if there is enough data at the location.

My Ruck Club  
Toying around with the idea of creating a random POI generator which can be used as a #StarCourse or an optimization challenge to navigate througho...
Sign in to participate in the conversation
Qoto Mastodon

QOTO: Question Others to Teach Ourselves
An inclusive, Academic Freedom, instance
All cultures welcome.
Hate speech and harassment strictly forbidden.