Incremental. Computing the convex hull. R. Inkulu

Similar documents
Computational Geometry. Lecture 1: Introduction and Convex Hulls

Shortest Path Algorithms

EE602 Algorithms GEOMETRIC INTERSECTION CHAPTER 27

Triangulation by Ear Clipping

Solving Geometric Problems with the Rotating Calipers *

Approximation of an Open Polygonal Curve with a Minimum Number of Circular Arcs and Biarcs

1 Computational Geometry

Arrangements And Duality

Shortest Inspection-Path. Queries in Simple Polygons

Disjoint Compatible Geometric Matchings

Algorithms for Computing Convex Hulls Using Linear Programming

G.H. Raisoni College of Engineering, Nagpur. Department of Information Technology

Geometry Chapter Point (pt) 1.1 Coplanar (1.1) 1.1 Space (1.1) 1.2 Line Segment (seg) 1.2 Measure of a Segment

Grade 7 & 8 Math Circles Circles, Circles, Circles March 19/20, 2013

Chapter 6 Notes: Circles

CHAPTER SIX IRREDUCIBILITY AND FACTORIZATION 1. BASIC DIVISIBILITY THEORY

Chapters 6 and 7 Notes: Circles, Locus and Concurrence

1. A student followed the given steps below to complete a construction. Which type of construction is best represented by the steps given above?

Diffuse Reflection Radius in a Simple Polygon

Final Review Geometry A Fall Semester

Scan-Line Fill. Scan-Line Algorithm. Sort by scan line Fill each span vertex order generated by vertex list

Largest Fixed-Aspect, Axis-Aligned Rectangle

Circle Name: Radius: Diameter: Chord: Secant:

Definitions, Postulates and Theorems

Angles that are between parallel lines, but on opposite sides of a transversal.

SCAN: A Structural Clustering Algorithm for Networks

2006 Geometry Form A Page 1

15. Appendix 1: List of Definitions

A Linear Online 4-DSS Algorithm

Shortcut sets for plane Euclidean networks (Extended abstract) 1

11.3 Curves, Polygons and Symmetry

Visualizing Triangle Centers Using Geogebra

Catalan Numbers. Thomas A. Dowling, Department of Mathematics, Ohio State Uni- versity.

SPERNER S LEMMA AND BROUWER S FIXED POINT THEOREM

Unit 3: Circles and Volume

2. If C is the midpoint of AB and B is the midpoint of AE, can you say that the measure of AC is 1/4 the measure of AE?

Selected practice exam solutions (part 5, item 2) (MAT 360)

We can display an object on a monitor screen in three different computer-model forms: Wireframe model Surface Model Solid model

DEGREE CONSTRAINED TRIANGULATION. Roshan Gyawali

DEFINITIONS. Perpendicular Two lines are called perpendicular if they form a right angle.

Mathematical Induction. Mary Barnes Sue Gordon

HOLES 5.1. INTRODUCTION

The Essentials of CAGD

Fast approximation of the maximum area convex. subset for star-shaped polygons

39 Symmetry of Plane Figures

28 Closest-Point Problems

ERROR PROPAGATION THROUGH GEOMETRIC TRANSFORMATIONS

Chapter 8. Digital and Analog Interfacing Methods

Curriculum Map by Block Geometry Mapping for Math Block Testing August 20 to August 24 Review concepts from previous grades.

Geometry Review Flash Cards

Line Segment Intersection

Research Statement. Andrew Suk

Point Location. Preprocess a planar, polygonal subdivision for point location queries. p = (18, 11)

Session 5 Dissections and Proof

Cpt S 223. School of EECS, WSU

Approximation Algorithms

Studia Scientiarum Mathematicarum Hungarica 41 (2), (2004)

CSC2420 Spring 2015: Lecture 3

Pre Calculus Math 40S: Explained!

Simple Robots with Minimal Sensing: From Local Visibility to Global Geometry

Collision Detection Algorithms for Motion Planning

3 Data Representations

Strictly Localized Construction of Planar Bounded-Degree Spanners of Unit Disk Graphs

Duplicating Segments and Angles

International Indian School, Riyadh SA1 Worksheet Class: VI Mathematics

Geometry: Unit 1 Vocabulary TERM DEFINITION GEOMETRIC FIGURE. Cannot be defined by using other figures.

Solutions to Exercises, Section 5.1

Load Balancing. Load Balancing 1 / 24

Area. Area Overview. Define: Area:

Cabri Geometry Application User Guide

Geometry Chapter 10 Study Guide Name

AN ALGORITHM FOR CENTRELINE EXTRACTION USING NATURAL NEIGHBOUR INTERPOLATION

24 Sample problems and algorithms

x 2 f 2 e 1 e 4 e 3 e 2 q f 4 x 4 f 3 x 3

