DeepAI
Log In Sign Up

List Locally Surjective Homomorphisms in Hereditary Graph Classes

02/25/2022
by   Pavel Dvořák, et al.
0

A locally surjective homomorphism from a graph G to a graph H is an edge-preserving mapping from V(G) to V(H) that is surjective in the neighborhood of each vertex in G. In the list locally surjective homomorphism problem, denoted by LLSHom(H), the graph H is fixed and the instance consists of a graph G whose every vertex is equipped with a subset of V(H), called list. We ask for the existence of a locally surjective homomorphism from G to H, where every vertex of G is mapped to a vertex from its list. In this paper, we study the complexity of the LLSHom(H) problem in F-free graphs, i.e., graphs that exclude a fixed graph F as an induced subgraph. We aim to understand for which pairs (H,F) the problem can be solved in subexponential time. We show that for all graphs H, for which the problem is NP-hard in general graphs, it cannot be solved in subexponential time in F-free graphs unless F is a bounded-degree forest or the ETH fails. The initial study reveals that a natural subfamily of bounded-degree forests F that might lead to some tractability results is the family 𝒮 consisting of forests whose every component has at most three leaves. In this case, we exhibit the following dichotomy theorem: besides the cases that are polynomial-time solvable in general graphs, the graphs H ∈{P_3,C_4} are the only connected ones that allow for a subexponential-time algorithm in F-free graphs for every F ∈𝒮 (unless the ETH fails).

READ FULL TEXT VIEW PDF

page 1

page 2

page 3

page 4

10/07/2020

Complexity of the list homomorphism problem in hereditary graph classes

A homomorphism from a graph G to a graph H is an edge-preserving mapping...
07/12/2021

Polynomial-time algorithm for Maximum Independent Set in bounded-degree graphs with no long induced claws

For graphs G and H, we say that G is H-free if it does not contain H as ...
09/25/2018

Subexponential algorithms for variants of homomorphism problem in string graphs

We consider the complexity of finding weighted homomorphisms from inters...
02/17/2022

Computing list homomorphisms in geometric intersection graphs

A homomorphism from a graph G to a graph H is an edge-preserving mapping...
03/28/2021

Computational Complexity of Covering Two-vertex Multigraphs with Semi-edges

We initiate the study of computational complexity of graph coverings, ak...
04/15/2020

An algorithmic framework for colouring locally sparse graphs

We develop an algorithmic framework for graph colouring that reduces the...

1 Introduction

Graph coloring is arguably one of the best-studied problems in algorithmic graph theory. It is well-known that -Coloring is polynomial-time solvable for and NP-hard for every  [27]. Furthermore, assuming the Exponential-Time Hypothesis (ETH) [25, 26], the hard cases do not even admit algorithms working in subexponential time.

Coloring -free graphs.

A very natural direction of research is to investigate what restrictions put on the family of input make the problem more tractable than for general graphs. In recent years, a very active topic has been to study the complexity of -Coloring and related problems in graphs defined by one or more forbidden induced subgraphs. For a family of graphs, we say that a graph is -free if does not contain any graph from as an induced subgraph. If consists of a single graph , then we say -free instead of -free. Note that the class of -free graphs is hereditary i.e., closed under vertex deletion. On the other hand, every hereditary class of graphs can be equivalently defined as -free graphs for some unique minimal (possibly infinite) family of graphs.

It is well-known that for every , the -Coloring problem is NP-hard in -free graphs, unless is a linear forest, i.e., every connected component of is a path. Indeed, for every constant , -Coloring is NP-hard in graphs of girth (i.e., the length of a shortest cycle) at least  [10]. Setting , we immediately obtain hardness for every that is not a forest. On the other hand, -Coloring is NP-hard in line graphs which are claw-free [23, 29]. The only forests that are claw-free are linear forests.

