##
###
The Complexity of General-Valued CSPs

Vladimir Kolmogorov, Andrei Krokhin, Michal Rolínek

2017
*
SIAM journal on computing (Print)
*

The full-text may be used and/or reproduced, and given to third parties in any format or medium, without prior permission or charge, for personal research or study, educational, or not-for-prot purposes provided that: • a full bibliographic reference is made to the original source • a link is made to the metadata record in DRO • the full-text is not changed in any way The full-text must not be sold in any format or medium without the formal permission of the copyright holders. Please consult
## more »

... . Please consult the full DRO policy for further details. Abstract. An instance of the valued constraint satisfaction problem (VCSP) is given by a finite set of variables, a finite domain of labels, and a sum of functions, each function depending on a subset of the variables. Each function can take finite values specifying costs of assignments of labels to its variables or the infinite value, which indicates an infeasible assignment. The goal is to find an assignment of labels to the variables that minimizes the sum. We study, assuming that P = NP, how the complexity of this very general problem depends on the set of functions allowed in the instances, the so-called constraint language. The case when all allowed functions take values in {0, ∞} corresponds to ordinary CSPs, where one deals only with the feasibility issue, and there is no optimization. This case is the subject of the algebraic CSP dichotomy conjecture predicting for which constraint languages CSPs are tractable (i.e., solvable in polynomial time) and for which they are NP-hard. The case when all allowed functions take only finite values corresponds to a finitevalued CSP, where the feasibility aspect is trivial and one deals only with the optimization issue. The complexity of finite-valued CSPs was fully classified by Thapper andŽivný. An algebraic necessary condition for tractability of a general-valued CSP with a fixed constraint language was recently given by Kozik and Ochremiak. As our main result, we prove that if a constraint language satisfies this algebraic necessary condition, and the feasibility CSP (i.e., the problem of deciding whether a given instance has a feasible solution) corresponding to the VCSP with this language is tractable, then the VCSP is tractable. The algorithm is a simple combination of the assumed algorithm for the feasibility CSP and the standard LP relaxation. As a corollary, we obtain that a dichotomy for ordinary CSPs would imply a dichotomy for general-valued CSPs. to the homomorphism problem for relational structures [23] . The CSP deals only with the feasibility issue: can all constraints be satisfied simultaneously? There are several natural optimization versions of the CSP: Max CSP (or Min CSP) where the goal is to find the assignment maximizing the number of satisfied constraints (or minimizing the number of unsatisfied constraints) [15, 19, 30, 31] , problems like Max-Ones and Min-Hom where the constraints must be satisfied and some additional function of the assignment is to be optimized [19, 32, 47] , and, the most general version, valued CSP or VCSP (also known as soft CSP), where each combination of values for variables in a constraint has a cost and the goal is to minimize the aggregate cost [13, 17, 35, 49] . Thus, an instance of the VCSP amounts to minimizing a sum of functions, each depending on a subset of variables. By using infinite costs to indicate infeasible combinations, VCSP can model both feasibility and optimization aspects and so considerably generalizes all the problems mentioned above [13, 17, 39] . There is much activity and there are very strong results concerning various aspects of approximability of (V)CSPs (see, e.g., [5, 8, 12, 19, 21, 22, 26, 43] for a small sample), but in this paper we focus on solving VCSPs to optimality. We assume throughout the paper that P = NP. Since all the above problems are NP-hard in full generality, a major line of research in CSP tries to identify the tractable cases of such problems (see books/surveys [16, 19, 20, 39] ), the primary motivation being the general picture rather than specific applications. The two main ingredients of a constraint are (a) variables to which it is applied and (b) relations/functions specifying the allowed combinations of values or the costs for all combinations. Therefore, the main types of restrictions on CSP are (a) structural where the hypergraph formed by sets of variables appearing in individual constraints is restricted [25, 41] , and (b) language-based where the constraint language, i.e., the set of relations/functions that can appear in constraints, is fixed (see, e.g., [10, 16, 19, 23, 49] ). The ultimate sort of results in these directions are dichotomy results, pioneered by [45] , which characterize the tractable restrictions and show that the rest are as hard as the corresponding general problem (which cannot generally be taken for granted). The language-based direction is considerably more active than the structural one, there are many partial language-based dichotomy results, e.g., [9, 11, 17, 19, 30, 31, 36, 47] , but many central questions are still open. In this paper, we study VCSPs with a fixed constraint language on a finite domain, and all further discussion concerns only such CSPs and VCSPs. Related work. The CSP dichotomy conjecture, stating that each CSP is either tractable or NP-hard, was first formulated by Feder and Vardi [23] . The universalalgebraic approach to this problem was discovered in [10, 28, 29] , and the precise boundary between the tractable cases and NP-hard cases was conjectured in algebraic terms in [10] , in what is now known as the algebraic CSP dichotomy conjecture (see Conjecture 2.16). The hardness part was proved in [10], and it is the tractability part that is the essence of the conjecture. This conjecture is still open in full generality and is the object of much investigation, e.g., [2, 3, 4, 1, 6, 10, 11, 16, 27] . It is known to hold for domains with at most three elements [9, 45] , for smooth digraphs [6], and for the case when all unary relations are available [1, 11] . The main two polynomial-time algorithms used for CSPs are one based on local consistency ("bounded width") and the other based on compact representation of solution sets ("few subpowers"), and their applicability (in pure form) is fully characterized in [2, 4] and [27], respectively. At the opposite (to CSP) end of the VCSP spectrum are the finite-valued CSPs, in which functions do not take infinite values. In such VCSPs, the feasibility aspect is trivial, and one has to deal only with the optimization issue. One polynomial-time Downloaded 07/14/17 to 129.234.0.70. Redistribution subject to SIAM license or copyright; see 1089 algorithm that solves tractable finite-valued CSPs is based on the so-called basic linear programming (BLP) relaxation, and its applicability (also for the general-valued case) was fully characterized in [35] (see Theorem 2.17). The complexity of finite-valued CSPs was completely classified in [49] , where it is shown that all finite-valued CSPs not solvable by BLP are NP-hard. For general-valued CSPs, full classifications are known for the Boolean case (i.e., when the domain is two-element) [17] and also for the case when all 0-1-valued unary cost functions are available [36] . The algebraic approach to the CSP was extended to VCSPs in [13, 14, 17, 37] , and was also key to much progress. An algebraic necessary condition for a VCSP to be tractable was recently proved by Kozik and Ochremiak in [37], where this condition was also conjectured to be sufficient (see Theorem 2.14 and Conjecture 2.15 below). This conjecture can be called the algebraic VCSP dichotomy conjecture, and it is a generalization of the corresponding conjecture for CSP. A large family of VCSPs satisfying the necessary condition from [37] has recently been shown tractable via a low-level Sherali-Adams hierarchy relaxation [48] . Our proof uses the technique of "lifting a language" introduced in [34]. Our contribution. We completely classify the complexity of VCSPs with a fixed constraint language modulo the complexity of CSPs (see Theorem 3.3). Clearly, for a VCSP to be tractable, it is necessary that the corresponding feasibility CSP is tractable. We prove that any VCSP satisfying this necessary condition and the necessary condition of Kozik and Ochremiak is tractable. The polynomial-time algorithm that solves such VCSP is a simple combination of the (assumed) polynomial-time algorithm for the feasibility CSP and BLP (see Theorem 3.4). Thus, our dichotomy theorem generalizes the dichotomy for finite-valued CSPs from [49] , and, with the help of the CSP tractability result from [4] , it also implies the tractability of VCSPs shown tractable in [48, 50] . Our classification result has the following several unexpected features. One is that the algorithm that solves all tractable VCSPs uses feasibility checking only as a black box. The other is that the algorithm is simply feasibility preprocessing followed by BLP -this was unexpected, for example, because higher levels of the Sherali-Adams hierarchy were used in [48] to prove tractability of a wide class of VCSPs. Finally, the proof of our result avoids structural universal algebra present in most CSP classifications and in [37, 38] . Our result says that any dichotomy for CSP (not necessarily the one predicted by the algebraic CSP dichotomy conjecture) will imply a dichotomy for VCSP. However, if the algebraic CSP dichotomy conjecture holds, then the necessary algebraic condition of Kozik and Ochremiak guarantees tractability of the feasibility CSP (see [37] ), implying that this algebraic condition alone is necessary and sufficient for tractability of a VCSP, and also that all the intractable VCSPs are NP-hard. In particular, the algebraic CSP dichotomy conjecture implies the algebraic VCSP dichotomy conjecture. On the technical level, some of our proofs (e.g., those in section 7) use techniques established in [35, 49] , while others (e.g., all of section 6) introduce new technical ideas. Our result is the culmination of research into complexity classification of languagebased VCSPs in the sense that its scope cannot be widened, the yet unclassified part of the VCSP landscape is the (nonvalued) CSP. One could, of course, extend the classification framework by looking at other forms of algorithmic tractability, say, approximation algorithms or fixed-parameter tractability, and such extensions will have many open questions. It is also interesting to obtain tighter and more explicit Downloaded 07/14/17 to 129.234.0.70. Redistribution subject to SIAM license or copyright; see

doi:10.1137/16m1091836
fatcat:zfnnwzkui5fdljkba2kd7e2aou