Summary. Acyclic Networks Join Tree Clustering. Tree Decomposition Methods. Acyclic Network. Tree Based Clustering. Tree Decomposition.

Similar documents
Acyclic Network. Tree Based Clustering. Tree Decomposition Methods

Acyclic Network. Tree Based Clustering. Tree Decomposition Methods

Constraint Optimisation Problems. Constraint Optimisation. Cost Networks. Branch and Bound. Dynamic Programming

Class2: Constraint Networks Rina Dechter

A Comparison of Structural CSP Decomposition Methods

Class 2 Constraint Networks

Belief propagation in a bucket-tree. Handouts, 275B Fall Rina Dechter. November 1, 2000

Graph and Digraph Glossary

These notes present some properties of chordal graphs, a set of undirected graphs that are important for undirected graphical models.

Constraint Solving by Composition

Graph Theory. Probabilistic Graphical Models. L. Enrique Sucar, INAOE. Definitions. Types of Graphs. Trajectories and Circuits.

University of Alberta

REU Problems of the Czech Group

CS242: Probabilistic Graphical Models Lecture 2B: Loopy Belief Propagation & Junction Trees

Constraint Satisfaction Problems

Last course. Last course. Michel Habib 28 octobre 2016

Reducing redundancy in the hypertree decomposition scheme

Index. C cmp;l, 126. C rq;l, 127. A A sp. B BANDWIDTH, 32, 218 complexity of, 32 k-bandwidth, 32, 218

Graphs and Network Flows IE411. Lecture 21. Dr. Ted Ralphs

Problem set 2. Problem 1. Problem 2. Problem 3. CS261, Winter Instructor: Ashish Goel.

Complexity Results on Graphs with Few Cliques

Search Algorithms for Solving Queries on Graphical Models & the Importance of Pseudo-trees in their Complexity.

Chordal graphs MPRI

arxiv: v1 [math.co] 20 Nov 2018

Applied Mathematics Letters. Graph triangulations and the compatibility of unrooted phylogenetic trees

Graphs: Introduction. Ali Shokoufandeh, Department of Computer Science, Drexel University

Enumeration of Perfect Sequences in Chordal Graphs

Constraint Satisfaction Problems

!!" '!" Fall 2003 ICS 275A - Constraint Networks 2

The 3-Steiner Root Problem

Conflict Graphs for Combinatorial Optimization Problems

Junction Trees and Chordal Graphs

Chordal Graphs: Theory and Algorithms

CS6702 GRAPH THEORY AND APPLICATIONS 2 MARKS QUESTIONS AND ANSWERS

Lecture 11: May 1, 2000

CIS-331 Fall 2013 Exam 1 Name: Total of 120 Points Version 1

The External Network Problem

Decreasing a key FIB-HEAP-DECREASE-KEY(,, ) 3.. NIL. 2. error new key is greater than current key 6. CASCADING-CUT(, )

Read-Once Functions (Revisited) and the Readability Number of a Boolean Function. Martin Charles Golumbic

On 2-Subcolourings of Chordal Graphs

Approximation Algorithms for Geometric Intersection Graphs

Consistency Enforcing and Constraint. Propagation: Path consistency and. i-consistency. i-consistency. Path. Consistency.

Some new results on circle graphs. Guillermo Durán 1

Lecture 13: May 10, 2002

Junction Trees and Chordal Graphs

Geometric Steiner Trees

The problem of minimizing the elimination tree height for general graphs is N P-hard. However, there exist classes of graphs for which the problem can

CIS-331 Exam 2 Fall 2015 Total of 105 Points Version 1

CIS-331 Spring 2016 Exam 1 Name: Total of 109 Points Version 1

Thinking Outside the Graph

Massachusetts Institute of Technology Department of Electrical Engineering and Computer Science Algorithms For Inference Fall 2014

PROBLEM SOLVING AND SEARCH IN ARTIFICIAL INTELLIGENCE

ALGORITHMS FOR DECISION SUPPORT

Solving NP-hard Problems on Special Instances

