Download presentation
Presentation is loading. Please wait.
Published byHector Oliver Modified over 9 years ago
1
The Art Gallery Problem Bart Verzijlenberg
2
Agenda Problem Problem Chvátal’s Classical Art Gallery Theorem Chvátal’s Classical Art Gallery Theorem Proof Proof The Holy Art Gallery The Holy Art Gallery Conclusion Conclusion
3
Problem Place cameras in an art gallery such that the entire gallery is monitored Place cameras in an art gallery such that the entire gallery is monitored Cameras have a 360° view Cameras have a 360° view Model the gallery as a simple polygon Model the gallery as a simple polygon Introduced by Victor Klee in 1973 Introduced by Victor Klee in 1973
4
Chvátal’s Classical Art Gallery Theorem Triangulate the gallery Triangulate the gallery Place a camera in each triangle Place a camera in each triangle
5
What is an Ear There is an ear at vertex V in P if There is an ear at vertex V in P if the triangle formed by V and its 2 adjacent vertices is inside P the triangle formed by V and its 2 adjacent vertices is inside P there is no vertex of P inside this triangle there is no vertex of P inside this triangle V1V1 V2V2
6
Two Ears Theorem Every simple polygon has at least two non-overlapping ears Every simple polygon has at least two non-overlapping ears Except triangles Except triangles
7
Triangulation Any polygon can be triangulated Any polygon can be triangulated Every polygon P has at least two ears. Every polygon P has at least two ears. Define one such ear as N 1, V, N 2 Define one such ear as N 1, V, N 2 Add an edge N 1 N 2 to P Add an edge N 1 N 2 to P Remove other two ear edges from P Remove other two ear edges from P Resulting polygon either Resulting polygon either Has at least two ears Has at least two ears Is a triangle Is a triangle
8
Example N=11 vertices
9
Upper Bound We can triangulate any n sided polygon into n -2 triangles We can triangulate any n sided polygon into n -2 triangles Hence we need at most n-2 cameras Hence we need at most n-2 cameras
10
Art Gallery Theorom Any simple polygon can be guarded by cameras Any simple polygon can be guarded by cameras 12/3 = 4 Guards
11
Proof For polygon P For polygon P Let T(P) be the triangulation of P Let T(P) be the triangulation of P Create a graph such that Create a graph such that Each triangle is a node Each triangle is a node There is an edge between two nodes iff There is an edge between two nodes iff The corresponding triangles share a diagonal The corresponding triangles share a diagonal
12
Proof (contd.) The graph will be a tree The graph will be a tree Connected graph Connected graph All triangles are joined by diagonals All triangles are joined by diagonals Will be acyclic Will be acyclic If there was a cycle, then there would be a hole in the polygon If there was a cycle, then there would be a hole in the polygon
13
A Tree: 9 triangles
14
Three Coloring Pick a Node Pick a Node Assign a colour to each of the corresponding triangle’s vertices Assign a colour to each of the corresponding triangle’s vertices Follow a tree edge to the next node Follow a tree edge to the next node The corresponding triangle has only one uncoloured vertex. The corresponding triangle has only one uncoloured vertex. Colour that remaining vertex Colour that remaining vertex Perform a DFS of the tree Perform a DFS of the tree Visit each of the Nodes Visit each of the Nodes
15
Result
16
Camera Placement We have a 3-Colouring of the vertices We have a 3-Colouring of the vertices Each triangle has 3 colours assigned Each triangle has 3 colours assigned One to each of its vertices One to each of its vertices Hence each colour guards every triangle Hence each colour guards every triangle Count number of vertices having each colour Count number of vertices having each colour Place cameras on the colour with fewest vertices Place cameras on the colour with fewest vertices
17
Running Time Triangulation: O(n) Triangulation: O(n) Colouring: O(n) Colouring: O(n)
18
Psuodo-Code Guard-Gallery(P) { Triangulation of P = Triangulate(P) Colored Triangulation = ThreeColor(T(P)) Pick Smallest Color Class Return Vertices in that Color Class }
19
Variations Polygons with Holes Polygons with Holes O’Rourke O’Rourke Bjorling-Sachs and Souvaine Bjorling-Sachs and Souvaine
20
Polygon With Holes Can be guarded with Can be guarded with Join each hole to the outer edge of P Join each hole to the outer edge of P Two edges each Two edges each Best known Best known upper bound
21
Bjorling-Sachs and Souvaine Guards the polygon using point guards Guards the polygon using point guards Connect each hole by Connect each hole by adding one new vertex adding one new vertex Creating a ‘channel’ between the hole and polygon Creating a ‘channel’ between the hole and polygon Such that a triangle can guard the entire channel Such that a triangle can guard the entire channel
26
Running time: O(n 2 )
27
Conclusion We can guard a gallery using at most cameras/guards when there are no holes We can guard a gallery using at most cameras/guards when there are no holes When there are holes When there are holes We can guard a gallery using vertex guards We can guard a gallery using vertex guards If we allow point guards, we can guard the gallery with If we allow point guards, we can guard the gallery with
28
Thanks You QuestionsComments
29
Bibliography An Efficient Algorithm for Guard Placement in Polygons with Holes An Efficient Algorithm for Guard Placement in Polygons with Holes Bjorling-Sachs, Souvaine Bjorling-Sachs, Souvaine Art Gallery and Illumination Problems Art Gallery and Illumination Problems Jorge Urrutia Jorge Urrutia http://cgm.cs.mcgill.ca/~godfried/teaching/cg- projects/97/Thierry/thierry507webprj/artgallery. html http://cgm.cs.mcgill.ca/~godfried/teaching/cg- projects/97/Thierry/thierry507webprj/artgallery. html
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.