Skip to main content
Erschienen in: Journal of Combinatorial Optimization 2/2018

Open Access 11.11.2017

Computational aspects of greedy partitioning of graphs

verfasst von: Piotr Borowiecki

Erschienen in: Journal of Combinatorial Optimization | Ausgabe 2/2018

Aktivieren Sie unsere intelligente Suche, um passende Fachinhalte oder Patente zu finden.

search-config
loading …

Abstract

In this paper we consider a variant of graph partitioning consisting in partitioning the vertex set of a graph into the minimum number of sets such that each of them induces a graph in hereditary class of graphs \({\mathcal {P}}\) (the problem is also known as \({\mathcal {P}}\)-coloring). We focus on the computational complexity of several problems related too greedy partitioning. In particular, we show that given a graph G and an integer k deciding if the greedy algorithm outputs \({\mathcal {P}}\)-coloring with at least k colors is \(\mathbb {NP}\)-complete if \({\mathcal {P}}\) is a class of \(K_p\)-free graphs with \(p\ge 3\). On the other hand we give a polynomial-time algorithm when k is fixed and the family of minimal forbidden graphs defining the class \({\mathcal {P}}\) is finite. We also prove \(\text {co}\mathbb {NP}\)-completeness of deciding if for a given graph G and an integer \(t\ge 0\) the difference between the largest number of colors used by the greedy algorithm and the minimum number of colors required in any \({\mathcal {P}}\)-coloring of G is bounded by t. In view of computational hardness, we present new Brooks-type bound on the largest number of colors used by the greedy \({\mathcal {P}}\)-coloring algorithm.

1 Introduction

Partitioning a graph into smaller parts is one of the fundamental algorithmic techniques and often an important part of more general tasks like parallelization, complexity reduction or simply a single step of divide-and-conquer algorithm. Over the years graph partitioning has been a subject of many variations and generalizations but it has been usually understood as partitioning the vertex set of a graph such that certain objective is met, e.g., it is possible to seek partitions into a given number of equal-sized sets such that the number of edges having endvertices in distinct sets is minimized or, as in this paper, one can minimize the number of the resulting sets under assumption that each set induces a graph with appropriate property.
Our main concern is the computational complexity of several problems related to greedy partitioning the vertex set of simple, finite and undirected graphs in such a way that each of the resulting sets induces a graph in some fixed hereditary class of graphs.

1.1 Hereditary classes

A class \({\mathcal {P}}\) of graphs is hereditary if for every graph G in \({\mathcal {P}}\) all induced subgraphs of G belong to \({\mathcal {P}}\), and it is additive if for every graph G all of whose components are in \({\mathcal {P}}\) it follows that also G is in \({\mathcal {P}}\). All classes of graphs considered in this paper are additive and hereditary, and we assume that the single-vertex graph and the empty graph (i.e., the graph with no vertices) belong to every nonempty hereditary class. This is a well known property due to Greenwell et al. (1973) that every hereditary class \({\mathcal {P}}\) of graphs can be uniquely characterized by the family \({\varvec{F}}({\mathcal {P}})\) of minimal forbidden graphs consisting of graphs G such that \(G\notin {\mathcal {P}}\) but each proper induced subgraph of G belongs to \({\mathcal {P}}\). We will also use a fact that hereditary class is additive if and only if all minimal forbidden graphs of that class are connected. The family \({\varvec{F}}({\mathcal {P}})\) should be distinguished from the family of minimal graphs in the class \({\mathcal {P}}\), denoted by \({\min }_{\le }{\mathcal {P}}\), which consists of all graphs in \({\mathcal {P}}\) that contain no graph from \({\mathcal {P}}\) as a proper induced subgraph. Naturally, if \({\mathcal {I}}\) denotes the class of all graphs, then \({\varvec{F}}({\mathcal {P}})={\min }_{\le }({\mathcal {I}}\setminus {\mathcal {P}})\). The graphs in \({\varvec{F}}({\mathcal {P}})\) as well as the graphs in \({\min }_{\le }{\mathcal {P}}\) are incomparable, in the sense that for any two graphs H and G neither \(H\le G\) nor \(G\le H\), where \(H\le G\) means that H is an induced subgraph of G (for brevity we will also say that G contains H).

1.2 Problem statement

A \({\mathcal {P}}\)-coloring of a graph \(G=(V,E)\) is a partition \((V_1,\ldots ,V_k)\) of the vertex set V(G) such that for each \(i\in \{1,\ldots ,k\}\) the graph induced by \(V_i\), denoted by \(G[V_i]\), is not empty and belongs \({\mathcal {P}}\). Equivalently, every \({\mathcal {P}}\)-coloring can be seen as a partition into \({\mathcal {P}}\)-independent sets, where a set of vertices is \({\mathcal {P}}\)-independent if graph induced by the vertices of that set belongs to \({\mathcal {P}}\). For example, if \({\varvec{F}}({\mathcal {P}}) = \{K_2\}\), where \(K_p\) denotes a complete graph of order p, then we deal with the classical proper coloring in which we simply partition the vertex set into independent sets (for brevity, when dealing with the classical variant, we usually omit \({\mathcal {P}}\)). The smallest k for which there exists some \({\mathcal {P}}\)-coloring of a graph G with k colors is called the \({\mathcal {P}}\)-chromatic number of G, and it is denoted by \(\chi _{{\mathcal {P}}}(G)\).
Greediness, as an an algorithmic paradigm, has already proved its usefulness in diverse areas of computer science. The greedy \({\mathcal {P}}\)-coloring algorithm (the greedy algorithm for short) colors subsequent vertices of graph G, one by one, in some order that is independent of the algorithm. Following the imposed order \((v_1,\ldots ,v_{n(G)})\) the algorithm colors each vertex \(v_i\) with the smallest color whose assignment to \(v_i\) results in \({\mathcal {P}}\)-coloring of the graph induced by \(\{v_1,\ldots ,v_i\}\) (in what follows, we assume that deciding the membership in \({\mathcal {P}}\) is polynomial). Let \((V_1,\ldots ,V_k)\) be an arbitrary \({\mathcal {P}}\)-coloring of a graph G. A vertex v is called a Grundy vertex if either \(v\in V_1\), or \(v\in V_i\) with \(i\ge 2\) and every set \(V_j\) with \(j<i\) contains a subset \(D_j\) such that \(G[D_j\cup \{v\}]\in {\varvec{F}}({\mathcal {P}})\). Since in every \({\mathcal {P}}\)-coloring produced by the greedy algorithm each vertex is a Grundy vertex, such a \({\mathcal {P}}\)-coloring is called the Grundy \({\mathcal {P}}\)-coloring. The number of colors used by the greedy algorithm strongly depends on vertex ordering; with the largest number of colors called the \({\mathcal {P}}\)-Grundy number of a graph G and denoted by \({\varGamma _{\mathcal {P}}(G)}\).
In what follows we focus mainly on the following two problems.
  • Grundy \({\mathcal {P}}\)-Coloring
    • Input: A graph G and positive integer k.
    • Question: Does G have a Grundy \({\mathcal {P}}\)-coloring with at least k colors?
  • Grundy \(({\mathcal {P}},k)\)-Coloring
    • Input: A graph G.
    • Question: Does G have a Grundy \({\mathcal {P}}\)-coloring with at least k colors?
Considering the above problems we indirectly use interpolation result of Cockayne et al. (1972) who proved that for every hereditary class \({\mathcal {P}}\) and every graph G the number of colors used by the greedy algorithm can take any value from \(\chi _{{\mathcal {P}}}(G)\) to \({\varGamma _{\mathcal {P}}(G)}\). We shall also use a fact that both \(\chi _{{\mathcal {P}}}(G)\) and \({\varGamma _{\mathcal {P}}(G)}\) are monotone with respect to taking induced subgraphs, i.e., if \(H\le G\), then \(\chi _{{\mathcal {P}}}(H)\le \chi _{{\mathcal {P}}}(G)\) and \({\varGamma _{\mathcal {P}}(H)}\le {\varGamma _{\mathcal {P}}(G)}\).
For proper coloring, the notion of the Grundy number is usually attributed to Christen and Selkow (1979) but it has its roots in the seminal work of Grundy (1939). From that moment on, the Grundy number has been intensively studied. The subject became too broad to be surveyed in a concise way, so we focus only on selected aspects related to our results.
Namely, from the computational point of view, Goyal and Vishwanathan (1998) proved that, restricted to proper coloring, the former of the above-mentioned problems is \(\mathbb {NP}\)-complete even for chordal graphs. In this way they solved the problem posed by Hedetniemi et al. (1982) (cf. Section 10.4 of the book on graph coloring problems by Jensen and Toft (1995)). Later, Zaker (2006) proved \(\mathbb {NP}\)-completeness of this problem for the complements of bipartite graphs. In this paper we ask if Grundy \({\mathcal {P}}\)-Coloring is \(\mathbb {NP}\)-complete for every nontrivial \({\mathcal {P}}\). In view of this question, it is worth mentioning that for every class \({\mathcal {P}}\), every Grundy \({\mathcal {P}}\)-coloring of any graph in the class \({\mathcal {P}}\) requires at most one color and hence Grundy \({\mathcal {P}}\)-Coloring with inputs in \({\mathcal {P}}\) can be solved in time O(1). Therefore, when considering hardness of Grundy \({\mathcal {P}}\)-Coloring one should focus on inputs in classes \({\mathcal {Q}}\) satisfying \({\mathcal {P}}\subset {\mathcal {Q}}\).
On the positive side, we know that for proper coloring the latter problem can be solved in polynomial time, which follows from a finite basis theorem of Gyárfás et al. (1979) who proved that for every nonnegative integer k the number of minimal forbidden graphs characterizing the class of graphs with the Grundy number equal to k is finite (in more detail, we refer to that result in Sect. 2; for closely related concepts see also Zaker (2006), and Borowiecki and Sidorowicz (2012)). Independently of vertex ordering the greedy algorithm outputs an optimal proper coloring for \(P_4\)-free graphs and graphs G with their chromatic number \(\chi (G)\) equal to \(Q(G)+1\), where Q(G) is the potential of G (see Borowiecki and Rautenbach 2015) for the definition, and Sect. 6 for a generalization of this notion. For several classes of graphs, e.g., for trees and \(P_4\)-laden graphs, determining the Grundy number is known to be polynomial (see Hedetniemi et al. 1982; Araujo and Linhares-Sales 2012, respectively). For other classes, e.g., interval graphs (Narayanaswamy and Subhash Babu 2008), complements of bipartite as well as chordal graphs (Gyárfás and Lehel 1990), bounded tolerance graphs (Kierstead and Saoub 2011) and \(\{P_5,K_4-e\}\)-free graphs (Choudum and Karthick 2010), polynomial-time constant-factor approximation algorithms are known. For more extensive discussion on approximability and other aspects of the Grundy number, including various bounds in terms of the clique number of a graph, we refer the reader to works of Borowiecki (2004), Goyal and Vishwanathan (1998), Kierstead (1998) and Kortsarz (2007).
The reminder of this paper is organized as follows. In Sect. 2 we shortly present our motivation and introduce the so-called critical partitions with an emphasis on the role of graphs minimal in the class of all graphs admitting such partitions. As we will see in Sect. 3, this leads to a polynomial-time algorithm for Grundy \(({\mathcal {P}},k)\)-Coloring, provided that \({\varvec{F}}({\mathcal {P}})\) is finite. Next, in Sect. 4 we show that Grundy  \({\mathcal {P}}\) -Coloring is \(\mathbb {NP}\)-complete if \({\varvec{F}}({\mathcal {P}})=\{K_p\}\) and \(p\ge 3\). Finally, in Sect. 5 we prove that deciding whether for a given graph G and an integer \(t\ge 0\) the difference between the \({\mathcal {P}}\)-Grundy number and the \({\mathcal {P}}\)-chromatic number of G is bounded by t, or equivalently, the problem of the membership in the class
$$\begin{aligned} {\mathcal {H}}({\mathcal {P}},t)=\{G\!\mid \!{\varGamma _{\mathcal {P}}(G)}-\chi _{{\mathcal {P}}}(G)\le t\} \end{aligned}$$
is \(\text {co}\mathbb {NP}\)-complete. In view of computational hardness in Sect. 6 we give a new Brooks-type bound on the \({\mathcal {P}}\)-Grundy number. Namely, for the \({\mathcal {P}}\)-Grundy number of every graph G we have
$$\begin{aligned} {\varGamma _{\mathcal {P}}(G)} \le {{\varPhi }_{\mathcal {P}}(G)} + 1 , \end{aligned}$$
where \({{\varPhi }_{\mathcal {P}}(G)}\) is the maximum of a new potential function defined in Sect. 6. Our new bound generalizes and strengthens several bounds for proper coloring stated in terms of various potential functions (see, e.g., Borowiecki and Rautenbach 2015; Stacho 2001 and Zaker 2008).
In what follows we use standard notation and terminology. In particular, by \(N_G(v)\) we denote the neighborhood of vertex v in a graph G while \(d_G(v) = |N_G(v)|\) stands for the degree of v. The clique number of graph G is denoted by \(\omega (G)\) while n(G) and m(G) denote the order and size of G, respectively. For any undefined notions we refer the reader to the following books: Brandstädt et al. (1999), Papadimitriou (1994) and West (2001).

2 Motivation, critical partitions and minimal graphs