Steiner Trees and Forests

Unifying Cluster-Tree Decompositions for Automated Reasoning. Kalev Kask, Rina Dechter and Javier Larrosa

9 About Intersection Graphs

A generic framework for solving CSPs integrating decomposition methods

CS388C: Combinatorics and Graph Theory

Foundations of Artificial Intelligence

Lex-BFS and partition renement, with applications to transitive orientation, interval graph recognition and consecutive ones testing

Interaction Between Input and Output-Sensitive

The minimum cost spanning tree problem

PART 1 GRAPHICAL STRUCTURE

28.1 Decomposition Methods

Notes on Minimum Cuts and Modular Functions

MATH 350 GRAPH THEORY & COMBINATORICS. Contents

Constraint Satisfaction Problems. Chapter 6

Characterizations of graph classes by forbidden configurations

Minimal Dominating Sets in Graphs: Enumeration, Combinatorial Bounds and Graph Classes

Practice Final Exam 1

Kernelization Upper Bounds for Parameterized Graph Coloring Problems

NEW ALGORITHMIC AND HARDNESS RESULTS ON GRAPH PARTITIONING PROBLEMS

Class2: Constraint Networks Rina Dechter

Lars Schmidt-Thieme, Information Systems and Machine Learning Lab (ISMLL), University of Hildesheim, Germany, Course on Artificial Intelligence,

CIS-331 Exam 2 Fall 2014 Total of 105 Points. Version 1

Computational Discrete Mathematics

Graph Theory. ICT Theory Excerpt from various sources by Robert Pergl

EE512 Graphical Models Fall 2009

An Extension of Complexity Bounds and Dynamic Heuristics for Tree-Decompositions of CSP

RS 232 PINOUTS. 1. We use RJ12 for all of our RS232 interfaces (Link-2-Modbus & Link-2-PC- Serial/RS232). The diagram below shows our pin out.

GEOMETRY BASIC GEOMETRICAL IDEAS. 3) A point has no dimensions (length, breadth or thickness).

V10 Metabolic networks - Graph connectivity

On Covering a Graph Optimally with Induced Subgraphs

Decomposition of log-linear models

Introduction to Combinatorial Algorithms

ORF 307: Lecture 14. Linear Programming: Chapter 14: Network Flows: Algorithms

6 : Factor Graphs, Message Passing and Junction Trees

Minimum-Spanning-Tree problem. Minimum Spanning Trees (Forests) Minimum-Spanning-Tree problem

Computing optimal total vertex covers for trees

Let G = (V, E) be a graph. If u, v V, then u is adjacent to v if {u, v} E. We also use the notation u v to denote that u is adjacent to v.

Theorem 2.9: nearest addition algorithm

Introduction to Graph Theory

9. Parameter Treewidth

4. Specifications and Additional Information

Computing Pure Nash Equilibria in Symmetric Action Graph Games

Minimum cost spanning tree

A Decomposition for Chordal graphs and Applications

Enumerating the decomposable neighbours of a decomposable graph under a simple perturbation scheme

Constraint Satisfaction Problems Part 2

Transcription:

Summary s Join Tree

Importance of s Solving Topological structure denes key features for a wide class of problems CSP: Inference in acyclic network is extremely ecient (polynomial) Idea: remove cycles from the network somehow We can always compile a cyclic graph into an acyclic tree-like structure We always pay a price in term of computational complexity The price we pay depends on the topological structure Graph Concept: Brief Review Hypergraphs Hypergraphs: H = (V, S) Vertices: V = {v 1,, v n } Hyperegdes: S = {S 1,, S k } where S i V Example (Hypergraph) V = {A, B, C, D, E, F } S = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}}

