Durham Research Online
Total Page:16
File Type:pdf, Size:1020Kb
Durham Research Online Deposited in DRO: 08 November 2010 Version of attached le: Published Version Peer-review status of attached le: Peer-reviewed Citation for published item: Carvalho, C. and Dalmau, V. and Krokhin, A. (2008) 'Caterpillar duality for constraint satisfaction problems.', in Twenty-third Annual IEEE Symposium on Logic in Computer Science, 24-27 June 2008, Pittsburgh, PA ; proceedings. Los Alamitos, CA: IEEE, 307 -316 . Further information on publisher's website: http://dx.doi.org/10.1109/LICS.2008.19 Publisher's copyright statement: c 2008 IEEE. Personal use of this material is permitted. However, permission to reprint/republish this material for advertising or promotional purposes or for creating new collective works for resale or redistribution to servers or lists, or to reuse any copyrighted component of this work in other works must be obtained from the IEEE. Additional information: Use policy 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 the full DRO policy for further details. Durham University Library, Stockton Road, Durham DH1 3LY, United Kingdom Tel : +44 (0)191 334 3042 | Fax : +44 (0)191 334 2971 https://dro.dur.ac.uk 23rd Annual IEEE Symposium on Logic in Computer Science Caterpillar duality for constraint satisfaction problems Catarina Carvalho V´ıctor Dalmau Andrei Krokhin Durham University University Pompeu Fabra Durham University Durham, DH1 3LE, UK Barcelona, 08003 Spain Durham, DH1 3LE, UK [email protected] [email protected] [email protected] Abstract programming language Datalog and its fragments are ar- guably some of the most important tools for solving CSPs. The study of constraint satisfaction problems definable In fact, all problems CSP(B) that are known to be tractable in various fragments of Datalog has recently gained con- can be solved via Datalog, or via the “few subpowers prop- siderable importance. We consider constraint satisfaction erty” [18], or via a combination of the two. Furthermore, problems that are definable in the smallest natural recursive for every problem CSP(B) that is currently known to be- fragment of Datalog - monadic linear Datalog with at most long to NL or to LOGSPACE, the complement of CSP(B) one EDB per rule. We give combinatorial and algebraic can be defined in linear Datalog and symmetric Datalog, characterisations of such problems, in terms of caterpillar respectively (see [4, 6, 9]). The algebraic approach to the dualities and lattice operations, respectively. We then apply CSP was recently linked with non-definability in the above our results to study graph H-colouring problems. fragments of Datalog [23]. The definability of CSP(B) in Datalog and its fragments is very closely related with homomorphism dualities (see, 1 Introduction e.g., [4]) that were much studied in the context of graph ho- momorphisms (see [15]). Roughly, a structure B has dual- The constraint satisfaction problem (CSP) provides a ity (of some type) if the non-existence of a homomorphism framework in which it is possible to express, in a natural from a given structure A to B can always be explained by way, many combinatorial problems encountered in artificial the existence of a simple enough obstruction structure (i.e., intelligence and computer science. A constraint satisfaction one that homomorphically maps to A but not to B). The problem is represented by a set of variables, a domain of types of dualities correspond to interpretations of the phrase values for each variable, and a set of constraints between “simple enough”. The most important duality is probably variables. The aim in a constraint satisfaction problem is bounded treewidth duality which is equivalent to definabil- then to find an assignment of values to the variables that ity in Datalog (see [4]). However, structures with this prop- satisfies the constraints. erty are not (yet) characterised, and this property is not even It is well known (see, e.g., [5, 11, 21]) that the constraint known to be decidable. More success has been obtained satisfaction problem can be recast as the following funda- for some particular cases of bounded treewidth duality such mental problem: given two finite relational structures A and as finite duality [22, 25] and tree duality [7, 11]. Both of B, is there a homomorphism from A to B? The CSP is NP- these properties are known to be decidable, and have nice complete in general, and the identifying of its subproblems logical, combinatorial, and algebraic characterisations (see that have lower complexity has been a very active research the above papers or [4]). For example, they correspond to direction in the last decade (see, e.g., [5, 11, 13, 21, 23]). definability in first-order logic and in monadic Datalog, re- One of the most studied restrictions on the CSP is when spectively. The simplest of trees are paths, and the concept the structure B is fixed, and only A is part of the input. of path duality was also much used to study graph homo- The obtained problem is denoted by CSP(B). Examples morphism (see [16, 17]), and in this paper we argue that, in of such problems include k-SAT,GRAPH H-COLOURING, the setting of general relational structures, a slightly more and SYSTEMS OF EQUATIONS (e.g., linear equations). general notion of caterpillar duality is more natural, and A variety of mathematical approaches to study prob- we give concise logical, combinatorial, and algebraic char- lems CSP(B) has been recently suggested. The most ad- acterisations of structures having this form of duality (see vanced approaches use logic, combinatorics, universal al- Section 3). gebra, and their combinations (see [4, 5, 20, 21]). The logic The problems CSP(B) with B being a digraph H are 1043-6871/08 $25.00 © 2008 IEEE 307 DOI 10.1109/LICS.2008.19 actively studied in graph theory under the name of H- element of A is a leaf if it is incident to exactly one block colouring [15]. Recently, algebraic and logical approaches in Inc(A). A block of A (i.e., a member of Block(A))is to the CSP were applied to solve well-known open prob- said to be pendant if it is incident to at most one non-leaf lems (or to give short proofs of known results) about H- element, and it is said to be non-pendant otherwise. For colouring (see, e.g., [1, 2, 3]). We also apply our findings to example, any block with a unary relation is always pendant. obtain new results about H-colouring in Section 4. In graph theory, a caterpillar is a tree which becomes a path after all its leaves are removed. Following [24], we 2 Preliminaries say that a τ-tree is a τ-caterpillar (or simply a caterpil- lar) if each of its blocks is incident to at most two non- 2.1 Basic definitions leaf elements, and each element is incident to at most two non-pendant blocks. Informally, a τ-caterpillar has a body consisting of a chain of elements a1,...,an+1 with A vocabulary is a finite set of relation symbols or predi- blocks B1,...,Bn where Bi is incident to ai and ai+1 τ cates. In what follows, always denotes a vocabulary. Ev- (i =1,...,n), and legs of two types: (i) pendant blocks in- ery relation symbol R in τ has an arity r = ρ(R) > 0 cident to exactly one of the elements a1,...,an+1, together R r associated to it. We also say that is an -ary relation sym- with some leaf elements incident to such blocks, and (ii) bol. A τ-structure A consists of a set A, called the universe leaf elements incident to exactly one the blocks B1,...,Bn. of A, and a relation RA ⊆ Ar for every relation symbol R ∈ τ where r is the arity of R. All structures in this paper Example 1. (i) If τ is the signature of digraphs then the τ- are assumed to be finite, i.e., structures with a finite uni- caterpillars are the oriented caterpillars, i.e., digraphs ob- verse. Throughout the paper we use the same boldface and tained from caterpillar graphs by orienting each edge in slanted capital letters to denote a structure and its universe, some way. respectively. (ii) Let B be a structure with B = {1, 2,...,6}, A homomorphism from a τ-structure A to a τ-structure one unary relation R1 = {2, 3}, one binary relation B is a mapping h : A → B such that for every r- R2 = {(1, 2), (2, 3), (3, 6)} and one ternary relation R3 = A ary R ∈ τ and every (a1,...,ar) ∈ R ,wehave {(3, 4, 5)}. The graph Inc(B) is shown on Fig. 1. The el- B (h(a1),...,h(ar)) ∈ R . We denote this by h : A → B. ements 2 and 3 are the non-leaves, and (R2, (2, 3)) is the We also say that A homomorphically maps to B, and write only non-pendant block. In particular, B is a caterpillar. A → B if there is a homomorphism from A to B and A → B if there is no homomorphism. Now CSP(B) can be (R1,2) (R1,3) 5 defined to be the class of all structures A such that A → B.