Introducing critical partitions and describing their structural properties we step towards a general technique that benefits from the knowledge of polynomial-time approximation algorithms for diverse optimization problems with inputs in certain graph classes, called basic classes. We use such algorithms to develop new polynomial-time approximation algorithms that can be applied to all inputs in carefully constructed superclasses of the basic classes. Our approach ensures that extending basic classes of inputs we preserve the order of approximation ratios of the original algorithms. More formally, let \({{\mathcal {C}}({\mathcal {{\mathcal {P}}}},k)}\) denote the class of graphs \({\mathcal {P}}\)-colorable with at most k colors and let \((V_1,\ldots ,V_k)\) be a \({\mathcal {P}}\)-coloring of an arbitrary graph \(G\in {{\mathcal {C}}({\mathcal {{\mathcal {P}}}},k)}\). Now, consider a minimization problem \(\varPi \) for which there is a polynomial-time \(\delta (n)\)-approximation algorithm \({{\texttt {A}}}_1\) for inputs in \({\mathcal {P}}\). Naturally, since \(G[V_i]\in {\mathcal {P}}\), the algorithm \({{\texttt {A}}}_1\) can be directly applied to each \(G[V_i]\). Additionally, assume that there exists a polynomial-time algorithm \({{\texttt {A}}}_2\) that, given the outputs of \({{\texttt {A}}}_1\) for each input \(G[V_i]\) gives a solution of \(\varPi \) for G such that \({{\texttt {A}}}_1(G)\le k\cdot \max \{{{\texttt {A}}}_1(G[V_i]) \mid 1\le i \le k\}\), where \({{\texttt {A}}}_1(G[V_i])\) denotes the worst-case cost of the solution produced by \({{\texttt {A}}}_1\) for \(G[V_i]\). We say that \(\varPi \) is a problem with compositive solutions if such an algorithm \({{\texttt {A}}}_2\) exists (note that such algorithms can be easily given for various domination and coloring problems). A major drawback of such a three-phase approach (partition, solve, compose) is that we do not know any simple realization of this procedure, because, with a sole exception of proper 2-Coloring, the \({\mathcal {P}}\)-coloring problem is computationally hard (see Brown 1996; Kratochvíl and Schiermeyer 1997). Furthermore, our knowledge of minimal forbidden subgraphs that characterize \({\mathcal {C}}({\mathcal {P}},k)\) is far from being complete (for some recent results in context of proper k-coloring of graphs in selected classes, mainly for \(k\in \{3,4\}\), see, e.g., Hoàng et al. (2015), Chudnovsky et al. (2016), and Goedgebeur and Schaudt (2016)). This directs our attention to the class \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k)}\) consisting of all graphs for which \({\varGamma _{\mathcal {P}}(G)}\le k\). Naturally, for every \(k\ge 2\) we have \({\mathcal {P}}\subset {{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k)}\subset {{\mathcal {C}}({\mathcal {{\mathcal {P}}}},k)}\). Hence, the class \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k)}\) is an extension of \({\mathcal {P}}\) and offers an intrinsic algorithmic property of its members to be greedily \({\mathcal {P}}\)-colorable with at most k colors. Therefore, the algorithm that follows the above-mentioned three phases and uses greedy \({\mathcal {P}}\)-coloring routine in the first phase (we denote this algorithm by \({{\texttt {PH}}}\)), can be used for all inputs in \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k)}\) and achieves an approximation ratio of the same order as \({{\texttt {A}}}_1\) for inputs in \({\mathcal {P}}\). For an illustration of the above concept see Fig. 1.
Proposition 2.1
Let \(\varPi \) be a minimization problem with compositive solutions. If \(\varPi \) admits a polynomial-time \(\delta (n)\)-approximation in \({\mathcal {P}}\), then the algorithm \({{\texttt {PH}}}\) is a polynomial-time \(k{\cdot }\delta (n)\)-approximation algorithm for \(\varPi \) in \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k)}\). \(\square \)
In what follows we also use a fact that every \({\mathcal {P}}\)-coloring \((V_1,\ldots ,V_k)\) of a graph G with k colors can be seen as a surjection \({\varphi :V(G)}\rightarrow \{1,\ldots ,k\}\) such that \(\varphi (v)=i\) for every vertex \(v\in V_i\) (for brevity we also say that \(\varphi \) is a \({\mathcal {P}}\)-coloring). A subset U of vertices of a graph G is strongly  \({\mathcal {P}}\)-dominating in G if for every vertex \(v\in V(G)\setminus U\) there exists a set \(D\subseteq U\) such that \(G[D\cup \{v\}]\in {\varvec{F}}({\mathcal {P}})\).
Proposition 2.2
Let \(k\ge 2\) and let H be an induced subgraph of a graph G. If \({\varGamma _{\mathcal {P}}(H)}\ge k-1\) and V(G) contains a nonempty \({\mathcal {P}}\)-independent set I that is disjoint from V(H) and strongly \({\mathcal {P}}\)-dominating in \(G[I\cup V(H)]\), then \({\varGamma _{\mathcal {P}}(G)}\ge k\).
Proof
Let \(V(H)=\{x_1,\ldots ,x_{n(H)}\}\), \(I=\{y_1,\ldots ,y_t\}\) and let \((x_1,\ldots ,x_{n(H)})\) be an ordering of V(H) that forces the greedy algorithm to produce \({\mathcal {P}}\)-coloring \(\varphi \) of the graph H with \(k-1\) colors. Now, consider the assignment of colors produced by the same algorithm for vertex ordering \((y_1,\ldots ,y_t, x_1,\ldots ,x_{n(H)})\). Naturally, since I is strongly \({\mathcal {P}}\)-dominating in \(G[I\cup V(H)]\), for each vertex \(x \in V(H)\) there exists a subset D of I such that \(G[D\cup \{x\}]\in {\varvec{F}}({\mathcal {P}})\). Moreover, since I is \({\mathcal {P}}\)-independent and no vertex in I is preceded by a vertex in V(H), all vertices in I will be colored 1. Consequently, according to the greedy rule, for each vertex x of H the algorithm will use color \(\varphi (x)+1\). This yields \({\varGamma _{\mathcal {P}}(G)}\ge k\), since \(G[I\cup V(H)]\le G\). \(\square \)
The above proposition reveals the importance of specific bipartition of the vertex set in which both parts have certain coloring or domination properties. We focus on how they come into play in graphs that are minimal with respect to the \({\mathcal {P}}\)-Grundy number under taking induced subgraphs. For \(k\ge 1\) by \({{\mathcal {U}}({\mathcal {P}},k)}\) we denote the class of graphs G for which \({\varGamma _{\mathcal {P}}(G)} \ge k\). Naturally \({{\mathcal {U}}({\mathcal {P}},k)} = {\mathcal {I}}\setminus {{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k-1)}\) (recall that \({\mathcal {I}}\) denotes the class of all graphs). In what follows \({\varvec{C}}_k({\mathcal {P}})\) stands for the family of minimal graphs in the class \({{\mathcal {U}}({\mathcal {{\mathcal {P}}}},k)}\), that is, the graphs for which \({\varGamma _{\mathcal {P}}(G)} = k\) and \({\varGamma _{\mathcal {P}}(G-v)} < k\), where v is an arbitrary vertex of G. Note that \({\varvec{C}}_1({\mathcal {P}})=\{K_1\}\), \({\varvec{C}}_2({\mathcal {P}})={\varvec{F}}({\mathcal {P}})\) and that forbidding all graphs in \({\varvec{C}}_k({\mathcal {P}})\) defines \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k-1)}\); more formally \({\varvec{C}}_k({\mathcal {P}})={\varvec{F}}({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k-1)})\). Minimal graphs play a crucial role in the greedy coloring process; in fact they determine the number of colors used by the greedy algorithm in the worst case, and they characterize classes \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},k)}\). For proper coloring the classes \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},2)}\) and \({{\mathcal {G}}({\mathcal {{\mathcal {P}}}},3)}\) were characterized by Gyárfás et al. (1979) who proved that \({\varvec{C}}_{3}({\mathcal {P}})=\{K_3,P_4\}\) and listed all 22 graphs in \({\varvec{C}}_{4}({\mathcal {P}})\).
The key notion in our analysis of minimal graphs is a class \({\mathcal {F}}({\mathcal {P}},k)\) consisting of all graphs G for which there exists a partition (IC) of V(G) such that I is nonempty, \({\mathcal {P}}\)-independent and strongly \({\mathcal {P}}\)-dominating in G, and \(G[C]\in {\varvec{C}}_{k-1}({\mathcal {P}})\), where \(k\ge 2\). Such a partition is called a critical partition of the graph G. Note that critical partition of G does not have to be unique.
Example 2.1
Consider the graphs \(G_1,\ldots ,G_4\) in Fig. 2 and the class \({\mathcal {P}}\) for which \({\varvec{F}}({\mathcal {P}})=\{K_3\}\). The graphs \(G_1\) and \(G_2\) are the elements of \({\varvec{C}}_{3}({\mathcal {P}})\); their Grundy \({\mathcal {P}}\)-coloring with 3 colors can be easily obtained using Proposition 2.2 with black vertices forming the set I. Additionally, if we denote by C the set of white vertices, then we get a critical partition (IC). It is not hard to verify that deleting any vertex results in the \({\mathcal {P}}\)-Grundy number equal to 2. The graphs \(G_3\) and \(G_4\) belong to \({\mathcal {F}}({\mathcal {P}},4)\), since they admit critical partitions with black and white vertices forming the sets I and C, respectively. Indeed, white vertices induce \(G_1\) or \(G_2\), while black ones do not induce \(K_3\), which means that I is \({\mathcal {P}}\)-independent. To see that I is strongly \({\mathcal {P}}\)-dominating observe that each white vertex belongs to a triangle with two black vertices. Again, it is not hard to see that \(G_3\in {\varvec{C}}_{4}({\mathcal {P}})\). Consequently, since \(G_3\le G_4\), we get \(G_4\in {\mathcal {F}}({\mathcal {P}},4)\setminus {\varvec{C}}_{4}({\mathcal {P}})\).    \(\square \)
Theorem 2.1
For every class \({\mathcal {P}}\) and integer \(k\ge 2\),
$$\begin{aligned} {\varvec{C}}_k({\mathcal {P}})={\min }_{\le }{\mathcal {F}}({\mathcal {P}},k) . \end{aligned}$$
Proof
Recall that \({\varvec{C}}_k({\mathcal {P}})\) is defined as a family of minimal graphs in the class \({{\mathcal {U}}({\mathcal {P}},k)}\) in which for every graph G we have \({\varGamma _{\mathcal {{\mathcal {P}}}}(G)}\ge k\). If \(G\in {\mathcal {F}}({\mathcal {P}},k)\), then by the definition of the class \({\mathcal {F}}({\mathcal {P}},k)\) and Proposition 2.2 we have \({\varGamma _{\mathcal {{\mathcal {P}}}}(G)}\ge k\). Thus \({\mathcal {F}}({\mathcal {P}},k)\subseteq {{\mathcal {U}}({\mathcal {{\mathcal {P}}}},k)}\). Consequently, for every graph \(H^\prime \in \min _{\le }{\mathcal {F}}({\mathcal {P}},k)\) there exists a graph \(H\in \min _{\le }{{\mathcal {U}}({\mathcal {P}},k)}\) such that \(H\le H^\prime \). To finish the proof it remains to show that \(H\in {\mathcal {F}}({\mathcal {P}},k)\). Note that by minimality \({\varGamma _{\mathcal {{\mathcal {P}}}}(H)}=k\). Now, if \((V_1,\ldots ,V_k)\) is an arbitrary Grundy \({\mathcal {P}}\)-coloring of H with k colors, we can simply construct a partition (IC) of V(H) by setting \(I=V_1\) and \(C=\bigcup _{i=2}^k V_i\). Naturally, the set I of the partition is nonempty, \({\mathcal {P}}\)-independent, and by the definition of Grundy \({\mathcal {P}}\)-coloring it is also strongly \({\mathcal {P}}\)-dominating in H. Since \((V_2, \ldots ,V_k)\) is a Grundy \({\mathcal {P}}\)-coloring of H[C], we have \({\varGamma _{\mathcal {P}}(H[C])}\ge k-1\). We shall show that \(H[C]\in {\varvec{C}}_{k-1}({\mathcal {P}})\). Suppose, contrary to our claim, that there exists a vertex \(v\in C\) and an ordering of \(C^\prime =C\setminus \{v\}\) that forces the algorithm to color \(H[C^\prime ]\) with \(k-1\) colors. Consequently, from Proposition 2.2 applied to I and \(H[C^\prime ]\) it follows that \({\varGamma _{\mathcal {P}}(H[I\cup C^{\prime }])}\ge k\). This contradicts minimality of H in the definition of \({\varvec{C}}_k({\mathcal {P}})\). Hence \(H\in {\mathcal {F}}({\mathcal {P}},k)\). \(\square \)

3 The complexity of Grundy \(({\mathcal {P}},k)\)-coloring

