Download presentation
Presentation is loading. Please wait.
Published byAubrey Harris Modified over 9 years ago
1
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree-Structured CSPs1 Foundations of Constraint Processing CSCE421/821, Spring 2008: www.cse.unl.edu/~choueiry/S08-421-821/ Berthe Y. Choueiry (Shu-we-ri) Avery Hall, Room 123B choueiry@cse.unl.edu Tel: +1(402)472-5444 Tree-Based Methods
2
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Outline Backtrack-Free Search -Principle -Applications -Backtrack-Bounded Search -Principle -Applications, extensions Tree-Structured CSPs2
3
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Backtrack-Free Search [Freuder, 1982] A CSP can be solved in a backtrack-free manner when it is strong w+1-consistent, where w is the width of the constraint network –Compute w the width of the graph –Reinforce strong w-consistency –May add arcs to the graph, increasing width and requiring higher-level of strong consistency, etc. Approach is of little practical use Except for trees, width = 1 Tree-Structured CSPs3
4
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree-structured CSPs Trees have w = 1 Enforcing 2-consistency does not alter the width Tree-structured CSPs can be solved in polynomial time –Apply Revise (V i,V j ) for all nodes from leaves to root –Instantiate variables from root to leaves Tree-Structured CSPs4
5
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Exploiting tree structures Cycle-Cutset Method –Dechter and Pearl 1997 –Dechter Section 10.1.1 pages 273—276 Independent Set Decomposition –Gompert, FLAIRS 2005 Graph Reduction (GRED) –Unpublished work by Yaling Zheng 2007 Tree-Structured CSPs5
6
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Cycle-Cutset Method (1) Identify a cycle cutset S in the CSP (nodes when removed yield a tree) Decompose the CSP into 2 partitions –The nodes in S –The nodes in T, forming a tree Idea –Solve the nodes in S –Try to extend the solution to nodes in T –Iterate Tree-Structured CSPs6
7
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Cycle-Cutset Method (2) Find a solution to nodes in S (S is smaller than initial problem) Repeat until you find a solution –For every solution to S Apply DAC from S to T If no domain is wiped-out, solve T (quick) If |S|=c, time is O(d c.(n-c)d 2 )=O(nd c+2 ) Finding the smallest cutset is NP-hard Tree-Structured CSPs7
8
Foundations of Constraint Processing, Spring 2008 April 16, 2008 GRED [Yaling Zheng] After each assignment and FC/MAC step –Check the connectivity of the remaining CSP – Identify “dangling trees” using Graham’s graph reduction operator For each dangling tree, –Do DAC from leaf to root –Domain wipe-out indicates unsolvability Restrict search to nodes outside the identified dangling trees Tree-Structured CSPs8
9
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Outline Backtrack-Free Search -Principle -Applications -Backtrack-Bounded Search -Principle -Applications, extensions Tree-Structured CSPs9
10
Foundations of Constraint Processing, Spring 2008 April 16, 2008 j-width [Freuder, 1985] Given an ordering –The width of a group of j consecutive nodes is the number of nodes preceding the j nodes in the group and connected to any of them –The j-width of a node is the minimum, for k=1 to j, of the width of the k consecutive nodes up to and including the node. –The j-width of an ordering is the maximum j-width of all nodes in the ordering The j-width of a graph is the minimum of all j-width of all orderings Tree-Structured CSPs10
11
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Separable Graphs (graphs with articulation points) Consider a CSP whose graph has articulation nodes Assume that the largest biconnected component has size b Build a tree whose nodes are the biconnected components, considering that the articulation node belong to the parent Build an ordering using a preorder traversal of the tree –The (b-1)-width of the ordering is 1 Tree-Structured CSPs11
12
Foundations of Constraint Processing, Spring 2008 April 16, 2008 b-Bounded Search If for any level h in the search, –We can instantiate variable at level h+1 –Considering its possible values, and –Reconsidering at most b-1 previous variables In a graph with articulation nodes, –let b be the size of the largest biconnected component –Ordering the graph ‘along’ its biconnected components guarantees b-bounded search Tree-Structured CSPs12
13
Foundations of Constraint Processing, Spring 2008 April 16, 2008 j-bounded search and j-width There is an ordering –That guarantees k-bounded backtrack search –If the graph strongly (i,k)-consistent, where i = j-width Problem: enforcing strong (i,k)-consistency may increase the j-width.. Idea: Consider (1,k)-consistency –(Strong) (1,k)-consistency can be enforced without altering the structure of the graph –Cost: time exponential in k+1 Tree-Structured CSPs13
14
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Achieving (1,k)-consistency Achieving (strong) k-consistency via the constraint synthesis algorithm –Freuder shows that it also achieves (strong) (i,j)-consistency for i+j=k, time exponential in k Consider the original CSP –Remove the filtered values from the domains, updating the binary constraints –The resulting network is (1,k)-consistent w/o altering the graph Tree-Structured CSPs14
15
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Graphs with articulation points Graphs whose largest biconnected component if b have (b-1)-width = 1 Enforcing (1,b-1)-consistency Can be enforced in time exponential in b While guaranteeing (b-1)-bounded search Result A CSP can be solved in time exponential in b where b is the size of its largest biconnected component Tree-Structured CSPs15
16
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Exploiting Separable Graphs Tree-Clustering Method –Dechter & Pearl, AIJ 1989 –Dechter Section 9.2.1 (Join Tree Clustering) Generalization: Tree decompositions –Hinge,Hypertree, etc. Tree-Structured CSPs16
17
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree-Clustering Method Sketch of algorithm –Triangulate the graph (MinFill, Fig 4.4, page 89) –Find maximal cliques (Max-Cardinality, Fig 4.5, page 90) –Create a tree structure over the cliques –Repeat Solve a clique (all solutions), at each node in tree Apply DAC from leaves to root Generate solutions in a BT-free manner Tree-Structured CSPs17
18
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree-Clustering Method: Complexity n: number of variables Triangulation: O(n 2 ) –MinFill and MaxCardinality: O(n+e) Finding cliques: linear in n Solving clusters: O(k r ), k is domain size, r is size of largest clique Generating a solution O(n t log t) –t is #tuples in each cluster, (sorted) domain of a ‘super’ variable –in best case, we have n cliques Complexity bounded by size of largest clique: –O(n 2 )+O(k r )+O(n t log t)=O(n k r log k r )=O(n r k r ) Tree-Structured CSPs18
19
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree Decompositions Tree must obey specific properties Inspired from Database Theory (acyclic queries) Studied for non-binary CSPs Complexity of solving the CSP is bounded by a ‘width’ parameter –Max number of nodes in cluster –Max number of constraints in cluster Used to characterize tractable classes of CSPs Little use beyond theoretical characterization, except BTD/BTD + by Jégou et al. Tree-Structured CSPs19
20
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree decomposition Def 9.4, p. 257 A tree decomposition (T, , ) of a CSP P=(X,D,C) where T=(V,E), = chi, =psi: labeling functions (v) X, (v) C 1.Each constraint appears in at least on node in the tree, and all its variables are in that node 2.Nodes where any variable appears induce a single connected subtree (connectedness property) Tree-Structured CSPs20
21
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Parameters of a tree decomposition Treewidth (tw) –Maximum number of variables in any node in tree - 1 Hyperwidth (hw) –Maximum number of constraints in any node in tree Separator of two nodes –Number of common variables Tree-Structured CSPs21
22
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Tree-Structured CSPs22 HINGE TCLUSTER Gyssens et al., 1994 HYPERCUTSET Gottlob et al., 2000 TCLUSTER Dechter & Pearl, 1989 BICOMP Freuder, 1985 HYPERTREE Gottlob et al., 2002 HINGE Gyssens et al., 1994 CaT CUT HINGE + TRAVERSE CUTSET Dechter, 1987 Structural decomposition methods The techniques in blue were proposed by Yaling Zheng in 2005.
23
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Constraint hypergraph Tree-Structured CSPs23 S1S1 S2S2 S4S4 S3S3 S5S5 S7S7 S6S6 S 15 S8S8 S 12 S 13 S 14 S 11 S 10 S9S9 S 16 S 17 A vertex represents a variable A hyperedge represents a constraint (delimits its scope) Cut is a set of hyperedges whose removal disconnects the graph Cut size is the number of hyperedges in the cut
24
Foundations of Constraint Processing, Spring 2008 April 16, 2008 HINGE [Gyssens et al., 94] Tree-Structured CSPs24 S2S2 S4S4 S3S3 S5S5 S7S7 S6S6 S8S8 S 12 S 13 S 14 S 11 S9S9 hw = 12 S1S1 S2S2 S4S4 S3S3 S5S5 S7S7 S6S6 S 15 S8S8 S 12 S 13 S 14 S 11 S 10 S9S9 S 16 S 17 S 10 S9S9 S 16 S9S9 S 15 S9S9 S 17 S 11 S1S1 S2S2 In HINGE, the cut size is limited to 1
25
Foundations of Constraint Processing, Spring 2008 April 16, 2008 HINGE + : maximum cut size is a parameter Tree-Structured CSPs25 S2S2 S4S4 S3S3 S5S5 S7S7 S6S6 S 12 S 13 S 11 S9S9 S 16 S 17 S9S9 S 11 S5S5 S4S4 S6S6 S 12 S8S8 S 14 hw = 5 S1S1 S2S2 S4S4 S3S3 S5S5 S7S7 S6S6 S 15 S8S8 S 12 S 13 S 14 S 11 S 10 S9S9 S 16 S 17 S8S8 S 14 S7S7 S 13 S 10 S9S9 S 15 S9S9 S1S1 S2S2 HINGE + with maximum cut size of 2:
26
Foundations of Constraint Processing, Spring 2008 April 16, 2008 Bibliography [Freuder, 1982] A Sufficient Condition for Backtrack Free Search, JACM 29 (1), pages 24—32. [Freuder, 1985] A Sufficient Condition for Backtrack Bounded Search, JACM. [Dechter & Pearl, 1987] The Cycle-Cutset Method for improving Search Performance in AI Applications. In Third IEEE Conference on AI Applications, pages 224–230. [Dechter and Pearl, 1989] R. Dechter and J. Pearl. Tree Clustering for Constraint Networks. Artificial Intelligence, 38:353–366. Tree-Structured CSPs26
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.