Graph Concept: Brief Review Primal Graph Primal Graph of a Hypergraph Nodes Vertices Two nodes connected i they appear in the same hyperedge For binary contraint networks, Hypergraph and Primal graph are identical Example (Primal Graph) V = {A, B, C, D, E, F } E = {{A, B}{A, C}{B, C}{A, E}{A, F } {E, F }{C, D}{C, E}{D, E}} Graph Concept: Brief Review Dual Graph Dual Graph of a Hypergraph Nodes Hyperedges Two nodes connected i they share at least one vertex Edges are labeled by the shared vertices Example (Dual Graph) V = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}} E = {{{A, E, F }{A, B, C}}{{A, E, F }, {C, D, E}} {{A, E, F }, {A, C, E}}{{A, B, C}, {C, D, E}} {{C, D, E}, {A, C, E}}{{A, B, C}, {A, C, E}}}

Constraint s and Graph Representation Graph for Constraint s Any constraint network can be associated with a hypergraph Contraint network R = {X, D, C} with C = {R S 1,, R S r } Hypergraph H R = (X, H) where H = {S 1,, S r } Dual Graph H d R = (H, E) where < S i, S j > E i S i S j { } Dual Problem R d = {H, D, C } D = {D 1,, D }, D set of tuples accepted by R r i Si C = {C 1,, C }, C =< S k k i, S j >, enforces equality for the set variables X k = S i S j ity of Constraint If the graph representation of a problem is acyclic then we can solve problem eciently Even cyclic graphs can have a tree-like structure relative to solution techniques Some arcs could be redundant In general it is hard to recognise redundant constraints

ity of Dual Problem Redundant Constraints for Dual Problems For the dual graph representation checking whether a constraint is redundant is actually easy All constraints force equality over shared variables A constraint and its corresponding arc can be deleted if the variables labeling the arc are contained in any alternative path between the two endpoints Because the constraint will be enforced by the other paths. This property is called running intersection or connectedness Example: ity of Dual Problem Example ( Dual Problem) Consider this dual graph: V = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}} E = {{{A, E, F }{A, B, C}}{{A, E, F }, {C, D, E}} {{A, E, F }, {A, C, E}}{{A, B, C}, {C, D, E}} {{C, D, E}, {A, C, E}}} We can remove redundant constraints: {{A, E, F }{A, B, C}} because the alternative path (AEF ) AE (ACE ) AC (ABC ) enforce constraint on A {{A, E, F }{C, D, E}} because the alternative path (AEF ) AE (ACE ) CE (CDE ) enforce constraint on E {{C, D, E}{A, B, C}} because the alternative path (CDE ) CE (ACE ) AC (ABC ) enforce constraint on C The remaining structure is a tree

Main Concepts Arc Subgraph of a graph G = {V, E}: any graph G = {V, E } such that E E Running Intersection property: G dual graph of an hypergraph, G an arc subgraph satises the running intersection properties if given any two nodes of G that share a variable, there exists a path of labeled arcs, each containing the variable. Join Graph: an arc subgraph of the dual graph that satises the running intersection properties Join Tree: an acyclic join graph Hypertree: a Hypergraph whose dual graph has a join tree : a network whose hypergraph is an hypertree Solving Algorithm for Solving Algorithm 1 Tree Solver Require: An Constraint R, A join-tree T of R Ensure: Determine consistency and generate a solution d = {R 1,, R r } order induced by T (from root to leaves) for all j = r to 1 and for all edges < j, k > in the T with k < j do R k π Sk (R K R j ) if we nd the empty relation then end if end for EXIT and state the problem has NO SOLUTION Select a tuple in R 1 for all i = 2 to r do Select a tuple that is consistent with all previous assigned tuples R 1,, R i 1 end for return The problem is CONSISTENT return the selected SOLUTION

Example: Solving Problem Example (Applying Tree Solver) Consider this join-tree: V = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}} E = {{{A, E, F }, {A, C, E}}{{C, D, E}, {A, C, E}} {{A, B, C}, {A, C, E}}} Assume constraints are given by R ABC = R AEF = {(0, 0, 1)(0, 1, 0)(1, 0, 0)} R CDE = R ACE = {(1, 1, 0)(0, 1, 1)(1, 0, 1)} d = {R ACE, R CDE, R AEF, R ABC } Recognising s Main methods To apply the tree solver algorithm we need to know whether a network is acyclic This can not be decided simply by checking whether there are cycles in the primal or dual graph Two main methods Dual based Recognition Primal based Recognition