In what follows, we have to carefully distinguish between the two important cases of finite and infinite family \({\varvec{F}}({\mathcal {P}})\). In this section we prove that if \({\varvec{F}}({\mathcal {P}})\) is finite, then Grundy  \(({\mathcal {P}},k)\) -Coloring can be solved in polynomial time.
Proposition 3.1
Let \({\mathcal {P}}\) be a class of graphs with finite \({\varvec{F}}({\mathcal {P}})\). If \(\alpha \) and \(\beta \) denote the minimum and maximum order of a graph in \({\varvec{F}}({\mathcal {P}})\), respectively, then for every integer \(k\ge 1\) and every graph \(G\in {\varvec{C}}_k({\mathcal {P}})\) we have \((\alpha -1)(k-1)+1 \le n(G) \le \beta ^{k-1}.\)
Proof
We use induction on k. The above inequalities are evidently fulfilled for \(k\in \{1,2\}\). Assume that the statement is true for the parameters smaller than k, where \(k\ge 3\). Let \(G\in {\varvec{C}}_k({\mathcal {P}})\). By Theorem 2.1 there exists a partition (IC) of V(G) such that I is nonempty, \({\mathcal {P}}\)-independent and strongly \({\mathcal {P}}\)-dominating in G. Moreover \(G[C]\in {\varvec{C}}_{k-1}({\mathcal {P}})\), which by the induction hypothesis implies
$$\begin{aligned} (\alpha -1)(k-2)+1 \le |C|\le \beta ^{k-2}. \end{aligned}$$
(3.1)
Since \(V(G)=I\cup C\) and \(I\cap C=\emptyset \), the proof will be completed by showing \( \alpha -1\le |I| \le \beta ^{k-2}(\beta -1)\).
The inequality \(\alpha -1\le |I|\) is obvious because C is nonempty and I is strongly \({\mathcal {P}}\)-dominating in G. Suppose to the contrary that \(|I|\ge \beta ^{k-2}(\beta -1)+1\). Let \({\vartheta }:C\rightarrow 2^I\) be a mapping that assigns to each \(x\in C\) a subset \({\vartheta }(x)\) of I such that \(G[{\vartheta }(x)\cup \{x\}]\in {\varvec{F}}({\mathcal {P}})\). Note that the existence of the set \({\vartheta }(x)\) follows immediately by the assumption that I is strongly \({\mathcal {P}}\)-dominating in G. Naturally \(|{\vartheta }(x)|\le \beta -1\) for each \(x\in C\) and the sets \({\vartheta }(x_1)\), \({\vartheta }(x_2)\) need not be distinct when \(x_1\ne x_2\). Let \(I^\prime \) denote the following union \(\bigcup _{x\in C}{\vartheta }(x)\). Thus
$$\begin{aligned} |I^\prime |=\bigl |\bigcup _{x\in C}{\vartheta }(x)\bigr | \le \sum _{x\in C}|{\vartheta }(x)| \le (\beta -1)|C| {\mathop {\le }\limits ^{(3.1)}} (\beta -1)\beta ^{k-2}. \end{aligned}$$
Consequently as a proper subset of I, the set \(I^\prime \) is \({\mathcal {P}}\)-independent in G and hence it is \({\mathcal {P}}\)-independent in each induced subgraph of G. Therefore, if \(G^\prime =G[I^\prime \cup C]\), then \(I^\prime \) is strongly \({\mathcal {P}}\)-dominating in \(G^\prime \) by its definition, and it is \({\mathcal {P}}\)-independent in \(G^\prime \) by our earlier consideration. Finally, it follows that \(G^\prime \in {\mathcal {F}}({\mathcal {P}},k)\) and that \(G^\prime \) is a proper induced subgraph of G. This contradicts the fact that by Theorem 2.1 the graph G is minimal in \({\mathcal {F}}({\mathcal {P}},k)\). \(\square \)
In what follows we need the class \({\mathcal {T}}({\mathcal {P}},k)\) of forcing  \(({\mathcal {P}},k)\)-trees. Namely, if \(k=2\), then \({\mathcal {T}}({\mathcal {P}},2)={\varvec{C}}_2({\mathcal {P}})\). For \(k\ge 3\) let B be a graph in \({\mathcal {T}}({\mathcal {P}},k-1)\) and let \(F_1,\ldots ,F_{n(B)}\) be disjoint graphs, each being isomorphic to a graph in \({\varvec{F}}({\mathcal {P}})\). A graph G belongs to \({\mathcal {T}}({\mathcal {P}},k)\) if it can be obtained from \(B,F_1,\ldots ,F_{n(B)}\) by an identification of each vertex of B with an arbitrary vertex of some graph \(F_j\), \(j\in \{1,\ldots ,n(B)\}\) in such a way that every \(F_j\) takes part in exactly one identification. As the root of forcing \(({\mathcal {P}},k)\)-tree we select an arbitrary vertex of \(B\in {\mathcal {T}}({\mathcal {P}},2)\). All graphs in \({\mathcal {T}}({\mathcal {P}},k)\) are minimal in the class \({\mathcal {F}}({\mathcal {P}},k)\) for every \(k\ge 2\) (see Borowiecki 2006).
Theorem 3.1
For every class \({\mathcal {P}}\) and every integer \(k\ge 2\), the set \({\varvec{C}}_k({\mathcal {P}})\) is finite if and only if \({\varvec{F}}({\mathcal {P}})\) is finite.
Proof
If \({\varvec{F}}({\mathcal {P}})\) is finite, then simply observe that by Proposition 3.1 the set \({\varvec{C}}_k({\mathcal {P}})\) is finite, too. Now, suppose to the contrary that \({\varvec{F}}({\mathcal {P}})\) is infinite and that for some k the set \({\varvec{C}}_{k}({\mathcal {P}})\) is finite. Since \({\varvec{C}}_2({\mathcal {P}})={\varvec{F}}({\mathcal {P}})\), it remains to consider \(k\ge 3\). Let \(n^*\) be the largest order of a graph in \({\varvec{C}}_{k}({\mathcal {P}})\) and let \(F\in {\varvec{F}}({\mathcal {P}})\) be a graph such that \(n(F)>\!\!\root k-1 \of {n^*}\). Note that by the finiteness of \({\varvec{C}}_{k}({\mathcal {P}})\) and the infiniteness of \({\varvec{F}}({\mathcal {P}})\) such a number and such a graph always exist. Next, consider \(T_k\in {\mathcal {T}}({\mathcal {P}},k)\) constructed in \(k-1\) steps starting with \(T_2=F\) and such that for each step \(i\in \{2,\ldots ,k-1\}\), in which we obtain \(T_{i+1}\), we have \(F_1=\cdots =F_{n(T_i)}=F\). Since \(T_k\in {\varvec{C}}_k({\mathcal {P}})\), the construction of \(T_k\) and the assumption on n(F) imply \( n(T_k) = (n(F))^{k-1} > (\!\root k-1 \of {n^*})^{k-1} = n^*\). A contradiction with the choice of \(n^*\). \(\square \)
The above finite basis theorem allows the proof of the following result on the computational complexity of Grundy  \(({\mathcal {P}},k)\) -Coloring.
Theorem 3.2
If \({\mathcal {P}}\) is a class with finite \({\varvec{F}}({\mathcal {P}})\) and \(k>0\) is a fixed integer, then Grundy \(({\mathcal {P}},k)\) -Coloring admits a polynomial-time algorithm.
Proof
Indeed, checking whether a graph H of order p is an induced subgraph of a given graph G of order n can be done by brute force in \(O(n^p)\) time. Since for finite \({\varvec{F}}({\mathcal {P}})\) by Proposition 3.1 the order of any graph in \(H\in {\varvec{C}}_{k}({\mathcal {P}})\) is bounded from above by \(\beta ^{k-1}\), deciding if H is contained in G can be done in \(O(n^{\beta ^{k-1}})\) time. The proof is completed by the observation that for any fixed k by Theorem 3.1 the number of graphs in \({\varvec{C}}_k({\mathcal {P}})\) is finite and independent of n. \(\square \)

4 The complexity of Grundy \({\mathcal {P}}\)-coloring

In this section we prove that Grundy \({\mathcal {P}}\) -Coloring is \(\mathbb {NP}\)-complete for every class \({\mathcal {P}}\) defined by \({\varvec{F}}({\mathcal {P}})=\{K_p\}\) with \(p\ge 3\).
In our proof we use a polynomial-time reduction from 3-Coloring of planar graphs with vertex degree at most 4 (for \(\mathbb {NP}\)-completeness see Garey et al. (1976)). In fact we need a slight strengthening of their result consisting in restricting the class to planar graphs with vertex degree at most 4, size \(m\equiv 1(\text{ mod } r)\) and every vertex belonging to at least one triangle; the class of such graphs we denote by \({\mathcal {L}}(r)\).
Theorem 4.1
For every fixed \(r\ge 2\), the problem 3-Coloring is \(\mathbb {NP}\)-complete in \({\mathcal {L}}(r)\).
For a proof of Theorem 4.1 we refer the reader to “Appendix A”.
Theorem 4.2
For every class \({\mathcal {P}}\) such that \({\varvec{F}}({\mathcal {P}})=\{K_p\}\) with \(p\ge 3\), the problem Grundy \({\mathcal {P}}\) -Coloring is \(\mathbb {NP}\)-complete.
In order to prove the above theorem we give Construction 4.1 and prove several lemmas. Let \(p\ge 3\), \({\varvec{F}}({\mathcal {P}})=\{K_p\}\), and let G be an instance of 3-Coloring in \({\mathcal {L}}(p-1)\). We construct a graph \(G^\prime \) and calculate an integer k such that \(G^\prime \) has a Grundy \({\mathcal {P}}\)-coloring with k colors if and only if G has a proper 3-coloring.
Construction 4.1
First, we define the vertices of \(G^\prime \). For each vertex \(v_i\in V(G)\), \(i\in \{1,\ldots ,n(G)\}\) create a set of vertices \(U_i = \{u^i_1,\ldots ,u^i_{p-1}\}\). Similarly, for each edge \(e_i\in E(G)\), \(i\in \{1,\ldots ,m(G)\}\) create a set of vertices \(W_i = \{w^i_1,\ldots ,w^i_{p-1}\}\) and a single vertex \(x_i\). Let Q denote the set \(\{x_1,\ldots ,x_{m(G)}\}\) and let \(U = \bigcup _{1\le i\le n(G)} U_i\), \(W = \bigcup _{1\le i\le m(G)}W_i\). Finally, set \(V(G^\prime ) = Q\cup W\cup U\). Now, we define the edges of \(G^\prime \). First, create all edges so that Q induces a complete graph. Then, for every edge \(e_t\in E(G)\), \(t\in \{1,\ldots ,m(G)\}\) with endvertices \(v_i\), \(v_j\) join the corresponding vertex \(x_t\) with all vertices in \(U_i\), \(U_j\) and \(W_t\), and create all edges so that \(U_i\cup W_t\) and \(U_j\cup W_t\) induce complete graphs. In what follows a graph induced in \(G^\prime \) by \(W_t\cup U_i\cup U_j\cup \{x_t\}\) is denoted by \(X_{t,i,j}\) and called the gadget corresponding to the edge \(e_t\). The construction is completed by setting
$$\begin{aligned} k =\lceil {m(G)}/(p-1) \rceil + 3. \end{aligned}$$
For an example of the construction see Fig. 3. \(\square \)
Property 4.1
Let \(H^\prime \) and \(G^\prime \) be the graphs resulting from Construction 4.1 applied to H and G, respectively. If \(H \subseteq G\), then \(H^\prime \le G^\prime \).
Property 4.2
Let \(X_{t,i,j}\) be a gadget and let \(H=K_p\) with \(p\ge 3\). If H contains some vertex in \(W_t\), then
(a)
\(V(H)\subseteq V(X_{t,i,j})\),
 
(b)
\(V(H)\subseteq U_{\tau }\cup W_t\cup \{x_t\}\) if there exists \(u\in V(H)\cap U_{\tau }\) for some \(\tau \in \{i,j\}\).
 
