Published on

02-Jul-2016View

212Download

0

Embed Size (px)

Transcript

<ul><li><p>Discrete Applied Mathematics 127 (2003) 415429www.elsevier.com/locate/dam</p><p>Parameterized complexity of vertex colouring</p><p>Leizhen Cai</p><p>Department of Computer Science and Engineering, The Chinese University of Hong Kong, Shatin,Hong Kong, China</p><p>Received 19 April 2000; received in revised form 15 October 2001; accepted 5 November 2001</p><p>To Derek Corneil for his love of graphs</p><p>Abstract</p><p>For a family F of graphs and a nonnegative integer k, F + ke and F ke, respectively,denote the families of graphs that can be obtained from F graphs by adding and deleting atmost k edges, and F + kv denotes the family of graphs that can be made into F graphs bydeleting at most k vertices.This paper is mainly concerned with the parameterized complexity of the vertex colouring</p><p>problem on F + ke, F ke and F + kv for various families F of graphs. In particular, itis shown that the vertex colouring problem is 5xed-parameter tractable (linear time for each5xed k) for split + ke graphs and split ke graphs, solvable in polynomial time for each 5xedk but W [1]-hard for split + kv graphs. Furthermore, the problem is solvable in linear time forbipartite + 1v graphs and bipartite + 2e graphs but, surprisingly, NP-complete for bipartite + 2vgraphs and bipartite + 3e graphs. ? 2002 Published by Elsevier Science B.V.</p><p>MSC: 05C15; 05C85; 68Q17; 68Q25; 68R10</p><p>Keywords: Vertex colouring; Fixed-parameter problem; Parameterized complexity; Split graph; Bipartitegraph</p><p>1. Introduction</p><p>Many graph problems are intractable for general graphs but tractable for variousspecial families of graphs. Let be an NP-hard problem and F be a family of graphsfor which is solvable in polynomial time. Consider the situation that an instance Gof is not an F graph, but is close to an F graph in the sense that it can be made</p><p> This work was partially supported by an Earmarked Research Grant from the Research Grants Councilof Hong Kong.</p><p> Fax: +852-2603-5024.E-mail address: lcai@cse.cuhk.edu.hk (L. Cai).</p><p>0166-218X/03/$ - see front matter ? 2002 Published by Elsevier Science B.V.PII: S0166 -218X(02)00242 -1</p></li><li><p>416 L. Cai /Discrete Applied Mathematics 127 (2003) 415429</p><p>into an F graph by altering a few vertices or edges. We often need to deal with sucha situation in solving practical problems because of incomplete information or errorsin data. In most cases, polynomial algorithms for solving on F graphs cannot beapplied directly to G and may become totally useless, and the NP-hardness of forgeneral graphs does not imply the tractability of on G. This calls for a study of thecomplexity of for the families of graphs formed by graphs like G that are nearlyF graphs. Surprisingly, very little attention, if any, has been paid to the complexityof graph problems for such graph families despite the enormous amount of work ontheir complexity for various special families of graphs.We now discuss the situation in a formal setting. Let k be a nonnegative integer.</p><p>We use F+ke to denote the family of graphs that can be obtained from F graphs byadding at most k edges (but no new vertices). Similarly, we use F ke (respectively,F kv) to denote the families of graphs that can be obtained from F graphs bydeleting at most k edges (vertices), and F + kv to denote the family of graphs thatcan be made into F graphs by deleting at most k vertices. Clearly, every graph is anF + ke graph for some k whenever F contains all edgeless graphs. Similarly, everygraph is an Fke graph for some k whenever F contains all complete graphs, and anF+kv graph for some k whenever F contains the single-vertex graph. (However, thiskind of statement does not hold for F kv graphs.) Therefore, for most F, F+ ke,F ke, and F + kv parameterize graphs with respect to F, and will be referred toas parameterized graph families.The observations in the previous paragraph imply that for most graph families F, if</p><p>k is part of input, problem is NP-hard for F+ ke, F ke and F+ kv. However,its complexity status becomes elusive when k is not part of input but a 5xed constant,i.e., when we regard problem for F+ ke (similarly, for other parameterized graphfamilies) as a 5xed-parameter problem. Is solvable in polynomial time for each 5xedk? If so, is 5xed-parameter tractable, i.e., is it solvable in polynomial time (as afunction of instance size) with the degree of the polynomial independent of k? If not,does the complexity of jump from polynomial to NP-hard when some k increasesto k + 1? In this paper, we try to answer these questions for the following classicalVERTEX COLOURING problem ([GT4] in [11]):Instance: Graph G = (V; E), positive integer t6 |V |.Question: Is G t-colourable, i.e., is there a function f :V {1; 2; : : : ; t} such that</p><p>for every edge uv of G, f(u) =f(v)?The problem is NP-complete even for t = 3 [12], but polynomial-time solvable for</p><p>many special families of graphs, such as bipartite graphs, split graphs, interval graphsand partial k-trees [19].The research in this paper is mainly inspired by the parameterized complexity theory</p><p>of Downey and Fellows [9], and also motivated by the polynomial-time solvability ofmany NP-hard problems on partial k-trees [14,7]. An algorithm for a 5xed-parameterproblem (I; k), where I is an instance and k is the parameter, is uniformly polynomialif it runs in time O(f(k)|I |c), where |I | is the size of I , for an arbitrary functionf(k) and a constant c independent of k. A 5xed-parameter problem is 3xed-parametertractable if it admits a uniformly polynomial algorithm. This notion of 5xed-parametertractability attempts to distinguish tractable and intractable 5xed-parameter problems,</p></li><li><p>L. Cai /Discrete Applied Mathematics 127 (2003) 415429 417</p><p>which is very akin to the notion of polynomial algorithms in distinguishing tractableand intractable problems. Downey and Fellows also de5ned a W -hierarchy, whichcorresponds to NP-completeness, to capture intractable 5xed-parameter problems: a5xed-parameter problem that is hard for any level of the hierarchy is unlikely to be5xed-parameter tractable. The reader is referred to their monograph [9] for the theoryof parameterized complexity.In this paper, we study the complexity of VERTEX COLOURING from the parameterized</p><p>complexity point of view. Usually, we parameterize a problem by a parameter asso-ciated with solutions, such as t in VERTEX COLOURING. However, this approach doesnot make the parameterized complexity theory applicable to VERTEX COLOURING as theproblem is NP-complete for every 5xed t 3. In this paper we parameterize VERTEXCOLOURING by a parameter linked to the input graph instead, and demonstrate throughinteresting results that this new way of parameterizing problems adds a new dimensionto the applicability of the parameterized complexity theory.We prove that VERTEX COLOURING is linear-time solvable for each 5xed k for split+ke</p><p>graphs and split ke graphs, polynomial-time solvable for each 5xed k but W [1]-hardfor split + kv graphs (Section 4). Furthermore, we show that it is linear-time solvablefor bipartite + 1v graphs and bipartite + 2e graphs but, surprisingly, NP-complete forbipartite+ 2v graphs and bipartite+ 3e graphs (Section 5). We also give some generalresults regarding the colouring problem for parameterized graphs in Section 3, anddiscuss future research directions in Section 6. To set the stage for our discussion, weestablish notation and de5nitions and give some elementary results in Section 2.</p><p>2. Preliminaries</p><p>All graphs in this paper are undirected simple graphs. We follow standard notationsin graph theory (see [22], for instance) with the convention that m and n, respectively,denote the number of edges and number of vertices of the input graph. A graph is asplit graph if its vertex set can be partitioned into an independent set and a clique. Splitgraphs are precisely the family of graphs that contain no induced subgraph isomorphicto 2K2, C4 or C5 [10].For two nonadjacent vertices u and v of G, we use G(u = v) to denote the graph</p><p>obtained from G by identifying u with v, i.e., replacing vertices u and v by a newvertex and connecting all vertices adjacent to either u or v to the new vertex. For anedge e in G, G e denotes the graph obtained from G by contracting edge e, i.e.,deleting e and identifying its two ends.A family F of graphs is hereditary if for every graph G F, all its induced sub-</p><p>graphs are F graphs; closed under edge contraction if for every G F and everyedge e of G, G eF; and closed under identi3cation of nonadjacent vertices if forevery G F and every pair of nonadjacent vertices u and v of G, G(u= v)F. Notethat for every hereditary family F and every k, F kv=F.A modulator of an F + ke graph G is a subset Ek of at most k edges in G such</p><p>that GEk F. Modulators of F ke and F+ kv graphs are de5ned similarly. It isclear that F+ ke F+ k e for every k6 k and F+ ke = (F+ (k 1)e) + 1e for</p></li><li><p>418 L. Cai /Discrete Applied Mathematics 127 (2003) 415429</p><p>every k 1, and similar relations hold for F ke and F+ kv. However we shouldnote that normally (F+ ke) ke =F. The following properties of parameterized Fgraphs are useful and can be easily proved from de5nitions.</p><p>Lemma 2.1. Let F be hereditary. Then for every k; F ke; F + ke and F + kvare all hereditary; and; furthermore; F ke F+ kv and F+ ke F+ kv.We note that the set inclusions in the above lemma may not hold when F is not</p><p>hereditary. For example, let C be the family of all cycles. Then C 1e is the familyof all paths and cycles, and C+1e is the family of all cycles with at most one chord.Neither family is a subset of C + 1v.</p><p>Lemma 2.2. If F is closed under edge contraction then for every k; F ke is alsoclosed under edge contraction.</p><p>Lemma 2.3. If F is closed under identi3cation of nonadjacent vertices; then for everyk; F+ ke is also closed under identi3cation of nonadjacent vertices.</p><p>We now turn to vertex colourings. A t-colouring of G=(V; E) is a function f :V {1; 2; : : : ; t} such that for every edge uvE, f(u) =f(v). The chromatic number of G,denoted (G), is the least integer t for which G has a t-colouring, and a t-colouringis an optimal colouring if t = (G). The chromatic polynomial (G; t) of G is apolynomial in t whose value at a given t equals the number of t-colourings of G.The LIST COLOURING problem is to determine, given a graph G and a list L(v) ofadmissible colours for each vertex v of G, whether there is a colouring f of G suchthat f(v)L(v) for every vertex.The following fundamental connectioncontraction method is a useful tool for deal-</p><p>ing with a vertex colouring problem : Whenever the input graph G is not a completegraph, 5nd two nonadjacent vertices u and v in G, construct two graphs G1=G+uv andG2=G(u=v), and then recursively solve on G1 and G2 and combine their solutions toget a solution for G. Note that (G)=min{(G1); (G2)}, (G; t)=(G1; t)+(G2; t), Gis t-colourable iO at least one of G1 and G2 is t-colourable, and an optimal colouring ofG can be obtained from an optimal colouring of G1 or G2. It was proved by Walsh [21]that the total number of complete graphs generated by using the contractionconnectionmethod is at most B(n), the nth Bell number which equals the number of ways to par-tition a set of n distinct elements into disjoint nonempty subsets. Asymptotically, B(n)grows faster than cn for any constant c but much slower than n factorial.To end this section, we remark that if F has bounded treewidth, then Fke, F+ke,</p><p>and F+kv all have bounded treewidth, and thus VERTEX COLOURING is 5xed-parametertractable for all of them [3]. Finally, for algorithms in the paper, we use the adjacencylist representation for input graphs.</p><p>3. General graphs</p><p>In general, it appears that we need to know a modulator of the input graph inorder to solve the vertex colouring problem on parameterized F graphs. Therefore,</p></li><li><p>L. Cai /Discrete Applied Mathematics 127 (2003) 415429 419</p><p>we will separate the issue of 5nding a modulator, and assume that a modulator of theinput graph is also given as input when we discuss colouring problems in this section.Note that whenever F graphs are recognizable in polynomial time, a modulator of aparameterized F graph can be found in polynomial time for each 5xed k by exhaustivesearch.Given an ePcient algorithm for solving VERTEX COLOURING on F graphs, how can it</p><p>help us in solving the problem on parameterized F graphs? It is not clear in general;however, for some F, it is possible to utilize the algorithm for F graphs to obtain anePcient colouring algorithm for parameterized F graphs. In this section, we presentsuch an algorithm to optimally colour Fke graphs for F closed under edge contrac-tion. We also solve VERTEX COLOURING for certain F+ ke graphs by using algorithmsfor computing chromatic polynomials of F graphs, and for certain F+ kv graphs byusing algorithms for solving LIST COLOURING on F graphs.We consider F ke graphs 5rst. It appears that, amongst parameterized F graphs,</p><p>Fke graphs are the easiest in terms of the hardness of solving VERTEX COLOURING. Aswe will see, if F is closed under edge contraction, then VERTEX COLOURING is solvablein polynomial time for F ke graphs whenever it is solvable in polynomial timefor F graphs. This is quite useful as many families of graphs are closed under edgecontraction, for instance, planar graphs, chordal graphs, split graphs, interval graphs,cographs, as well as graphs that are closed under taking minors. Note that the followingtheorem can be also stated in terms of VERTEX COLOURING instead of 5nding an optimalcolouring.</p><p>Theorem 3.1. Let F be a family of graphs closed under edge contraction; and T (m; n)denote the time to compute an optimal colouring of an F graph. Then an optimalcolouring of an F ke graph G; given a modulator of G; can be found in timeO(2k max{T (m+ k; n); m+ n+ k}).</p><p>Proof. We use the connectioncontraction method. Let Ek be a modulator of G. ThenG + Ek F. Pick an arbitrary edge uv in Ek (note that uv is not an edge in G) andconstruct from G two graphs G+ uv and G(u= v). Clearly G+ uv is an F (k 1)egraph with modulator Ek uv. Furthermore; since G(u = v) equals (G + uv) uv;G(u= v) is also an F (k 1)e graph by Lemma 2.2 and the corresponding edges ofEk uv in G(u= v) is a modulator of G(u= v). Therefore; the problem of 5nding anoptimal colouring of G is reduced to the problem of 5nding optimal colourings of twoF (k 1)e graphs; and we recursively apply the connectioncontraction method tothese two F (k 1)e graphs and their modulators inherited from Ek . The recursionterminates when an input graph is an F graph; and an optimal colouring of the graphis computed directly.To analyze the complexity of this algorithm, we consider its recursion tree. Since</p><p>the tree is a binary tree of height at most k, it has at most 2k leaves and 2k1 internalvertices. Each leaf takes at most T (m+ k; n) time since it is an F graph with at mostm+ k edges and n vertices, and each internal node takes at most O(m+ n+ k) time.Therefore the total time is O(2k(T (m+ k; n) +m+ n+ k)), which is O(2k max{T (m+k; n);...</p></li></ul>