Schaefer's dichotomy theorem


In computational complexity theory, a branch of computer science, Schaefer's dichotomy theorem states necessary and sufficient conditions under which a finite set S of relations over the Boolean domain yields polynomial-time or NP-complete problems when the relations of S are used to constrain some of the propositional variables.
It is called a dichotomy theorem because the complexity of the problem defined by S is either in P or NP-complete as opposed to one of the classes of intermediate complexity that is known to exist by Ladner's theorem.
Special cases of Schaefer's dichotomy theorem include the NP-completeness of SAT and its two popular variants 1-in-3 SAT and not-all-equal 3SAT. In fact, for these two variants of SAT, Schaefer's dichotomy theorem shows that their monotone versions are also NP-complete.

Original presentation

Schaefer defines a decision problem that he calls the Generalized Satisfiability problem for S, where is a finite set of relations over propositional variables. An instance of the problem is an S-formula, i.e. a conjunction of constraints of the form where and the are propositional variables. The problem is to determine whether the given formula is satisfiable, in other words if the variables can be assigned values such that they satisfy all the constraints as given by the relations from S.
Schaefer identifies six classes of sets of Boolean relations for which SAT is in P and proves that all other sets of relations generate an NP-complete problem. A finite set of relations S over the Boolean domain defines a polynomial time computable satisfiability problem if any one of the following conditions holds:
  1. all relations which are not constantly false are true when all its arguments are true;
  2. all relations which are not constantly false are true when all its arguments are false;
  3. all relations are equivalent to a conjunction of binary clauses;
  4. all relations are equivalent to a conjunction of Horn clauses;
  5. all relations are equivalent to a conjunction of dual-Horn clauses;
  6. all relations are equivalent to a conjunction of affine formulae.
Otherwise, the problem SAT is NP-complete.

Modern presentation

A modern, streamlined presentation of Schaefer's theorem is given in an expository paper by Hubie Chen. In modern terms, the problem SAT is viewed as a constraint satisfaction problem over the Boolean domain. In this area, it is standard to denote the set of relations by Γ and the decision problem defined by Γ as CSP.
This modern understanding uses algebra, in particular, universal algebra. For Schaefer's dichotomy theorem, the most important concept in universal algebra is that of a polymorphism. An operation is a polymorphism of a relation if, for any choice of m tuples from R, it holds that the tuple obtained from these m tuples by applying f coordinate-wise, i.e., is in R. That is, an operation f is a polymorphism of R if R is closed under f: applying f to any tuples in R yields another tuple inside R. A set of relations Γ is said to have a polymorphism f if every relation in Γ has f as a polymorphism. This definition allows for the algebraic formulation of Schaefer's dichotomy theorem.
Let Γ be a finite constraint language over the Boolean domain. The problem CSP is decidable in polynomial-time if Γ has one of the following six operations as a polymorphism:
  1. the constant unary operation 0;
  2. the constant unary operation 1;
  3. the binary AND operation ;
  4. the binary OR operation ∨;
  5. the ternary majority operation
  6. the ternary minority operation
Otherwise, the problem CSP is NP-complete.
In this formulation, it is easy to check if any of the tractability conditions hold.

Properties of Polymorphisms

Given a set Γ of relations, there is a surprisingly close connection between its polymorphisms and the computational complexity of CSP.
A relation R is called primitive positive definable, or short pp-definable, from a
set Γ of relations if R ⇔ ∃x1... xm. C holds for some conjunction C of constraints from Γ and equations over the variables.
For example, if Γ consists of the ternary relation nae holding if x,y,z are not all equal, and R is xyz, then R can be pp-defined by R ⇔ ∃a. naenae; this reduction has been used to prove that NAE-3SAT is NP-complete.
The set of all relations which are pp-definable from Γ is denoted by ≪Γ≫.
If Γ' ⊆ ≪Γ≫ for some finite constraint sets Γ and Γ', then CSP reduces to CSP.
Given a set Γ of relations, Pol denotes the set of polymorphisms of Γ.
Conversely, if O is a set of operations, then Inv denotes the set of relations having all operations in O as a polymorphism.
Pol and Inv together build a Galois connection.
For any finite set Γ of relations over a finite domain, ≪Γ≫ = Inv holds, that is, the set of relations pp-definable from Γ can be derived from the polymorphisms of Γ. Moreover, if PolPol for two finite relation sets Γ and Γ', then Γ' ⊆ ≪Γ≫ and CSP reduces to CSP. As a consequence, two relation sets having the same polymorphisms lead to the same computational complexity.

Generalizations

The analysis was later fine-tuned: CSP is either solvable in co-NLOGTIME, L-complete, NL-complete, ⊕L-complete, P-complete or NP-complete and given Γ, one can decide in polynomial time which of these cases holds.
Schaefer's dichotomy theorem was recently generalized to a larger class of relations.

Related work

If the problem is to count the number of solutions, which is denoted by #CSP, then a similar result by Creignou and Hermann holds. Let Γ be a finite constraint language over the Boolean domain. The problem #CSP is computable in polynomial time if Γ has a Mal'tsev operation as a polymorphism. Otherwise, the problem #CSP is #P-complete. A Mal'tsev operation m is a ternary operation that satisfies An example of a Mal'tsev operation is the Minority operation given in the modern, algebraic formulation of Schaefer's dichotomy theorem above. Thus, when Γ has the Minority operation as a polymorphism, it is not only possible to decide CSP in polynomial time, but to compute #CSP in polynomial time. There are a total of 4 Mal'tsev operations on Boolean variables, determined by the values of and. An example of less symmetric one is given by. On another domains, such as groups, examples of Mal'tsev operations include and
For larger domains, even for a domain of size three, the existence of a Mal'tsev polymorphism for Γ is no longer a sufficient condition for the tractability of #CSP. However, the absence of a Mal'tsev polymorphism for Γ still implies the #P-hardness of #CSP.