1 Main Results
Let be a finite set, be a set of relations on , called a constraint language. Then the Constraint Satisfaction Problem over the constraint language , denoted by , is the following decision problem: given a formula of the form
where and each ; decide whether the formula is satisfiable. The Surjective Constraint Satisfaction Problem over the constraint language , denoted by , is the problem of deciding whether there is a solution such that . In [HubieSlides] Hubie Chen conjectured the following characterization of the complexity of .
Conjecture 1.
For any constraint language the problems and are polynomially equivalent.
As it was proved in [SCSPforTwo1997] (see also [SCSPforTwoBook]) this conjecture holds for a 2element domain. In [chen2014algebraic] Hubie Chen confirmed that polymorphisms of can be used to describe the complexity of . For instance he proved NPhardness of for admitting only essentially unary polymorphisms. More information about the complexity of the SCSP can be found in the survey [SCSPSURVEY].
Let . The problem is called NoRainbowProblem. In fact if we interpret , and 2 as colors, then the relation forbids rainbow. The complexity of was an open question for many years and was formulated in many papers as an important open problem [SCSPSURVEY, HubieSlides]. In the paper we prove that this problem is NPhard.
Theorem 1.
is NPcomplete.
Thus, our result confirms Conjecture 1. Unfortunately, we found a counter example to this conjecture.
Let , (here columns are tuples).
Note that is the projection of onto coordinates 2,3 and 4. Hence, every polymorphism of is also a polymorphism of .
Theorem 2.
We have

is NPhard.

is solvable in polynomial time.

is NPHard.
Comparing (2) and (3) we derive that the complexity of cannot be described in terms of polymorphisms.
2 NoRainbow problem is NPHard (the first proof)
Let be a constraint language on .
The problem is known to be NPHard [Schaefer]. Hence, to prove Theorem 1 it is sufficient to prove the following theorem.
Theorem 3.
can be polynomially reduced to .
Let us define the reduction. Let be an instance of . Let us build an instance of such that holds if and only if has a surjective solution. Note that the problems and are equivalent because we can always propagate out the equalities.
Construction. Let be the variables of .
Choose variables . We define 14 sets of constraints:
,
,
,
,
,
,
,
,
,
,
,
,
,
.
Lemma 4.
holds if and only if has a surjective solution, where .
Proof.
Let us show both implications.
Let be a solution of . Put , , , , , for every .
Let us check that all constraints are satisfied.
holds because for any .
holds because for any .
holds because for any .
holds because are from the set .
holds because are from the set .
holds because are from the set .
holds because for any .
holds because for any .
holds because for any .
holds because for any .
holds because each constraint is equivalent to and equivalent to .
holds because each constraint is equivalent to and equivalent to .
holds because whenever .
holds because whenever .
Choose a surjective solution of . By we can choose such that and . Since the solution is surjective, there should be an element in the solution equal to .
Case 1. Assume that and . WLOG we may assume (everything is symmetric) that .
By , , we know that
Let us show that . If and , then we get a contradiction with .
If , then by we have , by we have , which implies and contradicts .
Let us show that is a solution of .
guarantees that all the constraints of the form hold, guarantees that all the constraints of the form hold, guarantees that all the constraints of the form hold, guarantees that all the constraints of the form hold. Thus, we proved that it is a solution.
Case 2. Assume that and . By we have . By we have . Since the solution is surjective, there should be such that . By we have , by we have . Contradiction.
Case 3. Assume that and for some . By we have , hence . By we have , hence . Since the solution is surjective, there should be such that . By , we have . By we have for every . Contradiction.
Case 4. Assume that and for some . By we have , hence . By , we have . By we obtain and since we have . Then by we obtain for every . If for some , then we get a contradiction with applied to . Since the solution is surjective, the only remaining option is , which contradicts .
Case 5. Assume that . Since the solution is surjective, there exists such that . By and we have . By we have for every , by we have for every . By we have , by we have . Therefore and by we obtain . Hence, none of the variables can be equal to . Contradiction. ∎
3 NoRainbow problem is NPHard (the second proof)
Here we present another proof of the fact that the NoRainbow problem is NPHard. By we denote the ternary relation on consisting of all tuples but and .
It is known from [Schaefer] that is NPhard. Hence, to prove Theorem 1 it is sufficient to prove the following theorem.
Theorem 5.
can be polynomially reduced to .
For a relation by we denote the set of all operations preserving (set of all polymorphisms). Note that consists of all essentially unary operations, and all operations such that .
Let be the matrix with 2 columns and rows whose rows are all pairs from . We know that can be defined by a quantifierfree ppformula over . Here is the set of all graphs of binary operations from .
Let us show how to encode as . Consider an instance of . Let be the variables of and be the set of all triples such that appears in the instance.
We encode every variable with nine variables on . The nine variables assigned to express the binary operation on preserving . We want to be the first projection if and to be the second projection if .
By we denote the following instance
This instance can be viewed as an instance of because we use only equalities, the relation and the relation .
Lemma 6.
holds if and only if has a surjective solution.
Proof.
. As we mentioned earlier, it is sufficient to put if , and if .
. Let .
If , then all the functions are essentially unary (and bijective). Assign if depends essentially on the first variable, and if depends essentially on the second variable. Then the third conjunction guarantees that we defined a solution to .
Assume that , then by the properties of , we have for every , which contradicts the surjectivity of the solution.
Assume that . Since the solution is surjective, the remaining two values should appear in the images of some functions and . Note that for every . To get a contradiction we use the last four conjunctions. The last three conjunctions are obtained by permutations of variables in and . Therefore, without loss of generality we consider and such that . By the fourth conjunction we obtain , and then by the fifth conjunction we get . Then by the fourth conjunction we have , which contradicts our assumption. ∎
4 Counter example
Recall that , .
Lemma 7.
is NPhard.
Proof.
Note that . We can check that is not preserved by any idempotent WNU on . Hence, is NPhard. Therefore, is NPhard. ∎
Lemma 8.
is NPhard.
Proof.
can be viewed as the SCSP on the twoelement set (we just add a variable that never appears), which is known to be NPHard [SCSPforTwo1997, SCSPforTwoBook]. ∎
Lemma 9.
can be solved in polynomial time.
Proof.
Let We will prove a stronger claim that is tractable for . Consider an instance of .
First, we want to make the instance 1consistent. The coordinates of have the domains , , and . If a variable has different domains in different constraints then the instance can be simplified. For example, if a variable appears at the fifth position of but it has a smaller domain in some other constraint then we do the following :
Thus, after we achieved 1consistency, we may have two cases:
Case 1. The instance does not contain at all. Then the instance is tractable. Indeed, we guess three variables taking values , and and solve a CSP instance over .
Case 2. The instance contains . Then we send the variables with the domain to , the variables with the domain to 1, and the variables with the domain to a. We can check that as a result we obtain a surjective solution of the instance. ∎
Comments
There are no comments yet.