Computational Geometry Lecture 12: Delaunay Triangulations - - PowerPoint PPT Presentation

computational geometry
SMART_READER_LITE
LIVE PREVIEW

Computational Geometry Lecture 12: Delaunay Triangulations - - PowerPoint PPT Presentation

Introduction Triangulations Delaunay Triangulations Delaunay Triangulations Computational Geometry Lecture 12: Delaunay Triangulations Computational Geometry Lecture 12: Delaunay Triangulations Introduction Triangulations Delaunay


slide-1
SLIDE 1

Introduction Triangulations Delaunay Triangulations

Delaunay Triangulations

Computational Geometry

Lecture 12: Delaunay Triangulations

Computational Geometry Lecture 12: Delaunay Triangulations

slide-2
SLIDE 2

Introduction Triangulations Delaunay Triangulations

Motivation: Terrains

a terrain is the graph of a function f : A ⊂ R2 → R we know only height values for a set of measurement points how can we interpolate the height at other points? using a triangulation

Computational Geometry Lecture 12: Delaunay Triangulations

slide-3
SLIDE 3

Introduction Triangulations Delaunay Triangulations

Motivation: Terrains

a terrain is the graph of a function f : A ⊂ R2 → R we know only height values for a set of measurement points how can we interpolate the height at other points? using a triangulation

Computational Geometry Lecture 12: Delaunay Triangulations

slide-4
SLIDE 4

Introduction Triangulations Delaunay Triangulations

Motivation: Terrains

a terrain is the graph of a function f : A ⊂ R2 → R we know only height values for a set of measurement points how can we interpolate the height at other points? using a triangulation

?

Computational Geometry Lecture 12: Delaunay Triangulations

slide-5
SLIDE 5

Introduction Triangulations Delaunay Triangulations

Motivation: Terrains

a terrain is the graph of a function f : A ⊂ R2 → R we know only height values for a set of measurement points how can we interpolate the height at other points? using a triangulation

?

Computational Geometry Lecture 12: Delaunay Triangulations

slide-6
SLIDE 6

Introduction Triangulations Delaunay Triangulations

Motivation: Terrains

a terrain is the graph of a function f : A ⊂ R2 → R we know only height values for a set of measurement points how can we interpolate the height at other points? using a triangulation – but which?

10 6 20 36 28 1000 980 990 1008 890 4 23 interpolated height = 985 q 10 6 20 36 28 1000 980 990 1008 890 4 23 interpolated height = 23 q

Computational Geometry Lecture 12: Delaunay Triangulations

slide-7
SLIDE 7

Introduction Triangulations Delaunay Triangulations

Triangulation

Let P = {p1,...,pn} be a point set. A triangulation of P is a maximal planar subdivision with vertex set P.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-8
SLIDE 8

Introduction Triangulations Delaunay Triangulations

Triangulation

Let P = {p1,...,pn} be a point set. A triangulation of P is a maximal planar subdivision with vertex set P. Complexity: 2n−2−k triangles 3n−3−k edges where k is the number of points in P

  • n the convex hull of P.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-9
SLIDE 9

Introduction Triangulations Delaunay Triangulations

Angle Vector of a Triangulation

Let T be a triangulation of P with m triangles and 3m

  • vertices. Its angle vector is A(T) = (α1,...,α3m) where

α1,...,α3m are the angles of T sorted by increasing value. Let T′ be another triangulation of P. We define A(T) > A(T′) if A(T) is lexicographically larger than A(T′). T is angle optimal if A(T) ≥ A(T′) for all triangulations T′ of P.

α1 α2 α3 α4 α5 α6 A(T) = (α1,...,α6)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-10
SLIDE 10

Introduction Triangulations Delaunay Triangulations

Angle Vector of a Triangulation

Let T be a triangulation of P with m triangles and 3m

  • vertices. Its angle vector is A(T) = (α1,...,α3m) where

α1,...,α3m are the angles of T sorted by increasing value. Let T′ be another triangulation of P. We define A(T) > A(T′) if A(T) is lexicographically larger than A(T′). T is angle optimal if A(T) ≥ A(T′) for all triangulations T′ of P.

