WSPD Applications.

Slides:



Advertisements
Similar presentations
CS 336 March 19, 2012 Tandy Warnow.
Advertisements

Trees Chapter 11.
Divide and Conquer. Subject Series-Parallel Digraphs Planarity testing.
QuickSort Average Case Analysis An Incompressibility Approach Brendan Lucier August 2, 2005.
Augmenting Data Structures Advanced Algorithms & Data Structures Lecture Theme 07 – Part I Prof. Dr. Th. Ottmann Summer Semester 2006.
 Distance Problems: › Post Office Problem › Nearest Neighbors and Closest Pair › Largest Empty and Smallest Enclosing Circle  Sub graphs of Delaunay.
Greedy Algorithms Greed is good. (Some of the time)
Recursive Definitions and Structural Induction
One of the most important problems is Computational Geometry is to find an efficient way to decide, given a subdivision of E n and a point P, in which.
Applications of well seperated pairs Closest Pair K-Closest Pairs All-Nearest neighbor.
Parallel Scheduling of Complex DAGs under Uncertainty Grzegorz Malewicz.
Tirgul 8 Graph algorithms: Strongly connected components.
Data Structures and Algorithms1 Trees The definitions for this presentation are from from: Corman, et. al., Introduction to Algorithms (MIT Press), Chapter.
Lectures on Network Flows
Great Theoretical Ideas in Computer Science.
Advanced Topics in Algorithms and Data Structures 1 Rooting a tree For doing any tree computation, we need to know the parent p ( v ) for each node v.
1 Discrete Structures & Algorithms Graphs and Trees: II EECE 320.
Section 3.1 Properties of Trees Sarah Graham. Tree Talk: Vocabulary oTree: a tree is a special type of graph that contains designated vertex called a.
Lists A list is a finite, ordered sequence of data items. Two Implementations –Arrays –Linked Lists.
Topics: 1. Trees - properties 2. The master theorem 3. Decoders מבנה המחשב - אביב 2004 תרגול 4#
Graphs and Trees This handout: Trees Minimum Spanning Tree Problem.
1 Separator Theorems for Planar Graphs Presented by Shira Zucker.
DAST 2005 Week 4 – Some Helpful Material Randomized Quick Sort & Lower bound & General remarks…
CSE 373, Copyright S. Tanimoto, 2002 Up-trees - 1 Up-Trees Review of the UNION-FIND ADT Straight implementation with Up-Trees Path compression Worst-case.
03/01/2005Tucker, Sec Applied Combinatorics, 4th Ed. Alan Tucker Section 3.1 Properties of Trees Prepared by Joshua Schoenly and Kathleen McNamara.
. Phylogenetic Trees (2) Lecture 12 Based on: Durbin et al Section 7.3, 7.8, Gusfield: Algorithms on Strings, Trees, and Sequences Section 17.
Induction and recursion
Approximating the Minimum Degree Spanning Tree to within One from the Optimal Degree R 陳建霖 R 宋彥朋 B 楊鈞羽 R 郭慶徵 R
Multiway Trees. Trees with possibly more than two branches at each node are know as Multiway trees. 1. Orchards, Trees, and Binary Trees 2. Lexicographic.
Binary Trees. Binary Tree Finite (possibly empty) collection of elements A nonempty binary tree has a root element The remaining elements (if any) are.
 2004 SDU Lecture 7- Minimum Spanning Tree-- Extension 1.Properties of Minimum Spanning Tree 2.Secondary Minimum Spanning Tree 3.Bottleneck.
Chapter 6: Geometric Analysis: The Gap Property By azam sadeghian 1.
Discrete Structures Lecture 12: Trees Ji Yanyan United International College Thanks to Professor Michael Hvidsten.
 Rooted tree and binary tree  Theorem 5.19: A full binary tree with t leaves contains i=t-1 internal vertices.
