Planarity K4 (complete)

Slides:



Advertisements
Similar presentations
Simple Graph Warmup. Cycles in Simple Graphs A cycle in a simple graph is a sequence of vertices v 0, …, v n for some n>0, where v 0, ….v n-1 are distinct,
Advertisements

Convex drawing chapter 5 Ingeborg Groeneweg. Summery What is convex drawing What is convex drawing Some definitions Some definitions Testing convexity.
Minimum Spanning Tree Sarah Brubaker Tuesday 4/22/8.
6.8 The Cheapest-Link Algorithm. The Cheapest-Link Algorithm Pick the edge with the smallest weight and mark it Pick the next edge with the smallest weight.
CSE 421 Algorithms Richard Anderson Lecture 23 Network Flow Applications.
Geometry 6-1 Properties of Polygons
POLYGONS! gone! Polly.
Drawing of G. Planar Embedding of G Chord A chord of a cycle C is an edge not in C whose endpoints lie in C.
4/17/2017 Section 8.5 Euler & Hamilton Paths ch8.5.
Drawing of G. Planar Embedding of G Proposition Proof. 1. Consider a drawing of K 5 or K 3,3 in the plane. Let C be a spanning cycle. 2. If the.
Curve Curve: The image of a continous map from [0,1] to R 2. Polygonal curve: A curve composed of finitely many line segments. Polygonal u,v-curve: A polygonal.
 The factorial function (n!)  Permutations  Combinations.
