Kinetic closest pairA kinetic closest pair data structure is a kinetic data structure that maintains the closest pair of points, given a set P of n points that are moving continuously with time in a metric space. While many efficient algorithms were known in the static case, they proved hard to kinetize,[1] so new static algorithms were developed to solve this problem. 2D caseApproach 1The simplest kinetic approach for maintenance of the closest pair is to use variants of the Delaunay triangulations.[2] Consider a hexagon and partition it into six equilateral triangles, and then create a Delaunay triangulation based on each equilateral triangle, as each one is a convex shape. The union of these six Delaunay triangulations, so called Equilateral Delaunay graph (EDG), is a supergraph for the nearest neighbor graph (NNG); the endpoints of the edge with minimum length in EDG gives the closest pair. It is straightforward to maintain Delaunay triangulations based on convex shapes. Given the EDG over time, by creating a kinetic tournament tree over the edges of the EDG, one can easily maintain the closest pair. This closest pair KDS is efficient, amortized responsive, and compact, but in general is not local. The following approach presents a local KDS for maintenance of the closest pair. Approach 2The second kinetic approach is based on the following observations.[3][4] Divide and conquerIf the space around a point p is divided angularly into six "wedges", each 60° wide, the closest point to p is the closest of the closest points in each of the wedges. The rest of this article will focus on the "main" wedges (those bisected by the x-axis), and symmetrical arguments will apply to the other wedges after rotating the plane by ±60°. Matched pointsPoints p and q are said to be "matched" if they are the closest points to each other. Clearly, the closest pair of points is a matched pair. Consider points p and q, such that p is to the left of q and q lies in the wedge centered at p described above. If p is the closest point to q, then q must be the closest point (in this wedge) to p, in the x-direction. Thus, the set of pairs of closest points (within this wedge) in the x-direction is a superset of the set of pairs of closest points. Construction
The closest pair of points in P corresponds to the minimum of the minimums obtained from the three priority queues Π above. MaintenanceCertificate failures can occur in the priority queues and the sorted lists. Swaps in the ordering of the points will cause changes to T (which will take O(log2 n) time), and may cause insertions/deletions in the priority queues. Note that the number of changes to the sets Π as defined above need not be a constant number. However, any pair that starts or stops being matched as a result of the ordering of p and q changing must contain p and/or q, and hence there are only a constant number of matched pairs that must be inserted into/deleted from the priority queues. It is ok to only update these matched pairs since, by definition, only matched pairs have a chance of being the closest pair. AnalysisThis KDS is:
This approach can be used to maintain the closest pair in higher dimensions. References
Information related to Kinetic closest pair |