5.5.2 M inimum spanning trees  Definition 24: A minimum spanning tree in a connected weighted graph is a spanning tree that has the smallest possible.
5.5.3 Rooted tree and binary tree  Definition 25: A directed graph is a directed tree if the graph is a tree in the underlying undirected graph.  Definition.
Reading and Writing Mathematical Proofs Spring 2015 Lecture 4: Beyond Basic Induction.
Connectivity and Paths 報告人:林清池. Connectivity A separating set of a graph G is a set such that G-S has more than one component. The connectivity of G,
CS 103 Discrete Structures Lecture 13 Induction and Recursion (1)
Introduction to Trees IT12112 Lecture 05 Introduction Tree is one of the most important non-linear data structures in computing. It allows us to implement.
Trees Dr. Yasir Ali. A graph is called a tree if, and only if, it is circuit-free and connected. A graph is called a forest if, and only if, it is circuit-free.
Trees Thm 2.1. (Cayley 1889) There are nn-2 different labeled trees
Mathematical Induction Section 5.1. Climbing an Infinite Ladder Suppose we have an infinite ladder: 1.We can reach the first rung of the ladder. 2.If.
CompSci 102 Discrete Math for Computer Science March 13, 2012 Prof. Rodger Slides modified from Rosen.
Algorithms for hard problems Parameterized complexity Bounded tree width approaches Juris Viksna, 2015.
Spanning Tree Definition:A tree T is a spanning tree of a graph G if T is a subgraph of G that contains all of the vertices of G. A graph may have more.
Introduction Wireless Ad-Hoc Network  Set of transceivers communicating by radio.
Chapter 11. Chapter Summary  Introduction to trees (11.1)  Application of trees (11.2)  Tree traversal (11.3)  Spanning trees (11.4)
5.6 Prefix codes and optimal tree Definition 31: Codes with this property which the bit string for a letter never occurs as the first part of the bit string.
Chapter 5 With Question/Answer Animations 1. Chapter Summary Mathematical Induction - Sec 5.1 Strong Induction and Well-Ordering - Sec 5.2 Lecture 18.
Chapter 11. Chapter Summary Introduction to Trees Applications of Trees (not currently included in overheads) Tree Traversal Spanning Trees Minimum Spanning.
Section Recursion 2  Recursion – defining an object (or function, algorithm, etc.) in terms of itself.  Recursion can be used to define sequences.
Trees.
Advanced Algorithms Analysis and Design
Data Structures and Algorithms
Introduction to Trees Section 11.1.
Lectures on Network Flows
Advanced Algorithms Analysis and Design
Greedy Algorithms / Minimum Spanning Tree Yin Tat Lee
Autumn 2016 Lecture 11 Minimum Spanning Trees (Part II)
Planarity Testing.
Enumerating Distances Using Spanners of Bounded Degree
Autumn 2015 Lecture 11 Minimum Spanning Trees (Part II)
3.5 Minimum Cuts in Undirected Graphs
CS 583 Analysis of Algorithms
Winter 2019 Lecture 11 Minimum Spanning Trees (Part II)
Switching Lemmas and Proof Complexity
Locality In Distributed Graph Algorithms
Autumn 2019 Lecture 11 Minimum Spanning Trees (Part II)
Presentation transcript:

WSPD Applications

Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner diameter Applications to other proximity problems

Reminder: Well Separated Pairs Let s > 0 be a real number and A, B are two finite sets of points in Rd. 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.

Reminder: Well Separated Pairs

Reminder: WSPD Let S be a set of n points in Rd, and let s > 0 be a real number. A WSPD for S in respect to s is a sequence {A1,B1},{A2,B2},…,{Am, Bm} of pairs of nonempty subsets of S, for some integer m such that: For each 1≤i≤m, Ai and Bi are well separated with respect to s. For any two distinct points p and q, there is exactly one index 1≤i≤m such that p Ai and q Bi or the opposite. The integer m is called the size of the WSPD.