The complexity of -Coloring in -free graphs, where is the path in vertices, has recently attracted a lot of attention. For , the problem is polynomial-time solvable for every constant  [22]. If , then the problem is NP-hard already in -free graphs [24]. The case is also fully understood: it is polynomial-time solvable for  [38] and NP-hard for  [24]. The case of is much more elusive. We know a polynomial-time algorithm for -free graphs [1]. However, for , we know neither polynomial-time algorithm nor any hardness result. Some positive results are also known for the case that is a disconnected linear forest [28, 6, 18].

Let us point out almost all mentioned algorithmic results also hold for the more general list variant of the problem, where each vertex is given a list of admissible colors. The notable exception is List 4-Coloring, which is NP-hard already in -free graphs [19]. Furthermore, all hardness results also imply the nonexistence of subexponential-time algorithms (assuming the ETH).

Some more general positive results can be obtained if we relax our notion of tractability. As observed by Groenland et al. [20], List 3-Coloring can be solved in subexponential time in -free graphs, for every fixed . This was recently improved by Pilipczuk, Pilipczuk, and Rzążewski [37] who showed a quasipolynomial-time algorithm for this problem. Note that this is strong evidence that the problem is not NP-hard.

Graph homomorphisms.

Graph colorings can be seen as a special case of graph homomorphisms. A homomorphism from a graph to a graph (with possible loops) is an edge-preserving mapping from to . Note that homomorphisms to are precisely proper -colorings. By the celebrated result of Hell and Nešetřil [21], determining whether an input graph admits a homomorphism to a fixed graph is polynomial-time solvable if is bipartite or has a vertex with a loop, and NP-hard otherwise. A list variant of the graph homomorphism problem, denoted by LHom(), has also been considered. It turns out that the problem can be solved in polynomial time if is a so-called bi-arc graph, and otherwise, the problem is NP-hard [12, 13, 14].

The complexity of variants of the graph homomorphism problem in hereditary graph classes was also studied. For example, Chudnovsky et al. [5] showed that LHom() for is polynomial-time solvable in -free graphs. On the negative side, they showed that for every the problem cannot be solved in -free graphs, unless every component of , where consists of graphs whose every connected component is a path or a tree with three leaves (called a subdivided claw). This negative result was later extended by Piecyk and Rzążewski [36] who showed that if is not a bi-arc graph (i.e., LHom() is NP-hard in general graphs), then LHom() is NP-hard and cannot be solved in subexponential time (assuming the ETH) in -free graphs, unless .

The case of forbidden path or subdivided claw was later investigated by Okrasa and Rzążewski [35]. They defined a class of predacious graphs and showed that if is not predacious, then for every , the LHom() problem can be solved in quasipolynomial time in -free graphs (for every ). Otherwise, for every , there exists for which LHom() cannot be solved in subexponential time in -free graphs unless the ETH fails. They also provided some partial results for the case of forbidden subdivided claws.

The complexity of variants of the graph homomorphism problem in other hereditary graph classes has also been considered [15, 7, 34].

Locally surjective graph homomorphisms.

Graph homomorphisms are a very robust notion, which can be easily extended by putting some additional restrictions on the solution. In this paper, we focus on one such variant called locally surjective homomorphisms. A homomorphism from to is locally surjective if it is surjective in the neighborhood of each vertex of . In other words, if , then for every neighbor of in (including , if it has a loop) there is a neighbor of in , such that . The study of locally surjective homomorphisms originates in social sciences, where they can be used to model some social roles (the problem is called role assignment [11]). The problem of determining whether an input graph admits a locally surjective homomorphism to a fixed graph is denoted by LSHom(). Fiala and Paulusma [17] provided the full complexity dichotomy for LSHom(). For simplicity, let us consider only connected graphs , and let be the one-vertex graph with a loop. They showed that LSHom() is polynomial-time-solvable if , and otherwise it is NP-hard. Again, the hardness reduction excluded also subexponential time algorithms under the ETH.

