An Introduction to Computational Geometry

Preview:

DESCRIPTION

An Introduction to Computational Geometry. Joseph S. B. Mitchell Stony Brook University. Mini-Course Info. Joe Mitchell (Math 1-109) jsbm@ams.sunysb.edu (631-632-8366) http://www.ams.sunysb.edu/~jsbm/nasa/tutorial.html Recommended Texts: - PowerPoint PPT Presentation

Citation preview

An Introduction to An Introduction to Computational GeometryComputational Geometry

Joseph S. B. MitchellStony Brook University

Mini-Course InfoMini-Course Info Joe Mitchell (Math 1-109)Joe Mitchell (Math 1-109) jsbm@ams.sunysb.edu (631-632-8366) (631-632-8366) http://www.ams.sunysb.edu/~jsbm/nasa/tutorial.html

Recommended Texts: Recommended Texts: • Computational GeometryComputational Geometry, by Mark de Berg, Marc van , by Mark de Berg, Marc van

Kreveld, Mark Overmars and Otfried Schwartzkopf (2Kreveld, Mark Overmars and Otfried Schwartzkopf (2ndnd edition)edition)

• Computational Geometry in CComputational Geometry in C, by Joe O’Rourke (2, by Joe O’Rourke (2ndnd Edition)Edition)

Surveys/Reference books:Surveys/Reference books:• CRC Handbook of Discrete and Computational Geometry, CRC Handbook of Discrete and Computational Geometry,

editted by Goodman and O’Rourke (2editted by Goodman and O’Rourke (2ndnd edition) edition)• Handbook of Computational Geometry, editted by Sack and Handbook of Computational Geometry, editted by Sack and

UrrutiaUrrutia

Sessions and TopicsSessions and Topics

Session 1:Session 1:• IntroductionIntroduction• Convex Hulls in 2D, 3DConvex Hulls in 2D, 3D• A variety of algorithmsA variety of algorithms

Session 2: Session 2: • Searching for intersections: Plane sweepSearching for intersections: Plane sweep• Halfspace intersections, low-dimensional Halfspace intersections, low-dimensional

linear programming (LP)linear programming (LP)• Range SearchRange Search

33

Sessions and TopicsSessions and Topics

Session 3:Session 3:• TriangulationTriangulation• Proximity: Voronoi/Delaunay diagramsProximity: Voronoi/Delaunay diagrams• Point location searchPoint location search

Session 4: Session 4: • ArrangementsArrangements• Duality and applicationsDuality and applications• Visibility graphs, shortest pathsVisibility graphs, shortest paths

44

Sessions and TopicsSessions and Topics

Session 5:Session 5:• Spatial partitioning, optimization, load Spatial partitioning, optimization, load

balancingbalancing• Binary Space PartitionsBinary Space Partitions• Clustering trajectoriesClustering trajectories

Session 6: Session 6: • GeoSect: Overview and algorithmsGeoSect: Overview and algorithms• 3D partitioning3D partitioning• Flow-respecting partitioningFlow-respecting partitioning

55

ArrangementsArrangements

Given a set Given a set SS of of nn lines in the plane lines in the plane Arrangement, Arrangement, A(S)A(S), is the , is the SS-induced -induced

decomposition of the plane into decomposition of the plane into cellscells (2- (2-faces), faces), edgesedges (1-faces), and (1-faces), and verticesvertices (0- (0-faces)faces)

66

L

Zone(L)

Constructing Constructing A(S)A(S)

GoalGoal: Build a DCEL of the planar graph of : Build a DCEL of the planar graph of vertices/edges of vertices/edges of A(S)A(S)

ComplexityComplexity: O(: O(nn2 2 ) faces, edges, vertices) faces, edges, vertices Incremental construction:Incremental construction:

• Zone TheoremZone Theorem: The zone, : The zone, Z(L)Z(L), of line , of line LL has has total complexity O(total complexity O(nn))

• Proof: InductionProof: Induction Add lines one by one; cost of adding line Add lines one by one; cost of adding line

LLii is O(is O(i i ), so total time is O(), so total time is O(nn2 2 ))77

More ArrangementsMore Arrangements

Huge subfield: Combinatorics/algorithmsHuge subfield: Combinatorics/algorithms Arrangements ofArrangements of

• Segments (Bentley-Ottmann sweep)Segments (Bentley-Ottmann sweep)• CirclesCircles• CurvesCurves• Higher dimensions: SurfacesHigher dimensions: Surfaces