Reminder: Split Tree R(S) is the bounding box of the set S. The split tree for S is a binary tree containing the points of S in its leaves. If S=1, the node consists of the single point. Else, the node consists of S, and it’s 2 sons consist of S’s 2 equal halves S1 & S2. The split tree is used to find WSPD.

Reminder: Split Tree S S3 S4 S S5 S6 S2 S1 S5 S6 S3 S4

Main Idea of spanner construction Let S be a set of n points in Rd Compute a split tree T for S. Construct a WSPD from T. Choose the pairs’ representatives wisely. Connect the representatives. We get a t-spanner with special properties. כאן יש לציין כי ע"פ סעיף 9.2 שהוצג ע"י רון, חיבור כל הנציגים של ה WSPD מרכיב לנו בהכרח t-spanner.

Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner diameter Applications to other proximity problems: The closest pair problem Computing k-closest pairs The all-nearest neighbors problem Computing an approximate MST

Spanner of bounded degree Construction Let S be a set of n points in Rd 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:= {{ai,bi} : 1≤i≤m}, is a √t-spanner for S. We will choose ai,bi from Ai , Bi wisely, using the split tree T.

Spanner of bounded degree Representatives selection For each leaf u in T, let r(u) be the point of S stored in it. For each internal node u of T, let r(u) be the point of S that is stored in the rightmost leaf of the left sub-tree of u. Since every internal node of T has 2 children, r(u) is distinct for every internal node.

Spanner of bounded degree Representatives selection S S2 S1 S5 S6 S3 S4 Who represents S3 ? Who represents S ? S4 immediately precedes S in an in-order traversal on T. How does S relate to S4 ?

Spanner of bounded degree Representatives selection Hence, in O(n) total time we can compute r(u) for each node u of T. Let i be 1≤i≤m, the pair Ai , Bi is represented implicitly by 2 nodes of T, ui & vi, respectively. Ai , Bi are the set of points stored in the sub-trees of ui & vi. We take r(ui) Ai to be it’s representative. We do the same for r(vi) Bi.

