- Research Article
20
- 10.1016/j.artint.2014.12.002
STR3: A path-optimal filtering algorithm for table constraints
- Dec 16, 2014
- Artificial Intelligence
- Christophe Lecoutre + 2 more +2
STR3: A path-optimal filtering algorithm for table constraints
Filtering by Generalized Arc Consistency (GAC) is a fundamental technique in Constraint Programming. Recent advances in GAC algorithms for extensional constraints rely on direct manipulation of tables during search. Simple Tabular Reduction (STR), which systematically removes invalid tuples from tables, has been shown to be a simple yet efficient approach. STR2, a refinement of STR, is considered to be among the best filtering algorithms for positive table constraints. In this paper, we introduce a new GAC algorithm called STR3 that is specifically designed to enforce GAC during search. STR3 can completely avoid unnecessary traversal of tables, making it optimal along any path of the search tree. Our experiments show that STR3 is much faster than STR2 when the average size of the tables is not reduced drastically during search.
STR3: A path-optimal filtering algorithm for table constraints
STR3: A path-optimal filtering algorithm for table constraints
Strong local consistency algorithms for table constraints
Table constraints are important in constraint programming as they are present in many real problems from areas such as configuration and databases. As a result, numerous specialized algorithms that achieve generalized arc consistency (GAC) on table constraints have been proposed. Since these algorithms achieve GAC, they operate on one constraint at a time. In this paper we propose new filtering algorithms for positive table constraints that achieve stronger local consistency properties than GAC by exploiting intersections between constraints. The first algorithm, called maxRPWC+, is a domain filtering algorithm that is based on the local consistency maxRPWC and extends the GAC algorithm of Lecoutre and Szymanek (2006). The second algorithm extends the state-of-the-art STR-based algorithms to stronger relation filtering consistencies, i.e., consistencies that can remove tuples from constraints’ relations. Experimental results from benchmark problems demonstrate that the proposed algorithms are quite competitive with standard GAC algorithms like STR2 in some classes of problems with intersecting table constraints, being orders of magnitude faster in some cases.
Read moreAn Efficient Higher-Order Consistency Algorithm for Table Constraints
Table constraints are very important in constraint programming as they are present in many real problems from areas such as configuration and databases. As a result, numerous specialized algorithms that achieve generalized arc consistency (GAC) on table constraints have been proposed. Since these algorithms achieve GAC, they operate on one constraint at a time. In this paper we propose an efficient algorithm for table constraints that achieves a stronger local consistency than GAC. This algorithm, called maxRPWC+, is based on the local consistency maxRPWC and allows the efficient handling of intersecting table constraints. Experimental results from benchmark problems demonstrate that maxRPWC+ is clearly more robust than a state-of-the-art GAC algorithm in classes of problems with interleaved table constraints, being orders of magnitude faster in some of these classes.
Read moreExtending Generalized Arc Consistency
Generalized arc consistency (GAC) is the most widely used local consistency in constraint programming. Several GAC algorithms for specific constraints, as well as generic algorithms that can be used on any constraint, have been proposed in the literature. Stronger local consistencies than GAC have also been studied but algorithms for such consistencies are generally considered too expensive. In this paper we propose an extension to the standard GAC algorithm GAC2001/3.1 that achieves a stronger local consistency than GAC by considering intersections of constraints. Importantly, the worst-case time complexity of the proposed algorithm, called GAC+, is higher than that of GAC2001/3.1 only by a factor e, where e is the number of constraints in the problem. Experimental results demonstrate that in many cases GAC+ can reduce the size of the search tree compared to GAC, resulting in improved cpu times. Also, in cases where there is no gain in search tree size, there is only a negligible overhead in cpu time.
Read moreBipartite Encoding: A New Binary Encoding for Solving Non-Binary CSPs
Constraint Satisfaction Problems (CSPs) are typically solved with Generalized Arc Consistency (GAC). A general CSP can also be encoded into a binary CSP and solved with Arc Consistency (AC). The well-known Hidden Variable Encoding (HVE) is still a state-of-the-art binary encoding for solving CSPs. We propose a new binary encoding, called Bipartite Encoding (BE) which uses the idea of partitioning constraints. A BE encoded CSP can achieve a higher level of consistency than GAC on the original CSP. We give an algorithm for creating compact bipartite encoding for non-binary CSPs. We present a AC propagator on the binary constraints from BE exploiting their special structure. Experiments on a large set of non-binary CSP benchmarks with table constraints using the Wdeg, Activity and Impact heuristics show that BE with our AC propagator can outperform existing state-of-the-art GAC algorithms (CT, STRbit) and binary encodings (HVE with HTAC).
Read moreArc Consistency Revisited
Binary constraints are a general representation for constraints and is used in Constraint Satisfaction Problems (CSPs). However, many problems are more easily modelled with non-binary constraints (constraints with arity >2). Several well-known binary encoding methods can be used to transform non-binary CSPs to binary CSPs. Historically, work on constraint satisfaction began with binary CSPs with many algorithms proposed to maintain Arc Consistency (AC) on binary constraints. In more recent times, research has focused on non-binary constraints and efficient Generalized Arc Consistency (GAC) algorithms for non-binary constraints. Existing results and “folklore” suggest that AC algorithms on the binary encoding of a non-binary CSP do not compete with GAC algorithms on the original problem. We propose new algorithms to enforce AC on binary encoded instances. Preliminary experiments show that our AC algorithm on the binary encoded instances is competitive to state-of-the-art GAC algorithms on the original non-binary instances and faster in some instances. This result is surprising and is contrary to the “folklore” on AC versus GAC algorithms. We believe our results can lead to a revival of AC algorithms as binary constraints and resulting algorithms are simpler than the non-binary ones.
Read moreExtending STR to a Higher-Order Consistency
One of the most widely studied classes of constraints in constraint programming (CP) is that of table constraints. Numerousspecialized filtering algorithms, enforcing the wellknown property called generalized arc consistency (GAC),have been developed for such constraints. Among the most successful GAC algorithms for table constraints, we find variants of simple tabular reduction (STR), like STR2. In this paper,we propose an extension of STR-based algorithms that achieves full pairwise consistency (FPWC), a consistency stronger than GAC and max restricted pairwise consistency (maxRPWC). Our approach involves counting the number of occurrences of specific combinations of values in constraint intersections. Importantly, the worst-case time complexity of one call to the basic filtering procedure at the heart of our new algorithm is quite close to that of STR algorithms. Experiments demonstrate that our method can outperform STR2 in many classes of problems, being significantly faster in some cases. Also, it is clearly superior to maxRPWC+, an algorithm that has been recently proposed.
Read moreSTR2: optimized simple tabular reduction for table constraints
Table constraints play an important role within constraint programming. Recently, many schemes or algorithms have been proposed to propagate table constraints and/or to compress their representation. In this paper, we describe an optimization of simple tabular reduction (STR), a technique proposed by J. Ullmann to dynamically maintain the tables of supports when generalized arc consistency (GAC) is enforced/maintained. STR2, the new refined GAC algorithm we propose, allows us to limit the number of operations related to validity checking and search of supports. Interestingly enough, this optimization makes simple tabular reduction potentially r times faster where r is the arity of the constraint(s). The results of an extensive experimentation that we have conducted with respect to random and structured instances indicate that STR2 is usually around twice as fast as the original STR, two or three times faster than the approach based on the hidden variable encoding, and can be up to one order of magnitude faster than previously state-of-the-art (generic) GAC algorithms on some series of instances. When comparing STR2 with the more recently developed algorithm based on multi-valued decision diagrams (MDDs), we show that both approaches are rather complementary.
Read moreEncoding Multi-Valued Decision Diagram Constraints as Binary Constraint Trees
Ordered Multi-valued Decision Diagram (MDD) is a compact representation used to model various constraints, such as regular constraints and table constraints. It can be particularly useful for representing ad-hoc problem specific constraints. Many algorithms have been proposed to enforce Generalized Arc Consistency (GAC) on MDD constraints. In this paper, we introduce a new compact representation called Binary Constraint Tree (BCT). We propose tree binary encodings to transform any MDD constraint into a BCT constraint. We also present a specialized algorithm enforcing GAC on the BCT constraint resulting from a MDD constraint. Experimental results on a large set of benchmarks show that the BCT GAC algorithm can significantly outperform state-of-the-art MDD as well as table GAC algorithms.
Read moreA Bitwise GAC Algorithm for Alldifferent Constraints
The generalized arc consistency (GAC) algorithm is the prevailing solution for alldifferent constraint problems. The core part of GAC for alldifferent constraints is excavating and enumerating all the strongly connected components (SCCs) of the graph model. This causes a large amount of complex data structures to maintain the node information, leading to a large overhead both in time and memory space. More critically, the complexity of the data structures further precludes the coordination of different optimization schemes for GAC. To solve this problem, the key observation of this paper is that the GAC algorithm only cares whether a node of the graph model is in an SCC or not, rather than which SCCs it belongs to. Based on this observation, we propose AllDiffbit, which employs bitwise data structures and operations to efficiently determine if a node is in an SCC. This greatly reduces the corresponding overhead, and enhances the ability to incorporate existing optimizations to work in a synergistic way. Our experiments show that AllDiffbit outperforms the state-of-the-art GAC algorithms over 60%.
Read moreDomain k-Wise Consistency Made as Simple as Generalized Arc Consistency
In Constraint Programming (CP), Generalized Arc Consistency (GAC) is the central property used for making inferences when solving Constraint Satisfaction Problems (CSPs). Developing simple and practical filtering algorithms based on consistencies stronger than GAC is a challenge for the CP community. In this paper, we propose to combine k-Wise Consistency (kWC) with GAC, where kWC states that every tuple in a constraint can be extended to every set of k − 1 additional constraints. Our contribution is as follows. First, we derive a domain-filtering consistency, called Domain k-Wise Consistency (DkWC), from the combination of kWC and GAC. Roughly speaking, this property corresponds to the pruning of values of GAC, when enforced on a CSP previously made kWC. Second, we propose a procedure to enforce DkWC, relying on an encoding of kWC to generate a modified CSP called k-interleaved CSP. Formally, we prove that enforcing GAC on the k-interleaved CSP corresponds to enforcing DkWC on the initial CSP. Consequently, we show that the strong DkWC can be enforced very easily in constraint solvers since the k-interleaved CSP is rather immediate to generate and only existing GAC propagators are required: in a nutshell, DkWC is made as simple and practical as GAC. Our experimental results show the benefits of our approach on a variety of benchmarks.
Read moreEliminating the Computation of Strongly Connected Components in Generalized Arc Consistency Algorithm for AllDifferent Constraint
AllDifferent constraint is widely used in Constraint Programming to model real world problems. Existing Generalized Arc Consistency (GAC) algorithms map an AllDifferent constraint onto a bipartite graph and utilize the structure of Strongly Connected Components (SCCs) in the graph to filter values. Calculating SCCs is time-consuming in the existing algorithms, so we propose a novel GAC algorithm for AllDifferent constraint in this paper, which eliminates the computation of SCCs. We prove that all redundant edges in the bipartite graph point to some alternating cycles. Our algorithm exploits this property and uses a more efficient method to filter values, which is based on breadth-first search. Experimental results on the XCSP3 benchmark suite show that our algorithm considerably outperforms the state-of-the-art GAC algorithms.
Read moreSaving constraint checks in maintaining coarse-grained generalized arc consistency
Constraint check plays a central role in establishing generalized arc consistency which is widely used to solve constraint satisfaction problems. In this paper, we propose a new generalized arc consistency algorithm, called GTR, which ensures that the tuples that have been checked to be allowed by a constraint will never be checked again. For each constraint, GTR maintains a dynamic list of the tuples that were checked to be allowed by this constraint and check their validities to identify some values with supports. It is equipped with a mechanism avoiding redundant validity checks. The basic GAC3 algorithm is employed to find a support for the rest values and to add new tuples to the dynamic list. The experiments show that maintaining GTR during search saves a number of constraint checks. It also brings some improvements over cpu time while solving some CSPs with tight constraints.
Read moreA Constraint-Programmed Planner for Deep Space Exploration Problems With Table Constraints
In recent years because of the increasing number and types of scientific payloads on a probe, the constraints between payload and probe and the constraints among payloads have become increasingly complex. The technology of constraint processing has gradually become a focus of research in deep space planning. In this paper, we propose a constrained-programmed planner called DSPlan for deep space planning problems based on table constraints. We first propose a technique for automatically converting the planning domain definition language model used in planning into the form of table constraints. Following the common practice of coding a planning problem as a constraint satisfaction problem with multiple levels, we propose a dynamic constraint set and a corresponding mutex filtering algorithm to express the different combinations of constraints on varying levels that need to be satisfied. This new form of data structure uses explicit domain information to maintain the generalized arc consistency of table constraints. Empirical analyses demonstrate the efficiency of table constraints over the international planning competition problem and classic deep space instances in general arc consistency schema algorithms. Experimental results also prove that DSPlan and table constraints are highly promising general-purpose tools for deep space planning problems compared with other planners.
Read moreGraph constraints refined for transitive relations
Graph constraints refined for transitive relations