Com CompSci Sci 275, 75, CONSTRAI
ONSTRAINT Netw
Network
- rks
Rina Dechter, Fall 2020
Fall 2020 1
Com CompSci Sci 275, 75, C ONSTRAI ONSTRAINT Netw Network orks - - PowerPoint PPT Presentation
Com CompSci Sci 275, 75, C ONSTRAI ONSTRAINT Netw Network orks Rina Dechter, Fall 2020 Directional consistency Chapter 4 Fall 2020 1 Outline Arc consistency algorithms Path consistency and i consistency Arc
Fall 2020 1
Fall 2020 2
res((A V B),B) = A
Relational arc‐consistency rule = unit‐resolution
Fall 2020 3
Fall 2020 4
Fall 2020 7
3 , 10 , 7 3 ], 10 , 10 [ 5 , 10 ] 9 , 5 [ ], 5 , 1 [ 10 ], 15 , 5 [ ], 10 , 1 [ z y y x adding by
z x y consistenc path z y z y y x adding by y x y consistenc arc y x y x
Gausian elimination of Gausian Elinination of:
Fall 2020 8
Fall 2020 9
literal)
Fall 2020 10
What level of consistency will guarantee global‐consistency
Backtrack free and queries: Consistency, All solutions Counting
Fall 2020 11
Let’s explore how we can make a problem backtrack‐free with a minimal amount of effort
D4={white,blue,black} D3={red,white,blue} D2={green,white,black} D1={red,white,black} X1=x2, x1=x3, x3=x4
Fall 2020 12
) (
2
ek O
Fall 2020 13
Directional arc‐consistency may not be enough
Fall 2020 15
Not equal constraints Is it arc‐consistent?
Fall 2020 17
E D A C B
} 2 , 1 { } 2 , 1 { } 2 , 1 { } 2 , 1 { } 3 , 2 , 1 {
Fall 2020 18
R_CB = { (1,3)(2,3)} R_DB = {((1,1)(2,2)} R_DC = {(1,1)(2,2)(1,3)(2,3)}
Fall 2020 19
DPC recursively connects parents in the ordered graph, yielding Induced‐ordered graph:
induced graph: recursively connecting the parents from last to first
(Arnborg, 1985) but greedy heuristics (min‐fill). E D A C B
Fall 2020 21
Fall 2020 22
Fall 2020 23
induced‐width
Fall 2020 24
Fall 2020 25
d d w
along graph primal the
width induced the ) (
*
The effect of the ordering:
4 ) (
1 *
d w 2 ) (
2 *
d w
Primal (moraal) graph A D E C B B C D E A E D C B A
slides4 COMPSCI 2020
Fall 2020 27
Primal (moraal) graph A D E C B
Fall 2020 28
Fall 2020 29
Fall 2020 30
Fall 2020 31
Figure 4.5 The max-cardinality (MC) ordering procedure.
Fall 2020 32
We see again that G in Figure 4.1(a) is not chordal since the parents of A are not connected in the max‐cardinality
induced graph is chordal.
Fall 2020 33
Fall 2020 34
Fall 2020 35
) ( :
2
nk O complexity
Fall 2020 36
Fall 2020 37
Fall 2020 38
Fall 2020 39
Fall 2020 40
Bucket E: E D, E C Bucket D: D A Bucket C: C B Bucket B: B A Bucket A: A C contradiction
=
D = C B = A
=
Fall 2020 41
Fall 2020 42
d
: space ,
* * *
w (d))) exp(w O(n 1)) (d) exp(w O(n : Time
E D A C B
} 2 , 1 { } 2 , 1 { } 2 , 1 { } 2 , 1 { } 3 , 2 , 1 {
: ) ( A B : ) ( B C : ) ( A D : ) ( B E C, E D, E : ) ( A Bucket B Bucket C Bucket D Bucket E Bucket
A E D C B
: ) ( E B : ) ( E C , B C : ) ( E D : ) ( B A D, A : ) ( E Bucket B Bucket C Bucket D Bucket A Bucket
E A D C B
|| RD
BE ,
|| RE || RDB || RDCB || RACB || RAB RA RC
BE
Adaptive Consistency (Dechter & Pearl, 1987)
Fall 2020 43
project and join E variable Eliminate
EC DBC EB ED DBC
R R R R
3 value assignment
D B C RDBC
eliminating E
Fall 2020 44
Eliminate variables
“constraint propagation” Solution generation after elimination is backtrack-free
3
Fall 2020 45
(Arnborg, 1985)
max‐cardinality (Bertele and Briochi, 1972; Freuder 1982), Min‐fill.
Fall 2020 46
Adaptive consistency is linear for trees and equivalent to enforcing directional arc-consistency (recording only unary constraints)
Fall 2020 47
Fall 2020 48
Fall 2020 49
Fall 2020 50
Each row, column and major block must be alldifferent “Well posed” if it has unique solution: 27 constraints
2 3 4 6
2
Constraint propagation
{1,2,3,4,5,6,7,8,9}
Fall 2020 51
Each row, column and major block must be alldifferent “Well posed” if it has unique solution
Fall 2020 52