Spanner of bounded degree Claim Let p be a point of S. There are at most 2 nodes u in T for which r(u) = p. Follows from the way we selected the representatives. <> For each i ,1≤i≤m, we direct the pair {Ai,Bi} as shown last week (lemma 9.4.4). We denote the directed graph as G`. Proof

Spanner of bounded degree Claim The out degree of of each vertex in G` is ≤ 2((2s + 4)√d +4) d Let p be an arbitrary vertex in G`. We’ve seen that there are at most 2 nodes u in T such that r(u) = p. For each directed pair {Ai,Bi}, where Ai is the set of points stored in u’s sub-tree, p has one out going edge. Proof

Spanner of bounded degree Proof cont. All out going edges of p are obtained by the same way. As shown last week (lemma 9.4.5 – the packing lemma), for each node u in T, there are at most ((2s + 4)√d +4) d nodes v in T such that (Su,Sv) is a pair in WSPD(T,s). <> Now we have a directed graph of bounded out degree. We want to transform it into an undirected t-spanner of bounded degree.

Spanner of bounded degree The transformation 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.

Spanner of bounded degree Time complexity WSPD construction: O(nlogn + sd 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).

Agenda Reminders Spanner of bounded degree Spanner with logarithmic spanner diameter Applications to other proximity problems: The closest pair problem Computing k-closest pairs The all-nearest neighbors problem Computing an approximate MST

Spanner with log. spanner diameter Construction Let S be a set of n points in Rd 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:= {{ai,bi} : 1≤i≤m}, is a t-spanner for S. We will choose ai,bi from Ai , Bi wisely, using the split tree T.

Spanner with log. spanner diameter Representatives selection Let u be any internal node of T. Let ul & ur be u’s left and right sons. Let el & er be the edges that connect u to ul & ur respectively. Let nl & nr be number of leaves in the sub- trees rooted by ul & ur respectively. If nl ≥ nr , we label el as ‘heavy’, and er as ‘light’. If nl < nr , we label er as ‘heavy’, and el as ‘light’.

Spanner with log. spanner diameter Representatives selection Each internal node is connected by exactly one ‘heavy’ edge to one of it’s 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).

Spanner with log. spanner diameter Representatives selection S S2 S1 S3 S4 S5 S6 S7 S8 S9 S10 S11 S12

Spanner with log. spanner diameter Representatives selection Let i be 1≤i≤m, the pair Ai , Bi is represented implicitly by 2 nodes of T, ui & vi, respectively. Ai , Bi are the set of points stored in the sub-trees of ui & vi. We take r(ui) Ai to be it’s representative. We do the same for r(vi) Bi. Now G=(S,E) is a t-spanner. We need to prove it’s diameter is logarithmic.

Spanner with log. spanner diameter Claim For each i ,1≤i≤m, and for each point p Ai there is a t-spanner path in G between p and the representative ai of Ai, that contains at most log|Ai| edges. From construction, there is a t-spanner path between p and ai . If p = ai , we are done. Assume otherwise. Proof

Spanner with log. spanner diameter Proof cont. Let j be the index such that: (i) p Aj and ai Bj . Or (ii) ai Aj and p Bj . WLOG assume (i). Recursively construct a path Q1 between p and it’s representative aj. Recursively construct a path Q2 between ai and it’s representative bj. Return Q = Q1 , {aj, bj} , Q2.

Spanner with log. spanner diameter Proof cont. We will show that |Q| ≤ log|Ai| (p Ai ). Induction on the size of set Ai. Base: Ai = {ai} => p = ai => we are done. Let i be an index such that |Ai| > 1, p ≠ ai. Assume, for all k such that |Ak| < |Ai| , and for all x Ak, the algorithm constructs a t-spanner path between x and ak with at most log|Ak| edges.

Spanner with log. spanner diameter Proof cont. Let ui, uj, vj be the nodes of T whose sub- trees store the sets Ai, Aj, Bj respectively. ui is a common ancestor of the leaves storing p and ai . uj lies on the path from root to the leaf of p. vj lies on the path from root to the leaf of ai Aj, Bj are disjoint => uj, vj are both in the sub-tree of ui, and neither is an ancestor of the other.

Spanner with log. spanner diameter Proof cont. S Ui Uj Vj p => ai = bj. => |Q2|=0 ai

Spanner with log. spanner diameter Proof cont. |Aj| ≤ |Ai|/2. Otherwise all the edges between ui and uj would be ‘heavy’. But then, the representative of Ai would be an element of Aj , but it’s not (ai Bj represents Ai). By induction hypothesis, the path Q1 between p and aj contains at most log|Aj| edges, which is ≤ log|Ai| - 1. We add {aj, bj} and get that |Q| ≤ log|Ai| . <>

Spanner with log. spanner diameter Claim 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 2logn–1 edges. Proof

Spanner with log. spanner diameter Proof cont. Let j be the index such that: (i) p Aj and q Bj . Or (ii) q Aj and p Bj . WLOG assume (i). Recursively construct a path Q1 between p and it’s representative aj. Recursively construct a path Q2 between ai and it’s representative bj. Return Q = Q1 , {aj, bj} , Q2.

Spanner with log. spanner diameter Proof cont. We proved that |Q1| ≤ log|Aj|. Similarly, |Q2| ≤ log|Bj|. Hence, |Q| ≤ log|Aj| + log|Bj| + 1. Aj, Bj are disjoint => |Aj| + |Bj| ≤ n. log|Aj| + log|Bj| ≤ log|Aj| + log|n - Aj| ≤ 2log(n/2) = 2logn – 2. Hence, Q contains at most 2logn – 1 edges.<>

Spanner with log. spanner diameter Time complexity WSPD construction: O(nlogn + sd n) as shown last week (Theorem 9.4.6). Representative selection: O(m) . All in all : O(nlogn).

BREAK