α1 α2 α3 α4 α5 α6 A(T) = (α1,...,α6)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-11
SLIDE 11

Introduction Triangulations Delaunay Triangulations

Angle Vector of a Triangulation

Let T be a triangulation of P with m triangles and 3m

  • vertices. Its angle vector is A(T) = (α1,...,α3m) where

α1,...,α3m are the angles of T sorted by increasing value. Let T′ be another triangulation of P. We define A(T) > A(T′) if A(T) is lexicographically larger than A(T′). T is angle optimal if A(T) ≥ A(T′) for all triangulations T′ of P.

α1 α2 α3 α4 α5 α6 A(T) = (α1,...,α6)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-12
SLIDE 12

Introduction Triangulations Delaunay Triangulations

Edge Flipping

α′

1

α′

4

α′

3

α′

5

α′

2

α′

6

pi p j pk pl pi α4 α1 α3 α5 α2 α6 p j pk pl edge flip

Change in angle vector: α1,...,α6 are replaced by α′

1,...,α′ 6.

The edge e = pipj is illegal if min1≤i≤6 αi < min1≤i≤6 α′

i.

Flipping an illegal edge increases the angle vector.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-13
SLIDE 13

Introduction Triangulations Delaunay Triangulations

Edge Flipping

α′

1

α′

4

α′

3

α′

5

α′

2

α′

6

pi p j pk pl pi α4 α1 α3 α5 α2 α6 p j pk pl edge flip

Change in angle vector: α1,...,α6 are replaced by α′

1,...,α′ 6.

The edge e = pipj is illegal if min1≤i≤6 αi < min1≤i≤6 α′

i.

Flipping an illegal edge increases the angle vector.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-14
SLIDE 14

Introduction Triangulations Delaunay Triangulations

Edge Flipping

α′

1

α′

4

α′

3

α′

5

α′

2

α′

6

pi p j pk pl pi α4 α1 α3 α5 α2 α6 p j pk pl edge flip

Change in angle vector: α1,...,α6 are replaced by α′

1,...,α′ 6.

The edge e = pipj is illegal if min1≤i≤6 αi < min1≤i≤6 α′

i.

Flipping an illegal edge increases the angle vector.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-15
SLIDE 15

Introduction Triangulations Delaunay Triangulations

Edge Flipping

α′

1

α′

4

α′

3

α′

5

α′

2

α′

6

pi p j pk pl pi α4 α1 α3 α5 α2 α6 p j pk pl edge flip

Change in angle vector: α1,...,α6 are replaced by α′

1,...,α′ 6.

The edge e = pipj is illegal if min1≤i≤6 αi < min1≤i≤6 α′

i.

Flipping an illegal edge increases the angle vector.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-16
SLIDE 16

Introduction Triangulations Delaunay Triangulations

Characterisation of Illegal Edges

How do we determine if an edge is illegal?

Computational Geometry Lecture 12: Delaunay Triangulations

slide-17
SLIDE 17

Introduction Triangulations Delaunay Triangulations

Characterisation of Illegal Edges

How do we determine if an edge is illegal? Lemma: The edge pipj is illegal if and only if pl lies in the interior

  • f the circle C.

pi p j pk pl illegal

Computational Geometry Lecture 12: Delaunay Triangulations

slide-18
SLIDE 18

Introduction Triangulations Delaunay Triangulations

Thales Theorem

Theorem: Let C be a circle, ℓ a line intersecting C in points a and b, and p,q,r,s points lying on the same side

  • f ℓ. Suppose that p,q lie on C, r lies

inside C, and s lies outside C. Then ∡arb > ∡apb = ∡aqb > ∡asb, where ∡abc denotes the smaller angle defined by three points a,b,c.

ℓ C p q r s a b

Computational Geometry Lecture 12: Delaunay Triangulations

slide-19
SLIDE 19

Introduction Triangulations Delaunay Triangulations

Thales Theorem

Theorem: Let C be a circle, ℓ a line intersecting C in points a and b, and p,q,r,s points lying on the same side

  • f ℓ. Suppose that p,q lie on C, r lies

