define:

  • as the farthest point in PQ at iteration

  • At , PQ is empty so and . In the next iterations decreases incrementally until it converges to the true k nearest neighbor distance , so:

Doubling space: Iteratively Covering Smaller Balls

Recursively cover each ball of radius with balls of half the radius , then each of those with balls of radius and so on. After subdivisions, **the radius of each ball becomes and the number of balls needed is .

given this, we decompose 1 iteratively. At each scale the number of clusters is . Summing over until :

Now consider the aspect ration . In the worst case scenario, if the -th nearest neighbor ​ is located at the minimum distance , and the dataset contains points at the maximum distance , then:

So substituting in :

Final running time:

  • for the main loop, where is the insertion time in the priority queue
  • for the sorting

Footnotes

  1. I redefined . I changed notation because i didnt want to write every time