Let us point out that LSHom() is closely related to the well-known hypergraph 2-coloring problem [30] (or, equivalently, Positive NAE SAT). In this problem, we ask whether the input hypergraph admits a 2-coloring of its vertices which makes no edge monochromatic. Consider a hypergraph with vertices and hyperedges , and let be its incidence graph, i.e., the bipartite graph with vertex set , where is adjacent to if and only if . Note that proper 2-colorings of are precisely locally surjective homomorphisms of to with consecutive vertices , where is mapped to , and is mapped to . As shown by Camby and Schaudt [3], 2-coloring of hypergraphs with -free incidence graph is polynomial-time solvable.

The structural and computational aspects of locally surjective homomorphisms were studied by several authors [4, 16, 2]. However, up to the best of our knowledge, no systematic study of LSHom() in hereditary graph classes has been conducted.

Our contribution.

In this paper, we consider the complexity of the list variant of LSHom(), called LLSHom(). First, we observe that if (recall, these are the easy cases of LSHom()), then also LLSHom() can be solved in polynomial time in general graphs.

Then we focus on the complexity of the problem in -free graphs. In particular, we are interested in determining the pair , for which the problem can be solved in subexponential time. Similarly to the case of LHom(), we split into two cases, depending whether .

In the first case, we identify two more positive cases: we show that if , then the problem admits a subexponential-time algorithm for every . The algorithm itself uses a win-win strategy: we combine branching on a high-degree vertex with a separator theorem that can be used if the maximum degree is bounded. A similar approach was used for various other problems [20, 31], however, the specifics of our problem require a slightly more complicated approach.

We also show that the above cases are the only positive ones for general , which provides the following dichotomy theorem.

Theorem 1.1.

Let be a fixed connected graph.

  1. If , then for every , the LLSHom() problem can be solved in time in -vertex -free graphs.

  2. Otherwise there is , such that the LLSHom() problem cannot be solved in subexponential time in -free graphs, unless the ETH fails.

Then, we turn our attention to other forbidden graphs . We show that whenever the problem is NP-hard for general graphs, i.e., for every , and for every there exists , such that LSHom() is NP-hard in graphs of degree at most and girth at least . This implies the following lower bound.

Theorem 1.2.

For every connected , there exists , such that the following holds. For every graph that is not a forest of maximum degree at most , the LLSHom() problem cannot be solved in time in -vertex -free graphs of maximum degree , unless the ETH fails.

We conclude the paper by discussing the possibilities of improving our theorems in order to fully classify the complexity of

LSHom() in -free graphs.

2 Preliminaries

For a graph and , by we denote the set of neighbors of in . For a set , by we denote . If is clear from the context, we omit the subscripts. By , where , we denote the subgraph of induced by the set .

For graphs and , by we denote their direct product (sometimes called categorical product or Kronecker product), i.e, the graph

For , by we denote the -vertex path, and by we denote the three-leaf tree with leaves at distance , , and , respectively, from the unique vertex of degree 3, which we denote as central. Every such is called a subdivided claw. Recall that by , we denote the family of graphs whose every connected component is either a path or a subdivided claw.

Let be a homomorphism from to . We say that a vertex is happy (in ) if . In other words, for every neighbor of , some neighbor of is colored . We say that a homomorphism is locally surjective if every vertex is happy in . If is a locally surjective homomorphism from to , we denote it by .

For a fixed graph (with possible loops) we consider the problem, whose instance is where is a graph and is a list function. We ask if there exists a homomrphism , such that for every it holds that . If is such a homomorphism, we denote it by .

Observe that if or is disconnected, then each component of must be mapped to some component of . Thus, the problem can be easily reduced to the case that both and are connected. We will assume this from now on.

Recall that the non-list variant of our problem, i.e., , is polynomial time-solvable if (where denotes the one-vertex graph with a loop), and NP-hard otherwise [17]. Let us point out that exactly the same dichotomy holds for .

Corollary 2.1.

If , then is polynomial-time solvable, and otherwise it is NP-hard.

