0
$\begingroup$

I have an array named "latitude" with multiple latitude points. I have another longitude array with multiple longitude poins in a way that the item[0] of both arrays translates to a point in a map.

Lets suppose I have 10 points in this map. I want to draw a circle with radius N that covers the most number of points. How do I know where should be the center of this circle?

Take a look at this image below. The red dots are my points. You can easily see that the pink big circle is better located than the green circle. How can I discover the center of this circle looping all combinations in my latitude/longitude array?

enter image description here

  • 0
    What is JS looping?2017-02-22
  • 0
    JS looping is a programming technique in Javascript to loop all itens in array.2017-02-22
  • 0
    See this: http://www.cs.princeton.edu/~chazelle/pubs/CirclePlacement.pdf which was suggested here: http://math.stackexchange.com/questions/159521/maximizing-the-number-of-points-covered-by-a-circular-disk-of-fixed-radius2017-02-22
  • 0
    So the only approach to solve this problem is with brute force?2017-02-23

0 Answers 0