inside C, and s lies outside C. Then ∡arb > ∡apb = ∡aqb > ∡asb, where ∡abc denotes the smaller angle defined by three points a,b,c.

ℓ C p q r s a b pi p j pk pl illegal

Computational Geometry Lecture 12: Delaunay Triangulations

slide-20
SLIDE 20

Introduction Triangulations Delaunay Triangulations

Thales Theorem

Theorem: Let C be a circle, ℓ a line intersecting C in points a and b, and p,q,r,s points lying on the same side

  • f ℓ. Suppose that p,q lie on C, r lies

inside C, and s lies outside C. Then ∡arb > ∡apb = ∡aqb > ∡asb, where ∡abc denotes the smaller angle defined by three points a,b,c.

ℓ C p q r s a b pi p j pk pl illegal

α α′ β β ′ α′ < α β ′ < β

Computational Geometry Lecture 12: Delaunay Triangulations

slide-21
SLIDE 21

Introduction Triangulations Delaunay Triangulations

Legal Triangulations

A legal triangulation is a triangulation that does not contain any illegal edge.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-22
SLIDE 22

Introduction Triangulations Delaunay Triangulations

Legal Triangulations

A legal triangulation is a triangulation that does not contain any illegal edge. Algorithm LegalTriangulation(T)

  • Input. A triangulation T of a point set P.
  • Output. A legal triangulation of P.

1. while T contains an illegal edge pipj 2. do (∗ Flip pipj ∗) 3. Let pipjpk and pipjpl be the two triangles adjacent to pipj. 4. Remove pipj from T, and add pkpl instead. 5. return T

Computational Geometry Lecture 12: Delaunay Triangulations

slide-23
SLIDE 23

Introduction Triangulations Delaunay Triangulations

Legal Triangulations

A legal triangulation is a triangulation that does not contain any illegal edge. Algorithm LegalTriangulation(T)

  • Input. A triangulation T of a point set P.
  • Output. A legal triangulation of P.

1. while T contains an illegal edge pipj 2. do (∗ Flip pipj ∗) 3. Let pipjpk and pipjpl be the two triangles adjacent to pipj. 4. Remove pipj from T, and add pkpl instead. 5. return T Question: Why does this algorithm terminate?

Computational Geometry Lecture 12: Delaunay Triangulations

slide-24
SLIDE 24

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Voronoi Diagram and Delaunay Graph

Let P be a set of n points in the plane. The Voronoi diagram Vor(P) is the subdivision of the plane into Voronoi cells V(p) for all p ∈ P. Let G be the dual graph of Vor(P). The Delaunay graph DG(P) is the straight line embedding of G. Question: How can we compute the Delaunay graph?

Computational Geometry Lecture 12: Delaunay Triangulations

slide-25
SLIDE 25

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Voronoi Diagram and Delaunay Graph

Let P be a set of n points in the plane. The Voronoi diagram Vor(P) is the subdivision of the plane into Voronoi cells V(p) for all p ∈ P. Let G be the dual graph of Vor(P). The Delaunay graph DG(P) is the straight line embedding of G. Question: How can we compute the Delaunay graph?

Vor(P)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-26
SLIDE 26

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Voronoi Diagram and Delaunay Graph

Let P be a set of n points in the plane. The Voronoi diagram Vor(P) is the subdivision of the plane into Voronoi cells V(p) for all p ∈ P. Let G be the dual graph of Vor(P). The Delaunay graph DG(P) is the straight line embedding of G. Question: How can we compute the Delaunay graph?

Vor(P) G

Computational Geometry Lecture 12: Delaunay Triangulations

slide-27
SLIDE 27

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Voronoi Diagram and Delaunay Graph

Let P be a set of n points in the plane. The Voronoi diagram Vor(P) is the subdivision of the plane into Voronoi cells V(p) for all p ∈ P. Let G be the dual graph of Vor(P). The Delaunay graph DG(P) is the straight line embedding of G. Question: How can we compute the Delaunay graph?

Vor(P) DG(P)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-28
SLIDE 28

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Voronoi Diagram and Delaunay Graph