Proof.

As is a restriction of , it is sufficient to show the polynomial cases. Indeed, NP-hardness of implies the NP-hardness of .

The positive instances of are edgeless graphs, where the list of every vertex is nonempty. Similarly, the positive instance of are graphs with no isolated vertices, where the list of every vertex is nonempty. In both cases, yes-instances can clearly be recognized in polynomial time.

Finally, let us consider the case that , denote its vertices by and . Let be an instance of . First, note that if is not bipartite, then is a no-instance, and we are done. If is disconnected, then we can process each connected component of separately.

So assume that is connected and bipartite, and its bipartition classes are and . We observe that every homomorphism from to either maps to 1 and to 2, or maps to 2 and to 1. It is clear that verification if any of these two functions is a locally surjective list homomorphism can be performed in polynomial time. ∎

2.1 Associated Bipartite Graphs and Associated Instances

Now let us show that in order to classify the hard cases of LLSHom() it is sufficient to consider the case that is bipartite. A similar approach was used to the LHom([32, 14], but to the best of our knowledge, we are the first to observe that it also works for LLSHom().

Let be a connected bipartite graph with bipartition classes , and consider an instance of , where is connected. Note that if is not bipartite, then is clearly a no-instance. Thus, assume that is bipartite with the bipartition classes . We observe that in every homomorphism , either all vertices of are mapped to , and all vertices of are mapped to , or all vertices of are mapped to , and all vertices of are mapped to . Thus in order to solve , we can consider these two cases separately. More specifically, we need to solve two instances and of , where

This motivates the following definition, see also [32].

Definition 2.2.

Let be a connected bipartite graph with bipartition classes . We say that an instance of is consistent, if

  1. is connected bipartite with the bipartition classes ,

  2. and .

For a graph , by we denote its associated bipartite graph. In other words, the vertex set of is and the edge set is . We also define and , i.e., are the bipartation classes of .

Note that if is connected and nonbipartite, then is connected. If is bipartite, then consists of two disjoint copies of .

Lemma 2.3.

Let be a fixed connected nonbipartite graph. Let be a consistent instance of . For each , define . Then is a yes-instance of if and only if is a yes-instance of .

Proof.

First consider . Define as follows: if and only if . Clearly, is a homomorphism from to , and it respects lists .

Let us show that is locally surjective. Consider such that and some . Since , we know that (the actual value depends on the bipartition class where belongs). By symmetry, assume that . Since is locally surjective and , there is , such that . Then, .

Now, consider . Let the bipartition classes of be , such that and (this holds since is consistent). We define as follows. Consider and let . If , then and if , then . Again, it is straightforward to verify that is a homomorphism from to , and it respects lists , since is consistent.

Now, let us argue that is locally surjective. By symmetry, consider , such that . Then, . Let . Since is locally surjective, there is , such that . Thus, . ∎

Corollary 2.4.

Let be a class of graphs and let be a fixed connected nonbipartite graph. Suppose there is an algorithm that solves every bipartite instance of , such that , in time . Then there is an algorithm that solves every instance of , where , in time .

Proof.

Consider an arbitrary instance of , where . If is disconnected, we apply the reasoning below to each connected component independently. Furthermore, we can assume that is bipartite, as otherwise, it is a trivial no-instance.

By the reasoning at the beginning of the section, we can reduce solving to solving two consistent instances. Thus, let us assume that is consistent. By Lemma 2.3, in order to solve , it is sufficient to solve the instance of , where the lists are defined as in the lemma. This can be done in time using the algorithm . As all additional computation (checking if is bipartite, determining lists ) can be performed in polynomial time, the claim follows. ∎

Note that Corollary 2.4 immediately implies the following.

Corollary 2.5.

Assume the ETH. Let be a fixed connected nonbipartite graph and let be a class of graphs. If cannot be solved in time for -vertex instances in , then cannot be solved in time for -vertex instances in .

3 Algorithm for -free Graphs for

An important tool used in our algorithm is the following structural result about -free graphs.

Theorem 3.1 (Okrasa, Rzążewski [33]).

Let be an integer. Given an -vertex -free graph with maximum degree , in time we can find a tree decomposition of with width at most .

Equipped by this, we are ready to prove the following algorithmic result.

Theorem 3.2.

Let be fixed integers. The in -vertex -free graphs can be solved in time .

Proof.

Denote the consecutive vertices of by . Let be an instance of , where has vertices and is -free. Let and note that is -free. Furthermore, if is not bipartite, then is clearly a no-instance. Thus, we can assume that is bipartite (and, in particular, triangle-free).

Furthermore, recall that we can safely assume that the instance is consistent. Let and denote the bipartition classes of , such that and . Note that if or , then we are clearly dealing with a no-instance. Thus from now on, let us assume otherwise. In particular, it means that every vertex from is always happy. Consequently, our task boils down to choosing colors for vertices of to make each vertex from happy.

Actually, we will design a recursive algorithm that solves a slightly more general problem, where we are additionally given a function . We are looking for a list homomorphism , such that for every it holds that . Initially, we have for every . Thus, the returned homomorphism is indeed locally surjective. During the course of the algorithm, we will modify the sets to keep track of the colors seen by vertices in in the part of the graph that was removed.

Each recursive call starts with a preprocessing phase. First, we exhaustively apply the following steps. If there is some with , then we immediately terminate the recursive call and report a no-instance. If there is some with , then we can safely remove from the graph. If there is some with , then we remove the element of from the sets of all neighbors of , and remove from the graph.

If none of the above steps can be applied and has an isolated vertex (note that ), then we terminate and report a no-instance. The preprocessing phase can clearly be performed in polynomial time.

Finally, if the graph obtained is disconnected, we apply the following reasoning to every connected component independently. Let us still denote the instance by , and assume that is connected.

We consider two cases. First, suppose that there is with . We branch on choosing the color for , i.e., we perform two recursive calls of the algorithm, in one branch setting , and in the other . Note that at least neighbors of have the same set . Consequently, in at least one branch, the sets will be reduced for at least vertices during the preprocessing phase. In the other branch, we are guaranteed to have a little progress, too: the vertex will be removed from the graph. Let us define the measure of the instance as . Clearly . Thus the complexity of this step is given by the following recursive inequality:

So now let us assume that for each it holds that . Let be the set of vertices satisfying . Observe that . Consequently, .

Consider the graph . As it is an induced subgraph of , it is -free. Furthermore, the maximum degree of is at most . Consequently by Theorem 3.1, in time we can find a tree decomposition of with width . Let us modify this tree decomposition by adding the set to every bag – this way we obtain a tree decomposition of with width .

Using fairly standard dynamic programming on a tree decomposition, we can solve our auxiliary problem on graphs given with a tree decomposition of width in time . Indeed, the state of the dynamic programming is the coloring of the vertices from in the current bag and the colors seen by the vertices from in subgraph induced the subtree rooted at the current bag (these colors are reflected in sets ). Thus, the total number of states to consider is at most (two possibilities for a vertex from and at most three for a vertex from ).

Consequently, in the second case we obtain the running time .

Summing up, the overall complexity of the algorithm is . This completes the proof. ∎

Note that every -free graph is also, e.g., -free, so Theorem 3.2 can also be applied to -free graphs. Now, let us show a slight generalization of Theorem 3.2 to the case that we exclude a forest of paths and subdivided claws.

Theorem 3.3.

For every , the problem in -vertex -free graphs can be solved in time .

Sketch of proof.

Let for some , where each is a subdivided claw.

We begin similarly to the algorithm from Theorem 3.2. Again, we are solving an auxiliary problem with instance . First, we check if the instance graph is bipartite, and otherwise, we reject it. Let the bipartition classes of be and , and let and . Then, we perform the preprocessing phase and the branching phase; note that in these phases, we do not assume anything about the forbidden induced graph. The recursion tree has leaves, each corresponds to an instance which is -free and every vertex from has maximum degree at most . Consider one such instance, for simplicity let us call it .

We continue as in the proof of Theorem 3.2 by selecting the set of vertices of degree at least . Recall that and the graph is of maximum degree at most .

Now for each we perform the following steps. Let be an instance corresponding to a leaf of the recursion tree, with the set removed. We check if contains as an induced subgraph, this can be done in polynomial time by the exhaustive enumeration. If not, then is -free and we can call the algorithm given by Theorem 3.1 and continue exactly as in the proof of Theorem 3.2.

Thus, let us suppose that there is , such that . We observe that . We exhaustively guess the coloring of , this results in branches. In each branch, we update the sets for the neighbors of colored vertices; in particular we reject if some vertex from does not see some color in . Note that each instance is -free.

After the last iteration, the instances corresponding to the leaves of the recursion tree are -free, and thus we continue as in the proof of Theorem 3.2, i.e., use Theorem 3.1, restore the set , and solve the problem by dynamic programming.

The total number of leaves of the recursion tree is at most

each of which corresponds to an instance that is -free for some , and thus can be solved in time as in Theorem 3.2. ∎

Now, let us show that the algorithm from Theorem 3.2 can be used to solve in -free graphs. The proof of the following lemma is based on a similar argument used by Okrasa and Rzążewski [34] in the non-list case.

Lemma 3.4.

Let be a consistent instance of . Then the problem can be reduced in polynomial time to solving two consistent instances of .

Proof.

Let the consecutive vertices of be . Let the bipartition classes of be , and let and .

Define as follows:

We claim that is a yes-instance of if and only if is a yes-instance of and is a yes-instance of . Note that both graphs and are induced three-vertex paths.

First, suppose that there is some . Let us define as follows:

Let us argue that that and . We prove only the first claim. The proof of the second one is analogous. First, is clearly a homomorphism. Furthermore, it satisfies the lists, as for we have , and for we have . Finally, let us argue that is locally surjective. For each , there are some such that and , as otherwise is not locally surjective. Thus, , which makes happy in . Similarly, for each , there are some such that and , as otherwise is not locally surjective. Thus, and , which makes happy in .

Now, suppose there are and . We define as follows:

Let us argue that .

First, note that is a homomorphism, as for every edge , where and , we have and .

Now, observe that respects the lists . Indeed, for we have and for we have .

Finally, let us argue that is locally surjective. Consider some ; the argument for vertices in is symmetric. Note that . Since is locally surjective, has two neighbors , such that and . Consequently, and , which makes happy in . This completes the proof. ∎

Combining Lemma 3.4 with Theorem 3.3, we immediately obtain the following.

Theorem 3.5.

For every , the in -vertex -free graphs can be solved in time .

4 Hardness for -free Graphs for

In this section, we will prove the hardness part of Theorem 1.1, i.e., if then there is such that LLSHom() cannot be solved in subexponential time in -free graphs. It easily follows that such contains at least one of as an induced subgraph, where and are graphs consisting of an edge with a loop at one or both of its endpoint, respectively. First, we will prove the theorem for several base cases for . Then, we will generalize the result for containing an induced subgraph . The last cases when contains or as an induced subgraph will follows from the base cases and Corollary 2.5 as for such the graph contains as an induced subgraph.

4.1 Hardness for

Theorem 4.1.

The LLSHom() problem cannot be solved in time in -vertex -free graphs, unless the ETH fails. Moreover, the constructed reduction use only lists of size at most 2, and each vertex of the construction which has a list of size exactly two has a neighbor with a list of size exactly one.

Proof.

Let , where is the central degree three vertex and are the leaves. We reduce from the 3-SAT problem. The ETH implies that an instance with variables and clauses cannot be solved in time  [9]. We first describe the reduction. For every variable , a variable gadget is represented by with the central vertex with and the leaves with lists , , and , respectively.

Claim 4.2 (Variable consistency).

There exists exactly two homomorphisms in which vertices of are happy:

  1. , , , , and

  2. , , , .

Proof of Claim 4.2.  In order to make vertex happy, vertices and have to be mapped to different vertices of . It is easy to check that all other vertices are happy.

For every clause , the clause gadget is represented by . Let denote the central vertex, and , , and denote vertices of the -th branch ordered by the distance from , for . We set the lists as , , , and . We construct the final graph as follows. If variable appears as the -th literal in clause , then (of ) is adjacent to or (of ) if the literal is positive or negative, respectively. Moreover, each central vertex of each clause is connected with each and with each vertices of all variable gadgets. For an overview of the described construction, see Figure 1. This completes the construction of the graph . The described construction gives only a constant blow-up, and therefore the ETH lower bound is preserved. Observe that vertex is happy if and only if for at least one has .

Figure 1: An example of variable gadgets connected to a clause gadget for the case . The variable gadget is depicted by blue color, clause gadget by black color, green are connections between each variable and clause gadgets, and red is the connection representing an occurrence of a variable in the clause (in this example, a positive occurrence).

First, suppose that we have a satisfying assignment of the formula. We will construct the sought homomorphism . For each variable , we set of based on Claim 4.2: we use assignment from (i) if is true and (ii) otherwise. As each clause is satisfied, say by the -th literal, there is a corresponding variable gadget such that sees a vertex mapped to 1 (either a true variable occurring as a positive literal or a false variable occurring as a negative literal in ). In order to make happy, we set and so , that immediately makes also happy. It is easy to check that all other vertices in a clause gadget may be mapped in a way to be happy and that we created a yes-instance.

Second, suppose there is a homomorphism . We define the truthfulness of variables based on Claim 4.2: is true if (i) and false if (ii). Now, it remains to check whether this is a satisfying assignment. For each clause , in is happy. Therefore for some , . In order for to be happy, vertex (or ) in the adjacent variable gadget has to be mapped to . In both cases, variable satisfies .

It remains to argue that the constructed graph is -free. Suppose there is an induced denoted as . Clearly, it is not solely within variable or clause gadgets. Hence, it must contain vertex or of some variable gadget as those are the only vertices that connect variable and clause gadgets. We denote this particular vertex . If no central vertex of a clause gadget belongs to , we are limited to an induced path on at most seven vertices. Therefore, contains a central vertex of some gadget. As all central vertices of clause gadgets induce together with all vertices and of variable gadgets a complete bipartite graph, either at most one other central vertex or at most one other vertex or can belong to . The former leads to an induced path on at most seven vertices, the latter to an induced path on at most nice vertices. ∎

4.2 Hardness for

Theorem 4.3.

The LLSHom() problem cannot be solved in time in -vertex -free graphs, unless the ETH fails. Moreover, the problem is hard even for instances where all the lists are of size at most 2, and each vertex that has a list of size exactly two has a neighbor with a list of size exactly one.

Proof.

Let , where are the consecutive vertices on the path. We reduce from the 3-SAT problem. Let be an instance of 3-SAT. Without loss of generality, we can assume that each variable appears at least once negatively and at least once positively in some clause in . For every variable we introduce a variable gadget to be a double-sided broom with a five-vertex path , called handle, set of leaves on one end, and set of leaves on the second end of the handle. The number of vertices in and equals to the number of positive and negative occurrences of in , respectively. We set the lists of to be , respectively, and the lists of all vertices in to be (see a part of Figure 2 for an illustration).

Claim 4.4 (Variable consistency).

There exists exactly two homomorphisms in which the vertices of the handle of are happy:

  1. , , , , , , and

  2. , , , , , .

Proof of Claim 4.4.  In order to make vertex happy, vertices and have to be mapped to different vertices of . As consequence, vertices are mapped to different vertices as well. It is easy to check that all other vertices except