1.5 – Analyzing Graphs of Functions
Algorithmic Foundations COMP108 COMP108 Algorithmic Foundations Greedy methods Prudence Wong
ADA: 10. MSTs1 Objective o look at two algorithms for finding mimimum spanning trees (MSTs) over graphs Prim's algorithm, Kruskal's algorithm Algorithm.
More Graphs, Subgraphs and Trees Planarity and Coloring.
Chapter 4 sections 1 and 2.  Fig. 1  Not connected  All vertices are even.  Fig. 2  Connected  All vertices are even.
V Spanning Trees Spanning Trees v Minimum Spanning Trees Minimum Spanning Trees v Kruskal’s Algorithm v Example Example v Planar Graphs Planar Graphs v.
MAT 2720 Discrete Mathematics Section 8.7 Planar Graphs
Computing the Cross Product The formula to compute the cross product is a complex one when vectors are in Cartesian form: if u = [a, b, c] and v = [d,
POLYNOMIALS. MULTIPLYING POLYNOMIALS REVIEW Polynomials:
Sec. 5.1: Planarity & Coloring
Graph.
Graphs A ‘Graph’ is a diagram that shows how things are connected together. It makes no attempt to draw actual paths or routes and scale is generally inconsequential.
By Meli & Amy & Meggie & Bex. What is route inspection hmmmm??? Objective: Is to go along every single edge and end up back to where you started from.
Prims Algorithm for finding a minimum spanning tree
Graph Concepts and Algorithms Using LEDA By Caroline Moore and Carmen Frerichs (252a-at and 252a-ao) each graph in the presentation was created using gw_basic_graph_algorithms.
Minimum Spanning Trees Text Read Weiss, §9.5 Prim’s Algorithm Weiss §9.5.1 Similar to Dijkstra’s Algorithm Kruskal’s Algorithm Weiss §9.5.2 Focuses on.
Section 1-1: Relations and Functions *Relation: *Domain: *Range: *Function: Example 1: State the domain and range of each relation. Then state whether.
NON-POLYGONS POLYGONS QUESTION WHAT IS A POLYGON? 1.
Unit 3 Chinese Postman. Non - Eulerian Semi - Eulerian Eulerian.
The graph is neither Eulerian or Semi – Eulerian as it has 4 ODD vertices.
Shared Mathematics Working together (talking / sharing) Working at centres Using manipulatives Explaining / justifying Answering “How do I know?” Independent.
Representing Graphs Depth First Search Breadth First Search Graph Searching Algorithms.
Chapter 5.
CSE 373, Copyright S. Tanimoto, 2002 Graphs 2 -
Çizge Algoritmaları.
COMP108 Algorithmic Foundations Greedy methods
Redraw these graphs so that none of the line intersect except at the vertices B C D E F G H.
Graphing Linear Functions
Conventions Red edges: traversed tree edges White edges: back edges
Lecture 12 Graph Algorithms
Kruskal’s Algorithm Elaicca Ronna Ordoña. A cable company want to connect five villages to their network which currently extends to the market town of.
Jan 2007.
Combinations COURSE 3 LESSON 11-3
3.1 – Graphing Linear Equations
Applied Combinatorics, 4th Ed. Alan Tucker
Planarity Testing.
The Art Gallery Problem
The Art Gallery Problem
Quiz Review.
CSE373: Data Structures & Algorithms Lecture 12: Minimum Spanning Trees Catie Baker Spring 2015.
CSE373: Data Structures & Algorithms Lecture 20: Minimum Spanning Trees Linda Shapiro Spring 2016.
Minimum Spanning Trees
Example A cable company want to connect five villages to their network which currently extends to the market town of Avonford. What is the minimum.
Minimum spanning trees
Floyd’s Algorithm (shortest-path problem)
Four of the Best Numeracy focus: Problem solving focus:
AB AC AD AE AF 5 ways If you used AB, then, there would be 4 remaining ODD vertices (C, D, E and F) CD CE CF 3 ways If you used CD, then, there.
Minimum spanning trees
Networks Kruskal’s Algorithm
Mathematical Trickery
Area of Quadrilateral.
GRAPHS G=<V,E> Adjacent vertices Undirected graph
Bipartite graphs and Planar Graphs
Kruskal’s Algorithm AQR.
DECISION 1 “It’s obvious” “It’s easy”
EQ: What are the properties of different quadrilaterals?
Homework Solutions.
Presentation transcript:

Planarity K4 (complete) If a graph can be drawn as a polygon with diagonals, you can test for planarity. If two diagonals cross you may be able to leave one on the inside and move the other to the outside.

Perform the planarity algorithm for the Hamilton cycle ABDCEFA Example Perform the planarity algorithm for the Hamilton cycle ABDCEFA STEP 1: Identify a Hamilton cycle. A B C D E F STEP 2: Redraw the graph with the Hamilton cycle as a polygon around the outside and the other edges as diagonals. Note: The order around the vertices should be the same as the H cycle.

Perform the planarity algorithm for the Hamilton cycle ABDCEFA Example Perform the planarity algorithm for the Hamilton cycle ABDCEFA STEP 3: Write two columns for inside and outside the polygon B D Inside Outside A C BF ✔ AD ✔ DF ✔ AC ✔ DE ✔ AE ✔ F E So the graph is PLANAR ... because inside (green) lines don’t cross each other and outside (red) lines don’t cross each other.

Example Inside Outside BF ✔ AD ✔ DF ✔ AC ✔ DE ✔ AE ✔ STEP 4: Draw the planar version of the graph. Inside Outside B D BF ✔ AD ✔ DF ✔ AC ✔ DE ✔ AE ✔ A C F E So the graph is PLANAR ... because inside (green) lines don’t cross each other and outside (red) lines don’t cross each other.

Example This is the same problem but the edge CF has been added. Perform the planarity algorithm for the Hamilton cycle ABDCEFA STEP 1: Identify a Hamilton cycle. A B C D E F STEP 2: Redraw the graph with the Hamilton cycle as a polygon around the outside and the other edges as diagonals.

x Example Inside Outside BF ✔ AD ✔ DF AC ✔ DE AE CF This is the same problem but the edge CF has been added. Perform the planarity algorithm for the Hamilton cycle ABDCEFA STEP 3: Write two columns for inside and outside the polygon B D Inside Outside A C BF ✔ AD ✔ DF AC ✔ DE x AE CF F E So the graph is NOT PLANAR ... because inside (green) lines CF and DE cross each other.

Use the planarity algorithm to determine whether this graph is planar Example Use the planarity algorithm to determine whether this graph is planar STEP 1: Identify a Hamilton cycle. ABDEFGCHA H A B E F G STEP 2: Redraw the graph with the Hamilton cycle as a polygon around the outside and the other edges as diagonals. C D Note: The order around the vertices should be the same as the H cycle.

Use the planarity algorithm to determine whether this graph is planar Example Use the planarity algorithm to determine whether this graph is planar ABDEFGCHA STEP 3: Write two columns for inside and outside the polygon A B Inside Outside D H AE ✔ HB ✔ AF ✔ HD ✔ BE ✔ CF ✔ E HG C ✔ G F So the graph is PLANAR ... because inside (green) lines don’t cross each other and outside (red) lines don’t cross each other.

Example Inside Outside AE ✔ HB ✔ AF ✔ HD ✔ BE ✔ CF ✔ HG ✔ STEP 4: Draw the planar version of the graph. Inside Outside A B AE ✔ HB ✔ H D AF ✔ HD ✔ BE ✔ CF ✔ E HG ✔ C G F So the graph is PLANAR ... because inside (green) lines don’t cross each other and outside (red) lines don’t cross each other.

Use the planarity algorithm to determine whether this graph is planar Example Use the planarity algorithm to determine whether this graph is planar H A B E F G C D

Use the planarity algorithm to determine whether this graph is planar Example Use the planarity algorithm to determine whether this graph is planar ABDEFGCHA STEP 3: Write two columns for inside and outside the polygon A B Inside Outside D H E C G F