Upload
dangnhan
View
224
Download
0
Embed Size (px)
Citation preview
RAINBOW CONNECTION NUMBER OF GRAPHPOWER AND GRAPH PRODUCTS
A Thesis
Submitted For the Degree of
Master of Science (Engineering)
in the Faculty of Engineering
by
Arunselvan. R
Computer Science and Automation
Indian Institute of Science
BANGALORE – 560 012
November 2011
Acknowledgements
First of all, I would like to thank my advisor Dr. L. Sunil Chandran for all the help and
support. I sincerely thank you for guiding me through my formative years in research.
I would like to thank my friends from the theory lab - Subramanya, Deepak, Manu,
Jasine, Rogers, Abhijit, Abhijin and others; who were a part and parcel of my life in the
institute. Learning had never been so much fun before. I was able to lead a balanced
life thanks to you folks. I remember discussions on both Cantor functions and Bach’s
partitas with the same fondness. I deeply appreciate all of your love and encouragement.
I would also like to thank all the non-teaching staff members of our department due to
whose hard work we have a smooth academic life. I would like to thank Dr. Y. Narahari
for those wonderful words of wisdom and encouragement. Finally, I would like to thank
Dr. Ashok Rao who has been a constant support throughout.
i
Abstract
The minimum number of colors required to color the edges of a graph so that any two
distinct vertices are connected by at least one path in which no two edges are colored
the same is called its rainbow connection number. This graph parameter was introduced
by Chartrand et al. in 2008. The problem has garnered considerable interest and
several variants of the initial version have since been introduced. The rainbow connection
number of a connected graph G is denoted by rc(G). It can be shown that the rainbow
connection number of a tree on n vertices is n− 1. Hence |G| − 1 is an upper bound for
rc(G) of any non-trivial graph G. For all non-trivial, bridge-less and connected graphs G,
Basavaraju et al. showed that rc(G) can be upper-bounded by a quadratic function of its
radius. In addition they also proved the tightness of the bound. It is clear that we cannot
hope to get an upper-bound better than |G| − 1 in the case of graphs with bridges. An
immediate and natural question is the following: Are there classes of bridge-less graphs
whose rainbow connection numbers are linear functions of their radii? This question is
of particular interest since the diameter is a trivial lower bound for rc(G). We answer
in affirmative to the above question. In particular we studied three (graph) product
operations (Cartesian, Lexicographic and Strong) and the graph powering operation.
We were able to show that the rainbow connection number of the graph resulting from
any of the above graph operations is upper-bounded by 2r(G) + c, where r(G) is radius
of the resultant graph and c ∈ {0, 1, 2}.
ii
Contents
Acknowledgements i
Abstract ii
1 Introduction 11.1 Rainbow Coloring: An Overview . . . . . . . . . . . . . . . . . . . . . . . 11.2 Graph Operations and Rainbow Coloring . . . . . . . . . . . . . . . . . . 151.3 Our Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
2 Preliminaries and Definitions 19
3 Graph Operations: An Introduction 223.1 The k − th Powering of a Graph H . . . . . . . . . . . . . . . . . . . . . 223.2 The Cartesian Product of Two Graphs, G′ and H ′ . . . . . . . . . . . . . 233.3 The Lexicographic Product of Two Graphs G′ and H . . . . . . . . . . . 253.4 The Strong Product of Two Graphs G′ and H ′ . . . . . . . . . . . . . . . 26
4 Rainbow Connection Number of Graph Power and Graph Products 284.1 Rainbow Connection Number of the k-th Power of a Graph H . . . . . . 284.2 Rainbow Connection Number of the Cartesian Product of Two Graphs G′
and H ′ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314.3 Rainbow Connection Number of the Lexicographic Product of Two Non-
Trivial Graphs G′ and H . . . . . . . . . . . . . . . . . . . . . . . . . . . 344.4 Rainbow Connection Number of the Strong
Product of Two Non-Trivial, ConnectedGraphs G′ and H ′ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Bibliography 50
iii
Chapter 1
Introduction
1.1 Rainbow Coloring: An Overview
Let G be a non-trivial, connected graph and let c : E(G) → {1, 2, . . . , k} be an edge
coloring of G such that adjacent edges may be given the same color. We say that G is
rainbow colored with respect to the edge coloring c, if every pair of vertices are connected
by a rainbow path. A rainbow path with respect to an edge coloring is a path in G such
that no two edges of the path are colored using the same color. The least number of
colors required to rainbow color G is called the rainbow connection number of G and is
denoted by rc(G).
We familiarize ourselves with the concept by working with a few simple and small
graphs. Let G be a non-trivial, complete graph on n vertices i.e. G = Kn. Let f be
an edge coloring of G that colors every edge of G using the same color. Given any two
vertices u, v ∈ V (G), the edge (u, v) ∈ E(G) is a trivial rainbow path between them.
Thus we can say that f is a valid rainbow coloring of G. Since f uses just one color
to edge-color G(= Kn), we have that rc(Kn) = 1 for any n ≥ 2. As our next example
we consider a path, Pn, on n vertices. Let f be an edge coloring of Pn using < n − 1
number of colors. Observe that the end vertices of Pn cannot be rainbow connected with
respect to f . Hence f is not a valid rainbow coloring of Pn. Thus we can say that any
1
Chapter 1. Introduction 2
valid rainbow coloring of Pn must use at least n− 1 colors i.e. rc(Pn) ≥ n− 1. But if we
color all the edges of a graph distinctly then it is a trivial rainbow coloring of the graph.
Hence rc(Pn) = n − 1. An immediate generalization of a path is a tree. Is the rainbow
connection number of a tree also n − 1? where n is the number of vertices in the tree.
We return to this question later in this section. As a final example consider G = K1,n,
a star graph on n+ 1 vertices and n edges. It can be verified that rc(K1,n) = n.
Let us compare the rainbow connection numbers of the graphs considered hitherto to
their chromatic indices (edge chromatic numbers). We know that rc(Kn≥2) = 1 while
χ′(Kn≥2) ≥ n− 1. Given a path, Pn, we know that rc(Pn) = n− 1 while χ′(Pn) = 2. In
the case of a star graph, K1,n, we have that χ′(K1,n) = rc(K1,n) = n. In general we
may conclude that the rainbow connection number and the chromatic index of a graph
need not be related.
The aim of this section is to present an overview of the evolution of the problem
and the associated concepts. We also discuss a few interesting variants of the problem.
Since the results are numerous, we do not list them all. A more exhaustive survey has
been done by Li et al. [3]. There the results are discussed in considerable depth. For
an introduction to rainbow connection number the reader is referred to the book by
Chartrand and Zhang [4].
Rainbow coloring of was first introduced by Chartrand et al. in 2008 [5]. In the same
paper they introduced a variant called the strong rainbow connection number of a graph.
Let G be a non-trivial, connected graph and let f be an edge coloring of G. We say that
G is strongly rainbow colored with respect to the edge coloring f if every pair of vertices,
u and v, are connected by a rainbow path of length distG(u, v) (distance between u and
v in G). The minimum number of colors required to strongly rainbow color a graph is
called the strong rainbow connection number and is denoted by src(G). Since any strong
rainbow coloring of G is also a valid rainbow coloring of it, the following relation holds:
rc(G) ≤ src(G). We know that ∃ u, v ∈ V (G) such that distG(u, v) = diam(G). Hence
Chapter 1. Introduction 3
the diameter is a trivial lower bound for the rainbow connection number. We thus have
that diam(G) ≤ rc(G) ≤ src(G).
Let G be any non-trivial, connected graph. Let G′ be a connected, spanning subgraph
of G. Let f be a rainbow coloring of G′. Any edge e ∈ E(G)\E(G′) is arbitrarily colored,
only using colors used by f . This coloring is a rainbow coloring of G, hence we have that
rc(G) ≤ rc(G′). Given a tree T and a rainbow coloring fT of T , we claim that fT uses
|T | − 1 number of colors. The proof of the claim involves arguing that if lesser number
of colors are used then there exist a pair of vertices that are not rainbow connected. A
simple implication of the claim is that rc(G) ≤ |G| − 1. Suppose all the edges of G are
colored distinctly then G is trivially both rainbow colored and strongly rainbow colored.
Hence we have the following trivial upper bound, rc(G) ≤ src(G) ≤ |E(G)|. It may be
noted that the equality holds only when G is a tree.
We now mention a few results by Chartrand et al. [5]. They characterized non-trivial
graphs that have rainbow connection numbers of 1, 2 and m, where m is the number of
edges in the given graph. Specifically they showed that rc(G) = 1 if and only if G is a
complete graph, rc(G) = 2 if and only if src(G) = 2 and rc(G) = m if and only if G
is a tree. They studied also rc and src of special classes of graphs. They showed that
rc(Cn) = src(Cn) =⌈n2
⌉for n ≥ 4, where Cn is a cycle on n vertices. A wheel graph,
Wn is a graph with n + 1 vertices and 2n edges. It contains a cycle on n vertices, Cn,
and a universal vertex that is connected to all the vertices of Cn. They showed that
rc(W3) = 1, rc(Wn) = 6 for 4 ≤ n ≤ 6 and rc(Wn) = 7 for n ≥ 7. They also showed that
src(Wn) =⌈n3
⌉for n ≥ 3. Given a complete bipartite graph, Ks,t, such that 1 ≤ s ≤ t,
they showed that src(Ks,t) =⌈
s√t⌉. They also find the src of complete k-partite graphs,
G = Kn1,n2,...,nk, where k ≥ 3 and n1 ≤ n2 ≤ · · · ≤ nk. Let s = Σk−1
i=1 ni and t = nk, then
they show the following: src(G) = 1 if nk = 1, src(G) = 2 if nk ≥ 2 and s > t and
src(G) =⌈
s√t⌉
if s ≤ t.
Chapter 1. Introduction 4
Another question answered by Chartrand et al. is the following: Given integers a and
b does there exist a graph, G, such that rc(G) = a and src(G) = b? They were able to
show that for a pair of integers a and b such that a ≥ 4 and b ≥ (5a− 6)/3 there exists
a connected graph G such that rc(G) = a and src(G) = b. They do so by explicitly
constructing a graph whose rc and src is a and b respectively. In addition to proving
several theorems they also made certain important conjectures. As observed earlier
rc(G) ≤ rc(H) when H is a spanning subgraph of G. But it is not immediately clear if
an analogous result would follow in the case of strong rainbow connection number. They
conjectured that src(G) ≤ src(H) where H is a connected, spanning subgraph of G. If
the conjecture is proved right then it follows that diam(G) ≤ rc(G) ≤ src(G) ≤ n − 1.
Unfortunately the conjecture was disproved by Chakraborty et al. [6]. We discuss this
briefly along with other results from the paper ([6]) later in this section.
Let G be a non-trivial, connected graph. Consider the following (natural) generaliza-
tion: Can we color the edges of G so that any two distinct vertices are connected by
k(≥ 1) edge disjoint rainbow paths? Such a coloring is called a rainbow k-coloring of G.
The minimum number of colors required to rainbow k-color a graph is called the rainbow
k-connection number of the graph and is denoted by rck(G). Note that if we color all the
edges of G distinctly, then such a coloring is a rainbow k-coloring for all 1 ≤ k ≤ κ(G).
It follows from definitions that rc(G) = rc1(G).
Let G be a non-trivial, connected graph on n vertices and let c be an edge coloring
of G such that adjacent edges may be given the same color. The following variant
was introduced by Chartrand, Okamoto and Zhang [14]. The edge coloring c is called
a k-rainbow coloring of G, for some 2 ≤ k ≤ n, if for every S ⊆ V (G) such that
|S| = k there exists a rainbow tree, T ⊆ G, such that S ⊆ V (T ) ⊆ V (G). Note that a
rainbow tree is a tree that is rainbow colored, i.e. all the edges of the tree are colored
distinctly. The minimum number of colors required to k-rainbow color G is called the
k-rainbow connection number of G and is denoted by rxk(G). It is not hard to see that
rx2(G) = rc(G) and that diam(G) ≤ rx2(G) ≤ rx3(G) ≤ . . . ≤ rxn(G) ≤ n − 1. Also
Chapter 1. Introduction 5
note that if G is k-rainbow colored by the edge coloring c, for some 2 ≤ k ≤ n, then no
two bridges of G (if any) will be colored the same. This simple observation implies that
no two bridges are colored the same by any rainbow coloring of G.
Rainbow coloring has a number of practical applications as explained by Li et al. [3].
We explain a couple of them here. Consider the following scenario: There is a network
of government agencies that wish to communicate “classified information” with each
other. Now if any two agencies, say A and B, have a direct communication link between
them, they could communicate directly. But maintaining a communication link between
every pair of agencies is often expensive since the “agency network” is typically large.
In practice only critical communication links are maintained and agencies communicate
by forwarding messages via other agencies in the network. The agency network can be
modeled as a graph whose vertex set corresponds to the set of government agencies and
any two vertices are connected by an edge if and only if the corresponding agencies have a
direct communication link between them. Suppose agency A wants to send a message to
agency B it does so by forwarding the message via agencies along some path connecting
A and B in the agency network. If the communication links are unprotected then enemies
on the prowl can intercept these messages. As the distance between two communicating
agencies in the agency network increases, the risk of the message being intercepted
by enemies increases proportionally since the message is “exposed” for a longer period
of time. To overcome this problem the government agencies encrypt messages before
transmitting. If a single encryption key is used by all agencies to transmit messages then
all messages transmitted will have the same level of security. Ideally it is desirable that
messages that are exposed longer be provided with a higher level of security. An easy
solution is to associate a unique encryption key with each communication link. When
an agency wishes to forward a message through some communication link, it does so by
first encrypting the message using the associated encryption key followed by forwarding
it through the link. This system provides the highest level of security possible to all
messages. Note that when agency A sends a message to agency B along a path of
Chapter 1. Introduction 6
length k there would be k levels of encryption added to the message. Moreover the
message would be encrypted using k different keys i.e. messages are provided with a
level of security that is proportional to the duration of exposure. The problem with the
aforementioned solution is that the cost of maintaining such an agency network can be
very high, especially if size of the agency network is very large. Let us assume that the
government expects this mode of security to be implemented. What is the minimum
no of keys required to implement it? The minimum number of keys required to secure
the agency network is exactly equal to the rainbow connection number of the agency
network.
Another interesting application as explained by Li et al. [3] is in the field of communi-
cations. Consider some communications network such as a cellular network. Suppose we
wish to route messages between vertices in the network with an additional constraint that
each link in the route be assigned a distinct channel (frequency channel). However we
want to minimize the number of distinct channels used in this communication network.
The number is exactly given by the rainbow connection number of the communications
network.
Caro et al. [7] studied the extremal graph theoretic behavior of rainbow connection
number. They observed that there existed graphs of order n with minimum degree 2
and rainbow connection number of n − 3. They construct the following example: Take
two vertex-disjoint triangles and connect them by a path of length n− 5. Note that this
graph has a minimum degree of 2 and a rainbow connection number of n − 3. As we
already know the rainbow connection number of a clique is 1. Caro et al. believed that
the rainbow connection number was inversely proportional to the minimum degree and
started studying the rainbow connection number of a graph with respect to its minimum
degree (δ(G)).
Caro et al. asked the following question: Is it true that a minimum degree of atleast
3 ensures that rc(G) ≤ αn, where α < 1 and is independent of n? They answer in
Chapter 1. Introduction 7
affirmative to the question. Specifically they were able to prove that for a graph G on n
vertices with δ(G) ≥ 3, the rainbow connection number, rc(G) < 5n/6. They observed
that the constant - 5/6 appearing in the proof of the theorem was not optimal. They
noted that there are 3-regular connected graphs with rc(G) = diam(G) = (3n − 10)/4
and hence concluded that the least constant that could replace 5/6 would be 3/4. They
conjectured that if δ(G) ≥ 3 then rc(G) < 3n/4. This conjecture was proved right by
Chandran et al. in [9] as a corollary of a more general result. We discuss the results
of Chandran et al. [9] later in this section. Caro et al. go on to provide a specialized
theorem that improves the result (5n/6 upper-bound) in most cases. The statement
of the theorem is as follows: Let G be a connected graph on n vertices. Assume that
there is a set of vertex-disjoint cycles that cover all but s vertices of G. Then rc(G)
< 3n/4 + s/4 1/2. In particular they show the following: (a) If G has a 2-factor then
rc(G) < 3n/4 (b) If G is k-regular and k is even then rc(G) < 3n/4 (c) If G is k-regular
and χ′(G) = k then rc(G) < 3n/4. They related the rainbow connection number of
a graph to its minimum degree in the following result. If G is connected graph on n
vertices with minimum degree δ(G) then rc(G) ≤ min{ n lnδδ
(1 + oδ(1)), n4lnδ+3δ}. They
commented that they did not know if the bound was tight. However they observed that
there were connected graphs with order n and minimum degree δ and diameter 3nδ+1−
δ+7δ+1
which they noted would be the best possible bound.
Let G be a connected, non-trivial graph. Caro et al. gave sufficient conditions for the
rainbow connection number of a graph to equal 2. As noted earlier, having a diameter of 2
is certainly the necessary condition for rc(G) = 2 but is insufficient (diam(K1,n) = 2 and
rc(K1,n) = n). Clearly if δ(G) ≥ n/2 and G is not a complete graph then diam(G) = 2.
Does this minimum degree requirement guarantee that rc(G) = 2? They found that by
slightly increasing the minimum degree requirements the required result was obtained.
Specifically they show that any non-complete graph, G, with δ(G) ≥ n/2 + log n has
rc(G) = 2.
Chapter 1. Introduction 8
The property - rc(G) ≤ 2, is a monotone graph property, since adding edges to a
graph does not increase its rainbow connection number. Let G(n, p) denote the random
graph as defined in the Erdos-Renyi Random Graph Model. Caro et al. showed that p
=√
log n/n is a sharp threshold function for the property rc(G(n, p)) ≤ 2. They also
studied the rainbow connection number of 2-connected graphs, the first step in relating
the connectivity of a graph to its rainbow connection number. They were also able to
prove that any 2-connected graph G on n vertices has rc(G) ≤ n/2 +O(√n). They
prove some minor results like: If G is a connected graph with minimum degree δ then
rc(G) ≤ n− δ.
As we already know, the rainbow k-connectivity is a generalization of rainbow con-
nectivity. He and Liang [24] were able to show that for every fixed integer d ≥ 2
and every k ≤ O(log n), p = (logn)1/d
n(d−1)/d is a sharp threshold function for the property
rck(G(n, p)) ≤ d. Note that this generalizes the result of Caro et al., which provides a
sharp threshold function for the property: rc1(G(n, p)) ≤ 2.
The log factor in the upper bound derived by Caro et al. (relating rc and δ) seemed to
be dispensable. Krivelevich et al. [8] studied this problem and asked if rc(G) ≤ Cn/δ is
possible, where C is a universal constant. If this were possible then rc(G) ∈ O(1) when
δ ∈ θ(n). In the paper by Krivelevich et al., among other results, they proved that for a
connected graph G on n vertices, the rc(G) ≤ 20n/δ(G). They commented that 20 was
certainly not the best achievable factor and speculated that the best achievable would
be 3. The result however proved the speculation that rainbow connection number of the
graph was inversely proportional to its minimum degree.
In the same paper, Krivelevich et al. [8] introduced the “vertex-version” of the rain-
bow connection problem called the rainbow vertex-connection problem. Consider a non-
trivial, connected graph G. Let f be a vertex coloring of G such that adjacent vertices
may be colored the same. We say that G is rainbow vertex-colored with respect to f
if every pair of vertices are connected by a path such that all the internal vertices of
Chapter 1. Introduction 9
the path are distinctly colored. The minimum number of colors required to rainbow
vertex-color a graph is called its rainbow vertex-connection number and is denoted by
rvc(G). It can be shown that rvc(Kn) = 0 for n ≥ 1. Now, we calculate the rainbow
vertex-connection number of a few simple graphs. Let T be a tree with n ≥ 3 vertices
and l leaves. We define a vertex coloring, f , of T as follows: Color all the internal
vertices of T distinctly; color all its leaves uniformly using a color already used to color
an internal vertex. Note that the vertex coloring, f , thus defined is both valid and
consistent. The coloring function f uses n − l colors in total. We claim that this is a
proper rainbow vertex-coloring of T . To see this, first observe that the path between
any two vertices of T does not contain a leaf as an internal vertex. Secondly, no two
non-leaf vertices are colored the same. Hence it follows that f is indeed a valid rainbow
vertex-coloring of T and rvc(T ) ≤ n − l. Let v1 and v2 be two distinct cut vertices of
some non-trivial, connected graph G. Observe that any valid rainbow vertex-coloring of
G colors v1 and v2 distinctly. This means that all the internal vertices of a tree must
be colored distinctly. Since the leaves are colored by f only using colors already used to
color the internal vertices of T , we have that rvc(T ) = n − l. We can upper-bound the
rainbow vertex-connection number of any non-trivial tree, T , by |T | − 2. Let Pn(≥2) be
a path on n vertices, then it can be shown that rvc(Pn) = n − 2. This example shows
that the upper-bound is tight. It follows that for any non-trivial, connected graph G, we
have rvc(G) ≤ |G| − 2. Also note that diam(G)− 1 is a trivial lower bound for rvc(G).
Observe that rc(K1,n) = n while rvc(K1,n) = 1, similarly rc(T ) = |T | − 1 while
rvc(T ) ≤ |T | − 2 (T is a tree). This is a natural question that follows: Is the rainbow
vertex-connection number of a graph always lesser than its rainbow connection number?
As it turns out, that is not always the case. Krivelevich et al. [8] constructed the
following graph, G, to illustrate the point: Take n vertex-disjoint triangles and designate
one vertex from each as “special”. Add a complete graph on the special vertices. Observe
that G has n cut-vertices, hence rvc(G) ≥ n. Consider the following vertex coloring,
f , of G: Any two cut vertices u and v are such that f(u) 6= f(v); all the remaining
Chapter 1. Introduction 10
vertices (non-cut vertices) of G are arbitrarily colored using previously used colors. Note
that f is valid rainbow vertex-coloring of G using n colors. We have thus shown that
rvc(G) = n. If we show that rc(G) ≤ 4 then this example lays the question to rest. To
do this we define an edge coloring function, f1, that rainbow colors G using 4 colors,
say {c1, c2, c3, c4}. Function f1 colors all the edges of the clique on “special” vertices
using color c1. It is now left to color the edges of the n triangles. Function f1 colors
the edge connecting two non-special vertices of a triangle using c2. The remaining two
edges of the triangle are colored c3 and c4 respectively in some order. It can be verified
that f1 is a valid rainbow vertex-coloring of G. This means that there is no upper bound
for one as a function of the other. However they were able to find an upper bound for
the rainbow vertex-connection number of a graph as a function of its minimum degree
(inversely proportional). Specifically they were able to show that a connected graph G
on n vertices has rvc(G) < 11n/δ(G).
Caro et al. [7] conjectured that computing the rainbow connection number of a graph
would be a NP-Hard problem and deciding if the rainbow connection number of a graph
was 2 would be a NP-Complete problem. Such algorithmic and computational aspects
of rainbow coloring were first tackled by Chakraborty et al. [6]. Given a graph G,
they were able to prove that deciding whether rc(G) = 2, is NP-Complete [6]. In
particular, computing rc(G) is NP-Hard. Here we present an overview of the reductions
involved in proving the NP-Completeness of deciding whether rc(G) = 2. They first show
that the Rainbow Connectivity 2 problem is computationally equivalent to the Subset
Rainbow Connectivity 2 problem. Then they show that the Subset Rainbow Connectivity
2 problem is computationally equivalent to the Extending to Rainbow Connectivity 2
problem. To complete the proof they reduce 3-SAT problem to Extending to Rainbow
Connectivity 2 problem in polynomial time. In the above set of reductions, Rainbow
Connectivity 2 asks for a 2-edge-coloring in which all vertex pairs have a rainbow path
connecting them; Subset Rainbow Connectivity 2 asks for a 2-edge-coloring in which
every pair of vertices in a given subset of pairs has a rainbow path connecting them;
Chapter 1. Introduction 11
Extending to Rainbow Connectivity 2 asks whether a given partial 2-edge-coloring can
be completed to obtain a rainbow connected graph.
Suppose we are given an edge coloring of G using a constant number of colors, checking
whether this is a valid rainbow coloring can be done in polynomial time. However we
know that the number of colors required to rainbow color G may be in the order of
G. In the general case, is there a polynomial time algorithm to check if a given edge
coloring of G is a valid rainbow coloring? Chakraborty et al. [6] proved that: Given an
edge-colored graph G, deciding whether the given coloring makes G rainbow connected
is NP-Complete. Their proof involves showing that the s-t version of the problem is
NP-Complete by a reduction from the 3-SAT problem. The s-t version of the problem
asks the following: Given two vertices s and t of an edge-colored graph, decide whether
there is a rainbow path connecting them.
Given a graph G on n vertices, recall that Caro et al. [7] proved that rc(G) is at most
2 if its minimum degree is slightly greater than n/2. Does this mean that there exist
graphs whose minimum degrees are exactly n/2 while their rainbow connection numbers
are arbitrarily high? In general what can we say about the rainbow connection number
of a graph whose minimum degree is in Θ(n). Chakraborty et al. proved that for every
δ > 0 there exists a constant C = C(δ) such that for a connected graph G on n vertices
with a minimum degree of at least δn, the rainbow connection number rc(G) ≤ C. For
a fixed δ, they provide a polynomial time algorithm that colors G using at most C(δ)
number of colors. We already know that the diameter of a graph is a trivial lower bound
for its rainbow connection number. This lower bound is often inadequate as there are
graphs with small diameters and large rainbow connection numbers, the star graph is
an excellent example to illustrate the point. The star graph on n+ 1 vertices, K1,n, has
a diameter of 2 while its rainbow connection number is n. Observe that the minimum
degree is very small, it is just 1. Chakraborty et al. asked the following question: Given
a graph G on n vertices with a diameter of 2, what should the minimum degree of G
be, in order to ensure that rc(G) ≤ 3? They found that the minimum degree must be
Chapter 1. Introduction 12
at least 8 log n to ensure this. In the same paper they claim that a uniformly random
3-edge-coloring of G is a rainbow coloring of it, with high probability. They also claim
that such a coloring can be found by a polynomial time deterministic algorithm. A direct
implication of the theorem is that any graph with minimum degree at least n/2 has a
rainbow connection number of at most 3.
Ingo Schiermeyer [13] proved that graphs with minimum degree 3 have a rainbow
connection number of < 3n/4, thereby proving the conjecture of Caro et al. In the same
paper, which was presented in IWOCA 2009, Ingo Schiermeyer motivates the following
problem: For every k ≥ 2 find a minimal constant ck with 0 < ck ≤ 1 such that
rc(G) ≤ ckn for all graphs G with minimum degree δ(G) ≥ k. Is it true that ck = 3k+1
for
all k ≥ 2? Among the questions asked by the audience at IWOCA 2009, as compiled by
Schiermeyer, the following asked by Jack Edmonds is particularly interesting − What is
the complexity of deciding whether a given edge-colored graph G has a rainbow spanning
tree?
The problem motivated by Ingo Schiermeyer was solved by Chandran et al. [9] using
what the authors claim to be a “weak strengthening” of ideas used by Krivelevich et al.
[8]. Here we merely state the three main results proved in this paper [9]. For details and
definitions the readers are referred to Chandran et al. [9]. If D is a connected two-way
dominating set in a graph G, then rc(G) ≤ rc(G[D]) + 3, where G[D] is a subgraph of G
that is induced by D. They go ahead and prove a generalization of this result which turns
out to be a vital link in proving Schiermeyer’s conjecture. Specifically, they show: if D is
a connected, two-way, two-step dominating set in a graph G, then rc(G) ≤ rc(G[D])+6.
For any graph G with minimum degree δ, the connected, two-way, two-step dominating
set is of size at most 3nδ+1− 2. This implies that rc(G) ≤ 3n
δ+1+ 3. Observe that D can
be colored using at most 3nδ+1− 2 − 1 colors. Therefore G can be colored using at most
3nδ+1−3+6 colors. They also observe that the radius of any connected graph is at most k
more than the radius of its k-step connected dominating set. Since the radius of D is at
most |D|/2, the radius of G, r(G) ≤ 3n2(δ+1)
+ 1. This bound is a marginal improvement
Chapter 1. Introduction 13
over 3(n−3)2(δ+1)
+ 5 found by Erdos, Pach, Pollack and Tuza in 1989.
Chandran et al. [9] also present bounds for the rainbow connection number of a
few graph classes. All the bounds presented are linear functions of the corresponding
diameters. Here is concise list of the results. If G is an interval graph then diam(G)
≤ rc(G) ≤ diam(G) + 1. If G is AT -free then diam(G) ≤ rc(G) ≤ diam(G) + 3. If G
is a threshold graph then diam(G) ≤ rc(G) ≤ 3. If G is a chain graph then diam(G) ≤
rc(G) ≤ 4. If G is a circular arc graph then diam(G) ≤ rc(G) ≤ diam(G) + 4. If G
is a bridge-less chordal graph, then rc(G) ≤ 3r(G). Moreover, there exists a bridge-less
chordal graph with rc(G) = 3r(G). If G is a unit interval graph such that δ(G) ≥ 2,
then rc(G) = diam(G).
We know that arbitrarily increasing the number of edges in a graph does not necessarily
decrease its rainbow connection number. This may happen due to the presence of large
“tree-like” subgraphs. Let G be a non-trivial, connected graph. Kemnitz et al. [15]
asked the following question: What should be the minimum size of |E(G)| to ensure that
rc(G) ≤ k, where k ∈ {1, 2, . . . , n−1}. They were able to show that if |E(G)| ≥(n−k+1
2
)+(k − 1) then rc(G) ≤ k.
Li and Sun [16] investigated the following problem: Can we bind the rainbow con-
nection number of a graph by placing constraints on the structure of its complement?
They were able show the following: Let G be a connected, non-trivial graph. If G is
such that diam(G) = 2, 3 and it contains exactly two connected components such that
one of them is trivial, then rc(G) ≤ 4. If graph G is triangle free, then they show that
rc(G) ≤ 6. Note that if G is triangle free then G is claw free. In general a complement
of a graph need not be connected even if the original graph was connected. Now, if both
the graph and its complement are connected then can we find bounds for the sum −
rc(G) + rc(G)? Chen et al. [17] proved that 4 ≤ rc(G) + rc(G) ≤ n + 2 if G, G are
connected and |G| ≥ 4. Furthermore the upper bound was shown to be sharp for |G| ≥ 4
while the lower bound was shown to be sharp for |G| ≥ 8.
Chapter 1. Introduction 14
Let G be a connected, non-trivial graph. The line graph of G, denoted by L(G),
is defined as follows: V (L(G)) = E(G) and any two vertices of L(G), say e1 and e2,
are adjacent if and only if the corresponding edges are adjacent in G. It is easy to see
that the line graph of a line graph i.e. L(L(G)) need not be isomorphic to the original
graph G. Hence we may iterate as many times as we want (to get possibly different
graphs for each i) i.e. Li(G) = L(Li−1(G)), where i ≥ 2 and L1(G) = L(G). Li and
Sun [18, 19] studied the rainbow connection number of line graphs and iterated line
graphs. We briefly describe a few terminologies used in [18, 19] that are necessary
to understand the statement of the theorem. Given a graph G, if every block of G is
a maximal clique then G is called a clique-tree-structure. If each maximal clique is a
triangle then G is called a triangle-tree-structure. They prove the following: For any set
T of t edge-disjoint triangles of a connected graph G, if the subgraph induced by the
edge set E(T ) is a triangle-tree-structure then rc(G) ≤ n2− t, where n2 is the number of
vertices of G with a degree of at least 2. If T is a set of t edge-disjoint triangles that cover
all but n′2 inner vertices (degree ≥ 2 vertices) of G and c is the number of components
of the induced subgraph G[E(T )], then rc(L(G)) ≤ t+ n′2 + c. They also show that for
connected graphs G with m edges and m1 pendant 2-length paths, rc(L2(G)) ≤ m−m1.
They also prove the tightness of the above bounds.
In the beginning of this section we saw the definition of the strong rainbow connection
number. Now we look at a few results related to strong rainbow coloring. Let G be a
connected, non-trivial graph with n vertices and m edges. Observe that m is a trivial
upper bound for src(G), the strong rainbow connection number of G. In general strong
rainbow coloring is more challenging. Li and Sun [21] were able to show that src(G) ≤
m − 2t, where t is the number of edge disjoint triangles in G. They construct a class
of graphs such that src(G′) = m − 2t for any graph G′ in the graph class. They also
prove that any graph whose rainbow connection number equals m− 2t should belong to
the graph class constructed. This way they characterized graphs with strong rainbow
connection number of m − 2t. Similarly Li and Sun characterized graphs whose strong
Chapter 1. Introduction 15
rainbow connection number is 6= m − 1 and = m − 2. Recall that if src(G) = |E(G)|
then G has to be a tree.
1.2 Graph Operations and Rainbow Coloring
In this section we try to explain why studying the important graph operations such
as the various graph product operations and the graph powering operation is relevant in
relation to rainbow coloring. Given a graph G, we know that rc(G) ≥ diam(G) ≥ r(G).
The question is, can the upper bound for rc(G) deviate arbitrarily from the lower bound?
If so, are there plenty of graph classes whose rainbow connection numbers are arbitrarily
large? Consider the star graph on n+1 vertices, K1,n. It has a radius of 1 and a diameter
of 2, while rc(K1,n) = n, where n can be arbitrarily large when compared to the radius
(diameter). Suppose r ≥ 1 is fixed, then do there exist graphs such that their radius
is r and their rainbow connection number is incomparable to r? Given a pair (r, rc)
such that rc ≥ r ≥ 1 if we are able to construct a graph such that it has a radius of r
and a rainbow connection number of rc, then we have provided an affirmative answer to
the above question. Given a fixed pair (r, rc) we construct the graph G as follows: Let
rc = nr + a, where 0 ≤ a ≤ r − 1 and n ≥ 0. Let G = K1,n if a = 0 else let G = K1,n+1.
Subdivide n edges of G such that each edge is a path of length r. Subdivide the last
edge (if it exists) into a path of length a. Observe that the resultant graph is a tree
on rc + 1 vertices with a radius of r. The resultant graph has a rainbow connection
number of rc as demanded. Note that all examples for graphs with small radii and
large rainbow connection numbers have been graphs with bridges (edge connectivity of
the graph equals 1). Any valid rainbow coloring of G colors the bridges distinctly. In
the above construction we have controlled rc(G) by essentially controlling the number of
bridges. This construction illustrates that it is futile to try and upper-bound the rainbow
connection number of a graph with bridges as a function of its radius or diameter.
Sweeping the class of graphs with bridges out of the way, we turn our attention to the
class of bridge-less graphs (graphs with edge connectivity of at least 2). We may ask the
Chapter 1. Introduction 16
following question: Are there bridge-less graphs whose rainbow connection numbers are
arbitrarily large in comparison to their radii? This question was answered by Basavaraju
et al. [1]. They proved that for a bridge-less, connected graph G with radius r, the
rainbow connection number rc(G) ≤ r(r+ 2). As we have seen earlier, the upper-bound
for the rainbow connection number of a graph is inversely proportional to its (vertex)
connectivity, κ(G). If a higher connectivity is assumed then can the upper bound be
improved. Basavaraju et al. were able to show that the bound could not be improved
even if higher vertex connectivity were to be assumed. Given a fixed pair (r, κ) (radius,
connectivity pair) such that r, κ ≥ 1 they construct a graph, G such that r(G) = r,
κ(G) = κ and its rainbow connection number, rc(G) = r(r + 2). Thus for bridge-less
graphs they proved that the upper-bound of r(r+2) could not be improved. All previous
upper-bounds on the rainbow connection number were directly proportional to the order
of the graph. This result asserts that any bridge-less graph with small radius has a small
rainbow connection number irrespective of the size of the graph. It may be worth noting
that the bound given by Basavaraju et al. was generalized to incorporate graphs with
bridges by Dong and Li [23].
We focus on the following question: Are there non-trivial, bridge-less graphs whose
rainbow connection numbers are always linear functions of their radii/ diameters? It is
in this respect that we studied the important graph product operations and the graph
powering operation. Specifically we studied three binary graph operations: Cartesian
Product, Lexicographic Product and Strong Product and one unary graph operation:
Graph Powering. For definitions of the above graph operations see Chapter 3. For a
detailed exposition on graph products the reader is referred to the book by Imrich and
Klavzar [2]. With respect to all the graph operations mentioned, if the operand graphs
are non-trivial and connected then the resultant graph can be shown to be two vertex
connected (and hence two edge connected). An upper-bound that is a quadratic func-
tion of the radius of the resultant graph already exists. Can we improve this bound?
Chapter 1. Introduction 17
Recall that rc(K1,n) = n and rc(K2) = 1. What can we say about the rainbow con-
nection number of the Cartesian product of K1,n and K2 i.e. rc(K1,n�K2)? First of all
observe that K1,n�K2 is bridge-less and that r(K1,n�K2) = 2. If we use the bounds
given by Basavaraju et al. [1] we get rc(K1,n�K2) ≤ 6 but a simple heuristic coloring
would reveal that rc(K1,n�K2) ≤ 4 i.e. rc(K1,n�K2) ≤ 2r(K1,n�K2). Such exam-
ples indicate that the bound given by Basavaraju et al. is inadequate to tightly bound
the rainbow connection numbers of graphs resulting from the graph operations that we
consider. Therefore these graph operations warrant a more thorough study. Can we
claim something similar for the Cartesian product of general graphs i.e. is rc(G1�G2) ≤
C1r(G1�G2) +C2? where C1 and C2 are small constants independent of the param-
eters of the operand graphs. Since the lexicographic product and the strong product
of graphs are denser than their cartesian product, can we expect similar bounds with
respect to these operations too? Can we ask for similar bounds when the operation is
graph powering? We answer in affirmative to all the above questions.
The usual way to study these graph operations would be to try and express the
rainbow connection number of the resultant graph in terms of the rainbow connec-
tion number of the operand graphs. Such a study was done by Li et al. [10], they
were able to prove for non-trivial, connected graphs G1 and G2 that rc(G1�G2) ≤
rc(G1) + rc(G2). Since G1�G2 is a spanning subgraph of G1�G2 (strong product of G1
and G2) they were also able conclude that rc(G1 � G2) ≤ rc(G1) + rc(G2). The bound
for the rainbow connection number of the strong product of two graphs was later im-
proved to max{rc(G1), rc(G2)} by Gologranc et al. [22]. The above bounds imply that
rc(K1,n�K2) ≤ n + 1 and rc(K1,n �K2) ≤ n for all n ≥ 1. But we already know that
rc(K1,n � K2) ≤ rc(K1,n�K2) ≤ 4. Even the quadratic bound given by Basavaraju et
al. [1] fares better in these cases. All this evidence seems to indicate that a conventional
study of the graph operations mentioned is completely inadequate.
The results obtained by us are compiled in the “Our Results” section presented next.
Chapter 1. Introduction 18
1.3 Our Results
1. If G is a connected graph then r(Gk) ≤ rc(Gk) ≤ 2r(Gk) + 1, for all k ≥ 2. The
lower bound is tight while the upper bound is tight up to an additive constant of
1. [See Theorem 1]
2. If G and H are two connected, non-trivial graphs then r(G�H) ≤ rc(G�H) ≤
2r(G�H). The bounds are tight. [See Theorem 2]
3. Given two non-trivial graphs G and H such that G is connected we have the
following:
(a) If r(G ◦ H) ≥ 2 then r(G ◦ H) ≤ rc(G ◦ H) ≤ 2r(G ◦ H). The bounds are
tight.
(b) If r(G ◦H) = 1 then 1 ≤ rc(G ◦H) ≤ 3. The bounds are tight.
[See Theorem 3]
4. If G and H are two connected, non-trivial graphs then r(G�H) ≤ rc(G�H) ≤
2r(G�H) + 2. The lower bound is tight while the upper bound is tight up to an
additive constant of 2. [See Theorem 4]
Chapter 2
Preliminaries and Definitions
We only consider simple, undirected graphs. Given a graph G, we use |G| to denote
the number of vertices of G also called the order of G. A trivial graph is a graph of
order 0 or 1.
Given a graph G, a walk from vertex u to vertex v is defined as a sequence of vertices
(not necessarily distinct), starting at u and ending at v, say {u = u0}, u1, . . . , {uk = v}
such that (ui, ui+1) ∈ E(G) for 0 ≤ i ≤ k − 1. A walk in which all the vertices are
distinct is called a path. The length of a path, P , is equal to the number of edges in P
and is denoted by |P |. Note that a single vertex path is defined to be a path of length
0. The distance between two vertices u and v in G is the length of a shortest path
between them and is denoted by distG(u, v). Given two walks W1 = u0, u2, . . . , uk and
W2 = v0, v1, . . . , vl such that uk = v0, we can concatenate W1 and W2 to get a longer
walk, W = W1.W2 = u0, u1, . . . , {uk = v0}, v1, v2, . . . , vl.
Given a graph G, the eccentricity of a vertex, v ∈ V (G) is given by ecc(v) = max{
distG(v, u): u ∈ V (G)}. The radius of G is given by r(G) = min{ecc(v) : v ∈ V (G)}
and the diameter of G is defined as diam(G) = max{ecc(v) : v ∈ V (G)}. A central
vertex of G is a vertex with eccentricity equal to the radius of G.
19
Chapter 2. Preliminaries and Definitions 20
Given a graph G, another graph G′ is called a spanning subgraph of G if G′ is a
subgraph of G and V (G′) = V (G). A vertex v is called universal when it is adjacent to
all the other vertices in the graph.
Given a tree T , the unique path between any two vertices, u and v, is denoted by
PT (u, v). It is sometimes convenient to consider some vertex from the tree as special;
such a vertex is then called the root of this tree. A tree with a fixed root is called a
rooted tree. Let T be a rooted tree with root, root(T) = v0. The level number of any
vertex v ∈ T is given by `T (v) = distT (v, v0). If the tree in context is clear then we
simply use `(v). The depth of T is given by d(T ) = max{`(v): v ∈ V (T )}. Given two
vertices u, v ∈ V (T ), u is called an ancestor of v if u ∈ PT (v, v0). It is easy to see that
`(v) ≥ `(u). If u is an ancestor of v and `(v) = `(u) + 1 then u is called the parent of v
and is denoted by parent(v).
Definition 1. [Layer-wise Coloring of a Rooted Tree] Given a rooted tree −
T and an ordered multi-set of colors − C = { ci: 1 ≤ i ≤ n } where n ≥ d(T ), we define
the edge coloring, fT,C: E(T ) → C as fT,C((u, v)) = ci where i = max{ `(u), `(v)}. We
refer to fT,C as the Layer-wise Coloring of T that uses colors from the set C.
Let f be an edge coloring of graph G using colors from the set C. Let P be a path in
G that is rainbow colored with respect to f . We call P as a C ′-Rainbow-Path if every
edge in P is colored from the set C ′ ⊆ C.
Observation 1. Let T be a rooted tree and C = {c1, c2, . . . , cn : n ≥ d(T )} be an
ordered set of colors i.e. ci 6= cj for i 6= j. Let T be edge colored using the Layer-wise
Coloring, fT,C as defined in Definition-1. If u, v ∈ V (T ) such that u is an ancestor of v
in T , then PT (v, u) is a C-Rainbow-Path with respect to the coloring fT,C. In particular
PT (v, u) is a {c`(u)+1, c`(u)+2, . . . , c`(v)}-Rainbow-Path with respect to fT,C.
Recall the definition of the Cartesian Product of two graphs G and H, denoted by
G�H (See Section 3.2). Below we define a decomposition of G�H into edge disjoint
Chapter 2. Preliminaries and Definitions 21
subgraphs, which we use frequently in our proofs.
Definition 2. [(G,H)-Decomposition of G�H] Given graphs G and H with
vertex sets V (G) = {gi : 1 ≤ i ≤ |G| − 1} and V (H) = {hi : 1 ≤ i ≤ |H| − 1}
respectively. We define a decomposition of G�H as follows:
For 0 ≤ j ≤ |H| − 1, define induced subgraphs, Gj, with vertex sets, V (Gj) = {[gi, hj] :
0 ≤ i ≤ |G|−1}. Similarly for 0 ≤ i ≤ |G|−1, define induced subgraphs, Hi, with vertex
sets, V (Hi) = {[gi, hj] : 0 ≤ j ≤ |H| − 1}. Then we have the following:
1. For 0 ≤ j ≤ |H| − 1, Gj is isomorphic to G and for 0 ≤ i ≤ |G| − 1, Hi is
isomorphic to H.
2. For 0 ≤ i < j ≤ |H| − 1, V (Gi) ∩ V (Gj) = ∅ and E(Gi) ∩ E(Gj) = ∅.
3. For 0 ≤ k < l ≤ |G| − 1, V (Hk) ∩ V (Hl) = ∅ and E(Hk) ∩ E(Hl) = ∅.
4. For 0 ≤ j ≤ |H| − 1 and 0 ≤ i ≤ |G| − 1, V (Gj) ∩ V (Hi) = [gi, hj] and E(Gj) ∩
E(Hi) = ∅
We call G1, G2, . . . , G|H|−1, H1, H2, . . . , H|G|−1 as the (G,H)-Decomposition of G�H.
Chapter 3
Graph Operations: An Introduction
In this chapter, we define three binary graph operations − the Cartesian Product,
the Lexicographic Product and the Strong Product. We also define one unary graph
operation − Graph Powering. In addition we present a few related observations that
are relevant to the thesis. The studies of various graphs operations such as graph power
and graph products have been an important and interesting branch of graph theory. For
a more detailed exposition on the subject the reader is referred to the book written by
Imrich and Klavzar [2].
In may be noted that all the graphs considered from here on are assumed to be non-
trivial and connected unless stated otherwise.
3.1 The k − th Powering of a Graph H
Definition: For k ∈ Z and k ≥ 1, we define the k-th power of a graph H, denoted by Hk,
as follows: V (Hk) = V (H) and any two vertices u and v ∈ V (Hk) are adjacent if and
only if distH(u, v) ≤ k. Note that H1 = H.
Observation 2. If u and v are two distinct vertices of Hk then distHk(u, v) =⌈distH(u,v)
k
⌉.
22
Chapter 3. Graph Operations: An Introduction 23
Proof. We first prove that distHk(u, v) ≤⌈distH(u,v)
k
⌉. Let P = {u = u0}, u1, . . . ,
{u|P | = v} be a path from u to v in H such that |P | = distH(u, v). In Hk, ver-
tices ui and uj of P are adjacent if and only if distH(ui, uj) ≤ k (|j − i| ≤ k), where
0 ≤ i < j ≤ distH(u, v). Let distH(u, v) = lk + k′ where l ≥ 0 and 0 ≤ k′ ≤ k − 1. Con-
sider the following path from u to v in Hk, P ′ = {u = u0}, uk, u2k, . . . , ulk, {v = ulk+k′}.
We have that⌈distH(u,v)
k
⌉= |P ′| ≥ distHk(u, v).
Now we prove that distHk(u, v) ≥⌈distH(u,v)
k
⌉. We start by assuming the contra-
diction: dHk(u, v) <⌈distH(u,v)
k
⌉. Let P ′′ be a path between u and v in Hk such
that |P ′′| = distHk(u, v). Corresponding to any two adjacent vertices of P ′′ there
exists a path of length at most k connecting them in H. Let W ′′ be a walk ob-
tained by replacing every pair of adjacent vertices in P ′′ by the corresponding path
in H. We have that k|P ′′| ≥ |W ′′| ≥ distH(u, v), i.e. k.distHk(u, v) ≥ distH(u, v) and
distHk(u, v) ≥⌊distH(u,v)
k
⌋. If
⌈distH(u,v)
k
⌉=⌊distH(u,v)
k
⌋then we already have a contra-
diction. Therefore we may assume that⌈distH(u,v)
k
⌉>⌊distH(u,v)
k
⌋. Hence we have the
following set of inequalities,⌈distH(u,v)
k
⌉> distHk(u,v) ≥
⌊distH(u,v)
k
⌋. In particular, we can
show that distH(u, v) > kdistHk(u, v). This implies that distH(u, v) > |W ′′|. This is a
contradiction.
From the above observation we conclude that r(Hk) =⌈r(H)k
⌉and diam(Hk) =⌈
diam(H)k
⌉.
3.2 The Cartesian Product of Two Graphs, G′ and
H ′
Definition: The Cartesian product of two graphs G′ and H ′, denoted by G′�H ′, is
defined as follows: V (G′�H ′) = V (G′) × V (H ′). Two distinct vertices [g1, h1] and [g2,
h2] of G′�H ′ are adjacent if and only if either g1 = g2 and (h1, h2) ∈ E(H ′) or (g1,
g2) ∈ E(G′) and h1 = h2. Note that the Cartesian Product is a commutative operator
i.e. G′�H ′ = H ′�G′. If G′ or H ′ is disconnected then G′�H ′ is disconnected. Finally,
Chapter 3. Graph Operations: An Introduction 24
G′�K1 = G′.
Let V (G′) = {g0, g1, . . . , G|G′|−1} and V (H ′) = {h0, h1, . . . , h|H′|−1}. Let G0, G1,
. . . , G|H′|−1, H0, H1, . . . , H|G′|−1 be the (G,H)-Decomposition of G′�H ′ as defined in
Definition-2.
Observation 3. If u = [gi, hj] and v = [gk, hl] are two distinct vertices of G′�H ′
then distG′�H′(u, v) = distG′(gi, gk) + distH′(hj, hl).
Proof. We first prove that distG′�H′(u, v) ≤ distG′(gi, gk)+distH′(hj, hl). Let P1 be a
path in Gj from vertex u = [gi, hj] to vertex u1 = [gk, hj] such that |P1| = distG′(gi, gk).
Similarly let P2 be a path in Hk from [gk, hj] to v = [gk, hl] such that |P2| = distH′(hj, hl).
The walk W = P1.P2 is a walk from vertex u to vertex v in G′�H ′. We have the following
set of inequalities, distG′(gi, gk)+ distH′(hj, hl) = |W | ≥ distG′�H′(u, v).
Now we prove that distG′�H′(u, v) ≥ distG′(gi, gk) + distH′(hj, hl). Consider the
path, P = {u = [gi0 , hj0 ]}, [gi1 , hj1 ], . . . , {[gi|P | , hj|P | ] = v} in G′�H ′ such that |P | =
distG′�H′(u, v). The sequence formed by the first co-ordinates of the vertices of P is a
walk from vertex gi0 to vertex gi|P | in G′, call it W ′1. Let W1 be the walk constructed
from W ′1 such that no two adjacent vertices are the same. In other words if S = gix , gix+1 ,
. . . , gix+n is a sub-sequence of vertices in W ′1 such that gix+j
= gix+j+1, where 0 ≤ j ≤ n−1,
then S is replaced by just a single copy of gix in W1. Using a similar process we construct
W2, the walk from vertex hj0 to hj|P | in H ′. Now, consider two consecutive vertices in
P say [gix , hjx ] and [gix+1 , hjx+1 ]. We have either gix = gix+1 or hjx = hjx+1 but not both.
This implies that any given edge of P contributes either to |W1| or |W2| but not both.
Thus |P | = |W1| + |W2|. But |W1| ≥ distG′(gi, gk) and |W2| ≥ distH′(hj, hl). Hence
|P | = distG′�H′(u, v) ≥ distG′(gi, gk) + distH′(hj, hl).
Hence the proof.
From the above observation we conclude that diam(G′�H ′) = diam(G′) + diam(H ′)
and r(G′�H ′) = r(G′) + r(H ′).
Chapter 3. Graph Operations: An Introduction 25
3.3 The Lexicographic Product of Two Graphs G′
and H
Definition: The lexicographic product of two graphs G′ and H, denoted by G′ ◦H,
is defined as follows: V (G′ ◦H) = V (G′)× V (H). Two distinct vertices [g1, h1] and [g2,
h2] of G′ ◦H are adjacent if and only if either (g1, g2) ∈ E(G′) or g1 = g2 and (h1, h2)
∈ E(H). Note that the lexicographic product is a non-commutative operator i.e. G′ ◦H
need not be isomorphic to H ◦G′. Suppose H is disconnected and G′ is connected then
G′ ◦H is connected. Hence with respect to the lexicographic product we do not assume
H to be connected. We however retain the assumptions that G′ is non-trivial, connected
and that H is non-trivial. Finally, G′ ◦K1 = K1 ◦G′ = G′.
Let V (G′) = {g0, g1, . . . , g|G′|−1} and V (H) = {h0, h1, . . . , h|H|−1}. Note that G′�H
is a spanning subgraph of G′ ◦ H. Let G0, G1, . . . , G|H|−1, H0, H1, . . . , H|G′|−1 be the
(G,H)-Decomposition of the subgraph isomorphic to G′�H as defined in Definition-2.
Observation 4. If G′ and H are two non-trivial graphs then we have following:
1: r(G′ ◦H) = 1 if and only if r(G′) = 1 and r(H) = 1.
2: If G′ is connected then r(G′ ◦H) ≥ r(G′).
Proof.
Proof of 1: We first prove that r(G′) = 1 and r(H) = 1 =⇒ r(G′ ◦ H) = 1. Let gi
and hj be universal vertices of G′ and H respectively. We claim that given any vertex
(gi′ , hj′) ∈ V (G′ ◦ H), the edge ([gi, hj], [gi′ , hj′ ]) ∈ E(G′ ◦ H). To see this, if gi = gi′
then ([gi, hj], [gi′ , hj′ ]) ∈ E(G′ ◦ H) since (hj, hj′) ∈ E(H). If, however gi 6= gi′ then
([gi, hj], [gi′ , hj′ ]) ∈ E(G′ ◦H) since (gi, gi′) ∈ E(G′). We have thus proved that [gi, hj] is
a universal vertex of G′ ◦H. Hence r(G′ ◦H) = 1.
Now we prove that r(G′ ◦ H) = 1 =⇒ r(G′) = 1 and r(H) = 1. Let [gi, hj] be a
universal vertex of G′◦H. For all [gi′ , hj] ∈ V (Gj), the edge ([gi, hj], [gi′ , hj]) ∈ E(G′◦H).
This can only happen if (gi, gi′) ∈ E(G′) for all gi′ ∈ V (G′). Hence gi is a universal vertex
of G′. Similarly for all [gi, hj′ ] ∈ V (Hi), the edge ([gi, hj′ ], [gi, hj]) ∈ E(G′ ◦ H). This
Chapter 3. Graph Operations: An Introduction 26
happens since (hj′ , hj) ∈ E(H) for all hj′ ∈ V (H). Hence hj is a universal vertex of H.
Proof of 2: To prove Part 2 of the observation, it is enough to prove that distG′◦H
([gi, hj], [gk, hl]) ≥ distG′(gi, gk), where [gi, hj] and [gk, hl] are two distinct vertices in
G′ ◦ H. Let P = {[gi, hj] = [gi0 , hj0 ]}, [gi1 , hj1 ], . . . , {[gi|P | , hj|P | ] = [gk, hl]} be a path
from [gi, hj] to [gk, hl] in G′ ◦H such that |P | = distG′◦H(u, v). Let W be the sequence
of the first co-ordinates of the vertices of P . Then W is a walk from gi to gk in G′.
Therefore distG′◦H([gi, hj], [gk, hl]) = |W | ≥ distG′(gi, gk)
3.4 The Strong Product of Two Graphs G′ and H ′
Definition: The strong product of two graphs G′ and H ′, denoted by G′ �H ′, is defined
as follows: V (G′ �H ′) = V (G′)× V (H ′). The edge set of G′ �H ′ consists of two types
of edges. An edge ([g1, h1], [g2, h2]) is Type-1 if and only if either g1 = g2 and (h1, h2)
∈ E(H ′) or h1 = h2 and (g1, g2) ∈ E(G′). An edge is of Type-2 if and only if (g1, g2)
∈ E(G′) and (h1, h2) ∈ E(H ′). Note that the strong product is a commutative operator
i.e. G′�H ′ = H ′�G′. If G′ or H ′ is disconnected then G′�H ′ is disconnected. Finally,
G′ �K1 = G.
Let V (G′) = {g0, g1, . . . , g|G|−1} and V (H ′) = {h0, h1, . . . , h|H|−1}.
Observation 5. If u = [gi, hj], v = [gk, hl] ∈ V (G′ � H ′) are two distinct vertices
then distG′�H′(u, v) = max{distG′(gi, gk), distH′(hj, hl)}.
Proof. First, we prove that distG′�H′(u, v) ≥ max{distG′(gi, gk), distH′(hj, hl)}. Let
P = {[gi, hj] = [gi0 , hj0 ]}, [gi1 , hj1 ], . . . , {[gi|P | , hj|P | ] = [gk, hl]} be a path from u to
v in G′ � H ′ such that |P | = distG′�H′(u, v). Let W1 be the sequence of first co-
ordinates of the vertices of P and let W2 be the sequence of second co-ordinates of the
vertices of P . W1 is a walk from gi to gk in G′ and W2 is a walk from hj to hl in H ′.
We have |P | = |W1| = |W2|, |W1| ≥ distG′(gi, gk) and |W2| ≥ distH′(hj, hl). Hence
distG′�H′(u, v) ≥ max{distG′(gi, gk), distH′(hj, hl)}.
Now, we prove that distG′�H′(u, v) ≤ max{distG′(gi, gk), distH′(hj, hl)}. Let P1 =
{gi = gi0}, gi1 , . . . , {gim = gk} be a path of length m = distG′(gi, gk) in G′. Similarly
Chapter 3. Graph Operations: An Introduction 27
let P2 = {hj = hj0}, hj1 , . . . , {hjn = hl} be a path of length n = distH′(hj, hl) in
H ′. Let m ≥ n, then the following is a path from u to v in G′ � H ′: P ′ = {[gi, hj] =
[gi0 , hj0 ]}, [gi1 , hj1 ], . . . , [gin , hjn ], [gin+1 , hjn ], . . . , {[gim , hjn ] = [gk, hl]}. We have that m =
|P ′| ≥ distG′�H′(u, v). If however m ≤ n then using symmetric arguments we can show
that n ≥ distG′�H′(u, v). Hence distG′�H′(u, v) ≤ max{distG′(gi, gk), distH′(hj, hl)}.
From the above observation we conclude that r(G′ � H ′) = max{r(G′), r(H ′)} and
diam(G′ �H ′) = max{diam(G′), diam(H ′)}.
Chapter 4
Rainbow Connection Number of
Graph Power and Graph Products
In this chapter we discuss, in detail, the bounds that we have obtained for rainbow
connection numbers of graphs resulting from the powering operation and the three prod-
uct operations. The reader is reminded that all graphs considered are assumed to be
non-trivial and connected, unless stated otherwise.
4.1 Rainbow Connection Number of the k-th Power
of a Graph H
Recalling the definition: For k ∈ Z and k ≥ 1, we define the k-th power of a graph
H, denoted by Hk, as follows: V (Hk) = V (H) and any two vertices u and v ∈ V (Hk)
are adjacent if and only if distH(u, v) ≤ k. Also recall that r(Hk) =⌈r(H)k
⌉and
diam(Hk) =⌈diam(H)
k
⌉.
Since H1 = H, for the remainder of this section we assume that k ≥ 2. Let T be the
BFS-Tree rooted at some central vertex, say h0, of H. Then clearly the depth of tree T,
d(T ) = r(H). Clearly T k is a spanning subgraph of Hk and hence rc(Hk) ≤ rc(T k). So
in order to derive an upper bound for rc(Hk) in terms of r(Hk) it is enough to derive an
28
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products29
upper bound for rc(T k) in terms of⌈d(T )k
⌉( r(Hk) =
⌈d(T )k
⌉).
Let V (T ) = { hi: 0 ≤ i ≤ |H|−1 }. For 0 ≤ i ≤ k−1, let Vi = { u ∈ V (T ) : `T (u) > 0
and `T (u) ≡ i mod k}. It is easy to see that V =⋃k−1i=0 Vi ]{h0}.
For 0 ≤ i ≤ k − 1 and 0 ≤ j ≤⌈d(T )k
⌉we define V j
i = {u ∈ Vi ∪ {h0} :⌈`T (u)k
⌉= j}.
Note that if u ∈ V (T ) \ {h0} then u belongs to exactly one V ji where 0 ≤ i ≤ k − 1 and
1 ≤ j ≤⌈d(T )k
⌉. For all 0 ≤ i ≤ k − 1, vertex h0 is the only vertex in V 0
i .
Now we define a function, par: V (T ) \ {h0} → V (T ) as follows: ∀u ∈ V (T ) \ {h0},
par(u) = v such that if u ∈ V ji then v ∈ V j−1
i and (u, v) ∈ E(T k). Such a vertex v
always exists because of the following reasons: If 1 ≤ `T (u) ≤ k then u ∈ V 1i for some
0 ≤ i ≤ k−1; we may choose v to be h0 since h0 ∈ V 0i and (h0, u) ∈ E(T k). If `T (u) > k
then we may choose v to be the ancestor of u in T such that `T (v) = `T (u) − k. Then
clearly v ∈ V j−1i and (u, v) ∈ E(T k).
For 0 ≤ i ≤ k − 1, define graph Gi with vertex set, V (Gi) = Vi ∪ {h0} and edge set,
E(Gi) = {(u, par(u)) : u ∈ Vi}. Since every vertex in Gi has a path to h0, the only
vertex in V 0i , Gi is connected. Moreover using the definition of the function par, it is
easy to verify that Gi does not contain any cycles. Hence Gi is a tree. For 0 ≤ i ≤ k− 1
let root(Gi) = h0. For i 6= j we have V (Gi) ∩ V (Gj) = {h0}, a singleton set and hence
E(Gi) ∩ E(Gj) = ∅.
We define an edge coloring, f : E(T k) → A ] B ] {c} where A = { ai: 1 ≤ i ≤
dd(T )/ke }, B = { bi: 1 ≤ i ≤ dd(T )/ke } and {c} are ordered sets of colors. Since
E(Gi) ∩ E(Gj) = ∅ for i 6= j, in order to define the edge coloring f it is sufficient to
define an edge coloring of Gi, for 0 ≤ i ≤ k− 1 and an edge coloring of all the remaining
edges of T k, separately. For 0 ≤ i ≤ k−1, if i ≡ 0 mod 2 then we choose the Layer-wise
Coloring fGi,A to color the edges of Gi else we choose fGi,B to color the edges of Gi. All
the remaining edges of T k are colored c.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products30
Claim 1. The edge coloring f is a rainbow coloring of T k.
Proof. Let u and v be two distinct vertices of T k. Without loss of generality let
u 6= h0. Then u ∈ Gi where 0 ≤ i ≤ k − 1. By Observation 1 there is an A-Rainbow-
Path/ B-Rainbow-Path from u to h0 if i is even/ odd. Now we can assume that u, v 6= h0.
Let u ∈ V (Gi) and v ∈ V (Gj). To illustrate a rainbow path between u and v we
consider the following two cases.
Case 1: [When |i− j| ≡ 1 mod 2]
Without loss of generality let i ≡ 0 mod 2 and j ≡ 1 mod 2.
Let Q1 = PGi(u, h0) and Q2 = PGj
(h0, v) be the A- and B-Rainbow-Paths in Gi and
Gj with respect to the Layer-wise Colorings fGi,A and fGj ,B respectively (See Observation
1). It follows that Q1 and Q2 are A- and B-Rainbow-Paths in T k with respect to edge
coloring f . Clearly Q = Q1.Q2 is a (A ∪ B)-Rainbow-Path from vertex u to vertex v.
Case 2: [When |i− j| ≡ 0 mod 2]
Without loss of generality we may assume that `T (v) ≥ `T (u).
If (u, v) ∈ E(T k) then there is a trivial rainbow path between them. If `T (u1) ≤ 1
and `T (u2) ≤ 1 then (u1, u2) ∈ E(T k) (since k ≥ 2). We consider the case when
(u, v) /∈ E(T k). This happens when the level number of one of the vertices is ≥ 2 i.e.
`T (v) ≥ 2. Let v1 ∈ V (T k) be the parent of v in T . Since `T (v) ≥ 2, v1 6= h0. Let
v1 ∈ Gl where `T (v1)(= `T (v) − 1) ≡ l mod k. From Case 1 we know that there is a
(A ∪ B)-Rainbow-Path, say P , between vertices u and v1 since |i− l| ≡ 1 mod 2. Edge
(v, v1) is colored c since (v, v1) /∈ E(Gi) for any 0 ≤ i ≤ k − 1. Extending P by edge
(v, v1) we get the required rainbow path between vertices u and v.
We have thus proved that f is a rainbow coloring of T k.
Theorem 1. If H is any connected, non-trivial graph then for all k ≥ 2, r(Hk) ≤
rc(Hk) ≤ 2r(Hk) + 1.
Proof. The edge coloring f uses |A| + |B| + |{c}| = 2r(Hk) + 1 colors. The upper
bound follows from Claim 1. The lower bound is trivial.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products31
4.2 Rainbow Connection Number of the Cartesian
Product of Two Graphs G′ and H ′
Recalling the definition: The Cartesian product of two graphs G′ and H ′, denoted by
G′�H ′, is defined as follows: V (G′�H ′) = V (G′) × V (H ′). Two distinct vertices [g1,
h1] and [g2, h2] of G′�H ′ are adjacent if and only if either g1 = g2 and (h1, h2) ∈ E(H ′)
or (g1, g2) ∈ E(G′) and h1 = h2. Also recall that diam(G′�H ′) = diam(G′)+diam(H ′)
and r(G′�H ′) = r(G′) + r(H ′).
Let G be the Breadth-First-Search-Tree (BFS-Tree) rooted at some central vertex,
say g0, of G′. Similarly let H be the BFS-Tree rooted at some central vertex, say h0,
of H ′. We have that d(G) = r(G′) and d(H) = r(H ′) where d(G) and d(H) are the
depths of trees G and H respectively. Clearly G�H is a connected spanning subgraph of
G′�H ′ and therefore rc(G′�H ′) ≤ rc(G�H). So in order to derive an upper bound for
rc(G′�H ′) in terms of r(G′�H ′) it is sufficient to derive an upper bound for rc(G�H)
in terms of r(G′�H ′).
Let V (G) = { g0, g1, . . . , g|G|−1} and V (H) = { h0, h1, . . . , h|H|−1}. Let G1, . . . G|H|−1,
H1, . . . , H|G|−1 be the (G,H)-Decomposition of G�H as defined in Definiton-2. For
0 ≤ i ≤ |H|−1 define root(Gi) = [g0, hi] and for 0 ≤ j ≤ |G|−1 define root(Hj) = [gj, h0].
Recall the following simple observations:
Observation 6. V (Gi)∩V (Hj) = {[gj, hi]}, V (Gi)∩V (Gj) = ∅ and V (Hi)∩V (Hj)
= ∅.
Observation 7. E(G�H) =⊎|H|−1i=0 E(Gi)
⊎|G|−1j=0 E(Hj)
We now define an edge coloring, f : E(G�H) → A]B ]C ]D where A = { ai : 1 ≤
i ≤ d(G) }, B = { bi : 1 ≤ i ≤ d(G) }, C = { ci : 1 ≤ i ≤ d(H) } and D = { di : 1 ≤
i ≤ d(H) } are ordered sets of colors. In view of Observation-7 it is clear that in order
to define the coloring f , it is sufficient to describe separately, an edge coloring for each
Gi, 0 ≤ i ≤ |H| − 1 and an edge coloring for each Hj, 0 ≤ j ≤ |G| − 1. We choose fG0,A
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products32
(See Definition-1) to be the edge coloring of G0 and fGi,B to be the edge coloring of Gi
for 1 ≤ i ≤ |H| − 1. Similarly we choose fH0,C to be the edge coloring of H0 and fHi,D
to be the edge coloring of Hi for 1 ≤ i ≤ |G| − 1.
Claim 2. The edge coloring, f , is a rainbow coloring of G�H.
Proof. Let u = [gi, hj] and v = [gk, hl] be two distinct vertices of G�H. We demon-
strate a rainbow path between u and v, by considering the following cases:
Case 1: [At least one of the vertices belong to V (G�H) \(V (G0)∪ V (H0))]
Without loss of generality let v ∈ V (G�H) \(V (G0) ∪ V (H0)) i.e. l 6= 0 and k 6= 0. We
now consider the following two sub-cases.
Case 1.a: [Vertex u /∈ V (G0), hence j 6= 0]
Vertex v = [gk, hl] ∈ V (Hk) and root(Hk) = [gk, h0]. Let Q1 = PHk(v, [gk, h0]), is a
D-Rainbow-Path in Hk with respect to the coloring fHk,D, by Observation 1. Similarly let
Q2 = PG0([gk, h0], [g0, h0]), Q3 = PH0([g0, h0], [g0, hj]) and Q4 = PGj([g0, hj], [gi, hj])
be A-, C- and B-Rainbow-Paths in G0, H0 and Gj 6=0 respectively. It follows that
Q1, Q2, Q3 and Q4 are D-,A-,C- and B-Rainbow-Paths in G�H with respect to the
coloring f . Clearly Q = Q1. Q2. Q3. Q4 is a rainbow walk from v to u in G�H that
contains a rainbow path between them.
Case 1.b: [Vertex u ∈ V (G0), hence u = [gi, h0]]
Vertex v ∈ VGl, let Q1 = PGl
(v, [g0, hl]), is a B-Rainbow-Path in Gl with respect to
edge coloring fGl,B, by Observation-1. Similarly let Q2 = PH0([g0, hl], [g0, h0]) and
Q3 = PG0([g0, h0], [gi, h0]) be C- and A-Rainbow-Paths in H0 and G0 respectively. It
follows that Q1, Q2 and Q3 are B-, C- and A-Rainbow-Paths in G�H with respect to
the coloring f . Clearly Q = Q1. Q2. Q3. is a rainbow walk from v to u in G�H that
contains a rainbow path between them.
Case 2: [Both the vertices belong to V (G0) ∪ V (H0)]
Without loss of generality let v 6= [g0, h0]. We consider the following 3 sub-cases:
Case 2.a: [Both the vertices belong to V (H0), hence u = [g0, hj] and v = [g0, hl]]
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products33
Vertex v = [g0, hl] ∈ V (Gl). Let v′ = [gk′ , hl] be another vertex in Gl such that (v, v′)
∈ E(Gl). The existence of v′ is guaranteed since G′ 6= K1. Let Q1 = PGl(v, v′) i.e. the
single edge (v, v′) is a B-Rainbow-Path in Gl with respect to the coloring fGl,B, noting
that l 6= 0 by the assumption that v 6= [g0, h0]. Similarly let Q2 = PHk′(v′, [gk′ , h0]), Q3
= PG0([gk′ , h0], [g0, h0]) and Q4 = PH0([g0, h0], [g0, hj]) be D-, A- and C-Rainbow-Paths
in Hk′ , G0 and H0 respectively. It follows that Q1, Q2, Q3 and Q4 are B-, D-, A- and
C-Rainbow-Paths in G�H with respect to coloring f . Clearly Q = Q1. Q2. Q3. Q4. is a
rainbow walk from v to u in G�H that contains a rainbow path between them.
Case 2.b: [Both the vertices belong to V (G0), hence u = [gi, h0] and v = [gk, h0]]
Vertex v ∈ V (Hk). Let v′ = [gk, hl′ ] be another vertex in Hk such that (v, v′) ∈ E(Hk).
The existence of v′ is guaranteed since H ′ 6= K1. Let Q1 = PHk(v, v′) i.e. the single
edge (v, v′) is a D-Rainbow-Path in Hk with respect to the coloring fHk,D, noting that
l 6= 0 by the assumption that v 6= [g0, h0]. Similarly let Q2 = PGl′(v′, [g0, hl′ ]), Q3 =
PH0([g0, hl′ ], [g0, h0]) and Q4 = PG0([g0, h0], [gi, h0]) be B-, C- and A-Rainbow-Paths
in Gl′ , H0 and G0 respectively. It follows that Q1, Q2, Q3 and Q4 are D-, B-, C- and
A-Rainbow-Paths in G�H with respect to coloring f . Clearly Q = Q1. Q2. Q3. Q4. is a
rainbow walk from v to u in G�H that contains a rainbow path between them.
Case 2.c: [One vertex belongs to V (G0) and the other to V (H0)]
Without loss of generality let u ∈ V (G0), v ∈ V (H0) then j = 0 and l = 0. In view of
Cases 2.a and 2.b we can assume that u, v 6= [g0, h0].
Let Q1 = PH0(v, [g0, h0]) and Q2 = PG0([g0, h0], u) is a C- and A-Rainbow-Paths in
H0 and G0 respectively. It follows that Q1 and Q2 are C- and A-Rainbow-Paths in G�H
with respect to the coloring f . Clearly Q = Q1.Q2 is a rainbow walk from vertex v to
vertex u in G�H that contains a rainbow path between them.
It follows that f is a rainbow coloring of G�H.
Theorem 2. If G′ and H ′ are two non-trivial, connected graphs then r(G′�H ′) ≤
rc(G′�H ′) ≤ 2r(G′�H ′). Moreover the bounds are tight.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products34
Proof. The edge coloring f uses |A|+ |B|+ |C|+ |D| = 2(d(G) + d(H)) = 2(r(G′) +
r(H ′)) = 2r(G′�H ′) number of colors. The upper bound follows from Claim-2 and the
lower bound is obvious.
Tight Example:
Consider two graphs G1 and G2 such that diam(G1) = 2r(G1) and diam(G2) = 2r(G2).
For example G1 and G2 may be taken as paths with odd number of vertices. Then
diam(G1�G2) = diam(G1) + diam(G2) = 2(rG1) + r(H1)). It follows from Theorem 2
that rc(G1�G2) = 2(rG1) + r(H1)) = 2r(G1�G2).
4.3 Rainbow Connection Number of the Lexicographic
Product of Two Non-Trivial Graphs G′ and H
Recalling the definition: The lexicographic product of two graphs G′ and H, denoted
by G′ ◦H, is defined as follows: V (G′ ◦H) = V (G′)× V (H). Two distinct vertices [g1,
h1] and [g2, h2] of G′ ◦ H are adjacent if and only if either (g1, g2) ∈ E(G′) or g1 =
g2 and (h1, h2) ∈ E(H). Also recall that r(G′ ◦ H) = 1 if and only if r(G′) = 1 and
r(H) = 1.
Theorem 3. Given two non-trivial graphs G′ and H such that G′ is connected, we
have the following:
1. If r(G′ ◦H) ≥ 2 then r(G′ ◦H) ≤ rc(G′ ◦H) ≤ 2r(G′ ◦H). This bounds are tight.
2. If r(G′ ◦H) = 1 then 1 ≤ rc(G′ ◦H) ≤ 3. This bounds are tight.
Note that in this section we allow graph H to be disconnected i.e. we assume that G′
is non-trivial, connected and that H is non-trivial.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products35
Part 1: r(G′ ◦H) ≥ 2
Since r(G′ ◦H) ≥ 2, either r(G′) ≥ 2 or r(H) ≥ 2. In either case it can be shown that
r(G′ ◦H) ≥ r(G′). Let G be the BFS-Tree rooted at some central vertex, say g0, of G′.
It is easy to see that the depth of G, d(G) = r(G′). Since G ◦H is a connected spanning
subgraph of G′ ◦ H, rc(G′ ◦ H) ≤ rc(G ◦ H). In order to derive an upper bound for
rc(G′ ◦H) in terms of r(G′ ◦H) it is sufficient to derive an upper bound for rc(G ◦H)
in terms of r(G′ ◦H).
Let V (G) = { gi: 0 ≤ i ≤ |G| − 1 } and V (H) = { hi: 0 ≤ i ≤ |H| − 1 }. Since G
is connected and non-trivial, vertex g0 has at least one neighbor. We label this neighbor
as g1 i.e. (g0, g1) ∈ E(G). Since H is a non-trivial graph, there are at least two vertices
in H − h0 and h1. Note that (h0 and h1) need not be adjacent in H.
It is easy to see that G�H is a spanning subgraph of G ◦H. Let G0, G1 . . . , G|H|−1,
H0, H1, . . . , H|G|−1 be the (G,H)-Decomposition of the subgraph of G ◦H that is isomor-
phic to G�H (See Definition 2). Recall that every Gi is isomorphic to G and every
Hj is isomorphic to H. We define root(Gi) = [g0, hi] and root(Hj) = [gj, h0]. From
Observation 6 we know that any vertex [gi, hj] belongs to both Gj and Hi.
Special note on notation:
In the rest of this section for any vertex v = [gi, hj] ∈ V (Gj), we abuse the notation and
simply use `(v) /`([gi, hj]) instead `Gj(v) /`Gj
([gi, hj]). Note that `Hi(v) need not make
sense as Hi need not be a tree.
Definition 3. Let E1 =⊎|H|−1i=0 E(Gi)
⊎|G|−1j=0 E(Hj) and E2 = E(G ◦H) \ E1.
We now define an edge coloring, f : E(G ◦ H) → A ] B where A = {ai : 1 ≤ i ≤
r(G′◦H)} and B = {bi : 1 ≤ i ≤ r(G′◦H)} are ordered sets of colors. Since r(G′◦H) ≥ 2,
both the sets A and B are of cardinality at least 2. Since E(G ◦ H) = E1 ] E2, it is
enough to define separately a coloring for E1 and a coloring for E2.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products36
Coloring the edges of E1:
To define a coloring of E1 it is enough to define an edge coloring for each Gi,
0 ≤ i ≤ |H| − 1 and an edge coloring for each Hj, 0 ≤ j ≤ |G| − 1. We choose
the Layer-wise Coloring, fG0,A (as defined in Definition 1) to color the edges of G0.
We define a new ordered set, B′ = {b′i : 1 ≤ i ≤ r(G′ ◦H)} where b′1 = ar(G′◦H)(∈ A)
and for 2 ≤ i ≤ r(G′ ◦H), b′i = bi ∈ B. For 1 ≤ i ≤ |H| − 1, we choose the Layer-wise
Coloring fGi,B′ to be the edge coloring of Gi. For 0 ≤ j ≤ |G| − 1, we color all the edges
of Hj using the color b1.
Coloring the edges of E2:
For any vertex v ∈ V (G ◦H) let E(v) be the set of edges from E2 that are incident on v.
We partition E(v) into two sets EL(v) and EU(v). Consider some edge (v, u) ∈ E(v), then
(v, u) ∈ EL(v) if and only if `(u) > `(v) and (v, u) ∈ EU(v) if and only if `(u) < `(v).
For two vertices v1 and v2 ∈ V (G ◦ H) we have that (v1, v2) ∈ EL(v1) if and only if
(v1, v2) ∈ EU(v2).
To color the edges of E2 we have the following set of rules:
Rule #1 : All the edges of EL([g0, h0]) are colored b1.
Rule #2 : For all v ∈ V (G0) \ [g0, h0], all the edges of EL(v) are colored a`(v)+1.
Rule #3 : All the edges of EU([gi, h0]), where `([gi, h0]) = 1, are colored br(G′◦H).
Rule #4 : All the edges of EL([g0, h1]) \ {([g0, h1], [gi, h0]) : `([gi, h0]) = 1} are
colored ar(G′◦H).
Rule #5 : For all v ∈ V (G1)\{[g0, h1]}, all the edges from EL(v) are colored b`(v)+1.
Rule #6 : All the edges of EU([gi, h1]) \ {([gi, h1], [g0, h0])}, where `G(gi) = 1, are
colored ar(G′◦H).
Rule #7 : All the remaining edges of E2 are colored b1.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products37
Claim 3. The edge coloring, f , is a rainbow coloring of G ◦H.
Proof. Let u = [gi, hj] and v = [gk, hl] be two distinct vertices of G ◦ H such that
`(v) ≥ `(u). We demonstrate a rainbow path between them by considering the following
cases.
Case 1: [When `(v) ≥ 2]
First we make the following 3 observations.
(a): There exists an A-Rainbow-Path from v to [g0, h0]:
If v ∈ V (G0), then the path PG0(v, [g0, h0]) is an A-Rainbow-Path in G0 with respect
to the edge coloring fG0,A (See Observation 1). If v /∈ V (G0), then ∃ v1 ∈ V (G0) such
that `(v1) ≥ 1, `(v1) = `(v) − 1 and (v1, v) ∈ EL(v1). Such a vertex always exists since
we have assumed that `(v) ≥ 2. Moreover it is also assumed that G, H are non-trivial
graphs and that G is connected. Since v1 ∈ V (G0) there is an A-Rainbow-Path from v1
to [g0, h0] as explained earlier, let this path be P . Specifically P is a {a1, a2, . . . , a`(v1)}-
Rainbow-Path. Since edge (v1, v) is colored a`(v1)+1 by Rule #2, we can extend path P
by (v1, v) to get the required A-Rainbow-Path from v to [g0, h0].
(b): There exists a B-Rainbow-Path from v to [g0, h0]:
If v ∈ V (G1) then there exists an ancestor of v, say v2, in G1 such that `(v2) = 1. The
path P1 = PG1(v, v2) is a {b`(v), b`(v)−1, . . . , b2}-Rainbow-Path from in G1 with respect to
the edge coloring fG1,B′ . The edge (v2, [g0, h0]) is colored b1 by Rule #1. We can extend
P1 by edge (v2, [g0, h0]) to get the required B-Rainbow-Path from vertex v to [g0, h0]. If
v /∈ V (G1), then there exists v3 = [gi′ , h1] ∈ V (G1) such that (v, v3) ∈ EL(v3). Since
v3 ∈ V (G1) as explained earlier there is a {b`(v), b`(v)−1, . . . , b2, b1}-Rainbow-Path, say P2,
from v3 to [g0, h0]. Since the edge (v3, v) is colored b`(v3)+1 (Rule #5), we can extend P2
by (v3, v) to get the required B-Rainbow-Path from v to [g0, h0].
(c): There exist both {b`(v), b`(v)−1, . . . , b2, ar(G′◦H)} and
{a`(v), a`(v)−1, . . . , a2, br(G′◦H)}-Rainbow-Paths from v to any vertex in V (H0) \ {[g0, h0]}:
Recall that `(v) ≥ 2. From observation (a) it can be inferred that there is a {b`(v),
b`(v)−1, . . . , b2}-Rainbow-Path from v to some vertex v4 ∈ V (G1) such that `(v4) = 1.
For any v5 ∈ V (H0) \[g0, h0], the edge (v4, v5) exists and is colored ar(G′◦H) by Rule #6
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products38
or by the Layer-wise Coloring fG1,B′ (whichever applicable). This implies that there
is a {b`(v), b`(v)−1, . . . , b2, ar(G′◦H)}-Rainbow-Path from vertex v to any vertex in V (H0)
\{[g0, h0]}. Similarly from observation (b) it can be inferred that there is a {a`(v), a`(v)−1,
. . . , a2}-Rainbow-Path from vertex v to some vertex v6 ∈ V (G0) such that `(v6) = 1.
Any vertex in V (H0) \ {[g0, h0]} is adjacent to v6 and is colored br(G′◦H) (Rule #3).
Now consider the different cases involving vertex u. If `(u) ≥ 2 then from observa-
tions (a) and (b) it follows that u and v are rainbow connected. If `(u) = 0 then from
observation (c) it follows that u and v are rainbow connected. Finally if `(u) = 1 then
we know that (u, [g0, h0]) ∈ E(G ◦H) and is colored either a1 or b1. Since v has both an
A- and a B-Rainbow-Path to [g0, h0]. It follows that u and v are rainbow connected.
Case 2: [When `(v) ≤ 1]
Without loss of generality we assume that vertex u 6= [g0, h0].
Case 2.a: [When `(v) 6= `(u)]
Vertices u and v are connected by an edge which is a trivial rainbow path between them.
Case 2.b: [When `(v) = `(u) = 0, hence u = [g0, hj] and v = [g0, hl]]
If v = [g0, h0] then we claim that the two length path, P = {v = [g0, h0]}, [g1, h0],
{[g0, hj] = u} is a rainbow path from v to u. The edges of P are colored a1, br(G′◦H)
in that order. To see this: edge (v, [g1, h0]) ∈ E(G0) and G0 is edge colored using the
Layer-wise Coloring, fG0,A. It follows that the edge is colored a1 (See Observation 1).
The edge ([g1, h0], u) ∈ EU([g1, h0]) and is colored br(G′◦H) by Rule #3. Note that edge
(v, [g1, h0]) ∈ E(G◦H) since G is non-trivial and it is assumed that edge (g0, g1) ∈ E(G).
If v ∈ V (H0) \ {[g0, h0]} then we claim that the four length path, P = {u = [g0, hj]},
[g1, h0], [g0, h0], [g1, h1], {[g0, hl] = v} is a rainbow path from u to v. The edges of P are
colored br(G′◦H), a1, b1, ar(G′◦H) in that order. To see this: edge (u, [g1, h0]) ∈ EU([g1, h0])
and is colored br(G′◦H) by Rule #3; edge ([g1, h0], [g0, h0]) ∈ E(G0) and is colored a1 by
the Layer-wise Coloring fG0,A; edge ([g0, h0], [g1, h1]) ∈ EL([g0, h0]) and is colored b1 by
Rule #1; finally edge ([g1, h1], v) is colored ar(G′◦H) by one of the two applicable rules:
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products39
(a): Edge ([g1, h1], v) ∈ E(G1) and G1 is edge colored using the Layer-wise Coloring
GG1,B′ or (b): Edge ([g1, h1], v) ∈ EU([g1, h1]) \{([g0, h0], [g1, h1])} and is colored ar(G′◦H)
by Rule #4.
Case 2.c: [When `(v) = `(u) = 1]
If exactly one of the vertices is in G0. Without loss of generality let u ∈ V (G0) and
v /∈ V (G0) then u = [gi, h0] and v = [gk, hl 6=0]. We claim that the two length path P =
{u = [gi, h0]}, [g0, h0], {[gk, hl] = v} is a rainbow path from u to v. The edges of P are
colored a1, b1 in that order.
If u, v ∈ V (G0) then u = [gi, h0] and v = [gk, h0]. We claim that the four length path
P = {u = [gi, h0]}, [g0, h0], [g1, h1], [g0, h1], {v = [gk, h0]} is a rainbow path from u to v.
The edges are colored a1, b1, ar(G′◦H), br(G′◦H) in that order.
If u, v /∈ V (G0) then u = [gi, hj 6=0] and v = [gk, hl 6=0]. We claim that the four length
path P = {u = [gi, hj]}, [g0, h0], [g1, h0], [g0, h1], {v = [gk, hl]} is a rainbow path from u
to v. The edges of P are colored b1, a1, br(G′◦H), ar(G′◦H) in that order.
We have thus proved that f is a valid rainbow coloring of G◦H. Since f uses 2r(G′◦H)
colors, we have that rc(G ◦H) ≤ 2r(G′ ◦H). Since it is assumed that r(G′ ◦H) ≥ 2 we
have proved the upper-bound in Part 1 of Theorem 3.
Tight Example:
Let G be a connected graph such that r(G) ≥ 2 and diam(G) = 2r(G); let H be any
non-trivial graph. It can be shown that diam(G ◦H) = diam(G) and r(G ◦H) = r(G).
Hence we can conclude that diam(G ◦ H) = 2r(G ◦ H). We know that rc(G ◦ H) ≥
diam(G ◦ H) and rc(G ◦ H) ≤ 2r(G ◦ H) (Part 1 from Theorem 3). It follows that
rc(G ◦H) = 2r(G ◦H). Hence the upper-bound in Part 1 from Theorem 3 is tight.
Part 2: r(G′ ◦H) = 1
We know that if r(G′ ◦H) = 1 then r(G′) = r(G) = 1 and r(H) = 1.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products40
Claim 4. If G′ and H are two non-trivial graphs such that r(G′ ◦ H) = 1 then
rc(G′ ◦H) ≤ 3.
Proof. Since r(G′ ◦ H) = 1 there exists an universal vertex, say u ∈ V (G′ ◦ H).
It can be verified that G′ ◦ H is two vertex connected. Now consider the following
theorem, Theorem Chandran et al.[9]: If D is a connected two-way dominating set in a
graph G, then rc(G) ≤ rc(G[D]) + 3. The proof and definitions involved are given in
[9]. The universal vertex, u, is a trivial dominating set. Moreover since G′ ◦ H is two
vertex connected and consequently two edge connected, it follows that {u} is a two-way
dominating set in G′ ◦H. As a result rc(G′ ◦H) ≤ rc({u}) +3. Since rc({u}) = 0, we
have rc(G′ ◦H) ≤ 3. We have thus proved the claim and the upper-bound in Part 2 of
Theorem 3.
Tight Example:
Consider two non-trivial graphs G and H such that G = K1,n (a star graph) where
n ≥ 2m + 1 and H is a graph such that r(H) = 1 and |H| = m. We claim that
rc(G ◦H) = 3.
Proof. We prove the claim using proof by contradiction.
Let f be a rainbow coloring of G ◦ H using at most 2 colors, say a1 and a2. Let
V (G) = {g0, g1, . . . , gn} where g0 is the central vertex of G. Similarly let V (H) =
{h0, h1, . . . , hm−1}. Let H0 be the induced subgraph of G ◦H with vertex set, V (H0) =
{[g0, hi] : 0 ≤ i ≤ m− 1}. Note that H0 is isomorphic to H.
For 1 ≤ i ≤ n, define the function fi : {[gi, h0]} × V (H0) → {a1, a2} as fi(([gi, h0],
[g0, hj])) = f(([gi, h0], [g0, hj])). Each of the functions, fi, are one among 2|H| possible
functions. Since n > 2|H|, by pigeon hole principle there must exist some fi and fk
such that i 6= k and fi = fk. If so there is no rainbow path between the vertices [gi, h0]
and [gk, h0] with respect to the edge coloring f . This is beacause any rainbow path with
respect to f between the two vertices is of length 2. Now any two length path between the
vertices is of the form [gi, h0], v, [gk, h0] where the intermediate vertex, v ∈ V (H0). We
know that fi([gi, h0], v) = fk([gk, h0], v) = f([gi, h0], v) = f([gk, h0], v) for all v ∈ V (H0).
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products41
This is a contradiction. Hence f is not a rainbow coloring of G ◦H.
Therefore any rainbow coloring of G◦H uses at least 3 colors. Now it follows from Claim
4 that rc(G ◦H) = 3. Hence the upper-bound in Part 2 from Theorem 3 is tight.
Proof of Theorem 3: The upper bounds follow from Claim 3 and Claim 4. The
lower bounds are trivial.
4.4 Rainbow Connection Number of the Strong
Product of Two Non-Trivial, Connected
Graphs G′ and H ′
Recalling the definition: The strong product of two graphs G′ and H ′, denoted by
G′�H ′, is defined as follows: V (G′�H ′) = V (G′)×V (H ′). The edge set ofG′�H ′ consists
of two types of edges. An edge ([g1, h1], [g2, h2]) is Type-1 if and only if either g1 = g2
and (h1, h2) ∈ E(H ′) or h1 = h2 and (g1, g2) ∈ E(G′). An edge is of Type-2 if and only if
(g1, g2) ∈ E(G′) and (h1, h2) ∈ E(H ′). Also recall that r(G′ �H ′) = max{r(G′), r(H ′)}
and diam(G′ �H ′) = max{diam(G′), diam(H ′)}.
We assume without loss of generality that r(G′) ≥ r(H ′) as G′ �H ′ is isomorphic to
H ′ �G′. Let rmax = r(G′). Let G and H be BFS-Trees rooted at some central vertices,
g0 and h0 respectively of G′ and H ′. It is easy to see that the depths of G and H are
d(G) = r(G′) and d(H) = r(H ′) respectively. Let V (G) = {gi : 0 ≤ i ≤ |G| − 1} and
V (H) = {hi : 0 ≤ i ≤ |H| − 1}. Since G and H are non-trivial connected trees there
is atleast one neighbor for g0 and h0 in G and H respectively. In the remainder of the
section we always let these vertices be g1 and h1 respectively. Therefore (g0, g1) ∈ E(G)
and (h0, h1) ∈ E(H).
Let Lw(G) = {gi ∈ V (G): `G(gi) = w } for 0 ≤ w ≤ d(G) and Lx(H) = {hi ∈ V (H):
`H(hi) = x } for 0 ≤ x ≤ d(H). We define Vw,x = Lw(G) × Lx(H) for 0 ≤ w ≤ d(G)
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products42
and 0 ≤ x ≤ d(H).
Since G�H is a spanning subgraph of G′�H ′, rc(G′�H ′) ≤ rc(G�H). So in order
to derive an upper bound for rc(G′ �H ′) in terms of r(G′ �H ′) it is enough to derive
an upper bound for rc(G � H) in terms of d(G) = rmax = r(G′). Recall that we have
assumed that r(G′) ≥ r(H ′) and therefore r(G′ �H ′) = r(G′).
We define an edge coloring, f : E(G�H)→ A ] B ] {c, d} where A = {ai : 1 ≤ i ≤
d(G)} and B = {bi : 1 ≤ i ≤ d(G)} are ordered sets of colors; and c and d are colors
that are not in A]B. Since E(G�H) is the disjoint union of Type-1 and Type-2 edges,
we can define the coloring for Type-1 and Type-2 edges separately.
Coloring the Type-1 edges
Note that if we restrict the edge set of G � H to Type-1 edges alone then the sub-
graph thus obtained is isomorphic to G�H, the Cartesian Product of G and H. Let
G1, G2, . . . , G|H|−1, H1, H2, . . . , H|G|−1 be the (G-H)-Decomposition of G�H (Type-1
edges) as defined in Definition 2. For 0 ≤ j ≤ |H| − 1, define root(Gj) = [g0, hj]
and for 0 ≤ i ≤ |G| − 1, define root(Hi) = [gi, h0]
Recall that A = {ai : i ≤ i ≤ d(G)} and B = {bi : 1 ≤ i ≤ d(G)} are ordered sets of
colors. We define several new ordered (multi) sets of colors by slightly modifying the sets
A and B. First we define the ordered set, A0 = {a0i : 1 ≤ i ≤ d(G)} where a01 = c and
a0i = ai(∈ A) for 2 ≤ i ≤ d(G). Also for 1 ≤ w ≤ d(H), we define ordered multi-sets,
Aw = {awi : 1 ≤ i ≤ d(G)} and Bw = {bwi : 1 ≤ i ≤ d(G)} where awi = d and bwi = d for
1 ≤ i ≤ w and awi = ai(∈ A) and bwi = bi(∈ B) for w + 1 ≤ i ≤ d(G).
Rules to color the Type-1 edges:
T1-R1: We choose the Layer-wise Coloring fH0,A to color the edges of H0.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products43
T1-R2: For each Hi such that `G(gi) = 1, we choose the Layer-wise coloring fHi,B to color
the edges of Hi.
T1-R3: For each Hi such that `G(gi) ≥ 2, we color all the edges of Hi using d.
T1-R4: For 0 ≤ w ≤ d(H) we choose fGi,Aw to color the edges of Gi if w is even and we
choose fGi,Bw to the color the edges of Gi if w is odd.
Coloring the Type-2 edges
Observation 8. If an edge ([gi, hj], [gk, hl]) ∈ E(G�H) is of Type-2 such that [gi, hj] ∈
Vw,x and [gk, hl] ∈ Vy,z then we have |w − y| = 1 and |x− z| = 1.
Proof. Since the edge ([gi, hj], [gk, hl]) is of Type-2, edges (gi, gk) and (hj, hl) are
edges of trees G and H respectively. Therefore |w − y| = |`G(gi) − `G(gk)| = 1 and
|x− z| = |`H(hj)− `H(hl)| = 1.
Rules to color the Type-2 edges:
T2-R1: Let ([gi, hj], [gk, hl]) ∈ E(G�H) be an edge of Type-2 such that [gi, hj] ∈ Vy,z and
[gk, hl] ∈ Vy+1,z+1, then define
f(([gi, hj], [gk, hl])) =
az+1 if |z − y| is even
bz+1 if |z − y| is odd
Note that z + 1 = `H(hl) ≤ d(H) ≤ d(G) and therefore az+1 and bz+1 exist.
T2-R2: Let ([gi, hj], [gk, hl]) ∈ E(G�H) such that [gi, hj] ∈ V1,1 and [gk, hl] ∈ V2,0 then we
choose f(([gi, hj], [gk, hl])) = a2.
Note that if [gk, hl] ∈ V2,0 then `G(gk) = 2 and thus d(G) ≥ 2 and a2 exists.
T2-R3: All the remaining edges of Type-2 are colored d.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products44
A-Reachable and B-Reachable Vertices:
We define the following 2 concepts with respect to the edge coloring f . We define a vertex
[gi, hj] ∈ V (G�H) to be A-Reachable if there exists an A-Rainbow-Path from [gi, hj] to
the vertex [g0, h0]. We define [gi, hj] to be B-Reachable if there exists a B-Rainbow-Path
from [gi, hj] to some vertex in V1,0.
We define two subsets, RA and RB of V (G�H):
RA =⊎
0≤z≤d(H)
V0,z⊎
1≤y≤z, |y−z| is even
Vy,z⊎
2≤y≤d(G)
Vy,0⊎
2≤z<y, z is even
Vy,z
RB =⊎
0≤z≤d(H)
V1,z⊎
2≤y≤z, |y−z| is odd
Vy,z⊎
z<y, z is odd
Vy,z
It is easy to verify that RA ∪RB = V (G�H), but RA ∩RB is non-empty.
Claim 5. If u ∈ RA, then u is A-Reachable with respect to the edge coloring f .
Proof. Let u = [gi, hj] ∈ Vy,z. We consider the following 4 cases.
Case 1: [When u ∈ V0,z where 0 ≤ z ≤ d(H)]
From Rule T1-R1 we know that the edges of H0 are colored using the Layer-wise Col-
oring, fH0,A. Hence by Observation 1 there is an A-Rainbow-Path from vertex u to
root(H0) = [g0, h0]. It follows that u is A-Reachable.
Case 2: [When u ∈ Vy,z where 1 ≤ y ≤ z and |y − z| is even ]
Since `G(gi) = y, the path from gi to g0 in G has y+1 vertices. Let this path be {gi = gi0},
gi1 , . . . , {giy = g0}. Let hj′ be the ancestor of hj in H such that `H(hj′) = z − y. Let
{hj = hj0}, hj1 , . . . , {hjy = hj′} be the path from hj to hj′ in H. It has y + 1 ver-
tices. Clearly P1 = {[gi, hj] = [gi0 , hj0 ]}, [gi1 , hj1 ], . . . , [g0, hj′ ] is a path in G �H whose
edges are colored az, az−1, . . . , az−y+1 in that order (By Rule T2-R1). Note that if y = z
then hj′ = h0 and P1 is the required A-Rainbow-Path from u to [g0, h0]. If z < y then
since [g0, hj′ ] ∈ V (H0), by Case 1 there is a A-Rainbow-Path, say P2, from [g0, hj′ ] to
[g0, h0]. In particular P2 is a {az−y, az−y−1, . . . , a1} -Rainbow-Path. Clearly P = P1. P2
is a {a1, a2, . . . , az}-Rainbow-Path from vertex u to [g0, h0] with respect to coloring f .
Hence u is A-Reachable.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products45
Case 3: [When u ∈ Vy,0 where 2 ≤ y ≤ d(G), hence u = [gi, h0] ∈ V (G0)]
Let u1 = [gi′ , h0] be an ancestor of u in G0 such that `G0(u1) = 2. By Rule T1-R4 G0
is edge colored using the Layer-wise Coloring fG0,A0 . The path from vertex u to u1 in
G0, say P1, is rainbow colored using colors from the set {ay, ay−1, . . . , a3}. Let gi′′ be
the parent of gi′ in G. Since H is non-trivial, h1 exists and (h0, h1) ∈ E(H). Therefore
([gi′ , h0], [gi′′ , h1]) ∈ E(G � H) and is colored a2 by Rule T2-R2. Since `G(gi′′) = 1,
(gi′′ , g0) ∈ E(G) and therefore ([gi′′ , h1], [g0, h0]) ∈ E(G � H) and is colored a1 by Rule
T2-R1. Hence the path P = P1. ([gi′ , h0], [gi′′ , h1], [g0, h0]) is an A-Rainbow-Path from
vertex u to [g0, h0]. Hence u is A-Reachable.
Case 4: [When u ∈ Vy,z where y > z ≥ 2 and z is even ]
Vertex u = [gi, hj] ∈ V (Gj). Let u1 = [gi′ , hj] be an ancestor of u in Gj such that
`Gj(u1) = z. Let P1 be the path in Gj from vertex u to u1. Since `H(hj) = z is even, by
Rule T1-R4, Gj is edge colored using the Layer-wise Coloring fGj ,Az . The edges of P1
are colored ay, ay−1, . . . , az+1 in that order. Since u1 = [gi′ , hj] ∈ Vz,z and z ≥ 2, by Case
2 we have a {az, az−1, . . . , a1}-Rainbow-Path, say P2, from vertex u1 to vertex [g0, h0].
Clearly P = P1. P2 is an A-Rainbow-Path from vertex u to [g0, h0]. Hence vertex u is
A-Reachable.
Claim 6. If u ∈ RB, then u is B-Reachable with respect to the edge coloring f .
Proof. Let u = [gi, hj] ∈ Vy,z. We consider the following 3 cases.
Case 1: [When u ∈ V1,z for 0 ≤ z ≤ d(G)]
Vertex u ∈ V (Hi) with root(Hi) = [gi, h0]. Since `G(gi) = 1, Hi is edge colored using
the Layer-wise Coloring fHi,B by Rule T1-R2. From Observation 1 we infer that there
is a {b1, b2, . . . , bz}-Rainbow-Path from vertex u to [gi, h0] ∈ V1,0 in Hi. If follows that u
is B-Reachable with respect to the edge coloring f .
Case 2: [When u ∈ Vy,z where 2 ≤ y ≤ z and |y − z| is odd ]
Let u = [gi, hj] ∈ Vy,z. InG, let gi′ be the ancestor of gi with `G(gi′) = 1. Since `G(gi) = y,
the path in G from gi to gi′ in G has y vertices. Let {gi = gi0}, gi1 , . . . , {giy−1 = gi′} be
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products46
that path. Similarly in H let hj′ be the ancestor of hj with `H(hj′) = z − y + 1. Then
the path in H from hj to hj′ has y vertices. Let {hj = hj0}, hj1 , . . . , {hjy−1 = hj′} be
that path. Clearly P1 = [gi, hj], [gi1 , hj1 ], . . . , [gi′ , hj′ ] is a path in G � H and its edges
are colored bz, bz−1, . . . , bz−y+2 in that order (By Rule T2-R1). Now [gi′ , hj′ ] ∈ V1,z−y+1
and by Case 1 there is a {b1, b2, . . . , bz−y+1}-Rainbow-Path, say P2, from [gi′ , hj′ ] to
[gi′ , h0] ∈ V1,0. Clearly P = P1. P2 is a B-Rainbow-Path from u to [gi′ , h0] ∈ V1,0. It
follows that u is B-Reachable with respect to the edge coloring f .
Case 3: [When u ∈ Vy,z where y > z and z is odd]
Let u = [gi, hj] ∈ Vy,z. We consider the following two sub-cases.
Case 3.a: [When y = z + 1 ]
Since `H(hj) = z, the path from hj to h0 in H has z + 1 vertices. Let this path be
{hj = hj0}, hj1 , . . . , {hjz = h0}. Similarly let gi′ be the ancestor of gi in G such that
`G(gi′) = 1. Since `G(gi) = z + 1 the path from gi to gi′ in G has z + 1 vertices. Let
this path be {gi = gi0}, gi1 , . . . , {giz = gi′}. Clearly {u = [gi, hj]}, [gi1 , hj1 ], . . . , [gi′ , h0]
is a path in G �H and is colored bz, bz−1, . . . , b1 in that order (By Rule T2-R1). Since
[gi′ , h0] ∈ V1,0 vertex u is B-Reachable.
Case 3.b: [When y > z + 1 ]
Vertex u ∈ Gj. Let u1 = [gi′′ , hj] be an ancestor of u in Gj such that `Gj(u1) = z + 1.
Since z is odd, by Rule T1-R4 we know that Gi is edge colored using the Layer-wise
Coloring fGj ,Bz . The edges of path, P1 = PGj(u, u1) are colored by, by−1, . . . , bz+2 in that
order and is a rainbow path. Since u1 ∈ Vz+1,z by Case 3.a there is a {bz, bz−1, . . . , b1}-
Rainbow-Path, say P2, from vertex u1 to some vertex, say u2 in V1,0. Clearly P = P1. P2
is a B-Rainbow-Path from vertex u to u2 ∈ V1,0. It follows that u is B-Reachable with
respect to the coloring f .
Claim 7. Let u ∈ V (G�H) \ {[g0, h0]} then we have the following:
(a) If u ∈ RA\RB then there exists u1 ∈ RB such that (u, u1) ∈ E(G�H) and is colored
d.
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products47
(b) If u ∈ RB \RA then there exists u1 ∈ RA such that (u, u1) ∈ E(G�H) and is colored
d.
Proof. We consider the following cases.
Case 1: [When u ∈ V0,z where 0 ≤ z ≤ d(H), i.e u ∈ V (H0) ]
In this case u = [g0, hj] ∈ RA \ RB. We take u1 = [g1, hj]. Since G is non-trivial,
vertex g1 exists and (g0, g1) ∈ E(G). Since `G(gi) = 1, we have u1 ∈ V1,z ⊆ RB,
where 1 ≤ z = `H(hj) ≤ d(H). Note that z 6= 0 since u 6= [g0, h0]. Now the edge
(u, u1) = ([g0, hj], [g1, hj]) ∈ E(Gj). By Rule T1-R4, Gj is edge colored using the Layer-
wise Coloring fGj ,Az or fGj ,Bz , where z = `H(hj), depending on whether z is even or
odd. Recalling that Az = {az1, az2, . . . , azd(G)} and Bz = {bz1, bz2, . . . , bzd(G)} the edge (u, u1)
is colored either az1 or bz1. Since z ≥ 1, az1 = bz1 = d and hence the edge (u, u1) is colored
either az1 = d or bz1 = d.
Case 2: [When u ∈ V1,z where 0 ≤ z ≤ d(H)]
In this case u ∈ RB. Note that if z is odd then V1,z ⊆ RA ∩RB. So we may assume that
z is even.
Case 2.a: [When u ∈ V1,0]
Let u = [gi, h0] ∈ V1,0 with `G(gi) = 1. We take u1 = [g0, h1]. Since H is non-
trivial, h1 exists and (h0, h1) ∈ E(H). Also edge (g0, gi) ∈ E(G). Therefore the edge
(u, u1) = ([gi, h0], [g0, h1]) ∈ E(G �H). It is easy to see that u1 ∈ V0,1 ⊆ V (H0) ⊆ RA.
The edge (u, u1) is colored d by Rule T2-R3.
Case 2.b: [When u ∈ V1,z where 2 ≤ z ≤ d(H) and z is even]
Let u = [gi, hj] ∈ V1,z with `G(gi) = 1. Then (g0, g1) ∈ E(G). We take u1 = [g0, hj] ∈
V0,z ⊆ RA, then (u, u1) = ([gi, hj], [g0, hj]) ∈ E(Gj). By Rule T1-R4, Gj is edge colored
using the Layer-wise Coloring fGj ,Az , since z = `H(hj) is even. Since z ≥ 2, az1 = bz1 = d
and the edge (u, u1) is colored d.
Case 3: [When u ∈ Vy,z where 2 ≤ y ≤ z]
Let u = [gi, hj] ∈ Gj. Let u1 = [gi′ , hj] be the parent of u in Gj. Since `G(gi′) =
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products48
`G(gi)−1 = y−1, u1 ∈ Vy−1,z. We claim that if u ∈ Vy,z ⊆ RA\RB then u1 ∈ Vy−1,z ⊆ RB
and if u ∈ Vy,z ⊆ RB \ RA then u1 ∈ Vy−1,z ⊆ RA. To see this first note that⊎1≤y≤z, |y−z| is even Vy,z ⊆ RA and
⊎1≤y≤z, |y−z| is odd Vy,z ⊆ RB. Now the following is
easy to see: if 2 ≤ y ≤ z and Vy,z ⊆ RB \RA (respectively RA \RB) then 1 ≤ y− 1 < z
and Vy−1,z ⊆ RA (respectively RB) since the parity of |y− z| is different from the parity
of |(y− 1)− z|. By Rule T1-R4, Gj is edge colored using the Layer-wise Coloring fGj ,Az
or fGj ,Bz depending on whether z = `H(hj) is even or odd. From the definition of the
sets Az and Bz we have that, for 1 ≤ i ≤ z, azi = bzi = d. Since 2 ≤ y ≤ z, edge (u, u1)
is colored azy = d or bzy = d.
Case 4: [When u ∈ Vy,0 where 2 ≤ y ≤ d(G)]
In this case u ∈ RA \ RB. Let u = [gi, h0] ∈ V (Hi). Let u1 = [gi, h1] ∈ V (Hi).
Since (h0, h1) ∈ E(H), (u, u1) = ([gi, h0], [gi, h1]) ∈ E(Hi). Vertex u1 ∈ Vy,1 ⊆ RB as
(z = 1) < 2 ≤ y and 1 is odd. Since `G(gi) = y ≥ 2, by Rule T1-R3 all the edges of Hi
are colored d. Hence (u, u1) is colored d.
Case 5: [When u ∈ Vy,z where 1 ≤ z < y]
Let u = [gi, hj] ∈ V (Hi). Let u1 = [gi, hj′ ] be the parent of u in Hi. Then (u, u1) =
([gi, hj], [gi, hj′ ]) ∈ E(Hi) and `H(hj′) = `H(hj) − 1 = z − 1 ≥ 0. Since y > z − 1 if
u ∈ Vy,z ⊆ RA \ RB (respectively RB \ RA) then z − 1 is odd (even) and u ∈ Vy,z−1 ⊆
RB (respectively RA). Also since y ≥ 2 by Rule T1-R3, all the edges of Hi are colored
d.
Lemma 1. The edge coloring f is a rainbow coloring of G�H.
Proof. We show that any distinct pair of vertices, u and v from G�H have a rainbow
path between them with respect to the edge coloring f . Since V (G � H) = RA ∪ RB,
vertex u ∈ RA or u ∈ RB. The same applies to vertex v. Let u = [g0, h0]. If v ∈ RA
then by Claim 5 there is an A-Rainbow-Path from v to u = [g0, h0]. If v ∈ RB then
by Claim 6 there is a B-Rainbow-Path from v to some vertex v′ ∈ V1,0. We know that
Chapter 4. Rainbow Connection Number of Graph Power and Graph Products49
(v′, [g0, h0]) ∈ E(G0) and is colored c by the Layer-wise Coloring fG0,A0 . Hence there is
a ({c} ]B)-Rainbow-Path from vertex v to u = [g0, h0].
We may now assume that u, v 6= [g0, h0]. We have the following three cases:
Case 1: [When one of the vertices is in RA and the other is in RB]
Without loss of generality let u ∈ RA and v ∈ RB. By Claim 5 there is an A-Rainbow-
Path between u and [g0, h0], let this path be P1. Similarly by Claim 6 there is a B-
Rainbow-Path between v and some vertex v1 = [gi, h0] ∈ V1,0, let this path be P2. Now
v1 ∈ V (G0) and `G(gi) = 1, hence (g0, g1) ∈ E(G) and (v1, [g0, h0]) ∈ E(G0). By Rule
T1-R4 G0 is edge colored using the Layer-wise Coloring fG0,A0 . The edge (v1, [g0, h0]) is
colored a01 = c. Clearly the path P = P1. ([g0, h0], v1). P2 is a (A]B]{c})-Rainbow-Path
between vertices u and v.
Case 2: [When both the vertices are in RA \RB]
By Claim 7 there exists a vertex u1 ∈ RB ⊂ V (G�H) such that (u, u1) ∈ E(G�H) and
is colored d. Since v ∈ RA and u1 ∈ RB by Case 1 there is a (A]B]{c})-Rainbow-Path
from vertex v to u1, say P1. Clearly P = P1. (u1, u) is a rainbow path from v to u.
Case 3: [When both the vertices are in RB \RA]
By Claim 7 there exists a vertex u2 ∈ RA ⊂ V (G � H) such that (u, u2) ∈ E(G � H)
and is colored d. Now using arguments similar to Case 2 we can prove that there exists
a rainbow path between vertices u and v.
Theorem 4. If G′ and H ′ are two non-trivial connected graphs then r(G′ � H ′) ≤
rc(G′ �H ′) ≤ 2r(G′ �H ′) + 2
Proof. The rainbow coloring f uses |A|+ |B|+ |{c, d}| = 2d(G) + 2 = 2r(G�H) + 2
colors. Since d(G) = r(G′) = r(G′ � H ′) From of Lemma 1 the upper bound follows.
The lower bound is trivial.
Bibliography
[1] M. Basavaraju, L.S. Chandran, D. Rajendraprasad, A. Ramaswamy: Rainbow Con-
nection Number and Radius; Arxiv preprint arXiv:1011.0620v1 [math.CO] (2010).
[2] W. Imrich, S. Klavzar: Product Graphs, Structure and Recognition; John Wiley &
Sons, Inc. (2000).
[3] X. Li, Y. Sun: Rainbow Connections of Graphs - A survey; Arxiv preprint
arXiv:1101.5747v2 [math.CO] (2011).
[4] G. Chartrand, P. Zhang: Chromatic Graph Theory; Chapman & Hall (2008).
[5] G. Chartrand, G. L. Johns, K. A. McKeon, P. Zhang: Rainbow Connection in
Graphs; Math. Bohem 133, Pages 85-98 (2008).
[6] S. Chakraborty, E. Fischer, A. Matsliah, R. Yuster: Hardness and Algorithms for
Rainbow Connectivity; Journal of Combinatorial Optimization, Pages 1-18 (2009).
[7] Y. Caro, A. Lev, Y. Roditty, Z. Tuza, R. Yuster: On Rainbow Connection; The
Electronic Journal of Combinatorics 15 (2008).
[8] M. Krivelevich, R. Yuster: The Rainbow Connection of a Graph is (at most) Recip-
rocal to its Minimum Degree; Journal of Graph Theory 63, Pages 185-191 (2010).
[9] L. S. Chandran, A. Das, D. Rajendraprasad, N. M. Varma: Rainbow Connection
Number and Connected Dominating Sets; EUROCOMB (2011).
[10] X. Li, Y. Sun: Characterize Graphs with Rainbow Connection Number m− 2 and
Rainbow Connection Numbers of Some Graph Operations (2010).
50
BIBLIOGRAPHY 51
[11] M. Basavaraju, L.S. Chandran, D. Rajendraprasad, A. Ramaswamy: Rain-
bow Connection Number of Graph Power and Graph Products; Arxiv preprint
arXiv:1104.4190v1 [math.CO] (2011).
[12] A. Ericksen: A matter of Security; Graduating Engineer & Computer Careersx,
Pages 24-28 (2007).
[13] Ingo Schiermeyer: Rainbow Connection in Graphs with Minimum Degree Three;
IWOCA 2009, LNCS 5874, Pages 432-437 (2009).
[14] G. Chartrand, F. Okamoto, P. Zhang: Rainbow Trees in Graphs and Generalized
Connectivity; Networks 55, Pages 360-367 (2010).
[15] A. Kemnitz, I. Schiermeyer: Graphs with Rainbow Connection Number Two; Dis-
cuss. Math. Graph Theory (2011).
[16] X. Li, Y. Sun: Rainbow Connection Numbers of Complementary Graphs; Utilitas
Math. 86 (2011).
[17] L. Chen, X. Li, H. Lian: Nordhaus-Gaddum-type Theorem for Rainbow Connection
Number of Graphs; Utilitas Math. 86 (2011).
[18] X. Li, Y. Sun: Rainbow Connection Numbers of Line Graphs; Ars Combin. 100
(2011).
[19] X. Li, Y. Sun: Upper Bounds for the Rainbow Connection Numbers of Line Graphs;
Graphs & Combin. (2011).
[20] H. Li, X. Li, S. Liu: Rainbow Connection in Graphs with Diameter 2; Arxiv preprint
arXiv:1101.2765v1 [math.CO] (2011).
[21] X. Li, Y. Sun: On the Strong Rainbow Connection Number of a Graph; Bull.
Malays. Math. Sci. Soc. (2011).
[22] T. Gologranc and G. Meki: Rainbow Connection and Graph Products; IMFM
preprint (2011).