1 / 61

Well-Separated Pair Decomposition

Seminar on Geometric Approximation Algorithms, Spring 2012 Eyal Altshuler. Well-Separated Pair Decomposition. Topics To Be Covered. Motivation WSPD – Basic Definitions WSPD – The Construction Algorithm Applications of WSPD Approximating the diameter Closest pair Spanners

brand
Download Presentation

Well-Separated Pair Decomposition

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Seminar on Geometric Approximation Algorithms, Spring 2012 Eyal Altshuler Well-Separated Pair Decomposition

  2. Topics To Be Covered • Motivation • WSPD – Basic Definitions • WSPD – The Construction Algorithm • Applications of WSPD • Approximating the diameter • Closest pair • Spanners • Approximated minimum spanning tree

  3. Motivation • Given a set P of points in , We want to represent the distances between them efficiently • Suggestions: • explicitly listing the distances • listing arrays of coordinates • We will see a more compact representation

  4. Motivation • Suppose that all we care about are approximate distances • Want to capture that: • s and q are close together as far as p is concerned • s and q have the “same distance” from p • A “spoiler” for today’s data structure: • () • We will see how to build it q p s

  5. WSPD – Basic Definitions • [ All works in , we will concentrate on ] • Let P be a set of n points in

  6. WSPD – Basic Definitions • Denote by • The set of all (unordered) pairs of points formed by two sets of points – A and B • Informally we will refer to as the pair of the sets A and B

  7. WSPD – Basic Definitions • For a point set P, a pair decomposition of P is a set of pairs – • such that: • for every i • = for every i • =

  8. WSPD – Basic Definitions • The pair Q and R is (-separated if where

  9. WSPD – Basic Definitions Q R

  10. WSPD – Basic Definitions • For a point set P, a well-separatedpair decomposition(WSPD) of P with parameter ( is a pair decomposition of P with a set of pairs- • such that, for any i, the sets and are ( separated

  11. Example b a f c d e

  12. Building a WSPD • How to represent a WSPD efficiently? • Construct a Tree T having the points of P as leaves. • Every Pair {} will be just a pair of nodes (, such that • denotes the points of P stored in the sub-tree of v

  13. Reminder - Quadtrees b a f c d e

  14. Reminder - Quadtrees b a f c d f e a d e c b

  15. Reminder - Quadtrees • Denote by the cell that contains the points that are in the subtree of v • Working with compressed quadtrees – time construction

  16. Building a WSPD • Build T as a compressed quadtree d f e a c b

  17. Building a WSPD • Find the pairs of vertices that define a WSPD d f e a c b

  18. Notes • The quadtree decomposes the points such that the diameter of a point set stored in a node drops quickly as we go down the tree • A given tree can be used to represent many possible WSPDs. We are looking for the WSPD that is “minimal”

  19. Notes • Suppose we find, for a given , the pairs of nodes that represent -separated point sets • This is the WSPD compact representation we want to achieve • It will be convenient, for each point set in a pair, to choose an arbitrary representative. Calculating distances between pairs will be done using these representatives

  20. The Construction Algorithm • Given – A set of n points P in • First, compute the quadtree T of P • Next, be greedy – by calling • algWSPD(root,root)

  21. Some More Definitions • - the “diameter” of the cell associated with • for a leaf, otherwise

  22. Examples b a f c v d f u a g e g d c e b ?

  23. Examples b a f c v d f u a g e g d c e b ?

  24. Examples b a f c v d f u a g e g d c e b

  25. algWSPD(u,v) • If and then • return // Don’t pair a leaf with itself • Ifthen • Exchange and • Ifthen • return // - the children of • return

  26. Analysis • Computing the com-pressed quadtree T of P can be done in time (see previous lecture) • We will prove that constructing an -WSPD takes time • running time

  27. Analysis • Lemma 1: • Let be a cell of a grid G of with cell diameter . For , the number of cells in G at distance at most from is • Proof: y y y x y

  28. Analysis • Lemma 2 (validity): • algWSPD terminates and computes a valid pair decomposition • Proof: • Termination – always stops if both and are leaves • Every pair of points is covered – by induction • Every pair is valid -

  29. Analysis • Lemma 3: (-WSPD) • For the WSPD generated by algWSPD, we have that for any pair in the WSPD, and , for any ,

  30. Analysis • Proof: ,

  31. Analysis • We got that the algorithm always return a valid -WSPD. • Note that the running time of the algorithm is clearly linear in its output size. • So, what is the output size?

  32. Analysis • For a pair computed by algWSPD, we have that- where denotes that parent of in T

  33. Analysis • [ • Proof: • Trivial that- • Let us show that

  34. Analysis • [ • Consider the set of recursive calls

  35. Analysis • [ • Assume

  36. Analysis • [ • Assume • Clearly,

  37. Analysis • [ • Similarly consider the index t where- • Clearly,

  38. Analysis • Lemma: (WSPD’s size) The number of pairs in the computed WSPD is • Corollary: For , one can construct an -WSPD of size , and the construction time is

  39. Analysis • Proof: • Suppose in the output • Suppose was called by • “charge” for that • Show that can’t be charged too much

  40. Analysis • If: • Then:

  41. Analysis • In addition- • Because the pair is not in the output • Denote-

  42. Analysis • Suppose the three possibilities • Each one can happen at most times • (show on board) • There are n possible s, thus the total number of charges is

  43. Applications

  44. remember from algWSPD • For an -WSPD , it holds, for any pair , that: • Will be very important in the application side

  45. Applications – Approximating The Diameter • Given a set P of n points in , find a pair such that , where is the diameter of P • Approximation vs. time, space

  46. Applications – Approximating The Diameter

  47. Applications – Approximating The Diameter • The affect of choosing the correct epsilon • Compute a -WSPD W of P • From the result- • Return the representatives of that have maximal distance between them

  48. Applications – Approximating The Diameter q s

  49. Applications – Approximating The Diameter • Consider the pair realizing the diameter of P • Let be the pair that contain the points q s

  50. Applications – Closest Pair • Let P be a set of points in . We would like to compute the closest pair. • (first lecture) • Let be an -WSPD. • Let us look at closest points p and q in P, and consider the pair that separates them

More Related