Dual Based Recognition Dual Based Recognition: Theoretical Result Maier 1983 If a hypergraph has a join tree then any maximum spanning tree of its dual graph is a join tree Weight of the arc are the number of shared variables Dual Based Recognition: Procedure Main idea Build the dual graph of the hypergraph Compute a maximum spanning tree (weight = number of shared variables) Check whether the hypertree is a join tree Ecient because there is only one path for each couple of nodes

Dual Based Recognition: algorithm Dual ity Algorithm 2 Dualicty Require: A hypergraph H R = (X, S) of a constraint network R = (X, D, C) Ensure: A join tree T = (S, E) of H R if R is acyclic T = (S, E) generate a maximum spanning tree of the weighted dual constraint graph of R for all couples u, v where u, v S do if the unique path connecting them in T does not satisfy the running intersection property then EXIT (R is not acyclic) end if end for return R is acyclic and T is a join tree Dual Based Recognition: Example Example (Dual Based Recognition) Consider this dual graph: V = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}} E = {{{A, E, F }{A, B, C}}{{A, E, F }, {C, D, E}} {{A, E, F }, {A, C, E}}{{A, B, C}, {C, D, E}} {{C, D, E}, {A, C, E}}} If we nd a MST weighting edges with number of shared variables we obtain T : V = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}} E = {{{A, E, F }, {A, C, E}}{{C, D, E}, {A, C, E}} {{A, B, C}, {A, C, E}}} Which satises the running intersection property.

Primal Based Recognition Primal Based Recognition: main concepts A hypergraph has a join tree i its primal graph is chordal and conformal [Maier 1983] Conformal A primal graph is conformal to a hypergraph if there is a one to one mapping between maximal cliques and scopes of constraints Chordal A primal graph is chordal if every cycle of length at least 4 has a chord (an edge connecting two vertices that are non adjacent in the cycle) Checking whether a graph is chordal and conformal can be done eciently using a max-cardinality order Primal Based Recognition using max cardinality order max cardinality order max-cardinality order is an ordering over vertices such that: rst node is chosen arbitrarily then the node that is connected to a maximal number of already ordered nodes is selected (breaking ties arbitrarily) Chordal Graph if in a max-cardinality order each vertex and all its ancestors form a clique Find Maximal clique just list nodes in the order and consider each node ancestors