Off-line Model Simplification for Interactive Rigid Body Dynamics Simulations Satyandra K. Gupta University of Maryland, College Park

GEOMETRY. Constructions OBJECTIVE #: G.CO.12

MATH STUDENT BOOK. 8th Grade Unit 6

GeoGebra. 10 lessons. Gerrit Stols

H.Calculating Normal Vectors

5.1 Bipartite Matching

Adaptive Linear Programming Decoding

Line and Polygon Clipping. Foley & Van Dam, Chapter 3

Lesson 2: Circles, Chords, Diameters, and Their Relationships

56 questions (multiple choice, check all that apply, and fill in the blank) The exam is worth 224 points.

BALTIC OLYMPIAD IN INFORMATICS Stockholm, April 18-22, 2009 Page 1 of?? ENG rectangle. Rectangle

Lesson 1: Introducing Circles

Triangle Trigonometry and Circles

MA 408 Computer Lab Two The Poincaré Disk Model of Hyperbolic Geometry. Figure 1: Lines in the Poincaré Disk Model

Mathematics Spring 2015 Dr. Alexandra Shlapentokh Guide #3

For the circle above, EOB is a central angle. So is DOE. arc. The (degree) measure of ù DE is the measure of DOE.

Most popular response to

CS 534: Computer Vision 3D Model-based recognition

1 Symmetries of regular polyhedra

Social Media Mining. Graph Essentials

37 Basic Geometric Shapes and Figures

Three Effective Top-Down Clustering Algorithms for Location Database Systems

Face detection is a process of localizing and extracting the face region from the

Lecture 24: Saccheri Quadrilaterals

INCIDENCE-BETWEENNESS GEOMETRY

Closest Pair Problem

Transcription:

Incremental Computing the convex hull R. Inkulu http://www.iitg.ac.in/rinkulu/ (Convex hull incremental construction) 1 / 10

Convex hull A simple polygon P is convex if for any two points p, q P (chosen from the boundary/interior of P), the line segment pq lies in P. 1 assume that no three points in S are collinear 2 when S is a set of points, no polygon P exists so that it encloses S and P CH; in other words, CH has the smallest area (Convex hull incremental construction) 2 / 10

Convex hull A simple polygon P is convex if for any two points p, q P (chosen from the boundary/interior of P), the line segment pq lies in P. Given a set S of n points 1 in R 2, the convex hull CH of S is the smallest 2 convex polygon containing S. 1 assume that no three points in S are collinear 2 when S is a set of points, no polygon P exists so that it encloses S and P CH; in other words, CH has the smallest area (Convex hull incremental construction) 2 / 10

Observations A subset S S of points, known as vertices of CH(S), define the boundary of CH(S). (Convex hull incremental construction) 3 / 10

Observations A subset S S of points, known as vertices of CH(S), define the boundary of CH(S). The interior angle at every vertex of CH(S) is < π. (Convex hull incremental construction) 3 / 10

Observations A subset S S of points, known as vertices of CH(S), define the boundary of CH(S). The interior angle at every vertex of CH(S) is < π. For any two successive vertices v, v of CH(S), all the points in S {v, v } lie on one side of the line v v. (Convex hull incremental construction) 3 / 10

Observations A subset S S of points, known as vertices of CH(S), define the boundary of CH(S). The interior angle at every vertex of CH(S) is < π. For any two successive vertices v, v of CH(S), all the points in S {v, v } lie on one side of the line v v. Let S be an ordered set of vertices of CH(S) while traversing the boundary of CH(S). With respect to any interior point of CH(S), the angles vertices in S make increase (modulo 2π). (Convex hull incremental construction) 3 / 10

Naive algorithm For every pair of points in S, determine whether they are vertices of CH(S). Find an interior point p of CH(S); sort the vertices in angular order w.r.t. p. (Convex hull incremental construction) 4 / 10

Naive algorithm For every pair of points in S, determine whether they are vertices of CH(S). Find an interior point p of CH(S); sort the vertices in angular order w.r.t. p. takes O(n 3 ) time (Convex hull incremental construction) 4 / 10

Incremental algorithm Let p i+1 be the newly added point. Ignore p i+1 if it lies interior to CH i. Otherwise, insert p i+1 to the boundary of CH i at the appropriate position. (Convex hull incremental construction) 5 / 10

Incremental algorithm Let p i+1 be the newly added point. Ignore p i+1 if it lies interior to CH i. Otherwise, insert p i+1 to the boundary of CH i at the appropriate position. paradigm: while considering input online, maintain the object of interest corresponding to the input considered (Convex hull incremental construction) 5 / 10

