Presentation is loading. Please wait.

Presentation is loading. Please wait.

Graph Coloring.

Similar presentations


Presentation on theme: "Graph Coloring."— Presentation transcript:

1 Graph Coloring

2 Definitions A coloring of a graph G assigns colors to the vertices of G so that adjacent vertices are given different colors. The minimal number of colors required to color a graph is called the chromatic number and denoted

3 It doesn’t work! The chromatic number of this graph is 3. X X
3 is the minimum number of colors required to color this graph To verify that the chromatic number of a graph is k, we must show that the graph cannot be (k-1) colored. Try coloring with 2 colors

4 Coloring a Wheel A graph of this form is called a wheel.
In wheels with an even number of “spokes”, you can alternate colors on the outside, then add an additional color for the center vertex. As is seen in this wheel with 6 spokes, a wheel with an even number of spokes can be 3-colored. In wheels with an odd number of spokes, it’s not possible to alternate colors on the outside, so there must be 3 colors on the outside and then an additional color for the center vertex, thus the chromatic number is 4.

5 Example 1 State legislature many committees Meet one hour each week
Schedule meetings that minimize number of hours Two committees cannot meet at the same time if they have overlapping membership 10 committees Vertices = Committees Edges = Overlap in membership Colors = Different meeting times

6 Solution to Example 1 To model this problem, we can use a vertex for each of the committees and an edge joining 2 vertices if they represent committees with overlapping membership. Then we can color the graph with each color representing a different meeting time.

7 The chromatic number of this graph is 4, thus 4 meeting times will suffice to schedule committee meetings without conflict. We can check this by trying to color the graph with n-1 colors, 3 colors, and it will not work.

8 If we consider this part of the graph as a wheel with 6 spokes, we know it must be 3-colored.
Thus, these two vertices can’t be red or blue, but they also cannot be the same color as each other. The final vertex then can be red or blue.

9 Chromatic Polynomials
The chromatic polynomial of a graph G gives a formula for the number of ways to properly color G with k colors. Example What is the chromatic polynomial of a complete graph on five vertices?

10 Solution In a complete graph, each vertex must be a different color. Thus since there are k possible choices for the first vertex to be colored; then that color cannot be used again, and so the second vertex has k-1 choices, and so on.

11 Deletion Contraction Method
- = Delete an edge Combine -

12 Deletion Contraction Cont.
Example: Use deletion contraction method to find the chromatic polynomial of the following graph.

13 - = - -( - ) = - -( - - )-( -( - = ))

14 Exercise Set up A set of solar experiments is to be made at observatories. Each experiment begins on a given day of the year and ends on a given day (each experiment is repeated for several years). An observatory can perform only one experiment at a time. The problem is, What is the minimum number of observatories required to perform a given set of experiments annually? Model this scheduling problem as a graph-coloring problem

15 Problem Vertices = Experiment Edges = Overlapping time interval
Colors = Observatories needed Experiment A Sept. 2 to Feb. 3 Experiment B Oct. 15 to April 10 Experiment C Nov 20 to Feb 17 Experiment D Jan. 23 to May 30 Experiment E April 4 to July 28 Experiment F April 30 to July 28 Experiment G June 24 to Sept. 30

16 The chromatic number is 4, so there are 4 observatories needed.
Solution A B C D E F G The chromatic number is 4, so there are 4 observatories needed.


Download ppt "Graph Coloring."

Similar presentations


Ads by Google