Triangle-free graphs of tree-width t are ceil((t + 3)/2)-colorable
aa r X i v : . [ m a t h . C O ] J un Triangle-free graphs of tree-width t are ⌈ ( t + 3) / ⌉ -colorable Zdenˇek Dvoˇr´ak ∗ Ken-ichi Kawarabayashi † Abstract
We prove that every triangle-free graph of tree-width t has chro-matic number at most ⌈ ( t + 3) / ⌉ , and demonstrate that this boundis tight. The argument also establishes a connection between coloringgraphs of tree-width t and on-line coloring of graphs of path-width t . While there exist triangle-free graphs of arbitrarily large chromatic num-ber, forbidding triangles improves bounds on the chromatic number in cer-tain graph classes. For example, planar graphs are 4-colorable [3, 4] andeven deciding their 3-colorability is an NP-complete problem [6], while alltriangle-free planar graphs are 3-colorable [7]. A graph on n vertices mayhave chromatic number up to n , while Ajtai et al. [1] and Kim [10] proved atight upper bound O (cid:0)p n/ log n (cid:1) on the chromatic number of triangle-free n -vertex graphs. The chromatic number of graphs of maximum degree ∆ maybe as large as ∆ + 1, while Johansson [9] proved that triangle-free graphs ofmaximum degree ∆ have chromatic number O (∆ / log ∆).On the other hand, no such improvement is possible for graphs withbounded degeneracy. A graph G is d -degenerate if each subgraph of G con-tains a vertex of degree at most d . A straightforward greedy algorithm colorsevery d -degenerate graph using d + 1 colors; and a construction by BlancheDescartes [5] gives for every positive integer d a d -degenerate triangle-free ∗ Charles University, Prague, Czech Republic. E-mail: [email protected] .Supported by project 17-04611S (Ramsey-like aspects of graph coloring) of Czech ScienceFoundation. † National Institute of Informatics, 2-1-2 Hitotsubashi, Chiyoda-ku, Tokyo 101-8430,Japan. E-mail: k [email protected] . Supported by JST ERATO Grant Number JPM-JER1305, Japan. d -colorable, as observed by Kostochka and Neˇsetˇril [11]. Aconstruction of triangle-free graphs with high chromatic number by Zykov [12]also has this property, and the same construction was given (and possiblyindependently rediscovered) by Alon, Krivelevich, and Sudakov [2].In this note, we consider the chromatic number of graphs of given tree-width t . Note that every graph of tree-width t is t -degenerate, but on theother hand, the clique K t +1 has tree-width t , establishing t +1 as the tight up-per bound on the chromatic number of graphs of tree-width t . We show thatthe bound can be improved by a constant factor if triangles are forbidden. Theorem 1.
For any positive integer t , every triangle-free graph of tree-widthat most t has chromatic number at most ⌈ ( t + 3) / ⌉ . We also show that this result is tight. Actually, we give the follow-ing stronger result on graphs with bounded clique number. Let g ( t,
2) = g (0 , k ) = 1 for all integers t ≥ k ≥
2. For t ≥ k ≥
3, let usinductively define g ( t, k ) = ⌈ ( t + 1) / ⌉ + g ( ⌊ ( t − / ⌋ , k − Theorem 2.
For all integers t ≥ and k ≥ , there exists a K k -free graphof tree-width at most t with chromatic number at least g ( t, k ) . Note that g ( t,
3) = ⌈ ( t + 3) / ⌉ for all t ≥ g ( t, k ) > (cid:0) − k − (cid:1) t for all t ≥ k ≥
2. Theorem 2 motivates the following question, whichwe were not able to resolve.
Problem 3.
For integers k ≥ and t ≥ k − , what is the maximumchromatic number of K k -free graphs of tree-width at most t ? Let us remark that in the list coloring setting, the question is much easierto settle—the complete bipartite graph K t,t t has tree-width t , but there existsan assignment of lists of size t to its vertices from that it cannot be colored,showing that no improvement analogous to Theorem 1 is possible.Another natural question concerns graphs with larger girth. The con-struction of Blanche Descartes [5] actually produces d -degenerate graphs ofgirth six that are not d -colorable, and Kostochka and Neˇsetˇril [11] generalizethis result to graphs of arbitrarily large girth. Problem 4.
For integers g ≥ and t ≥ g − , what is the maximum chro-matic number of graphs of tree-width at most t and girth at least g ? Tree-width, path-width, and on-line color-ing
To prove Theorems 1 and 2, it is convenient to establish a connection betweenchromatic number of graphs with given tree-width t and an on-line variantof the chromatic number for graphs of path-width t . In on-line coloring [8],the graph to be colored is revealed vertex by vertex and a color has to beassigned to each revealed vertex immediately, with no knowledge regardingthe rest of the graph. We need a variation on this idea, revealing the verticesin the order given by a path decomposition of the graph.Let us first recall some definitions. A tree decomposition of a graph G isa pair ( T, β ), where T is a tree and β is a function assigning to each vertex of T a set of vertices of G , such that for every uv ∈ E ( G ) there exists z ∈ V ( T )with { u, v } ⊆ β ( z ), and such that for every v ∈ V ( G ), the set { z : v ∈ β ( z ) } induces a non-empty connected subtree in T . The width of the decompositionis the maximum of 1 + | β ( z ) | over all z ∈ V ( T ), and the tree-width of G isthe minimum possible width of its tree-decomposition. A path decomposition is a tree decomposition ( T, β ) where T is a path, and path-width of G is theminimum possible width of its path decomposition.Suppose ( P, β ) is a path decomposition of a graph G , where P = z z . . . z n .We say that the path decomposition is nice if β ( z ) = ∅ and | β ( z i ) \ β ( z i − ) | =1 for i = 1 , . . . , n . Observe that each path decomposition can be transformedinto a nice one of the same width. A nice path decomposition gives a naturalway to produce the graph G by adding one vertex at a time: the constructionstarts with the null graph, and in the i -th step for i = 1 , . . . , n , the uniquevertex v i ∈ β ( z i ) \ β ( z i − ) is added to G and joined to its neighbors in β ( z i ).An on-line coloring algorithm A at each step of this process assigns a colorto the vertex v i distinct from the colors of the neighbors of v i in β ( z i ). Notethat the assigned color cannot be changed later, and that the algorithm doesnot in advance know the graph G , only its part revealed till the current stepof the process. Let χ A ( G, P, β ) denote the number of colors A needs to color G when G is presented to the algorithm A vertex by vertex according to thenice path decomposition ( P, β ).Let us remark that we misuse the term “algorithm” a bit, as we are notconcerned with the question of efficiency or even computability in any modelof computation. Formally, an on-line coloring algorithm A is a function fromthe set of triples ( H, Q, γ ), where H is a graph with a nice path decomposition3 Q, γ ), to the integers, such that the following holds. Consider any graph G with a nice path decomposition ( P, β ), where P = z z . . . z n for some n ≥
1. For i = 1 , . . . , n , let v i be the unique vertex in β ( z i ) \ β ( z i − ), let P i = P − { z i +1 , . . . , z n } , G i = G − { v i +1 , . . . , v n } , and let β i be the restrictionof β to V ( P i ). If ϕ : V ( G ) → Z is defined by ϕ ( v i ) = A ( G i , P i , β i ), then ϕ isa proper coloring of G . And, χ A ( G, P, β ) is defined as the number of colorsused by this coloring ϕ .Nevertheless, it is easier to think about on-line coloring in the adversarialsetting: an enemy is producing the graph G with its nice path decompositionon the fly and the algorithm A is assigning colors to the vertices as theyarrive; and the enemy can construct further parts of the graph dependingon the coloring chosen by A so far. We now present the main result of thissection, which we use both to give upper bounds on the chromatic numberof graphs with bounded tree-width and to prove the existence of boundedtree-width graphs with large chromatic number. Lemma 5.
Let t and k be positive integers, and let c be the maximum of χ ( G ) over all K k -free graphs G of tree-width at most t . There exists an on-line coloring algorithm A t such that every K k -free graph H that has a nicepath decomposition ( P, β ) of width at most t satisfies χ A t ( H, P, β ) ≤ c .Conversely, if an on-line coloring algorithm A ′ t satisfies χ A ′ t ( H, P, β ) ≤ c ′ for every K k -free graph H having a path decomposition ( P, β ) of width atmost t , then χ ( G ) ≤ c ′ for every K k -free graph G of tree-width at most t .Proof. Let us start with the second claim. Let G be a K k -free graph and let( T, β ) be its tree decomposition of width at most t . Without loss of generality,we can assume that the tree T is rooted in a vertex r such that β ( r ) = ∅ and that each vertex z = r of T with parent z ′ satisfies | β ( z ) \ β ( z ′ ) | = 1.For each path P in T starting in r and ending in a leaf of T , let G P be thesubgraph of G induced by S z ∈ V ( P ) β ( z ) and let β P be the restriction of β to V ( P ). Then ( P, β P ) is a nice path decomposition of G P of width at most t , and thus the algorithm A ′ t can be used to color G P by at most c ′ colors.Furthermore, if P ′ is another root-leaf path in T and some vertex v belongsboth to G P and G P ′ , then v ∈ β ( z ) for some vertex z belonging to the sharedinitial subpath of P and P ′ , and thus the algorithm A ′ t assigns the same colorto v in its run on ( G P , P, β P ) and on ( G P ′ , P ′ , β P ′ ). We conclude that thecolorings of the graphs G P for all root-leaf paths P are consistent, and theirunion gives a proper coloring of G using at most c ′ colors.4onversely, let c be as given in the statement of the lemma. Consider the“universal” infinite K k -free graph G of tree-width at most t . That is, G isan infinite graph with rooted tree decomposition ( T, β ) of width at most t satisfying the following conditions. The root r of T has β ( r ) = ∅ . For everyvertex z of T and all sets I ⊆ B ⊆ β ( z ) such that G [ I ] is K k − -free and | B | ≤ t , there exists a child z ′ of z in T such that β ( z ′ ) = B ∪ { v } for avertex v not belonging to β ( z ), with v adjacent in G [ β ( z ′ )] precisely to thevertices in I ; and z has no other children. A standard compactness argumentshows that there exists a coloring ϕ of G using c colors. Now, for any K k -freegraph H with a nice path decomposition ( P, β ) of width at most t , we canidentify P with a path in T and H with an induced subgraph of G in thenatural way, and the algorithm A t works by assigning colors to vertices of H according to the coloring ϕ . Hence, χ A t ( H, P, β ) ≤ c . In this section, we give the construction proving Theorem 2.Let H and H be graphs with nice path decompositions ( P , β ) and( P, β ), respectively. We say that (
H, P, β ) extends ( H , P , β ) if P is aninitial segment of P , β is the restriction of β to V ( P ), and H is an inducedsubgraph of H . Let z be the last vertex of P . We say that a coloring ϕ of H is c -forced if there exists an independent set I ⊆ β ( z ) of size c such thatvertices of I receive pairwise distinct colors according to ϕ . Lemma 6.
Let k ≥ and c ≥ be integers, and let A be an on-line coloringalgorithm. Let H be a triangle-free graph with a nice path decomposition ( P , β ) of width at most c − . Let c ≤ c − be a non-negative integer. Ifthe coloring ϕ of H produced by A is c -forced, then there exists a triangle-free graph H with a nice path decomposition ( P, β ) of width at most c − such that ( H, P, β ) extends ( H , P , β ) and the coloring ϕ of H produced by A is ( c + 1) -forced.Proof. Let z be the last vertex of P and let I = { v , . . . , v c } be an inde-pendent set contained in β ( z ) such that ϕ assigns pairwise distinct colorsto vertices of I . Without loss of generality ϕ ( v ) = 1, . . . , ϕ ( v c ) = c . As( H, P, β ) will be chosen to extend ( H , P , β ), the coloring ϕ produced bythe algorithm A will match ϕ on V ( H ).5e will now append further vertices x , x , . . . at the end of P to obtainthe path P as follows. Let β ( x ) = { v , . . . , v c , v ′ } for a new vertex v ′ withno neighbors, and use the algorithm A to extend ϕ to this vertex. If ϕ ( v ′ ) isdistinct from 1, . . . , c , then we stop the construction. Otherwise, we can bysymmetry assume that ϕ ( v ′ ) = 1. We then let β ( x ) = { v , . . . , v c , v ′ , v ′ } for a new vertex v ′ adjacent to v . If ϕ ( v ′ ) is distinct from 1, . . . , c ,then we stop the construction (the independent set receiving c + 1 distinctcolors is { v ′ , v , . . . , v c , v ′ } ). Otherwise, since ϕ ( v ′ ) = ϕ ( v ), we can as-sume that ϕ ( v ′ ) = 2. Similarly, we proceed for j = 3 , . . . , c + 1: we set β ( x j ) = { v , . . . , v c , v ′ , . . . , v ′ j } , with v ′ j adjacent to v , . . . , v j − , and de-pending on the decision of A regarding the color of v ′ j , we either stop withthe independent set { v ′ , v ′ , . . . , v ′ j − , v j , v j − , . . . , v c , v ′ j } using c + 1 distinctcolors, or we can assume that ϕ ( v ′ j ) = j . The former happens necessarily atlatest when j = c + 1.All the bags created throughout this process have size at most 2 c + 1 ≤ c −
1, and thus the width of the resulting path decomposition is at most2 c − Corollary 7.
Let t ≥ be an integer. For any on-line coloring algorithm A ,there exists a triangle-free graph H with a nice path decomposition ( P, β ) ofwidth at most t such that the coloring ϕ of H produced by A is ⌈ t +12 ⌉ -forced. We are now ready to establish Theorem 2.
Proof of Theorem 2.
By Lemma 5, it suffices to show that for every on-linecoloring algorithm A , there exists a K k -free graph H with a nice path de-composition ( P, β ) of width at most t such that χ A ( H, P, β ) ≥ g ( t, k ). Weprove the claim by induction on k . When k = 2 or t = 0, we have g ( t, k ) = 1and the claim obviously holds, with H being a single-vertex graph. Hence,we can assume that k ≥ t ≥
1. Let c = ⌈ t +12 ⌉ and c = t − c = ⌊ t − ⌋ .Let H be a triangle-free graph with a nice path decomposition ( P , β ) ofwidth at most t such that the coloring ϕ of H produced by A is c -forced,obtained using Corollary 7. Let z be the last vertex of P and let I be anindependent set in H [ β ( z )] of size c whose vertices are colored by pairwisedistinct colors in ϕ .Let A ′ be an on-line coloring algorithm defined as follows: given any graph H with a nice path decomposition ( P , β ), let H ′ be the graph obtained from6 disjoint union of H and H by adding all edges between I and V ( H ). Let P ′ be the concatenation of P and P , with β ′ ( z ) = β ( z ) for z ∈ V ( P ) and β ′ ( z ) = β ( z ) ∪ I for z ∈ V ( P ). Then ( P ′ , β ) is a nice path decompositionof H ′ . The algorithm A ′ obtains a coloring of H as the restriction of thecoloring of H ′ given by the algorithm A to V ( H ).By the induction hypothesis, there exists a K k − -free graph H with anice path decomposition ( P , β ) of width at most t − c = c such that χ A ′ ( H , P , β ) ≥ g ( c , k − H and its path decomposition ( P, β ) bechosen as the corresponding graph H ′ with path decomposition defined as inthe previous paragraph. Since H is K k − -free, H is triangle-free, and I is anindependent set, we conclude that H is K k -free. Let ϕ be the coloring of H obtained by A . The restriction of ϕ to V ( H ) matches ϕ , and in particular c distinct colors are used on I . The restriction of ϕ to V ( H ) by definitionmatches the coloring of H obtained by the algorithm A ′ , and thus it usesat least g ( c , k −
1) distinct colors. Furthermore, since each vertex of I isadjacent to all vertices of V ( H ) in H , the sets of colors used on I and on V ( H ) are disjoint. Therefore, χ A ( H, P, β ) ≥ c + g ( c , k −
1) = g ( t, k ). Let c ′ be a positive integer, let F be a graph, and let ϕ be a c ′ -coloring of F . We say that ϕ is F -valid if F does not contain any independent set onwhich ϕ uses all c ′ distinct colors. We say that a color a is ( F, ϕ ) -forbidden if there exists an independent set A a ⊆ V ( F ) in F such that ϕ uses all colorsexcept for a on A a . We need the following auxiliary claim. Lemma 8.
Let c ′ be a positive integer and let ϕ be a c ′ -coloring of a graph F . If ϕ is F -valid, then at most max( | V ( F ) | − c ′ + 2 , colors are ( F, ϕ ) -forbidden.Proof. We prove the claim by induction on | V ( F ) | , and thus we assume thatLemma 8 holds for all graphs with fewer than | V ( F ) | vertices. For each( F, ϕ )-forbidden color a , let A a be an independent set such that ϕ uses allcolors except for a on A a .If | V ( F ) | ≤ c ′ −
2, then F contains no independent set of size c ′ −
1, andthus no color is (
F, ϕ )-forbidden. Hence, suppose that | V ( F ) | ≥ c ′ −
1, andthus | V ( F ) | − c ′ + 2 ≥
1. If at most one color is (
F, ϕ )-forbidden, then thelemma holds. Hence, we can by symmetry assume that colors 1 and 2 are7orbidden. Note that all c ′ colors appear at least once on A ∪ A . If each( F, ϕ )-forbidden color is used on at least two vertices of F , then the numberof ( F, ϕ )-forbidden colors is at most | V ( F ) | − c ′ , and the lemma holds.Hence, we can assume that the color c ′ is ( F, ϕ )-forbidden and used onexactly one vertex v of F . Let F ′ be the graph obtained from F by removing v and all the neighbors of v , and let ϕ ′ be the restriction of ϕ to F ′ . Note that ϕ ′ is a ( c ′ − F ′ . We claim that ϕ ′ is F ′ -valid. Indeed, if all colors1, . . . , c ′ − A ′ ⊆ V ( F ′ ), then all colors1, . . . , c would be used on the independent set A ′ ∪ { v } in F , contradictingthe assumption that ϕ is F -valid. If a color a = c ′ is ( F, ϕ )-forbidden, thennote that A a contains v since v is the only vertex of F of color c ′ , and doesnot contain any of the neighbors of v since A a is an independent set. Hence, A a \{ v } is an independent set in F ′ on that all colors except for a appear, andthus a is ( F ′ , ϕ ′ )-forbidden. Denoting by f ′ the number of ( F ′ , ϕ ′ )-forbiddencolors, we conclude that at most f ′ + 1 colors are ( F, ϕ )-forbidden.Since ϕ is F -valid, the set A c ′ ∪ { v } is not independent, and thus v hasdegree at least one. Consequently, | V ( F ′ ) | ≤ | V ( F ) | −
2. By the inductionhypothesis, we conclude that the number of (
F, ϕ )-forbidden colors is at mostmax( | V ( F ′ ) | − ( c ′ −
1) + 2 ,
0) + 1 ≤ max( | V ( F ) | − c ′ + 2 ,
1) = | V ( F ) | − c ′ + 2 , as required.We are now ready to bound the chromatic number of triangle-free graphsof tree-width at most t . Proof of Theorem 1.
We need to show that every triangle-free graph G oftree-width at most t can be colored using c ′ = ⌈ ( t + 3) / ⌉ colors. Note that2 c ′ − > t . By Lemma 5, it suffices to design an on-line coloring algorithm A ′ that colors every triangle-free graph H with a nice path decomposition( P, β ) of width at most t using at most c ′ colors.The algorithm A ′ maintains the invariant that the restriction of the c ′ -coloring ϕ produced by this algorithm to β ( z ) is H [ β ( z )]-valid for every z ∈ V ( P ). Consider any vertex z ′ with predecessor z ′′ in P , let v be theunique vertex in β ( z ′ ) \ β ( z ′′ ), and let N be the set of neighbors of v in β ( z ′ ). Since H is triangle-free, N is an independent set, and thus at mostmin( | N | , c ′ −
1) colors appear on N by the invariant. To get a proper coloringmaintaining the invariant, it suffices to assign v an arbitrary color that does8ot appear on N and that is not ( H [ β ( z ′ ) \ ( N ∪ { v } )] , ϕ )-forbidden. Since | β ( z ′ ) | ≤ t + 1, Lemma 8 implies that the number of such colors is at least c ′ − min( | N | , c ′ − − max( t − | N | − c ′ + 2 , . If | N | ≥ c ′ , this is at least c ′ − ( c ′ − − max( t − c ′ + 2 ,
0) = 1, using the factthat 2 c ′ − > t . If | N | ≤ c ′ −
1, this is at least c ′ −| N |− max( t −| N |− c ′ +2 ,
0) =min(2 c ′ − t − , c ′ − | N | ) ≥
1. In either case it is possible to extend thecoloring.
Acknowledgments
We would like to thank Endre Cs´oka, Tom´aˇs Kaiser, and Edita Rollov´a forfruitful discussions which led to a simplification of the proof of Lemma 8.
References [1]
M. Ajtai, J. Koml´os, and E. Szemer´edi , A note on Ramsey num-bers , Journal of Combinatorial Theory, Series A, 29 (1980), pp. 354–360.[2]
N. Alon, M. Krivelevich, and B. Sudakov , Coloring graphs withsparse neighborhoods , J. Comb. Theory, Ser. B, 77 (1999), pp. 73–82.[3]
K. Appel and W. Haken , Every planar map is four colorable, PartI: Discharging , Illinois J. of Math., 21 (1977), pp. 429–490.[4]
K. Appel, W. Haken, and J. Koch , Every planar map is four col-orable, Part II: Reducibility , Illinois J. of Math., 21 (1977), pp. 491–567.[5]
B. Descartes , Solution to advanced problem no. 4526 , Amer. Math.Monthly, 61 (1954), p. 532.[6]
M. Garey and D. Johnson , Computers and Intractability: A Guideto the Theory of NP-completeness , WH Freeman & Co. New York, NY,USA, 1979.[7]
H. Gr¨otzsch , Ein Dreifarbensatz f¨ur Dreikreisfreie Netze auf derKugel , Math.-Natur. Reihe, 8 (1959), pp. 109–120.98]
A. Gy´arf´as and J. Lehel , On-line and first fit colorings of graphs ,Journal of Graph theory, 12 (1988), pp. 217–227.[9]
A. Johansson , Asymptotic choice number for triangle free graphs , DI-MACS Technical Report, 91-4, 1196 (1996).[10]
J. H. Kim , The Ramsey number R (3 , t ) has order of magnitude t / log t ,Random Structures & Algorithms, 7 (1995), pp. 173–207.[11] A. Kostochka and J. Neˇsetˇril , Properties of Descartes’ construc-tion of triangle-free graphs with high chromatic number , Combinatorics,Probability and Computing, 8 (1999), pp. 467–472.[12]