Few definitions The convex hull CH(S) running from the leftmost point to the rightmost point when the vertices are listed in clockwise order is termed upper hull of CH(S). The remaining part is termed the lower hull of CH(S). (Convex hull incremental construction) 6 / 10

Upper and lower tangents: definitions h u+1 h u h u 1 CH i h l+1 h l h l 1 p i+1 Let the vertices of CH i be numbered in counterclockwise order, starting with the rightmost. Given a convex hull CH i (defined with n > 3 points) and a point p i+1 exterior to CH i and a vertex h u of CH i, p i+1 h u is said to be the upper tangent to CH i from p i+1 if p i+1 is located rightof( h u+1 h u ) and leftof( h u h u 1 ). (Convex hull incremental construction) 7 / 10

Upper and lower tangents: definitions h u+1 h u h u 1 CH i h l+1 h l h l 1 p i+1 Let the vertices of CH i be numbered in counterclockwise order, starting with the rightmost. Given a convex hull CH i (defined with n > 3 points) and a point p i+1 exterior to CH i and a vertex h u of CH i, p i+1 h u is said to be the upper tangent to CH i from p i+1 if p i+1 is located rightof( h u+1 h u ) and leftof( h u h u 1 ). Analogous definition applies to lower tangent from p i+1 to CH i. (Convex hull incremental construction) 7 / 10

Algorithm 1 h u+1 h u h u 1 CH i h l+1 h l h l 1 p i+1 Let CH i be the convex hull of p 1,...,p i and let p i+1 be the newly added point. Determine whether p i+1 is interior by checking its location w.r.t. every edge of CH(S); if yes, go to next iteration For every convex hull vertex h of CH i, check whether h is an endpoint of an upper tangent from p i+1. The upper hull of CH i+1 is defined by excluding points on the convex hull from h u to rightmost point of CH i in the clockwise order and including p i+1 after h u. (Convex hull incremental construction) 8 / 10

Algorithm 1 h u+1 h u h u 1 CH i h l+1 h l h l 1 p i+1 Let CH i be the convex hull of p 1,...,p i and let p i+1 be the newly added point. Determine whether p i+1 is interior by checking its location w.r.t. every edge of CH(S); if yes, go to next iteration For every convex hull vertex h of CH i, check whether h is an endpoint of an upper tangent from p i+1. The upper hull of CH i+1 is defined by excluding points on the convex hull from h u to rightmost point of CH i in the clockwise order and including p i+1 after h u. takes O(n 2 ) time (after analogously computing lower tangent etc.,) (Convex hull incremental construction) 8 / 10

Algorithm 2: improved h u+1 h u h u 1 h h CH i h l+1 h l h l 1 p i+1 Incrementally add points by their increasing x-coord value. Let CH i be the convex hull of p 1,...,p i and let p i+1 be the newly added point. Find the endpoint h u of upper tangent from p i+1 to CH i by doing binary search over the vertices of the upper hull of CH i. The upper hull of CH i+1 is defined by excluding points on the convex hull from h u to rightmost point of CH i in the clockwise order and including p i+1 after h u. (Convex hull incremental construction) 9 / 10

Algorithm 2: improved h u+1 h u h u 1 h h CH i h l+1 h l h l 1 p i+1 Incrementally add points by their increasing x-coord value. Let CH i be the convex hull of p 1,...,p i and let p i+1 be the newly added point. Find the endpoint h u of upper tangent from p i+1 to CH i by doing binary search over the vertices of the upper hull of CH i. The upper hull of CH i+1 is defined by excluding points on the convex hull from h u to rightmost point of CH i in the clockwise order and including p i+1 after h u. takes O(n lg n) time (after analogously computing lower tangent etc.,) (Convex hull incremental construction) 9 / 10

Algorithm 3: simpler algo but bit involved analysis Incrementally add points by their increasing x-coord value. Let CH i be the convex hull of p 1,...,p i and let p i+1 be the newly added point. While the last two points p, p (ordered) on upper hull of CH i together with p i+1 make right turn at p prune p from CH i and continue till reaching h u The upper hull of CH i+1 is defined by the leftmost vertex of CH i to h u along CH i appended with p i+1 (Convex hull incremental construction) 10 / 10

Algorithm 3: simpler algo but bit involved analysis Incrementally add points by their increasing x-coord value. Let CH i be the convex hull of p 1,...,p i and let p i+1 be the newly added point. While the last two points p, p (ordered) on upper hull of CH i together with p i+1 make right turn at p prune p from CH i and continue till reaching h u The upper hull of CH i+1 is defined by the leftmost vertex of CH i to h u along CH i appended with p i+1 takes O(n lg n) time charging argument: constant amount of work done w.r.t. a point p CH i is being charged to p itself if p is determined to be interior to CHi+1; otherwise, charge the same to p i+1 itself (Convex hull incremental construction) 10 / 10