We say that in a \({\mathcal {P}}\)-colored graph H a set \(U\subseteq V(H)\) uses color \(\ell \) if every vertex in U has color \(\ell \).
Lemma 4.1
If G has a proper coloring with 3 colors, then the graph \(G^\prime \) admits a Grundy \({\mathcal {P}}\)-coloring with k colors.
Proof
Let \(\varphi \) be a proper 3-coloring of G. In order to define the corresponding Grundy \({\mathcal {P}}\)-coloring \(\varphi ^\prime \) of \(G^\prime \) we set \(\varphi ^\prime (u)=\varphi (v_i)\) for all vertices u in the set \(U_i\) corresponding to the vertex \(v_i\) of G. Consequently, each set \(U_i\) uses one of the colors in \(\{1,2,3\}\), which is feasible since U is \({\mathcal {P}}\)-independent. Let \(X_{t,i,j}\) be an arbitrary gadget in \(G^\prime \). Since \(X_{t,i,j}\) corresponds to the edge \(v_i v_j\) and \(\varphi \) is proper, the sets \(U_i\) and \(U_j\) use distinct colors, say a and b, respectively. Thus for every vertex \(w\in W_t\) its colored neighbors in \(U_i\cup U_j\) use colors in \(\{a,b\}\) and hence the color \(c\in \{1,2,3\}\setminus \{a,b\}\) is feasible for w. We set \(\varphi ^\prime (w)=c\). Following Construction 4.1, for every vertex \(w\in W_t\) we have \(G^\prime [U_i\cup \{w\}]=K_p\) and \(G^\prime [U_j\cup \{w\}]=K_p\). It remains to observe that independently of color permutation, each color smaller than \(\varphi ^\prime (w)\) is used by \(U_i\) or \(U_j\). Hence, if \(\varphi ^\prime (w)=c\), then w is a Grundy vertex. Now, without loss of generality consider a vertex u in \(U_i\). Since by assumption every vertex of G belongs to a triangle, say induced by \(\{v_i, v_j, v_{\tau }\}\), the colors used by the corresponding sets \(U_i, U_j\) and \(U_{\tau }\) are distinct and uniquely determine distinct colors used by the sets \(W_t\) and \(W_{t^\prime }\) that correspond to the edges \(v_iv_j\) and \(v_iv_{\tau }\), respectively. Naturally, u is a Grundy vertex, which follows by a similar argument as above (note \(G^\prime [W_t\cup \{u\}]=K_p\) and \(G^\prime [W_{t^\prime }\cup \{u\}]=K_p\)). Thus we have proved that \(\varphi ^\prime \vert _{W\cup U}\) is a Grundy \({\mathcal {P}}\)-coloring. It remains to extend \(\varphi ^\prime \vert _{W\cup U}\) to \(V(G^\prime )\) by processing vertices of Q in an arbitrary order and \({\mathcal {P}}\)-coloring them greedily. Since for each \(x_t\in Q\) the sets \(W_t, U_i, U_j\) of \(X_{t,i,j}\) use three distinct colors in \(\{1,2,3\}\) and \(G^\prime [A\cup \{x_t\}]=K_p\) for every \(A\in \{U_i,U_j,W_t\}\), and \(G^\prime [D\cup \{x_t\}]=K_p\) for every \((p-1)\)-element subset D of Q, a simple inductive argument shows that every \((p-1)\)st vertex of Q new color is introduced with the largest one achieving \(\lceil m(G)/(p-1)\rceil +3\). For an example see Fig. 3. \(\square \)
Lemma 4.2
If \(\varphi ^\prime \) is a Grundy \({\mathcal {P}}\)-coloring of a graph \(G^\prime \) using \(k\ge 6\) colors, then \(\varphi ^\prime (v) \le 3\) if and only if vertex v belongs to \(U\cup W\).
For a rather technical proof of Lemma 4.2 we refer the reader to “Appendix B”.
Let \(V_1\), \(V_2\) be two nonempty vertex sets of the same cardinality, and let \(\ell _1\), \(\ell _2\) be two distinct colors. We say that \(V_1\), \(V_2\) mix colors \(\ell _1\) and \(\ell _2\) if there exists a partition \((A_1,A_2)\) of \(V_1\cup V_2\) such that \(\vert A_1\vert = \vert A_2\vert \), \(A_1\ne V_i\) and \(A_i\) uses \(\ell _i\), \(i\in \{1,2\}\). The next lemma says that certain vertex sets of \(G^\prime \) cannot mix colors.
Lemma 4.3
Let \(X_{t,i,j}\) be an arbitrary gadget in \(G^\prime \). If \(\varphi ^\prime \) is a Grundy \({\mathcal {P}}\)-coloring of a graph \(G^\prime \) with \(k\ge 6\) colors, then the sets \(U_i\), \(U_j\) and \(W_t\) of \(X_{t,i,j}\) use pairwise distinct colors in \(\{1,2,3\}\).
Proof
First we show that \(V(X_{t,i,j})\setminus \{x_t\}\) contains the three sets such that each of them uses a distinct color in \(\{1,2,3\}\). By Lemma 4.2 we have \(\varphi (x_t)\ge 4\). Hence, since \(x_t\) is a Grundy vertex, for each \(\ell \in \{1,2,3\}\) there exists a set \(D_{\ell }\) that uses color \(\ell \) in coloring \(\varphi ^\prime \) and \(G^\prime [D_{\ell }\cup \{x_t\}]=K_p\). By the same claim it follows that each of these sets is contained in \(N_{G^\prime }(x_t)\cap (U\cup W)\) while from the construction of \(G^\prime \) it is easy to see that \(N_{G^\prime }(x_t)\cap (U\cup W) = V(X_{t,i,j})\setminus \{x_t\}\). Clearly, the sets \(D_1, D_2\) and \(D_3\) are pairwise disjoint and hence by their cardinalities it follows that \(D_1\cup D_2\cup D_3 = V(X_{t,i,j})\setminus \{x_t\}\). It remains to prove that \(\{D_1,D_2,D_3\} = \{U_i,U_j,W_t\}\). Using Property 4.2(b) it is not hard to argue that for every gadget \(X_{t,i,j}\), considered independently of other gadgets, either (a) \(U_i, U_j, W_t\) use distinct colors in \(\{1,2,3\}\), or (b) \(U_i,W_t\) (resp. \(U_j,W_t\)) mix colors \(a,b\in \{1,2,3\}\) and \(U_j\) (resp. \(U_i\)) uses the color in \(\{1,2,3\}\setminus \{a,b\}\). Now, we show that if one considers \(X_{t,i,j}\) as a subgraph of \(G^\prime \), then only the former condition is feasible. Let \(v_i\) be an arbitrary vertex of G. By assumption \(v_i\) belongs to a triangle, say induced by \(v_i,v_j\) and \(v_{\tau }\). Let \(X_{t,i,j}\), \(X_{t^\prime ,i,\tau }\) and \(X_{t^{\prime \prime },j,\tau }\) be the gadgets corresponding to the edges of this triangle. Without loss of generality, suppose to the contrary that \(U_i\), \(W_t\) mix colors \(a,b\in \{1,2,3\}\). If so, then following (b) for \(X_{t^\prime ,i,\tau }\) we get that also \(U_i\), \(W_{t^\prime }\) have to mix a and b. Again by (b) applied to \(X_{t,i,j}\) and \(X_{t^\prime ,i,\tau }\), it follows that \(U_j\) and \(U_\tau \) have to use the third color, say c. This results in \(2(p-1)\) vertices of \(X_{t^{\prime \prime },j,\tau }\) that use color c and hence contradicts the property that \(V(X_{t^{\prime \prime },j,\tau })\) contains three sets of cardinality \(p-1\) such that each of them uses a distinct color in \(\{1,2,3\}\). \(\square \)
Lemma 4.4
If \(G^\prime \) has a Grundy \({\mathcal {P}}\)-coloring with k colors, then G admits a proper coloring with 3 colors.
Proof
By the construction of \(G^\prime \), each set \(U_i\) of \(G^\prime \) corresponds to a unique vertex \(v_i\) of G, \(i\in \{1,\ldots ,n(G)\}\). Let \(\varphi ^\prime \) be a Grundy \({\mathcal {P}}\)-coloring of \(G^\prime \) with k colors and let \(\ell _i\) denote the color used by the set \(U_i\) in \(\varphi ^\prime \). In order to define an appropriate proper coloring \(\varphi \) of the graph G with 3 colors, for each vertex \(v_i\) of G we set \(\varphi (v_i)=\ell _i\). From Lemma 4.3 it follows that \(\ell _i\in \{1,2,3\}\) and that for every edge \(e_t=v_iv_j\) of G the corresponding sets \(U_i, U_j\) of the gadget \(X_{t,i,j}\) use distinct colors. Thus \(\varphi \) is a proper coloring of G with 3 colors. \(\square \)
Proof of Theorem 4.2
If \({\varvec{F}}({\mathcal {P}})\) is finite, we can use the arguments similar to those in the proof of Theorem 3.2 to show that a certificate function \(\varphi :V(G)\rightarrow \mathbb {N}\) can be verified in polynomial time for being a Grundy \({\mathcal {P}}\)-coloring with k colors. Hence Grundy \({\mathcal {P}}\) -Coloring belongs to \(\mathbb {NP}\). Now, Lemmas 4.1 and 4.4, and the fact that Construction 4.1 is polynomial in the size of G imply \(\mathbb {NP}\)-hardness of the problem, which finishes the proof. \(\square \)

5 \(\text {co}\mathbb {NP}\)-completeness of the membership in \({\mathcal {H}}({\mathcal {P}},t)\)

In this section we investigate the computational complexity of the problem of deciding the membership in the class \({\mathcal {H}}({\mathcal {P}},t)=\{G\!\mid \!{\varGamma _{\mathcal {P}}(G)}-\chi _{{\mathcal {P}}}(G)\le t\}\). We prove that the problem is \(\text {co}\mathbb {NP}\)-complete for every \(t\ge 0\) and every class \({\mathcal {P}}\) for which \({\varvec{F}}({\mathcal {P}})=\{K_p\}\) with \(p\ge 3\). We present a polynomial-time reduction from Grundy  \({\mathcal {P}}\) -Coloring of graphs in the class \({\mathcal {Q}}(p-1)\), where by \({\mathcal {Q}}(p-1)\) we mean the class of graphs obtained by the application of Construction 4.1 to all graphs G in \({\mathcal {L}}(p-1)\) for which \(m(G)\ge 4p-3\) (note that such a restriction on the size of graphs does not influence the hardness of Grundy  \({\mathcal {P}}\) -Coloring, i.e., it remains \(\mathbb {NP}\)-complete even in \({\mathcal {Q}}(p-1)\)). Before proving the hardness of the above membership problem we need some facts on the \({\mathcal {P}}\)-Grundy number of graphs in \({\mathcal {Q}}(p-1)\).
Lemma 5.1
Let \({\mathcal {P}}\) be a class of graphs such that \({\varvec{F}}({\mathcal {P}})=\{K_p\}\) with \(p\ge 3\). If \(G^\prime \in {\mathcal {Q}}(p-1)\), then
$$\begin{aligned} \chi _{{\mathcal {P}}}(G^\prime )=\lceil \omega (G^\prime )/(p-1) \rceil . \end{aligned}$$
Proof
Let \(G\in {\mathcal {L}}(p-1)\), where \(p\ge 3\) and \(m(G)\ge 4p-3\). Moreover, let an instance \((G^\prime ,k)\) of Grundy \({\mathcal {P}}\) -Coloring result from the application of Construction 4.1 to a graph G (recall that \(k = \lceil m(G)/(p-1)\rceil +3\)). We are going to prove that \(\chi _{{\mathcal {P}}}(G^\prime ) = k-3\).
First, observe that if \({\varvec{F}}({\mathcal {P}})=\{K_p\}\), then for every graph H we have \( \chi _{{\mathcal {P}}}(H) \ge \lceil \omega (H)/(p-1) \rceil , \) where \(\omega (H)\) stands for the clique number of H. From the construction of \(G^\prime \) it easily follows that if \(m(G)\ge 2p-1\), then \(\omega (G^\prime ) = m(G)\) (recall \(m(G) = \vert Q \vert \)). Consequently, if \(m(G)\ge 4p-3\), then \(\chi _{{\mathcal {P}}}(G^\prime ) \ge k-3\).
Next, in order to show \(\chi _{{\mathcal {P}}}(G^\prime ) \le k-3\) we start with an arbitrary \({\mathcal {P}}\)-coloring of complete graph \(G^\prime [Q]\) using \(k-3\) colors. Now, we argue that it is possible to color the remaining vertices of \(G^\prime \) such that all vertices in U are colored before any vertex in W and that we do not need to introduce any additional colors. Let \(X_{t,i,j}\) be an arbitrary gadget in \(G^\prime \). Since G is a graph of degree bounded by 4, every vertex \(u\in U_i\) has at most 4 neighbors in Q. Moreover, by assumption \(k = \lceil m(G)/(p-1)\rceil + 3\) and \(m(G)\ge 4(p-1)+1\), which implies \(k\ge 8\). Hence, there are at least 5 colors used for vertices in Q. Thus, for every vertex \(u\in U_i\) there exists at least one color in \(\{1,\ldots ,k-3\}\) that has not been used for any vertex in \(N_{G^\prime }(u)\cap Q\). Note that the same color can be used for all \(p-1\) vertices in \(U_i\) and since U is \({\mathcal {P}}\)-independent, the selection of color for vertices in \(U_i\) is independent of selections for vertices in \(U\setminus U_i\). Thus, there exists a \({\mathcal {P}}\)-coloring of \(G^\prime [Q\cup U]\) with \(k-3\) colors. It remains to color the vertices in W. First, observe that for every vertex \(w\in W_t\) we have \(N_{G^\prime }(w) = U_i\cup U_j\cup \{x_t\}\), where \(x_t\in Q\). Thus, following the above \({\mathcal {P}}\)-coloring of \(G^\prime [Q\cup U]\), there are at most three colors used for vertices in \(N_{G^\prime }(w)\) and hence, since \(k\ge 8\), there are at least two colors in \(\{1,\ldots ,k-3\}\) that can be used for w. The argument is completed by the observation that the same color can be used for all \(p-1\) vertices in \(W_t\) and that the selection of color for vertices in \(W_t\) is independent of selections for vertices in \(W\setminus W_t\).
Since \(\chi _{{\mathcal {P}}}(G^\prime ) = k-3\), to complete the proof observe that if \(m(G)\ge 4p-3\), then \(m(G)=\omega (G^\prime )\). \(\square \)
Remark 5.1
Since by the above proof \(\chi _{{\mathcal {P}}}(G^\prime ) = k-3\), the problem of determining the \({\mathcal {P}}\)-Grundy number of graphs in \({\mathcal {Q}}(p-1)\) can be solved in polynomial time. Moreover, since by Lemma 4.1 we have \({\varGamma _{\mathcal {{\mathcal {P}}}}(G^\prime )} \ge k\), we know that \(\chi _{{\mathcal {P}}}(G^\prime ) < {\varGamma _{\mathcal {{\mathcal {P}}}}(G^\prime )}\) for every graph \(G^\prime \in {\mathcal {Q}}(p-1)\).
Theorem 5.1
If \({\mathcal {P}}\) is a class of graphs such that \({\varvec{F}}({\mathcal {P}})=\{K_p\}\) with \(p\ge 3\), then for every \(t\ge 0\) the problem of the membership in \({\mathcal {H}}({\mathcal {P}},t)\) is \(\text {co}\mathbb {NP}\)-complete.
Proof
In order to show that our problem belongs to \(\text {co}\mathbb {NP}\) it is enough to observe that a graph does not belong to \({\mathcal {H}}({\mathcal {P}},t)\) if and only if it admits two Grundy \({\mathcal {P}}\)-colorings with \(k_1\) and \(k_2\) colors respectively, and \(k_2 > k_1 + t\). Equivalently, two orderings of the vertex set leading to the above-mentioned colorings could also serve as an appropriate No certificate. Clearly, due to the general assumption that the membership in \({\mathcal {P}}\) can be checked in polynomial time, the problem of the verification of our certificate is also polynomial.
Now, we present a polynomial-time reduction from Grundy  \({\mathcal {P}}\) -Coloring of graphs in \({\mathcal {Q}}(p-1)\) to the problem of the membership in \({\mathcal {I}}\setminus {\mathcal {H}}({\mathcal {P}},t)\) (recall that \({\mathcal {I}}\) denotes the class of all graphs). Given an arbitrary instance \((G,\kappa )\) of the former problem, for every \(t\ge 0\) we construct a graph \(G^\prime \) such that \(G^\prime \notin {\mathcal {H}}({\mathcal {P}},t)\) if and only if \({\varGamma _{\mathcal {P}}(G)}\ge \kappa \).
Construction 5.1
First, given graph G with the vertex set \(\{v_1,\ldots ,v_{n(G)}\}\) we construct a graph \(H_t\). Let \(T_1,\ldots ,T_{n(G)}\) be disjoint graphs such that each of them is isomorphic to the forcing \(({\mathcal {P}},t+1)\)-tree T (note that because \({\varvec{F}}({\mathcal {P}})=\{K_p\}\), such a graph T is unique) and let \(x_i\) denote the root of \(T_i\), \(i\in \{1,\ldots ,n(G)\}\). The graph \(H_t\) we construct from the graphs \(G,T_1,\ldots ,T_{n(G)}\) by the identification of each vertex \(v_i\) of G with the root \(x_i\) of the corresponding \(T_i\), \(i\in \{1,\ldots ,n(G)\}\). Next, following Lemma 5.1 we calculate \(\chi _{{\mathcal {P}}}(G)\). If \(\chi _{{\mathcal {P}}}(G) \ge \kappa \), then we set \(G^\prime =H_t\). On the other hand, if \(\chi _{{\mathcal {P}}}(G) < \kappa \), then in order to construct \(G^\prime \) we take a complete graph K of order \(\kappa (p-1)\) and a set \(S\subseteq V(K)\) such that \(\vert S \vert = p-1\) and join each vertex of \(H_t\) with all vertices in S. Since the order of \(G^\prime \) is at most \( n(G)\cdot p^t + \kappa = O(n(G))\) and by Lemma 5.1 determining \(\chi _{{\mathcal {P}}}(G)\) admits a polynomial-time algorithm, the graph \(G^\prime \) can be constructed in polynomial time. See Fig. 4 for an illustration of the construction. \(\square \)
In what follows we use the following properties of \(H_t\) with \(t\ge 0\).
(i)
\(\chi _{{\mathcal {P}}}(H_t) = \chi _{{\mathcal {P}}}(G)\),
 
