WSPD Applications. Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner...

35
WSPD Applications

Transcript of WSPD Applications. Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner...

  • Slide 1

WSPD Applications Slide 2 Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner diameter Applications to other proximity problems Slide 3 Reminder: Well Separated Pairs Let s > 0 be a real number and A, B are two finite sets of points in R d. A and B are well separated with respect to s if there are 2 disjoint d-dimensional balls Ca and Cb such that: Ca and Cb have the same radius. Ca contains the axes parallel bounding box R(A) of A. Cb contains the axes parallel bounding box R(B) of B. The distance between Ca and Cb is greater than or equal to s times the radius of Ca. Slide 4 Reminder: Well Separated Pairs Slide 5 Reminder: WSPD Let S be a set of n points in R d, and let s > 0 be a real number. A WSPD for S in respect to s is a sequence {A1,B1},{A2,B2},,{A m, B m } of pairs of nonempty subsets of S, for some integer m such that: For each 1im, A i and B i are well separated with respect to s. For any two distinct points p and q, there is exactly one index 1im such that p Ai and q Bi or the opposite. The integer m is called the size of the WSPD. Out Of Scope. The transformation"> Spanner of bounded degree For each point q in S, let Vq be all the points r S, such that (r,q) is a directed edge in G`. We replace all edges (r,q), by the edges of a q-sink (t/t)-spanner. Now, we replace all the directed edges in the graph with un-directed edges. We got an undirected t-spanner with bounded degree of O(1/(t-1) 2d-1 )). Proof => Out Of Scope. The transformation Slide 18 Spanner of bounded degree WSPD construction: O(nlogn + s d n) as shown last week (Theorem 9.4.6). Representative selection: O(n). Undirected t-spanner of bounded degree transformation: O(nlogn). Proof => Out Of Scope (section 4.2.2). All in all : O(nlogn). Time complexity Slide 19 Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner diameter Applications to other proximity problems: TT he closest pair problem CC omputing k-closest pairs TT he all-nearest neighbors problem CC omputing an approximate MST Slide 20 Spanner with log. spanner diameter Let S be a set of n points in R d Compute a split tree T for S. Construct a WSPD with s=4(t + 1)/(t - 1). As shown last week (section 9.2), G=(S,E), where E:= {{a i,b i } : 1im}, is a t-spanner for S. We will choose a i,b i from A i, B i wisely, using the split tree T. Construction Slide 21 Spanner with log. spanner diameter Let u be any internal node of T. Let u l & u r be us left and right sons. Let e l & e r be the edges that connect u to u l & u r respectively. Let n l & n r be number of leaves in the sub- trees rooted by u l & u r respectively. If nl nr, we label el as heavy, and e r as light. If nl < nr, we label er as heavy, and el as light. Representatives selection Slide 22 Spanner with log. spanner diameter Each internal node is connected by exactly one heavy edge to one of its children. Each internal node has a unique chain of heavy edges down to the bottom of T. Let l(u) be the leaf whose chain contains u. Let r(u) be the point of S stored in l(u). Representatives selection Slide 23 Spanner with log. spanner diameter Representatives selection S S2 S1 S6S5 S4 S3 S10 S9S8S7 S12S11 Slide 24 Spanner with log. spanner diameter Representatives selection Let i be 1im, the pair A i, B i is represented implicitly by 2 nodes of T, u i & v i, respectively. A i, B i are the set of points stored in the sub-trees of u i & v i. We take r(u i ) A i to be its representative. We do the same for r(v i ) B i. Now G=(S,E) is a t-spanner. We need to prove its diameter is logarithmic. Slide 25 Spanner with log. spanner diameter For each i,1im, and for each point p A i there is a t-spanner path in G between p and the representative a i of A i, that contains at most log|A i | edges. From construction, there is a t-spanner path between p and a i. If p = a i, we are done. Assume otherwise. Claim Proof Slide 26 Spanner with log. spanner diameter Let j be the index such that: (i) p A j and a i B j. Or (ii) ai A j and p B j. WLOG assume (i). Recursively construct a path Q1 between p and its representative a j. Recursively construct a path Q2 between a i and its representative b j. Return Q = Q1, {a j, b j }, Q2. Proof cont. Slide 27 Spanner with log. spanner diameter We will show that |Q| log|A i | (p A i ). Induction on the size of set A i. Base: Ai = {a i } => p = a i => we are done. Let i be an index such that |A i | > 1, p a i. Assume, for all k such that |A k | < |A i |, and for all x A k, the algorithm constructs a t-spanner path between x and a k with at most log|A k | edges. Proof cont. Slide 28 Spanner with log. spanner diameter Let u i, u j, v j be the nodes of T whose sub- trees store the sets A i, A j, B j respectively. u i is a common ancestor of the leaves storing p and a i. u j lies on the path from root to the leaf of p. v j lies on the path from root to the leaf of a i A j, B j are disjoint => u j, v j are both in the sub-tree of u i, and neither is an ancestor of the other. Proof cont. Slide 29 Spanner with log. spanner diameter Proof cont. S Ui Vj Uj p aiai => a i = b j. => |Q2|=0 Slide 30 Spanner with log. spanner diameter |A j | |A i |/2. Otherwise all the edges between u i and u j would be heavy. But then, the representative of Ai would be an element of Aj, but its not (a i Bj represents Ai). By induction hypothesis, the path Q1 between p and a j contains at most log|A j | edges, which is log|A i | - 1. We add {a j, b j } and get that |Q| log|A i |.Proof cont. Slide 31 Spanner with log. spanner diameter G is a t-spanner for S, whose diameter is less than equal to 2logn 1. Let p and q be 2 distinct points in G. We will show that there is a t-spanner path between them with at most 2logn1 edges. Claim Proof Slide 32 Spanner with log. spanner diameter Let j be the index such that: (i) p A j and q B j. Or (ii) q A j and p B j. WLOG assume (i). Recursively construct a path Q1 between p and its representative a j. Recursively construct a path Q2 between a i and its representative b j. Return Q = Q1, {a j, b j }, Q2. Proof cont. Slide 33 Spanner with log. spanner diameter We proved that |Q1| log|A j |. Similarly, |Q2| log|B j |. Hence, |Q| log|A j | + log|B j | + 1. A j, B j are disjoint => |A j | + |B j | n. log|A j | + log|B j | log|A j | + log|n - A j | 2log(n/2) = 2logn 2. Hence, Q contains at most 2logn 1 edges. Proof cont. Slide 34 Spanner with log. spanner diameter WSPD construction: O(nlogn + s d n) as shown last week (Theorem 9.4.6). Representative selection: O(m). All in all : O(nlogn). Time complexity Slide 35