Let P be a set of n points in the plane. The Voronoi diagram Vor(P) is the subdivision of the plane into Voronoi cells V(p) for all p ∈ P. Let G be the dual graph of Vor(P). The Delaunay graph DG(P) is the straight line embedding of G. Question: How can we compute the Delaunay graph?

Vor(P) DG(P)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-29
SLIDE 29

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Planarity of the Delaunay Graph

Theorem: The Delaunay graph of a planar point set is a plane graph.

Cij pi p j contained in V(pi) contained in V(p j)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-30
SLIDE 30

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Delaunay Triangulation

If the point set P is in general position then the Delaunay graph is a triangulation.

v f

Computational Geometry Lecture 12: Delaunay Triangulations

slide-31
SLIDE 31

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Empty Circle Property

Theorem: Let P be a set of points in the plane, and let T be a triangulation of P. Then T is a Delaunay triangulation of P if and only if the circumcircle of any triangle of T does not contain a point of P in its interior.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-32
SLIDE 32

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Delaunay Triangulations and Legal Triangulations

Theorem: Let P be a set of points in the plane. A triangulation T of P is legal if and only if T is a Delaunay triangulation.

pi p j pk pl C(pipj pk) pm C(pipj pm) e

Computational Geometry Lecture 12: Delaunay Triangulations

slide-33
SLIDE 33

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Angle Optimality and Delaunay Triangulations

Theorem: Let P be a set of points in the plane. Any angle-optimal triangulation of P is a Delaunay triangulation of

  • P. Furthermore, any Delaunay triangulation of P maximizes

the minimum angle over all triangulations of P.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-34
SLIDE 34

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

Algorithm DelaunayTriangulation(P)

  • Input. A set P of n+1 points in the plane.
  • Output. A Delaunay triangulation of P.

1. Initialize T as the triangulation consisting of an outer triangle p0p−1p−2 containing points of P, where p0 is the lexicographically highest point of P. 2. Compute a random permutation p1,p2,...,pn of P\{p0}. 3. for r ← 1 to n 4. do 5. Locate(pr,T) 6. Insert(pr,T) 7. Discard p−1 and p−2 with all their incident edges from T. 8. return T

Computational Geometry Lecture 12: Delaunay Triangulations

slide-35
SLIDE 35

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

pr pi pk p j pr p j pi pk pl pr lies in the interior of a triangle pr falls on an edge

Computational Geometry Lecture 12: Delaunay Triangulations

slide-36
SLIDE 36

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

Insert(pr,T) 1. if pr lies in the interior of the triangle pipjpk 2. then Add edges from pr to the three vertices of pipjpk, thereby splitting pipjpk into three triangles. 3. LegalizeEdge(pr,pipj,T) 4. LegalizeEdge(pr,pjpk,T) 5. LegalizeEdge(pr,pkpi,T) 6. else (∗ pr lies on an edge of pipjpk, say the edge pipj ∗) 7. Add edges from pr to pk and to the third vertex pl of the

  • ther triangle that is incident to pipj, thereby splitting the

two triangles incident to pipj into four triangles. 8. LegalizeEdge(pr,pipl,T) 9. LegalizeEdge(pr,plpj,T) 10. LegalizeEdge(pr,pjpk,T) 11. LegalizeEdge(pr,pkpi,T)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-37
SLIDE 37

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

LegalizeEdge(pr,pipj,T) 1. (∗ The point being inserted is pr, and pipj is the edge of T that may need to be flipped. ∗) 2. if pipj is illegal 3. then Let pipjpk be the triangle adjacent to prpipj along pipj. 4. (∗ Flip pipj: ∗) Replace pipj with prpk. 5. LegalizeEdge(pr,pipk,T) 6. LegalizeEdge(pr,pkpj,T)

pr pi p j pk

Computational Geometry Lecture 12: Delaunay Triangulations

slide-38
SLIDE 38

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

= ⇒ pr

All edges created are incident to pr.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-39
SLIDE 39

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

= ⇒ pr

All edges created are incident to pr. Correctness: Are new edges legal?

Computational Geometry Lecture 12: Delaunay Triangulations

slide-40
SLIDE 40

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

pi p j pl pr C C′