(ii)
\({\varGamma _{\mathcal {P}}(H_t)} = {\varGamma _{\mathcal {P}}(G)} + t\).
 
The former equation follows easily by the fact that every forcing \(({\mathcal {P}},t+1)\)-tree admits a \({\mathcal {P}}\)-coloring with 2 colors. For a lower bound in the latter one it is enough to consider one of the “from the leaves up” orderings, that forces the greedy algorithm to use \(t+1\) colors on each of the forcing \(({\mathcal {P}},t+1)\)-trees \(T_1,\ldots ,T_{n(G)}\) while an upper bound follows by the analysis of graphs F in \({\varvec{C}}_k({\mathcal {P}})\) contained in \(H_t\) and such that \(k>\chi _{{\mathcal {P}}}(F)\).
First, let \(\chi _{{\mathcal {P}}}(G)\ge \kappa \). Naturally, \(\chi _{{\mathcal {P}}}(G)\ge \kappa \) implies \({\varGamma _{\mathcal {P}}(G)}\ge \kappa \) and hence \((G,\kappa )\) is a Yes instance of Grundy  \({\mathcal {P}}\) -Coloring. Since by Remark 5.1 for every graph \(G\in {\mathcal {Q}}(p-1)\) we have \(\chi _{{\mathcal {P}}}(G) < {\varGamma _{\mathcal {P}}(G)}\), by (i) and (ii) we get \( \chi _{{\mathcal {P}}}(G^\prime ) = \chi _{{\mathcal {P}}}(G) < {\varGamma _{\mathcal {P}}(G)} = {\varGamma _{\mathcal {P}}(G^\prime )} - t \) (recall \(G^\prime =H_t\)). Thus \(G^\prime \notin {\mathcal {H}}({\mathcal {P}},t)\); in other words \(G^\prime \) is a Yes instance of the problem of the membership in \({\mathcal {I}}\setminus {\mathcal {H}}({\mathcal {P}},t)\).
Next, assume \(\chi _{{\mathcal {P}}}(G) < \kappa \). Let us consider a graph \(H^\prime = H_t + G^\prime [S]\). It is not hard to see that \(\chi _{{\mathcal {P}}}(H^\prime ) \le \chi _{{\mathcal {P}}}(H_t)+1\) and hence by (i) we easily get \(\chi _{{\mathcal {P}}}(H^\prime )\le \chi _{{\mathcal {P}}}(G)+1\). On the other hand, \(\chi _{{\mathcal {P}}}(H^\prime ) \ge \lceil \omega (H^\prime )/(p-1) \rceil \). Since \(\omega (H^\prime ) = \omega (H_t) + p - 1\) and \(\omega (H_t)=\omega (G)\), we have \(\chi _{{\mathcal {P}}}(H^\prime ) \ge \lceil \omega (G)/(p-1) \rceil + 1\), which, by Lemma 5.1, results in \(\chi _{{\mathcal {P}}}(H^\prime ) \ge \chi _{{\mathcal {P}}}(G) + 1\). Finally, \(\chi _{{\mathcal {P}}}(H^\prime ) = \chi _{{\mathcal {P}}}(G)+1\).
Now, consider \(G^\prime \) and observe that \(\chi _{{\mathcal {P}}}(G^\prime ) = \max \{\chi _{{\mathcal {P}}}(H^\prime ), \chi _{{\mathcal {P}}}(K)\}\). Hence, since \(\chi _{{\mathcal {P}}}(K)=\kappa \) and by assumption \(\chi _{{\mathcal {P}}}(G) < \kappa \), we get
$$\begin{aligned} \chi _{{\mathcal {P}}}(G^\prime ) = \max \{ \chi _{{\mathcal {P}}}(G) + 1, \kappa \} = \kappa . \end{aligned}$$
Moreover, by Proposition 2.2 and simple analysis of maximum degrees of appropriate subgraphs of \(G^\prime \) we see that \({\varGamma _{\mathcal {P}}(H^\prime )} = {\varGamma _{\mathcal {P}}(H_t)} + 1\). A similar argument results in \({\varGamma _{\mathcal {P}}(G^\prime )} = \max \{{\varGamma _{\mathcal {P}}(H^\prime )}, {\varGamma _{\mathcal {P}}(K)} \}\), and since \({\varGamma _{\mathcal {P}}(K)} = \kappa \) and by (ii) we have \({\varGamma _{\mathcal {P}}(H_t)} = {\varGamma _{\mathcal {P}}(G)} + t\), we see that
$$\begin{aligned} {\varGamma _{\mathcal {P}}(G^\prime )} = \max \{{\varGamma _{\mathcal {P}}(G)} + t + 1, \kappa \}. \end{aligned}$$
Now, we continue by considering the two possibilities. If \({\varGamma _{\mathcal {P}}(G)}\ge \kappa \), then \( {\varGamma _{\mathcal {P}}(G^\prime )} \ge \max \{\kappa + t + 1, \kappa \} = \kappa + t + 1 > \chi _{{\mathcal {P}}}(G^\prime ) + t, \) which implies \(G^\prime \notin {\mathcal {H}}({\mathcal {P}},t)\). On the other hand, if \({\varGamma _{\mathcal {P}}(G)}<\kappa \), then \( {\varGamma _{\mathcal {P}}(G^\prime )} \le \max \{\kappa -1+ t + 1, \kappa \} = \kappa + t = \chi _{{\mathcal {P}}}(G^\prime ) + t \) and hence \(G^\prime \in {\mathcal {H}}({\mathcal {P}},t)\).
Thus \(G^\prime \notin {\mathcal {H}}({\mathcal {P}},t)\) if and only if \({\varGamma _{\mathcal {P}}(G)}\ge \kappa \). \(\square \)

6 An upper bound on the \({\mathcal {P}}\)-Grundy number

We conclude our paper with a new upper bound on the \({\mathcal {P}}\)-Grundy number. For clarity of presentation first we recall some notation introduced in the proof of Lemma 4.2 (see “Appendix B”). For a vertex v of a graph G we use \({\mathcal {D}}(G,v)\) to denote the family of all subsets of \(V(G)\setminus \{v\}\) such that \(G[D\cup \{v\}]\in {\varvec{F}}({\mathcal {P}})\) holds for every D in \({\mathcal {D}}(G,v)\). The set \({N_{G}({\mathcal {P}},v)} = \{u\in D \mid D \text{ is } \text{ a } \text{ member } \text{ of } {\mathcal {D}}(G,v)\}\) is called the \({\mathcal {P}}\)-neighborhood of vertex v in G. By the \({\mathcal {P}}\)-degree of a vertex v of G, denoted by \({d_{G}({\mathcal {P}},v)}\), we mean the cardinality of a largest subfamily of \({\mathcal {D}}(G,v)\) consisting of pairwise disjoint sets.
A natural upper bound
$$\begin{aligned} {\varGamma _{\mathcal {P}}(G)} \le \max _{v\in V(G)}{d_{G}({\mathcal {P}},v)} + 1 \end{aligned}$$
(6.1)
follows directly from the greedy color assignment rule. The above bound, however, can be significantly improved by careful analysis of function \({\phi }_{G}:V(G)\rightarrow \mathbb {N}_0\) defined recursively on the vertex set of a graph G. Namely, let \({{\phi }^{0}_{G}({\mathcal {P}},v)} = {d_{G}({\mathcal {P}},v)}\). For every integer \(r\ge 1\), let \({{\phi }^{r}_{G}({\mathcal {P}},v)}\) be the largest k for which there exist k pairwise disjoint sets \(D_1,\ldots ,D_k\) in \({\mathcal {D}}(G,v)\) such that for each of them \({\lambda ^{r-1}_{G}(D_i)}\ge i\), where \({\lambda ^{r-1}_{G}(D_i)}\) denotes the \((r-1)\)st intensity of \(D_i\) defined as follows
$$\begin{aligned} {\lambda ^{r-1}_{G}(D_i)} = \min \{{{\phi }^{r-1}_{G}({\mathcal {P}},u)} \mid u\in D_{i}\}, \end{aligned}$$
where \(i\in \{1,\ldots ,k\}\). A simple inductive argument shows that \({{\phi }^{r}_{G}({\mathcal {P}},v)}\le {{\phi }^{r-1}_{G}({\mathcal {P}},v)}\) for every vertex v and every \(r\ge 1\). This implies the existence of an integer \(t\ge 0\) such that \({{\phi }^{t}_{G}({\mathcal {P}},v)}={{\phi }^{r}_{G}({\mathcal {P}},v)}\) for every vertex v and every \(r\ge t\). Thus \({{\phi }^{t}_{G}({\mathcal {P}},v)}\) is uniquely determined. The \({\mathcal {P}}\)-potential of a vertex v, denoted by \({{\phi }^{}_{G}({\mathcal {P}},v)}\), is given by \( {{\phi }^{}_{G}({\mathcal {P}},v)}={{\phi }^{t}_{G}({\mathcal {P}},v)}. \) The \({\mathcal {P}}\)-potential of a graph G, denoted by \({{\varPhi }_{\mathcal {P}}(G)}\), is defined as follows
$$\begin{aligned} {{\varPhi }_{\mathcal {P}}(G)} = \max \{{{\phi }^{}_{G}({\mathcal {P}},v)} \mid v\in V(G)\}. \end{aligned}$$
Let us consider a simple example.
Example 6.1
Let \(H\in {\varvec{C}}_k({\mathcal {P}})\) and let \(H_1,\ldots ,H_m\) with \(m\ge 2\) be disjoint copies of H. In each \(H_i\), \(i\in \{1,\ldots ,m\}\) we distinguish a single vertex \(x_i\). Let G be a graph obtained from \(H_1,\ldots ,H_m\) by the identification of vertices \(x_1,\ldots ,x_m\), and let x denote the unique vertex of G that has neighbors in each \(H_i\), \(i\in \{1,\ldots ,m\}\). Using simple arguments, e.g., minimality of H and the fact that x is a cut vertex, it is not hard to see that for every \(v\in V(G)\setminus \{x\}\) we have \({d_{G}({\mathcal {P}},v)} = 1\), while \({d_{G}({\mathcal {P}},x)} = m\). Thus, by (6.1) we have \({\varGamma _{\mathcal {P}}(G)} \le m + 1\). Moreover, when considering x, observe that the only choice of the sets in \({\mathcal {D}}(G,x)\) that realize \({d_{G}({\mathcal {P}},x)}\) is \(D_i=V(H_i)\setminus \{x\}\) for all \(i\in \{1,\ldots ,{d_{G}({\mathcal {P}},x)}\}\). Hence \({\lambda ^{0}_{G}(D_i)} = 1\), which implies \({{\phi }^{1}_{G}({\mathcal {P}},x)} = 1\). Similarly, other vertices v of G satisfy \({{\phi }^{1}_{G}({\mathcal {P}},v)} = 1\). This finally gives \({{\phi }^{}_{G}({\mathcal {P}},v)} = 1\) for all vertices v of G and hence \({{\varPhi }_{\mathcal {P}}(G)} = 1\). As we will see later on from (6.2) it follows that \({\varGamma _{\mathcal {P}}(G)}\le 2\), which is best possible. Moreover, the example shows that the difference between the bounds (6.1) and (6.2) can be arbitrarily large. \(\square \)
For the proof of Theorem 6.1 we need the following property.
Proposition 6.1
Let \({\mathcal {P}}\) be a class of graphs and let G be a graph in \({\mathcal {P}}\). If \(H\le G\) and v is a vertex of H, then \({{\phi }^{r}_{H}({\mathcal {P}},v)}\le {{\phi }^{r}_{G}({\mathcal {P}},v)}\) for every \(r\ge 0\).
Proof
The proof is by induction on r. If \(r=0\), then the assertion holds by the fact that \({d_{H}({\mathcal {P}},v)}\le {d_{G}({\mathcal {P}},v)}\). Let \(r>0\). If \({{\phi }^{r}_{H}({\mathcal {P}},v)}=k\), then for every \(j\in \{1,\ldots ,k\}\) there exists \(D_j\subseteq {N_{H}({\mathcal {P}},v)}\) such that \(H[D_j\cup \{v\}]\in {\varvec{F}}({\mathcal {P}})\) and \({\lambda ^{r-1}_{H}(D_j)}\ge j\), which implies \({{\phi }^{r-1}_{H}({\mathcal {P}},u)}\ge j\) for every \(u\in D_j\). Thus, by the induction hypothesis, all vertices \(u\in D_j\) satisfy \({{\phi }^{r-1}_{G}({\mathcal {P}},u)}\ge j\), where \(j\in \{1,\ldots ,k\}\). This implies \({\lambda ^{r-1}_{G}(D_j)}\ge j\) for every \(j\in \{1,\ldots ,k\}\), which results in \({{\phi }^{r}_{G}({\mathcal {P}},v)}\ge k\). \(\square \)
Theorem 6.1
For every class \({\mathcal {P}}\) and every graph G we have
$$\begin{aligned} {\varGamma _{\mathcal {P}}(G)} \le {{\varPhi }_{\mathcal {P}}(G)} + 1. \end{aligned}$$
(6.2)
Proof
Let G be a graph such that \({\varGamma _{\mathcal {P}}(G)}=k\). It is not hard to see that the assertion holds for \(k=1\). Assume \(k\ge 2\) and let H be an induced subgraph of G such that \(H\in {\varvec{C}}_{k}({\mathcal {P}})\) and let \((V_1,\ldots ,V_k)\) be a Grundy \({\mathcal {P}}\)-coloring \(\varphi \) of H with k colors. Since every vertex \(v\in V_i\), \(i\in \{1,\ldots ,k\}\) is a Grundy vertex, for every \(j\in \{1,\ldots ,i-1\}\) there exists \(D_j\subseteq {N_{H}({\mathcal {P}},v)}\cap V_j\) such that \(H[D_j\cup \{v\}]\in {\varvec{F}}({\mathcal {P}})\) (naturally, \(D_j\) and \(D_{j^\prime }\) are disjoint when \(j\ne j^\prime \)). If \(i=k\), then directly from minimality of H it follows that \(V_k\) is a singleton, say \(V_k=\{v_k\}\). On the other hand, if \(i<k\), then by minimality of H there exist \(w\in V_{i+1}\) and \(D_i\subseteq {N_{H}({\mathcal {P}},w)}\cap V_{i}\) such that \(v\in D_i\) and \(H[D_i\cup \{w\}]\in {\varvec{F}}({\mathcal {P}})\). In other words, every vertex v with color \(i<k\) has to be active in forcing some color \(\ell >i\), for otherwise \({\varGamma _{\mathcal {P}}(H-v)}=k\), which contradicts the minimality of H. In the proof, for coloring \(\varphi \) and vertex \(v\in V_i\) with \(i<k\) we use \({\mathcal {S}}_i(v)\) in place of \(D_1,\ldots ,D_i\) (note that we include \(D_i\)) and we simply say that w is a friend of \(D_i\).
We claim that the following conditions are satisfied:
(a)
\({{\phi }^{r}_{H}({\mathcal {P}},v_k)}\ge k-1\),
 
