Presentation is loading. Please wait.

Presentation is loading. Please wait.

Mark Waitser Computational Geometry Seminar December 19 2001 Iterated Snap Rounding.

Similar presentations


Presentation on theme: "Mark Waitser Computational Geometry Seminar December 19 2001 Iterated Snap Rounding."— Presentation transcript:

1 Mark Waitser Computational Geometry Seminar December 19 2001 Iterated Snap Rounding

2 Agenda Introduction ISR Algorithm Example of ISR ISR Details ISR Complexity Analysis ISR Data Structure Examples of SR & ISR Conclusion

3 Introduction Snap Rounding (SR) is a method for converting arbitrary-precision arrangements of segments into fixed-precision representation. An arrangement of segments before (a) and after (b) snap rounding.

4 - Collection of input segments. - Arrangement of. Subdivision of plane into vertices, edges and faces. Vertex - is either a segment endpoint or the intersection of two segments. Hot pixel - Pixel contains a vertex of - Set of Hot Pixels induced by Introduction - Definitions

5 Iterated Snap Rounding (ISR) is a method which rounds the arrangement such that each vertex is at least half-the-width-of-a-pixel away from any non-incident edge. ISR preserves the topology of the original arrangement. Maximum combinatorial complexity is the SAME for SR and ISR. Introduction - Iterated Snap Rounding

6 Create chains out of input segments such that a chain that passes through a hot pixel is re- routed to pass through the pixel’s center. Each vertex is at least half-the-width-of-a- pixel away from any non-incident edge. ISR – Goal of Algorithm.

7 Problem - Once we reroute a chain, it may have entered other hot pixels and it need to further reroute. SR Problem.

8 IRS algorithm consists of two stages: First stage - Preprocessing stage - Compute the hot pixels and prepare a segment intersection search structure. Second stage - Operate a recursive procedure, Reroute, on each input segment. ISR – Rounding Algorithm

9 Compute the Hot Pixels by finding all Vertices of the arrangement. Prepare a segment intersection search structure on the Hot Pixels to answer following queries: Given a segment, report the Hot Pixels that intersects. ISR – First Stage

10 Operate a recursive procedure, Reroute, on each input segment. Reroute is a “depth-first” procedure. Reroute does not add more Hot Pixels. Reroute input is a segment Reroute output is a polygonal chain which approximates as an order list of links. ISR – Second Stage

11 ISR – Scheme of Algorithm

12 ISR – Reroute Procedure

13 Input arrangement (a) ISR – Example

14 Input arrangement (a) Step 1 arrangement (b) ISR – Example – Step 1

15 Step 1 arrangement (b)

16 ISR – Example – Step 2 Step 1 arrangement (b) Step 2 arrangement (c)

17 ISR – Example – Step 2 Step 2 arrangement (c)

18 ISR – Example – Step 3 Step 2 arrangement (c) Step 3 arrangement (d)

19 The Tree corresponding to Reroute( ). Nodes denoted by full-line circles contain segments which query the structure The dashed-line circle contains an exact copy of the segment of its parent. ISR – Example – Reroute Tree

20 Lemma 1 Given a set of segments, the output of ISR is equivalent to the final output of finite series of SR starting with, where the output of one SR is the input to the next SR. Proof: SR does not create new Hot Pixels The chains are the result of applying SR to the links in chains Hot Pixel is not discovered more that one per tree. There are at most Hot Pixels, therefore the process will stop. ISR – Algorithmic Details

21 Corollary ISR preserves the topology of the arrangement of the input segments in the same sense that SR does. Proof: ISR does not create new Vertices. No Vertex of the arrangement ever crosses through a curve. ISR – Algorithmic Details (continue)

22 Lemma 2 – (i) If an output chain of ISR passes through a Hot Pixel then it passes through its center – (ii) In the output chains each vertex is at least 0.5 a unit away from any non incident segment. Proof: (i) follows from the definition of the Reroute. (i i) consequence of (i) ISR – Algorithmic Details (continue)

23 Lemma 3 – A final chain lies in the Minkowski sum of and a square of side centered at the origin. Proof: In SR, a rounded segment lies inside the Minkowski sum of input segment and a unit square centered at origin. ISR is equivalent to applications of SR. ISR – Algorithmic Details (continue)

24 ISR - Complexity Analysis Lemma 4 If an output chain consists of links then during Reroute( ) the structure D is queries at most 2 times. Proof: It is clearly from definition of Reroute procedure

25 ISR - Complexity Analysis (continue) Theorem Given an arrangement of n segments with I intersection points, the ISR requires time for any and working storage, where N is the number of Hot Pixels (N=2n+I) and L is the overall number of links in the chains produced by the algorithm.

26 In the theoretical analysis used (multi- level) partition trees. – Asymptotically good worst-case complexity. – Difficult to implement. In practice implemented a data structure consisting of several kd-trees. ISR – Search Structure D

27 It answer range queries for axis-parallel rectangles. It is practically efficient. Worst-case query time is far from optimal. ISR – Structure D - kd-Tree

28 Trivial solution – query axis-parallel bounding box (B(s)) of M(s). The area of B(s) may be much large that the area of M(s). ISR – Structure D - kd-Tree (continue) M(s). B(s).

29 Construct a collection of kd-trees each serving as a range search structure for a rotated copy of the centers of Hot Pixels. Goal is produce a number of rotated copies so that for each query segment there will be one rotation with not too much different between M(s) and B(s). ISR – Structure D c-oriented kd-Tree

30 Congestion Data – 200 segments and 18674 intersections. Triangulation Data – 906 segments. Geographic Data – Map of USA, 486 segments. Rounding Examples: SR vs. ISR

31 Rounding Examples: SR vs. ISR Congestion Data 200 segments 18674 intersections.

32 Rounding Examples: SR vs. ISR Congestion Data

33 Rounding Examples: SR vs. ISR Triangulation Data 906 segments. Intersections only in endpoints.

34 Rounding Examples: SR vs. ISR Triangulation Data

35 Rounding Examples: SR vs. ISR Geographic Data 486 segments. Intersections only in endpoints.

36 Rounding Examples: SR vs. ISR Geographic Data

37 Conclusions Snap Rounding procedure which rounds Arbitrary Precision Arrangement in Rounded Arrangement. Each Vertex at least half a unit away from any non-incident Edge. New scheme more robust for further manipulation with limited precision arithmetic.

38 End

39 Abbreviation Explanation Rounding Examples: SR vs. ISR (continue) inkdinput number of kd-trees nkdactual number of kd-trees created nfhpoverall number of false hot pixels in all the queries tttotal time relative to using one tree mdmaximum deviation over all chains ad average deviation mnvmaximum number of vertices in an output chain anvaverage number of vertices in an output chain mdvsminimum distance between a vertex and a non- incident edge ncvsnumber of pairs of a vertex and a non-incident edge that are less than half the width of a pixel apart pspixel size nhpnumber of hot pixels

40 Rounding Examples: SR vs. ISR Congestion Data

41 Rounding Examples: SR vs. ISR Triangulation Data

42 Rounding Examples: SR vs. ISR Geographic Data


Download ppt "Mark Waitser Computational Geometry Seminar December 19 2001 Iterated Snap Rounding."

Similar presentations


Ads by Google