Primal Based Recognition: Procedure Main idea 1 build a max-cardinality order 2 Test whether the graph is chordal use the max-cardinality order check if ancestors form a clique 3 Test whether the graph is conformal use the max-cardinality order extract maximal cliques, check conformality Primal Based Recognition: algorithm Primal ity Algorithm 3 Primalicty A constraint network R = (X, D, C) and its primal graph G A join tree T = (S, E) of H R if R is acyclic Build d m = {x1,, xn} max-cardinality order Test Chordality using d m : Require: Ensure: for all i = n to 1 do end for if the ancestors of x i are not all connected then EXIT (R is not acyclic) end if Test Conformality using d m : ancestors) for all i = r to 1 do if C i corresponds to scope of one constraints C then (R is acyclic) else end if EXIT (R is not acyclic) Let {C1,, Cr } be the maximal cliques (a node and all its end for Create a join tree of the cliques (e.g., create a maximum spanning tree were weights are number of shared variables) return R is acyclic and T is a join tree

Example: Primal based recognition Example (Primal based recognition) Consider this hypergraph V = {A, B, C, D, E, F } S = {{A, E, F }{A, B, C}{C, D, E}{A, C, E}} decide whether this constraint network is acyclic using the primal based recongition procedure. Compiling network to tree-like structures Aim: Compile network to acyclic structure Solve the acyclic structure eciently using a tree-solver alg. : grouping subsets of constraints to form a tree-like structure Solve each subproblem (replace the set of relations with the solution of the problem) Solve the acyclic network If all steps are tractable this process is very ecient

Approaches Join Tree Given a constraint network Computes an acyclic equivalent constraint problem Cluster Tree Elimination More general scheme Given a Combine the acyclic problem solving with subproblem solution Join Tree I Basic Concept Input: Hypergraph H = {X, H}, H set of scopes of constraints Output: Hypertree S = {X, S}, and a partition of the original relations (Hyperedges) into the new hypertree edges S each edge denes a subproblem containing a constraint if its scope is contained in the hyperedge Each subproblem is solved independently Each subproblem is replaced with one constraint that has the scope of the hyperedges and accepts the solution tuples of the subproblem The smaller the hyperdge size, the better.

Join Tree II Basic Steps 1 Choose an order of variable 2 Create an induced graph given the ordering to ensure the running intersection property 3 Create a join tree Identify all maximal cliques in the induced graph C 1,, C t Create a tree structure T over the cliques (e.g., create a maximum spanning tree were weights are number of shared variables) 4 Allocate constraints to any clique that contains its scope (P i subproblem associated with C i ). 5 Solve each P i with R i its set of solutions 6 Return C = {R 1,, R t} Induced graph Induced Graph and Induced Width Given graph G :< V, E > and order d over V Ancestors: neighbours that precedes the vertices in the ordering G induced graph of G over d is obtained by: process variables from last to rst when processing v, add edges to connect all ancestors of v The width of a node is the number of ancestors of the node The width of a graph is the maximal width of its nodes The induced width w (d) of G given d is the width of G The induced width w of G is minimum induced width over all possible orderings

Induced Graph and chordality Induced Graph and chordality A graph is chordal i it has a perfect elimination ordering [Fulkerson and Gross 1965] Perfect elimination ordering: ordering of the vertices such that, for each vertex v, v and its ancestors form a clique An induced graph < G, d > is chordal: d is a perfect elimination ordering for G Example Example (Creating the join tree) Consider the following graph and assume it is a primal graph of binary contraint newtork: Variables: A, B, C, D, E, F Edges: (A, B)(A, C)(A, E)(B, E)(B, D)(C, D)(D, F ) Consider the orderings d 1 = F, E, D, C, B, A d 2 = A, B, C, D, E, F

Example contd. Example (Creating the join tree) The resulting join trees are: d 1 Cliques: Q 1 = (A, B, C, E), Q 2 = (B, C, D, E), Q 3 = (D, E, F ) Edges: < Q 1, Q 2 >, < Q 2, Q 3 > d 1 Cliques: Q 1 = (D, F ), Q 2 = (A, B, E), Q 3 = (B, C, D), Q 4 = (A, B, C) Edges: < Q 1, Q 3 >, < Q 2, Q 4 >, < Q 3, Q 4 > Creating the chordal graph max-cardinality order Creating the chordal graph using a max-cardinality order is more ecient do not add useless edges if graph is already chordal

Ensuring the graph is conformal conformality When nding the maximal cliques we might violate conformality could create maximal cliques that have no mapping to constraints Conformality is enforced in later steps by creating a unique constraint for each sub problem Complexity of JTC Complexity The running time of join tree clustering is dominated by computing the set of solutions of each sub problem This is exponential in the size of the clique Running time is dominated by running time to solve the subproblem of the maximal clique Size of maximal cliques is the induced width of the graph plus one The order used to compute the cliques is crucial Finding the best ordering is hard

Finding a Complete Solution Constraint Propagation Once we have solved the subproblems we still need to force arc-consisteny expand local solution to a global solution (if problem is consistent) We can use Tree-Solver for this Exercise: Finding a Complete Solution Tree Solving Consider the following contraint network Variables: A, B, C, D, E, F Domains: id i = {0, 1} Constraints: (A B)(A C)(A E)(B = E) (B D)(C D)(D F ) Solve this constraint network using the JTC algorithm using the following orderings d 1 = F, E, D, C, B, A d 2 = A, B, C, D, E, F