Applications: Motion planning, optimization, Applications: Motion planning, optimization, Voronoi diagrams, pattern matching, Voronoi diagrams, pattern matching, fundamental to many algorithmsfundamental to many algorithms

Further motivation: Point-line dualityFurther motivation: Point-line duality88

DualityDuality

Point Point p=(pp=(pxx,p,pyy)) and line and line L: y=mx+b L: y=mx+b in the in the “primal” “primal” Line Line p*: y=pp*: y=px x x-px-py y and point and point L*=(m,-b)L*=(m,-b)

99

pq

L

r

L*

Key Property: p is above/on/below L iff L* is above/on/below p*

q*

P*r*

DualityDuality

A really nice demo (MIT)A really nice demo (MIT) AppletApplet

Another nice (simple) demo (Andrea)Another nice (simple) demo (Andrea) AppletApplet

1010

Applications of DualityApplications of Duality

Degeneracy testing: Any 3 collinear Degeneracy testing: Any 3 collinear points?points?

Stabbing line segmentsStabbing line segments Min-area triangleMin-area triangle Halfplane range searchHalfplane range search Ham sandwich cutsHam sandwich cuts Computing discrepancyComputing discrepancy Sorting points around each other point: Sorting points around each other point:

visibility graphsvisibility graphs1111

1212

Geometric Geometric Shortest PathsShortest Paths

GivenGiven::• (Outer) Polygon P(Outer) Polygon P• Polygonal oPolygonal obstaclesbstacles • Points s and tPoints s and t

Find:Find: • shortest shortest s-t s-t path path • avoiavoiding obstaclesding obstacles

Robotics motion Robotics motion planningplanning

Application: Weather Application: Weather AvoidanceAvoidance

1313

1414

Basic Optimal PathsBasic Optimal Paths

Visibility Graph

BEST: Output-sensitive alg: O(|E|+n log n)

Local optimality: taut string

Naïve algorithm:

O(n3)Better algorithms:

O(n2 log n) sweep

O(n2 ) duality

Visibility GraphsVisibility Graphs

Visibility Graph applet

Shows also the topological sweep of an arrangement, animated.

Example: Shortest Path in Example: Shortest Path in Simple PolygonSimple Polygon

Triangulate Triangulate PP Determine the “sleeve” defined by Determine the “sleeve” defined by

the triangles in a path in the dual the triangles in a path in the dual tree, from start to goaltree, from start to goal

WUSTL appletWUSTL applet

1818

Shortest Path MapShortest Path Map

Decomposition of the free spaceDecomposition of the free space

Shortest Paths Shortest Paths

go throughgo through

same verticessame vertices

Construct in time: O(n log n); size O(n)

2020

Optimal Path Map: Control Optimal Path Map: Control LawLaw

Fix s

Vary t

2121

Hazardous Weather AvoidanceHazardous Weather Avoidance

2222

Hazardous Weather AvoidanceHazardous Weather Avoidance

2323

Optimal Paths: Weighted Optimal Paths: Weighted RegionsRegions

Different costs/nmi in different regions (e.g. weather intensity)

Local optimality: Snell’s Law of Refraction

Can also apply grid-based searching

2424

Grid-Based SearchesGrid-Based Searches

2525

Other Optimal Path Other Optimal Path ProblemsProblems

3D shortest paths: NP-hard3D shortest paths: NP-hard• But good approximationsBut good approximations

Turn constraints:Turn constraints:• Min-# turns: Link distanceMin-# turns: Link distance• Bounds on turn angles (radius of Bounds on turn angles (radius of

curvature)curvature) ““Thick” paths (for air lanes)Thick” paths (for air lanes)

2626

Turn-Constrained Weighted Costs: Turn-Constrained Weighted Costs: Weather Route Generator (WRG)Weather Route Generator (WRG)

DFW

fix

Departure

space

Weather Avoidance Algorithms for En Route Weather Avoidance Algorithms for En Route Aircraft Aircraft

3 Flows

Sector

Find maximum number of air lanes through the mincut

Routing MaxFlowRouting MaxFlow

Example: Robot Motion Example: Robot Motion PlanningPlanning

applet

Shows Minkowski sum, visibility graph, shortest path for a disk, triangle, etc.

Example: Robot Motion Example: Robot Motion PlanningPlanning

applet

Voronoi method of robot motion planning

Probabilistic Road MapsProbabilistic Road Maps

Movie (Stanford)

Recommended