Correctness: For any new edge there is an empty circle through endpoints. New edges are legal.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-41
SLIDE 41

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

Initializing triangulation: treat p−1 and p−2 symbolically. No actual coordinates. Modify tests for point location and illegal edges to work as if far away. Point location: search data structure. Point visits triangles of previous triangulations that contain it.

Computational Geometry Lecture 12: Delaunay Triangulations

slide-42
SLIDE 42

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Randomized Incremental Construction

split ∆1 flip pip j flip pipk pi pk ∆1 ∆1 ∆2 ∆2 ∆3 ∆3 pr ∆1 ∆2 ∆3 ∆2 ∆3 pi p j ∆1 ∆2 ∆3 ∆4 ∆4 ∆5 ∆6 ∆7 ∆7 ∆6 ∆1 ∆2 ∆3 ∆4 ∆3 ∆5 ∆4 ∆5

Computational Geometry Lecture 12: Delaunay Triangulations

slide-43
SLIDE 43

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

1 Expected total number of triangles created in O(n) 2 Expected total number of triangles visited while search

point location data structure: O(nlogn) We will only consider the first (see book for second)

Computational Geometry Lecture 12: Delaunay Triangulations

slide-44
SLIDE 44

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Lemma: Total number of triangles created is at most 9n+1. How many triangles are created when inserting pr? Backwards analysis: Any point of p1,...,pr has the same probability 1/r to be pr. Expected degree of pr ≤ 6. Number of triangles created ≤ 2degree(pr)−3 (Why? Count flips.) 2·6−3 = 9 + outer triangle

Computational Geometry Lecture 12: Delaunay Triangulations

slide-45
SLIDE 45

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Lemma: Total number of triangles created is at most 9n+1. How many triangles are created when inserting pr? Backwards analysis: Any point of p1,...,pr has the same probability 1/r to be pr. Expected degree of pr ≤ 6. Number of triangles created ≤ 2degree(pr)−3 (Why? Count flips.) 2·6−3 = 9 + outer triangle

Computational Geometry Lecture 12: Delaunay Triangulations

slide-46
SLIDE 46

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Lemma: Total number of triangles created is at most 9n+1. How many triangles are created when inserting pr? Backwards analysis: Any point of p1,...,pr has the same probability 1/r to be pr. Expected degree of pr ≤ 6. Number of triangles created ≤ 2degree(pr)−3 (Why? Count flips.) 2·6−3 = 9 + outer triangle

Computational Geometry Lecture 12: Delaunay Triangulations

slide-47
SLIDE 47

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Lemma: Total number of triangles created is at most 9n+1. How many triangles are created when inserting pr? Backwards analysis: Any point of p1,...,pr has the same probability 1/r to be pr. Expected degree of pr ≤ 6. Number of triangles created ≤ 2degree(pr)−3 (Why? Count flips.) 2·6−3 = 9 + outer triangle

Computational Geometry Lecture 12: Delaunay Triangulations

slide-48
SLIDE 48

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Lemma: Total number of triangles created is at most 9n+1. How many triangles are created when inserting pr? Backwards analysis: Any point of p1,...,pr has the same probability 1/r to be pr. Expected degree of pr ≤ 6. Number of triangles created ≤ 2degree(pr)−3 (Why? Count flips.) 2·6−3 = 9 + outer triangle

Computational Geometry Lecture 12: Delaunay Triangulations

slide-49
SLIDE 49

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Lemma: Total number of triangles created is at most 9n+1. How many triangles are created when inserting pr? Backwards analysis: Any point of p1,...,pr has the same probability 1/r to be pr. Expected degree of pr ≤ 6. Number of triangles created ≤ 2degree(pr)−3 (Why? Count flips.) 2·6−3 = 9 + outer triangle

Computational Geometry Lecture 12: Delaunay Triangulations

slide-50
SLIDE 50

Introduction Triangulations Delaunay Triangulations Properties Randomized Incremental Construction Analysis

Analysis

Theorem: The Delaunay triangulation of n points can be computed in O(nlogn) expected time.

Computational Geometry Lecture 12: Delaunay Triangulations