(b)
\({{\phi }^{r}_{H}({\mathcal {P}},v)}\ge i\) for every \(v\in V_i\), \(i\in \{1,\ldots ,k-1\}\).
 
The proof is by induction on r. First we justify conditions (a) and (b) when \(r=0\). Since for every \(i\in \{1,\ldots ,k-1\}\) the sets in \({\mathcal {S}}_i(v)\) are pairwise disjoint, \({d_{H}({\mathcal {P}},v)}\ge i\) holds, and since \({{\phi }^{0}_{H}({\mathcal {P}},v)}={d_{H}({\mathcal {P}},v)}\), we have \({{\phi }^{0}_{H}({\mathcal {P}},v)}\ge i\). Similarly, the sets \(D_1,\ldots ,D_{k-1}\) are pairwise disjoint and hence \({d_{H}({\mathcal {P}},v_k)}\ge k-1\), which by the definition of \({\phi }\) results in \({{\phi }^{0}_{H}({\mathcal {P}},v_k)}\ge k-1\).
Let \(r\ge 1\) and assume that the assertion holds for parameters smaller than r. Let \(v\in V_i\), where \(i\in \{1,\ldots ,k-2\}\). Assume \(D^\prime = D_i\setminus \{v\}\cup \{w\}\), where \(D_i\in {\mathcal {S}}_i(v)\) and w is a friend of \(D_i\). Since \(w\in V_{i+1}\), by the induction hypothesis \({{\phi }^{r-1}_{H}({\mathcal {P}},w)}\ge i+1\) while for every \(u\in D^\prime \) such that \(u\ne w\) we have \({{\phi }^{r-1}_{H}({\mathcal {P}},u)}\ge i\). Hence, by definition \({\lambda ^{r-1}_{H}(D^\prime )}\ge i\). Moreover, for every \(j\in \{1,\ldots ,i-1\}\) by the induction hypothesis all vertices \(u\in D_j\) satisfy \({{\phi }^{r-1}_{H}({\mathcal {P}},u)}\ge j\) and hence by definition \({\lambda ^{r-1}_{H}(D_j)}\ge j\). Thus, taking into account the intensities of \(D_1,\ldots ,D_{i-1}\) and \(D^\prime \) we get \({{\phi }^{r}_{H}({\mathcal {P}},v)}\ge i\).
Let \(v\in V_{k-1}\). Similarly as above, assume \(D^\prime =D_{k-1}\setminus \{v\}\cup \{v_k\}\), where \(D_{k-1}\in {\mathcal {S}}_{k-1}(v)\) and \(v_k\) is the friend of \(D_{k-1}\). By part (a) of the induction hypothesis we have \({{\phi }^{r-1}_{H}({\mathcal {P}},v_k)}\ge k-1\) while by part (b) for all \(u\in D^\prime \) such that \(u\ne v_k\) we have \({{\phi }^{r-1}_{H}({\mathcal {P}},u)}\ge k-1\). Hence, by definition \({\lambda ^{r-1}_{H}(D^\prime )}\ge k-1\). Moreover, by the induction hypothesis applied to all vertices of every \(D_j\) with \(j\in \{1,\ldots ,k-2\}\) we get \({\lambda ^{r-1}_{H}(D_j)}\ge j\). Thus taking into account the intensities of \(D_1,\ldots ,D_{k-2}\) and \(D^\prime \) it follows that \({{\phi }^{r}_{H}({\mathcal {P}},v)}\ge k-1\).
Analogously, for the last case (i.e., when \(v=v_k\)) we directly apply part (b) of the induction hypothesis to all vertices of every \(D_j\) with \(j\in \{1,\ldots ,k-1\}\), which clearly results in \({\lambda ^{r-1}_{H}(D_j)}\ge j\) for all of these sets and hence \({{\phi }^{r}_{H}({\mathcal {P}},v_k)}\ge k-1\).
Thus (a) and (b) hold, as claimed.
By the above claim and the definition of \({\varPhi }_{{\mathcal {P}}}\) we have \({{\varPhi }_{\mathcal {P}}(H)}\ge {\phi }_H(v_k)\ge k-1\), and since from Proposition 6.1 it follows that \({{\varPhi }_{\mathcal {P}}(G)}\ge {{\varPhi }_{\mathcal {P}}(H)}\), we get \({{\varPhi }_{\mathcal {P}}(G)}\ge {\varGamma _{\mathcal {P}}(G)}-1\), which completes the proof. \(\square \)

Acknowledgements

