0% found this document useful (0 votes)
211 views35 pages

UNIT-3: Chromatic Number

The document discusses graph coloring and related concepts: 1. The Four Color Theorem states that every map can be colored with 4 colors. It was proved using computers by checking many graphs. 2. Graph coloring assigns colors to vertices such that no adjacent vertices share the same color. The chromatic number is the fewest colors needed. 3. Other concepts discussed include chromatic partitioning, independent sets, maximal independent sets, independence number, chromatic polynomial, matchings, and maximum matchings. Applications to scheduling, chemistry, and more are mentioned.

Uploaded by

Ch Vyna
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
211 views35 pages

UNIT-3: Chromatic Number

The document discusses graph coloring and related concepts: 1. The Four Color Theorem states that every map can be colored with 4 colors. It was proved using computers by checking many graphs. 2. Graph coloring assigns colors to vertices such that no adjacent vertices share the same color. The chromatic number is the fewest colors needed. 3. Other concepts discussed include chromatic partitioning, independent sets, maximal independent sets, independence number, chromatic polynomial, matchings, and maximum matchings. Applications to scheduling, chemistry, and more are mentioned.

Uploaded by

Ch Vyna
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 35

UNIT-3

CHROMATIC NUMBER
Four Color Theorem (Appel, Hakel, 1976):
Every map can be colored with 4 colors.

Proved using a computer.

checked almost 2000 graphs.

Robertson, Sanders, Seymour, and Thomas gave a much simpler proof 1997
(still using a computer search).

Graph Coloring
A graph coloring is a coloring of the graph vertices such that the number of pairs
of adjacent vertices shares the same color.

The chromatic number of a graph G is the smallest number of colors needed to


color the graph.

Example

UNIT-3 1
UNIT-3 2
UNIT-3 3
UNIT-3 4
Bounds on the Chromatic Number

UNIT-3 5
UNIT-3 6
Applications

UNIT-3 7
Questions:

1. What is the chromatic number of k3,3

2. is there a planar graph that cannot be colored in 5 colors?

3. what is the largest value of the chromatic number of graphs on n vertices?

4. from brooks theorem, we know that any graph of degree delta can be colored in
delta + 1 colors. But is there a 5-regular graph that cannot be colored in 5
colors?

CHROMATIC PARTITIONING
A proper coloring of a graph naturally induces a partitioning of the vertices into
different subsets.

UNIT-3 8
chromatic partitioning = {v1, v4}, {v2}, and {v3, v5}

Independent set
A set of vertices in a graph is said to be an independent set of vertices or simply an
independent set (or an internally stable set) if no 2 vertices in the set are adjacent.

{a, c, d} is an independent set

Maximal independent set


Independent set to which no other vertex can be added without destroying its
independence property. A graph can have many maximal independent sets and they
may be of different sizes

maximal independent sets = {a, c, d, f}, {b, f}, {b, g}

UNIT-3 9
UNIT-3 10
Independent sets are related to colorings
Each color in a valid coloring constitutes an independent set (but not necessarily
an MIS, and we must decide for which color to go beforehand, e.g., color 0!).

Choose all nodes of the first color. Then for any additional color, and in parallel
as many nodes as possible! (Exploit additional independent sets from coloring).

Example

