We consider two coloring problems: interval coloring and max-coloring for chordal graphs. Given a graph <i>G</i> = (<i>V</i>, <i>E</i>) and positive-integral vertex weights <i>w</i>:<i>V</i> → <b>N</b>, the <i>interval-coloring</i> problem seeks to find an assignment of a real interval <i>I</i>(<i>u</i>) to each vertex <i>u</i>∈ <i>V</i>, such that two constraints are satisfied: (i) for every vertex <i>u</i> ∈ <i>V</i>, |<i>I</i>(<i>u</i>)| = <i>w</i>(<i>u</i>) and (ii) for every pair of adjacent vertices <i>u</i> and <i>v</i>, <i>I</i>(<i>u</i>)∩<i>I</i>(<i>v</i>) = ∅. The goal is to minimize the <i>span</i> |∪<sub><i>v</i>∈<i>V</i></sub><i>I</i>(<i>v</i>)|. The <i>max-coloring problem</i> seeks to find a proper vertex coloring of <i>G</i> whose color classes <i>C</i><sub>1</sub> <i>C</i><sub>2</sub>, …, <i>C</i><sub><i>k</i></sub>, minimize the sum of the weights of the heaviest vertices in the color classes, that is, ∑<sup><i>k</i></sup><sub><i>i</i> = 1</sub> <i>max</i><sub><i>v</i>ε<i>C</i><sub><i>i</i></sub></sub><i>w</i>(<i>v</i>). Both problems arise in efficient memory allocation for programs. The interval-coloring problem models the compile-time memory allocation problem and has a rich history dating back at least to the 1970s. The max-coloring problem arises in minimizing the total buffer size needed by a dedicated memory manager for programs. In another application, this problem models scheduling of conflicting jobs in batches to minimize the <i>makespan</i>. Both problems are NP-complete even for interval graphs, although there are constant-factor approximation algorithms for both problems on interval graphs. In this paper, we consider these problems for <i>chordal graphs</i>, a subclass of perfect graphs. These graphs naturally generalize interval graphs and can be defined as the class of graphs that have no induced cycle of length >3. Recently, a 4-approximation algorithm (which we call GeomFit) has been presented for the max-coloring problem on perfect graphs (Pemmaraju and Raman 2005). This algorithm can be used to obtain an interval coloring as well, but without the constant-factor approximation guarantee. In fact, there is no known constant-factor approximation algorithm for the interval-coloring problem on perfect graphs. We study the performance of GeomFit and several simple <i>O</i>(log(<i>n</i>))-factor approximation algorithms for both problems. We experimentally evaluate and compare four simple heuristics: first-fit, best-fit, GeomFit, and a heuristic based on partitioning the graph into vertex sets of similar weight. Both for max-coloring and for interval coloring, GeomFit deviates from OPT by about 1.5%, on average. The performance of first-fit comes close second, deviating from OPT by less than 6%, on average, for both problems. Best-fit comes third and graph-partitioning heuristic comes a distant last. Our basic data comes from about 10,000 runs of each of the heuristics for each of the two problems on randomly generated chordal graphs of various sizes, sparsity, and structure.
[1]
R. Möhring.
Algorithmic graph theory and perfect graphs
,
1986
.
[2]
Rajiv Raman,et al.
Approximation Algorithms for the Max-coloring Problem
,
2005,
ICALP.
[3]
Robert E. Tarjan,et al.
Simple Linear-Time Algorithms to Test Chordality of Graphs, Test Acyclicity of Hypergraphs, and Selectively Reduce Acyclic Hypergraphs
,
1984,
SIAM J. Comput..
[4]
Sriram V. Pemmaraju,et al.
Using graph coloring in an algebraic compiler
,
1997,
Acta Informatica.
[5]
Mikkel Thorup,et al.
OPT Versus LOAD in Dynamic Storage Allocation
,
2004,
SIAM J. Comput..
[6]
L. Lovász,et al.
Geometric Algorithms and Combinatorial Optimization
,
1981
.
[7]
Jordan Gergov,et al.
Algorithms for compile-time memory optimization
,
1999,
SODA '99.
[8]
Rajiv Raman,et al.
Buffer minimization using max-coloring
,
2004,
SODA '04.
[9]
Sandy Irani.
Coloring inductive graphs on-line
,
2005,
Algorithmica.
[10]
David S. Johnson,et al.
Computers and Intractability: A Guide to the Theory of NP-Completeness
,
1978
.
[11]
R. Govindarajan,et al.
Buffer allocation in regular dataflow networks: an approach based on coloring circular-arc graphs
,
1996,
Proceedings of 3rd International Conference on High Performance Computing (HiPC).
[12]
M. Golumbic.
CHAPTER 3 – Perfect Graphs
,
1980
.
[13]
Marek Chrobak,et al.
On Some Packing Problem Related to Dynamic Storage Allocation
,
1988,
RAIRO Theor. Informatics Appl..
[14]
Mikkel Thorup,et al.
OPT versus LOAD in dynamic storage allocation
,
2003,
STOC '03.
[15]
J. G. Pierce,et al.
Geometric Algorithms and Combinatorial Optimization
,
2016
.
[16]
Guy Kortsarz,et al.
Sum Multicoloring of Graphs
,
2000,
J. Algorithms.
[17]
Rajiv Raman,et al.
Approximating Interval Coloring and Max-Coloring in Chordal Graphs
,
2004,
WEA.
[18]
M. Golumbic.
Algorithmic Graph Theory and Perfect Graphs (Annals of Discrete Mathematics, Vol 57)
,
2004
.
[19]
H. A. Kierstead,et al.
The Linearity of First-Fit Coloring of Interval Graphs
,
1988,
SIAM J. Discret. Math..
[20]
M. Golumbic.
Algorithmic graph theory and perfect graphs
,
1980
.
[21]
Hal A. Kierstead,et al.
A polynomial time approximation algorithm for dynamic storage allocation
,
1991,
Discret. Math..
[22]
Jordan Gergov,et al.
Approximation Algorithms for Dynamic Storage Allocation
,
1996
.
[23]
Frances E. Allen,et al.
Automatic storage optimization
,
2004,
SIGP.
[24]
Giuseppe Confessore,et al.
An approximation result for the interval coloring problem on claw-free chordal graphs
,
2002,
Discret. Appl. Math..