Special thanks to Dariusz Dereniowski and Ewa Drgas-Burchardt for their remarks on preliminary version of this paper, and to Sundar Vishwanathan for sending me the manuscript (Goyal and Vishwanathan 1998). An extended abstract of a preliminary version of this paper has been presented at 11th International Workshop on Frontiers in Algorithmics, FAW 2017 (see Borowiecki 2017).
Open AccessThis article is distributed under the terms of the Creative Commons Attribution 4.0 International License (http://​creativecommons.​org/​licenses/​by/​4.​0/), which permits unrestricted use, distribution, and reproduction in any medium, provided you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made.
Anhänge

Appendix A: Proof of Theorem 4.1

Recall that \({\mathcal {L}}(r)\) denotes the class of planar graphs with vertex degree at most 4, size \(m\equiv 1(\text{ mod } r)\) and every vertex belonging to at least one triangle.
Theorem 4.1
For every fixed \(r\ge 2\), the problem 3-Coloring is \(\mathbb {NP}\)-complete in \({\mathcal {L}}(r)\).
Proof
Let \(r\ge 2\) and let G be a planar graph such that \(d_G(v)\le 4\) for every vertex \(v\in V(G)\). Given G we construct a planar graph \(G^\prime \in {\mathcal {L}}(r)\), that is, a graph for which \(m(G^\prime )\equiv 1(\text{ mod } r)\) and every vertex u of \(G^\prime \) has two distinct neighbors xy such that \(G^\prime [\{u,x,y\}]=K_3\) and \(d_{G^\prime }(u)\le 4\).
Let \(R_2, R_3, R_4\) and \(A_s\) with \(s\ge 7\) denote the graphs presented in Fig. 5. In what follows we call them gadgets. Each gadget has some distinguished vertices called connectors (see dark vertices in the figure). For gadgets \(R_t\), \(t\in \{2,3,4\}\) the connectors are denoted by \(x_1,\ldots ,x_t\). Let v be a vertex of degree t in a graph H. A replacement of the vertex v with the gadget \(R_t\) is an operation that results in graph \(H^\prime \) satisfying the following conditions: (i) \(V(H^\prime ) = V(H)\setminus \{v\}\cup V(R_t)\), (ii) \(E(H^\prime ) = E(H) \setminus E_1 \cup E_2 \cup E(R_t)\), where \(E_1\) is the set of edges incident to v in H while \(E_2=\{x_i u_i \mid i\le t, \{u_1,\ldots ,u_t\} = N_H(v) \}\), i.e., \(E_2\) consists of the edges joining each connector \(x_i\) with a single neighbor \(u_i\) of v in H.
In order to obtain \(G^\prime \), given the graph G we follow subsequent steps of Construction A.1 and if after Step (i), \(i\in \{1,2,3\}\) the resulting graph \(G_i\) belongs to \({\mathcal {L}}(r)\) we skip the remaining steps and set \(G^\prime =G_i\). Similarly, if initially \(G\in {\mathcal {L}}(r)\), then we set \(G^\prime =G\).
Construction A.1
(1)
Repeat deleting vertices of degree 1 until no pending vertices remain.
 
(2)
If every vertex of \(G_1\) belongs to a triangle and \(G_1\) is 4-regular, then select an arbitrary vertex and replace it with \(R_4\).
 
(3)
Repeat replacing vertices that do not belong to any triangle until no such vertices remain (each vertex replace with appropriate gadget \(R_t\)).
 
(4)
Set s such that \(m(G_3)+s\equiv 1(\text{ mod } r)\) and identify the connectors of \(A_s\) with arbitrarily chosen adjacent vertices of degree at most 3 in \(G_3\). \(\square \)
 
Considering the degree condition, first observe that the operations in Step (1) cannot increase the degree of any vertex. Moreover, since for every gadget \(R_{t}\) the degrees of connectors are at most 3, by the definition of the replacement, the degrees of vertices in graphs after replacement are at most 4. For the feasibility of Step (4), observe that one cannot get \(G_3\) without replacement of at least one vertex in Step (2) or (3) and hence, since every gadget \(R_t\) contains a non-connector vertex of degree 3 that is adjacent either to a non-connector vertex of degree at most three or to a connector of degree at most two, there exists a pair of adjacent vertices in \(G_3\) whose identification with the connectors of any gadget \(A_s\) does not violate the degree condition. Naturally, the class of planar graphs is closed with respect to all operations performed in the construction.
When considering triangles, observe that if v is not contained in a triangle, then the replacement of v with a gadget \(R_t\) cannot affect the property of “being contained in a triangle” of any other vertex. Hence, if the replacement of some vertex w (contained in a triangle) in Step (2) resulted in loss of the property by some neighbor u of w, then the replacement of u in Step (3) cannot in turn affect this property for vertex w. Thus, every vertex is replaced at most once and hence the number of replacements is finite.
For the divisibility condition, it is enough to observe that \(m(A_s) = s\) and hence there are infinitely many gadgets \(A_s\) satisfying \(m(G_3)+m(A_s)\equiv 1(\text{ mod } r)\).
Now, we consider the relationship between 3-colorings of G and \(G^\prime \) (in order to cover all steps of the construction we assume \(G^\prime =G_4\)). First, let \(\chi (G)=3\) and let \(\varphi \) be a 3-coloring of G. Since \(\chi (G_1)=\chi (G)\), we let \(\varphi _1\) to be a 3-coloring of \(G_1\) obtained by setting \(\varphi _1(v)=\varphi (v)\) for every vertex v of \(G_1\). Since for a given \(\varphi _1\) obtaining 3-coloring of graphs \(G_2\) and \(G_3\) is analogous, without loss of generality we consider obtaining a 3-coloring \(\varphi _3\) of \(G_3\). For each vertex v that has been replaced with \(R_t\), color the connectors \(x_1,\ldots ,x_t\) such that \(\varphi _3(x_i) = \varphi _2(v)\), then color all other vertices of \(R_t\) according to Fig. 5, applying appropriate color permutation if necessary. Set \(\varphi _3(v) = \varphi _2(v)\) for all vertices of \(G_3\) that have not took part in the replacements. Finally, observe that \(\varphi _3\) can be trivially extended to 3-coloring \(\varphi _4\) of \(G_4\). The key property of gadgets \(R_t\) is that in every  3-coloring the colors of the connectors are the same (a simple proof of this fact is left to the reader). Let \(\varphi _4\) be a proper 3-coloring of \(G_4\). In what follows for each \(i\in \{1,2,3\}\) we define appropriate coloring \(\varphi _i\) of \(G_i\). Note that given \(\varphi _4\), obtaining \(\varphi _3\) and \(\varphi _2\) is trivial. Now, by the above property of gadgets, for every \(R_t\) the color c of the connectors in coloring \(\varphi _3\) can be used for the vertex v replaced with \(R_t\) in Step (2) or (3). We set \(\varphi _1(v)=c\). Now, setting \(\varphi _1(v)=\varphi _4(v)\) for all vertices of \(G_1\) that has not been replaced with any gadgets we complete the definition of \(\varphi _1\). Naturally, \(\varphi _1\) can be easily extended to 3-coloring \(\varphi \) of the graph G.
The proof concludes by an observation that Construction A.1 is polynomial in the size of G. \(\square \)

Appendix B: Proof of Lemma 4.2

Before being able to prove Lemma 4.2 we need to introduce additional notions (we recall some of them in Sect. 6). For a vertex v of a graph G we use \({\mathcal {D}}(G,v)\) to denote the family of all subsets of the set \(V(G)\setminus \{v\}\) such that for every set D in \({\mathcal {D}}(G,v)\) we have \(G[D\cup \{v\}]\in {\varvec{F}}({\mathcal {P}})\). The set \({N_{G}({\mathcal {P}},v)} = \{u\in D \mid D \text{ is } \text{ a } \text{ member } \text{ of } {\mathcal {D}}(G,v)\}\) is called the \({\mathcal {P}}\)-neighborhood of vertex v in G. By the \({\mathcal {P}}\)-degree of a vertex v of G, denoted by \({d_{G}({\mathcal {P}},v)}\), we mean the cardinality of a largest subfamily of \({\mathcal {D}}(G,v)\) consisting of pairwise disjoint sets. Note that if \(\varphi \) is a Grundy \({\mathcal {P}}\)-coloring, then, by definition, for a particular vertex v the sets \(D_1,\ldots ,D_{\varphi (v)-1}\) need not be uniquely determined but they are pairwise disjoint, contained in \({N_{G}({\mathcal {P}},v)}\), and the number of such sets is never greater that \({d_{G}({\mathcal {P}},v)}\). Hence, we have the following bound.
$$\begin{aligned} \varphi (v)\le {d_{G}({\mathcal {P}},v)}+1. \end{aligned}$$
(B.1)
A vertex u is said to be active in forcing a color in vertex v if \(\varphi (u)<\varphi (v)\) and there exists a set D in \({\mathcal {D}}(G,v)\) that uses color \(\varphi (u)\). We write \(u\prec v\), to express that vertex u is colored before v, and we say that Grundy \({\mathcal {P}}\)-coloring \(\varphi \) is obtained consecutively if every two vertices uv such that \(u\prec v\) satisfy \(\varphi (u)\le \varphi (v)\).
Property B.1
For every Grundy \({\mathcal {P}}\)-coloring \(\varphi \) of a graph G, there exists a Grundy \({\mathcal {P}}\)-coloring \(\bar{\varphi }\) of G in which the colors of the vertices are the same as in \(\varphi \), and \(\bar{\varphi }\) is obtained consecutively. \(\square \)
Now, we are ready to prove Lemma 4.2.
Lemma 4.2
If \(\varphi ^\prime \) is a Grundy \({\mathcal {P}}\)-coloring of a graph \(G^\prime \) with \(k\ge 6\) colors, then \(\varphi ^\prime (v) \le 3\) if and only if \(v\in U\cup W\).
Proof
As we will see in the last part of the proof, there is no loss of generality in assuming that \({\mathcal {P}}\)-colorings considered in the claims are obtained consecutively.
Let \({{\bar{\varphi }}^{\prime }}\) be a Grundy \({\mathcal {P}}\)-coloring obtained consecutively and such that \({{\bar{\varphi }}^{\prime }}(v)=\varphi ^\prime (v)\) for every vertex v of \(G^\prime \). Before the main part of the proof we need a series of claims on \({{\bar{\varphi }}^{\prime }}\).
First, in Claim B.1 we consider a vertex w in the set W.
Claim B.1
For every \({{\bar{\varphi }}^{\prime }}\) and every vertex \(w\in W\) we have \({{\bar{\varphi }}^{\prime }}(w)\le 4\). Moreover, if \({{\bar{\varphi }}^{\prime }}(w)=4\), then
(a)
for every vertex \(v\in {N_{G^\prime }({\mathcal {P}},w)}\) we have \(v\prec w\),
 
(b)
there exists a vertex \(x\in Q\) such that \(x\prec w\) and \({{\bar{\varphi }}^{\prime }}(x)\in \{1,2,3\}\).
 
Proof
For the first part of the proof it is enough to observe that for every vertex \(w\in W\) we have \({d_{G^\prime }({\mathcal {P}},w)} \le \lfloor d_{G^\prime }(w)/(p-1)\rfloor = 3\), and since by (B.1) we have \({{\bar{\varphi }}^{\prime }}(w)\le {d_{G}({\mathcal {P}},w)}+1\), it follows that \({{\bar{\varphi }}^{\prime }}(w)\le 4\).
Next, suppose, contrary to (a), that there exists a vertex \(u\in {N_{G^\prime }({\mathcal {P}},w)}\) such that \(w\prec u\). Since by assumption w is a Grundy vertex and \({{\bar{\varphi }}^{\prime }}(w)=4\), for each color \(\ell \in \{1,2,3\}\) there exists a set \(D_{\ell }\) that uses color \(\ell \) and \(G^\prime [D_{\ell }\cup \{w\}]=K_p\). Moreover, those sets are pairwise disjoint and for each of them \(\vert D_{\ell }\vert = p-1\). Thus, there are at least \(3(p-1)\) vertices v contained in \({N_{G^\prime }({\mathcal {P}},w)}\) and such that \(v\prec w\), which including the vertex u results in \(\vert {N_{G^\prime }({\mathcal {P}},w)}\vert \ge 3(p-1)+1\). A contradiction with \(\vert {N_{G^\prime }({\mathcal {P}},w)}\vert = 3(p-1)\).
Now the proof of (b) is a matter of immediate observation that each of \(3(p-1)\) vertices in \({N_{G^\prime }({\mathcal {P}},w)}\) has color in \(\{1,2,3\}\) and \({N_{G^\prime }({\mathcal {P}},w)}\cap Q\ne \emptyset \)\(\square \)
Next, in Claims B.2B.5 we consider a vertex u in the set U. We focus on situations in which u can be colored with a color greater than 3. Consequently, for the proofs of Claims B.2B.5 we assume \({{\bar{\varphi }}^{\prime }}(u)\ge 4\). From Claim B.1 (a) it follows that if \(w\in W\) and \({{\bar{\varphi }}^{\prime }}(w)=4\), then w cannot be active in forcing any color because all vertices in \({N_{G^\prime }({\mathcal {P}},w)}\) whose colors could eventually depend on \({{\bar{\varphi }}^{\prime }}(w)\) have already been colored before w. Therefore, when considering colors greater that 3 for vertices in U there is no loss of generality in assuming that \({{\bar{\varphi }}^{\prime }}(w)\in \{1,2,3\}\) for every \(w\in W\). Consequently, since \({{\bar{\varphi }}^{\prime }}\) is obtained consecutively and we assumed \({{\bar{\varphi }}^{\prime }}(u)\ge 4\), we also assume that every vertex \(w\in W\) satisfies \(w\prec u\).
Let \({Q^{}(u)}=Q \cap {N_{G^\prime }({\mathcal {P}},u)}\), \({U^{}(u)}=U \cap {N_{G^\prime }({\mathcal {P}},u)}\), and let \(D_3\) denote a set in \({\mathcal {D}}(G^\prime ,u)\) that uses color 3 in \({{\bar{\varphi }}^{\prime }}\). In what follows we also use a property that every \(u\in U\) satisfies \(\vert Q(u)\vert \le 4\), which follows from the fact that G is a graph of degree bounded by 4.
Claim B.2
If \(X_{t,i,j}\) is a gadget such that \(u\in U_i\), and under \({{\bar{\varphi }}^{\prime }}\) there is a set \(D_3\) that contains some vertex \(w\in W_t\), then \({{\bar{\varphi }}^{\prime }}(v)\in \{1,2,3\}\) for every \(v\in V(X_{t,i,j})\setminus \{u\}\). In particular:
(a)
for every vertex \(v\in {U^{}(u)}\) we have \(v\prec u\),
 
(b)
there exists a vertex \(v\in {Q^{}(u)}\) such that \(v\prec u\) and \({{\bar{\varphi }}^{\prime }}(v)\in \{1,2,3\}\).
 
Proof
Since \(D_3\) induces a complete graph and contains w, by Property 4.2(a) we see that \(D_3\subseteq V(X_{t,i,j})\). Moreover, since \({{\bar{\varphi }}^{\prime }}(w)=3\) and w is a Grundy vertex, there exist disjoint sets \(D_1, D_2\) that use colors 1 and 2 respectively, and such that \(G^\prime [D_1\cup \{w\}]=K_p\) and \(G^\prime [D_2\cup \{w\}]=K_p\). Thus, by the same property \(D_1\subseteq V(X_{t,i,j})\) and \(D_2\subseteq V(X_{t,i,j})\). In view of the assumption that \({{\bar{\varphi }}^{\prime }}(u)\ge 4\) and \({{\bar{\varphi }}^{\prime }}\) was obtained consecutively, the assertion follows by the fact that \(D_1, D_2\) and \(D_3\) are pairwise disjoint, which implies \(\vert D_1\cup D_2 \cup D_3\vert = 3(p-1) = \vert V(X_{t,i,j})\setminus \{u\}\vert \). \(\square \)
Claim B.3
If under \({{\bar{\varphi }}^{\prime }}\) there is no set \(D_3\) that contains some vertex \(w\in W\), then there exists a vertex \(v\in {Q^{}(u)}\) such that \(v\prec u\) and \({{\bar{\varphi }}^{\prime }}(v)\in \{1,2,3\}\).
Proof
Suppose to the contrary that every \(v\in {Q^{}(u)}\) satisfies \(u\prec v\). Naturally, if \(D_3\) does not contain any vertex \(w\in W\), then \(D_3\subseteq {Q^{}(u)}\cup {U^{}(u)}\), and since \(\vert D_3\vert > \vert {U^{}(u)}\vert = p-2\), there exists a vertex \(v\in D_3\cap {Q^{}(u)}\). However, since \({{\bar{\varphi }}^{\prime }}\) was obtained consecutively and by assumption \({{\bar{\varphi }}^{\prime }}(u)\ge 4\), for every vertex \(v\in D_3\) we have \(v\prec u\). A contradiction. \(\square \)
Let u be a vertex with \({{\bar{\varphi }}^{\prime }}(u)\ge 4\), and let \({\gamma (u)}\) denote the largest number of vertices v in \({Q^{}(u)}\cup {U^{}(u)}\) with colors at least 4 in some consecutively obtained \({\mathcal {P}}\)-coloring \({{\bar{\varphi }}^{\prime }}\).
Claim B.4
Every vertex \(u\in U\) with \({{\bar{\varphi }}^{\prime }}(u)\ge 4\) satisfies \({\gamma (u)}\le \vert {Q^{}(u)}\vert - 1\).
Proof
Let \(D_3\in {\mathcal {D}}(G^\prime ,u)\) be a set that uses color 3 in coloring \({{\bar{\varphi }}^{\prime }}\). Since \({{\bar{\varphi }}^{\prime }}\) was obtained consecutively, all vertices in \(D_3\) are colored before u. If \(D_3\) does not contain any \(w\in W\), then \(D_3\subseteq {Q^{}(u)}\cup {U^{}(u)}\) and hence we have
$$\begin{aligned} {\gamma (u)} = \vert {Q^{}(u)}\cup {U^{}(u)}\vert - \vert D_3 \vert \le \vert {Q^{}(u)}\vert + (p-2) - (p-1) = \vert {Q^{}(u)}\vert -1. \end{aligned}$$
Similarly, if \(D_3\) contains a vertex \(w\in W_t\) of some gadget \(X_{t,i,j}\), then
$$\begin{aligned} {\gamma (u)}= & {} \vert {Q^{}(u)}\cup {U^{}(u)}\vert - \vert {U^{}(u)}\cup \{x_i\}\vert \le (\vert {Q^{}(u)}\vert +(p-2))-((p-2) + 1) \\= & {} \vert {Q^{}(u)}\vert -1, \end{aligned}$$
where the second term of the difference follows from Claim B.2(a) and (b). Thus \({\gamma (u)}\le \vert {Q^{}(u)}\vert -1\). \(\square \)
Recall that \(\vert {Q^{}(u)}\vert \le 4\) follows from the assumption that the graph G in Construction 4.1 has degree bounded by 4, and note that this implies \({\gamma (u)}\le 3\).
Claim B.5
For every vertex \(u\in U\) we have
$$\begin{aligned} {{\bar{\varphi }}^{\prime }}(u) \le {\left\{ \begin{array}{ll} 5 &{} \quad \text {if } p\in \{3,4\}\\ 4 &{} \quad \text {if } p\ge 5.\\ \end{array}\right. } \end{aligned}$$
Proof
Recall that by Claim B.1 the set W does not contain a vertex w with \({{\bar{\varphi }}^{\prime }}(w) > 3\) that is active in forcing. Therefore, when considering the largest color of u we focus on colors of the vertices in \(Q(u)\cup U(u)\). The existence of \({{\bar{\varphi }}^{\prime }}\) in which \({{\bar{\varphi }}^{\prime }}(u) = 4\) is obvious. By Claim B.4 at most 3 vertices in \(Q(u)\cup U(u)\) can be colored with a color \(\ell \ge 4\) (w.l.o.g. we assume \(\vert {Q^{}(u)}\vert = 4\)). Consequently, for every \(p\ge 3\) the set \(Q(u)\cup U(u)\) contains at most \(\lfloor {\gamma (u)}/(p-1) \rfloor \) sets \(D_{\ell }\) that use color \(\ell \ge 4\) and such that \(G^\prime [D_{\ell }\cup \{u\}]=K_p\). Thus \({{\bar{\varphi }}^{\prime }}(u)\le (3 + \lfloor {\gamma (u)}/(p-1) \rfloor ) + 1 \le 4 + \lfloor 3/(p-1)\rfloor \). \(\square \)
Claim B.6
If x is a vertex with \({{\bar{\varphi }}^{\prime }}(x)\ge 6\), then \(x\in Q\) and for every set \(D_\ell \in {\mathcal {D}}(G^\prime ,x)\) which in \({{\bar{\varphi }}^{\prime }}\) uses color \(\ell \in \{4,\ldots ,{{\bar{\varphi }}^{\prime }}(x)-1\}\) we have \(D_\ell \subseteq Q\).
Proof
The first part of the assertion, follows directly from Claims B.1 and B.5. Consequently, for every \(\ell \ge 6\) we have \(D_\ell \subseteq Q\). Note that this holds for all \(p\ge 3\). Therefore, it remains to consider the cases in which x is a vertex with \({{\bar{\varphi }}^{\prime }}(x)=6\) and \(\ell \in \{4,5\}\).
Let \(D^x_\ell \) denote a set in \({\mathcal {D}}(G^\prime ,x)\) that uses color \(\ell \). Note, that if u is a vertex in \(D^x_\ell \cap U\), then \(x\in {N_{G^\prime }({\mathcal {P}},u)}\). Hence, since \(x\in Q\) we have (\(\star \)) \(x\in Q(u)\cup U(u)\).
First, let \(\ell =5\). If \(p\ge 5\), then \(D_5\subseteq Q\) follows directly from Claims B.1 and B.5. Hence, let \(p\in \{3,4\}\) and suppose to the contrary that \(D^x_5\) is not contained in Q. Since using Claim B.1(a) we easily get \(D^x_5\cap W = \emptyset \), there exists a vertex u in \(D^x_5\cap U\). Because u is a member of \(D^x_5\), all vertices in \(D^x_5\setminus \{u\}\) belong to \({N_{G^\prime }({\mathcal {P}},u)}\) while \(D^x_5\subseteq {N_{G^\prime }({\mathcal {P}},x)}\) follows from the definition of \({\mathcal {D}}(G^\prime ,x)\). Hence, \(D^x_5\setminus \{u\} \in {N_{G^\prime }({\mathcal {P}},u)} \cap {N_{G^\prime }({\mathcal {P}},x)}\), and since \(D^x_5\cap W=\emptyset \), by the definitions of Q(u) and U(u) we get \(D^x_5\setminus \{u\} \subseteq (Q(u)\cup U(u)) \cap {N_{G^\prime }({\mathcal {P}},x)} \subseteq Q(u)\cup U(u)\).
Moreover, since \({{\bar{\varphi }}^{\prime }}(u)=5\), there exists a set \(D^u_4\) in \({\mathcal {D}}(G^\prime ,u)\) that uses color 4, and since \(D^u_4\subseteq {N_{G^\prime }({\mathcal {P}},u)}\) and \(D^u_4\cap W = \emptyset \) we have \(D^u_4 \subseteq Q(u)\cup U(u)\). Consequently, by the above argument and (\(\star \)) all vertices in \(D^u_4\), \(D^x_5 \setminus \{u\}\) and vertex x belong to \(Q(u)\cup U(u)\) and hence we conclude that \(Q(u)\cup U(u)\) contains at least \(\vert D^u_4 \vert + \vert D^x_5 \setminus \{u\} \vert + 1 = (p-1)+(p-2)+1 = 2p-2\) vertices with colors at least 4. A contradiction, since by Claim B.4 we have \({\gamma (u)}\le 3\).
Next, let \(\ell =4\) and by the first part of the proof let \(D^x_5\cup \{x\} \subseteq Q\). Hence, for every \(p\ge 3\) there are at least p vertices in Q with colors at least 5. Now, suppose to the contrary that \(D^x_4\) is a set in \({\mathcal {D}}(G^\prime ,x)\) that uses color 4 and is not contained in Q. Naturally, there exists \(u\in D^x_4\cap U\) for which, similarly as for \(D^x_5\), we have \(D^x_4\subseteq Q(u)\cup U(u)\).
From Claim B.4 we have \({\gamma (u)}\le \vert {Q^{}(u)}\vert -1\). On the other hand \(\vert D^x_4\setminus \{u\}\vert = p-2\) and since \(D^x_4\) uses color 4, there are at most (\(\star \star \)) \(\vert {Q^{}(u)}\vert +1-p\) vertices in Q(u) with colors at least 5. Now, for every \(p\ge 3\) by (\(\star \)), (\(\star \star \)) and the fact that Q contains at least \(p-1\) vertices with color 5 we infer that there are at least \((p-1)-(\vert Q(u)\vert - p) \ge 2p-5\) vertices \(y\in Q\) such that \({{\bar{\varphi }}^{\prime }}(y)=5\) and \(y\notin Q(u)\).
Let y be such a vertex, and similarly as for x suppose to the contrary that \(D^y_4\) is a set in \({\mathcal {D}}(G^\prime ,y)\) that uses color 4 and is not contained in Q. Naturally, there exists \(u^\prime \) such that \(u^\prime \in D^y_4\cap U\) and \(U(u^\prime ) \cap U(u) = \emptyset \).
Following the above properties, if \(p\ge 5\), or \(p=4\) and \(\vert {Q^{}(u)}\vert <4\), then by (\(\star \star \)) the set Q(u) contains only vertices with colors smaller than 5. A contradiction by (\(\star \)). For the remaining cases observe that, by (\(\star \star \)) each of the sets Q(u) and \(Q(u^\prime )\) contains at least \(p-1\) vertices with colors at most 4, and since by Construction 4.1 we have \(\vert Q(u)\cap Q(u^\prime )\vert \le 1\), it follows that \(Q(u)\cup Q(u^\prime )\) contains at least \(2(p-1)-1\) vertices with colors at most 4. Hence, taking into account vertices xy and the remaining \(p-2\) vertices with color 5, and if \(k>6\), then additionally 2 vertices with color 6 and \((k-6)(p-1)\) vertices with colors greater than 6, we finally get \(\vert Q \vert \ge (k-3)(p-1)+2\). A contradiction, since from Construction 4.1 we have \(\vert Q \vert \le (k-3)(p-1)\). \(\square \)
Having proved the above claims we are now ready to complete the proof of Lemma 4.2. Let \(x\in Q\) be colored with a color \(\ell \ge 6\). From Claim B.6 it follows that Q contains pairwise disjoint sets \(D_i\in {\mathcal {D}}(G^\prime ,x)\), \(i\in \{4,\ldots ,\ell -1\}\) such that each \(D_i\) uses color i. Consequently, the set Q contains at least \((\ell -4)(p-1)\) vertices v such that \(v\prec x\) and at least one vertex colored \(\ell \), that is,
$$\begin{aligned} \vert Q \vert \ge (\ell -4)(p-1) + 1. \end{aligned}$$
(B.2)
In order to prove the “if” statement of the lemma for \({{\bar{\varphi }}^{\prime }}\) suppose to the contrary that there exists a vertex v in \(U\cup W\) such that \({{\bar{\varphi }}^{\prime }}(v) > 3\). Consequently, from Claims B.1(b), B.2(b) and B.3 it follows that there must be at least one vertex in Q with color in \(\{1,2,3\}\). For the proof of the “only if” statement the existence of such a vertex in Q follows directly from the contradictive assumption. Thus, taking into account (B.2) we conclude that for both statements \( \vert Q \vert \ge (\ell -4)(p-1) + 2.\) Now, consider \(\ell =k\) and recall that by Construction 4.1 we have \(k =\lceil {m(G)}/(p-1) \rceil + 3\). Since \(G\in {\mathcal {L}}(p-1)\), we have \(m(G)\equiv 1(\text{ mod } (p-1))\), that is, \(m(G) = q(p-1)+1\) for some integer \(q\ge 2\). Hence,
$$\begin{aligned} \vert Q \vert \ge (\lceil q + 1/(p-1)\rceil - 1)(p-1) + 2 = q(p-1)+2 = m(G)+1, \end{aligned}$$
which contradicts \(\vert Q \vert = m(G)\).
Thus, we have proved that there does not exist consecutively obtained Grundy \({\mathcal {P}}\)-coloring \({{\bar{\varphi }}^{\prime }}\) with k colors such that \(k\ge 6\), and some vertex in \(U\cup W\) has color greater than 3 or a vertex in Q has color in \(\{1,2,3\}\). The proof is completed by applying Property B.1. \(\square \)
Literatur
Zurück zum Zitat Borowiecki P (2004) On-line coloring of graphs. In: Kubale M (ed) Graph colorings. Contemporary mathematics, vol 352. American Mathematical Society, Providence, pp 21–33CrossRef Borowiecki P (2004) On-line coloring of graphs. In: Kubale M (ed) Graph colorings. Contemporary mathematics, vol 352. American Mathematical Society, Providence, pp 21–33CrossRef
Zurück zum Zitat Brandstädt A, Le VB, Spinrad JP (1999) Graph classes: a survey. SIAM monographs in discrete mathematics and applications. SIAM, PhiladelphiaCrossRef Brandstädt A, Le VB, Spinrad JP (1999) Graph classes: a survey. SIAM monographs in discrete mathematics and applications. SIAM, PhiladelphiaCrossRef
Zurück zum Zitat Chudnovsky M, Goedgebeur J, Schaudt O, Zhong M (2016) Obstructions for three-coloring graphs with one forbidden induced subgraph. In: Proceedings of 27th annual ACM-SIAM symposium on discrete algorithms, SODA’16, pp 1774–1783 Chudnovsky M, Goedgebeur J, Schaudt O, Zhong M (2016) Obstructions for three-coloring graphs with one forbidden induced subgraph. In: Proceedings of 27th annual ACM-SIAM symposium on discrete algorithms, SODA’16, pp 1774–1783
Zurück zum Zitat Cockayne EJ, Miller GG, Prins G (1972) An interpolation theorem for partitions which are complete with respect to hereditary properties. J Combin Theory Ser B 13:290–297MathSciNetCrossRefMATH Cockayne EJ, Miller GG, Prins G (1972) An interpolation theorem for partitions which are complete with respect to hereditary properties. J Combin Theory Ser B 13:290–297MathSciNetCrossRefMATH
Zurück zum Zitat Goedgebeur J, Schaudt O (2016) Exhaustive generation of \(k\)-critical \(\cal{H}\)-free graphs. In: Proceedings of 42nd international workshop on graph-theoretic concepts in computer science, WG’16, LNCS 9941. Springer, pp 109–120 Goedgebeur J, Schaudt O (2016) Exhaustive generation of \(k\)-critical \(\cal{H}\)-free graphs. In: Proceedings of 42nd international workshop on graph-theoretic concepts in computer science, WG’16, LNCS 9941. Springer, pp 109–120
Zurück zum Zitat Goyal N, Vishwanathan S (1998) NP-completeness of undirected Grundy numberings and related problems. (Unpublished manuscript) Goyal N, Vishwanathan S (1998) NP-completeness of undirected Grundy numberings and related problems. (Unpublished manuscript)
Zurück zum Zitat Greenwell DL, Hemminger RL, Klerlein J (1973) Forbidden subgraphs. In: Proceedings of 4th S-E conference on combinatorics, graph theory and computing. Utilitas Mathematica, pp 389–394 Greenwell DL, Hemminger RL, Klerlein J (1973) Forbidden subgraphs. In: Proceedings of 4th S-E conference on combinatorics, graph theory and computing. Utilitas Mathematica, pp 389–394
Zurück zum Zitat Grundy PM (1939) Mathematics and games. Eureka 2:6–8 Grundy PM (1939) Mathematics and games. Eureka 2:6–8
Zurück zum Zitat Gyárfás A, Lehel J (1990) First-fit and on-line chromatic number of families of graphs. Ars Combinatoria 29C:168–176MathSciNetMATH Gyárfás A, Lehel J (1990) First-fit and on-line chromatic number of families of graphs. Ars Combinatoria 29C:168–176MathSciNetMATH
Zurück zum Zitat Hedetniemi SM, Hedetniemi ST, Beyer T (1982) A linear algorithm for the Grundy (coloring) number of a tree. Congr Numer 36:351–363MathSciNetMATH Hedetniemi SM, Hedetniemi ST, Beyer T (1982) A linear algorithm for the Grundy (coloring) number of a tree. Congr Numer 36:351–363MathSciNetMATH
Zurück zum Zitat Jensen TR, Toft B (1995) Graph coloring problems. Wiley, New YorkMATH Jensen TR, Toft B (1995) Graph coloring problems. Wiley, New YorkMATH
Zurück zum Zitat Kierstead HA (1998) Coloring graphs on-line. In: Fiat A, Woeginger GJ (eds) Online algorithms—the state of the art, vol 1442. LNCS. Springer, Berlin, pp 281–305CrossRef Kierstead HA (1998) Coloring graphs on-line. In: Fiat A, Woeginger GJ (eds) Online algorithms—the state of the art, vol 1442. LNCS. Springer, Berlin, pp 281–305CrossRef
Zurück zum Zitat Kortsarz G (2007) A lower bound for approximating Grundy numbering. Discrete Math Theor Comput Sci 9:7–22MathSciNetMATH Kortsarz G (2007) A lower bound for approximating Grundy numbering. Discrete Math Theor Comput Sci 9:7–22MathSciNetMATH
Zurück zum Zitat Papadimitriou CH (1994) Computational complexity. Addison Wesley Longman, LondonMATH Papadimitriou CH (1994) Computational complexity. Addison Wesley Longman, LondonMATH
Zurück zum Zitat West DB (2001) Introduction to graph theory. Prentice Hall, Upper Saddle River West DB (2001) Introduction to graph theory. Prentice Hall, Upper Saddle River
Metadaten
Titel
Computational aspects of greedy partitioning of graphs
verfasst von
Piotr Borowiecki
Publikationsdatum
11.11.2017
Verlag
Springer US
Erschienen in
Journal of Combinatorial Optimization / Ausgabe 2/2018
Print ISSN: 1382-6905
Elektronische ISSN: 1573-2886
DOI
https://doi.org/10.1007/s10878-017-0185-2

Weitere Artikel der Ausgabe 2/2018

Journal of Combinatorial Optimization 2/2018 Zur Ausgabe