UNIT-3 11
UNIT-3 12
UNIT-3 13
Independence number
The number of vertices in the largest independent set of graph G is called the
independence number (or the coefficient of internal stability.

UNIT-3 14
Chromatic polynomial
For a given graph G, the number of ways of coloring the vertices with x or fewer
colors is defined as P(G, x) and is called the chromatic polynomial of G (in terms of
x).

Examples:

G = chain of length n - 1 (so there are n vertices)


P(G,x) = x * Math.pow(x - 1, n - 1)

P(G, x) = x(x-1)(x-2)(x-3)

P(G, x) = x * Math.pow(x-1, 5)

P(G, x) = x(x − 1)2 + x(x − 1)(x − 2)2 = x4 −


4x3 + 6x2 − 3x
P (Kn, x) = xn = x(x − 1)(x − 2)...(x − n + 1)

UNIT-3 15
P (In, x) = xn where In is the graph on n Isolated vertices (no edges, called the
empty graph)

Matching
In graph theory, matching in a graph is a set of edges that do not have a set of
common vertices. In order words, a matching is a graph where each node has either
zero or one edge incident to it.
Graph matching is not to be confused with graph isomorphism. Graph isomorphism
checks if two graphs are the same whereas matching is a particular subgraph of a
graph.

The subset of edges colored red represents a matching in both graphs.

Graph matching has applications in flow networks, scheduling, and planning,


modeling bonds in chemistry, graph coloring, the stable marriage problem, neural
networks in artificial intelligence and more.
Say there is a group of candidates and a set of jobs, and each candidate is qualified
for at least one of the jobs. We can use graph matching to see if there is a way we

UNIT-3 16
can give each candidate a job they are qualified for. The graph below shows all of
the candidates and jobs and there is an edge between a candidate and each job
they are qualified for.

Is there a way to assign each person to a single job they are qualified for such that
every job has only one person assigned to it?

Definition: Given a graph G = (V, E), a matching is a subgraph of G, P where


every node has a degree of at most 1. The matching consists of edges that do not
share nodes.

Maximal matching:
A matching, P, of the graph, G, is said to be maximal if no other edges of G can be
added to P because every node is matched to another node. In other words, if an
edge that is in G and is not in P is added to P, it would cause P to no longer be a
matching graph, as a node will have more than one edge incidence to it. P is also
maximal matching if it is not a proper subset of any other matching in G; if every
edge in G has a non-empty intersection with at least one edge in P. Note that the
maximal matching is not necessarily the subgraph that provides the maximum
number of matches within a graph.

UNIT-3 17
Maximal matchings shown by the subgraph of red
edges.

Maximum matching
A matching is a maximum matching if it is a matching that contains the largest
possible number of edges matching as many nodes as possible. Simply stated, a
maximum matching is the maximal matching with the maximum number of edges.
Every maximum matching is maximal, but not every maximal matching is a
maximum matching.

In weighted graphs, sometimes it is useful to find a matching that maximizes the


weight.

Minimum weight matchings

can also be performed if the purpose of a maximal matching is to minimize the


overall weight of the graph; if the teacher in the example above asked students to
rank their best friends in ascending order.
A graph may contain more than one maximum matching if the same maximum
weight is achieved with a different subset of edges. The size, or total weight, of the
maximum matching in a graph is called the matching number.

maximum weight matchings in red color

UNIT-3 18
Example of matching problem:

1. The purpose of the stable marriage problem is to facilitate matchmaking


between two sets of people. Given a list of potential matches among an equal
number of brides and grooms, the stable marriage problem gives a necessary
and sufficient condition on the list for everyone to be married to an agreeable
match. This theorem can be applied to any situation where two vertices must be
matched together so as to maximize utility, or overall happiness.

2.

There are 6 gifts labeled (1,2,3,4,5,6) under the Christmas tree, and 5 children


receiving them: Alice, Bob, Charles, Danielle, and Edward. Can the gifts be
distributed to each person so that each one of them gets a gift they’ll like?
If none of them like any of the gifts, then the solution may be impossible and nobody
will enjoy their presents. Even if slight preferences exist, distribution can be quite
difficult if, say, none of them like gifts 5 or 6, then only 4 gifts will be have to be
distributed amongst the 5 children. On another scenario, suppose that
Alice wants gifts 1, 3.
Bob wants gifts 2, 4, 5, 6

.Charles wants gifts 2, 3.


Dot wants gifts 1, 2, 3.

Edward wants gifts 2.

UNIT-3 19
There is still no way to distribute the gifts to make everyone happy. In fact, notice
that four of the children, Alice, Charles, Danielle, and Edward, only want one of the
first three gifts, which makes it clear that the problem is impossible and one of them
will be stuck with a gift they will not enjoy.
It turns out, however, that this is the only way for the problem to be impossible. As
long as there isn't a subset of children that collectively like fewer gifts than there are
children in the subset, there will always be a way to give everyone something they
want. This is the crux of Hall's marriage theorem.

VERTEX COVER
Vertex cover sometimes called node cover, is a famous optimization problem that
uses matching. For a graph G = (V, E), a vertex is a set of vertices V' belongs to V
such that every edge in the graph has at least one endpoint that is in V'. Below are
two graphs and their vertex cover sets represented in red. Basically, a vertex cover
"covers" all of the edges.

the vertex cover above do not contain the minimum number of vertices
for a vertex cover.

Example:
An art museum is filled with famous paintings so security must be airtight. It is of
paramount importance to assure nobody can steal these expensive artworks, so the
security personnel must install security cameras to closely monitor every painting. To
determine where to place these cameras in the hallways so that all paintings are
guarded, security can look at a map of the museum and model it as a graph where
the hallways are the edges and the corners are the nodes. If there are five paintings
lined up along a single wall in a hallway with no turns, a single camera at the
beginning of the hall will guard all five paintings. This way, the security staff can
determine the vertex cover set to find out where to place the cameras.

To further improve upon the placement of cameras, the security staff can minimize
the number of cameras needed to protect the entire museum by implementing an

UNIT-3 20
algorithm called minimum vertex cover.

The vertex cover is not unique. Each set of vertices: blue, green, and red, form a
vertex cover.
A more theoretical concept relating to vertex cover is Konig's theorem that states
that for any bipartite graph, the maximum size of matching is equal to the minimum
size of vertex cover.

Question 1
Install the minimum number of antivirus system on computers to cover all
the network connections between them. A network connection between two
computers is covered if a computer at one of its endpoints has an
antivirus system.

UNIT-3 21
Question 2

Install the minimum number of antivirus system on computers to cover all


the network connections between them. A network connection between two
computers is covered if a computer at one of its endpoints has an
antivirus system.

UNIT-3 22
Question 3
Install the minimum number of antivirus system on computers to cover all
the network connections between them. A network connection between two
computers is covered if a computer at one of its endpoints has an
antivirus system.

UNIT-3 23
UNIT-3 24
Digraphs and binary relations

UNIT-3 25
UNIT-3 26
UNIT-3 27
Symmetric relation

UNIT-3 28
Reflexive relation

UNIT-3 29
Transitive relation

UNIT-3 30
UNIT-3 31
Equivalence relation

UNIT-3 32
UNIT-3 33
UNIT-3 34
UNIT-3 35

You might also like