Constraint Satisfaction Problems
Berlin Chen 2004
References:
- 1. S. Russell and P. Norvig. Artificial Intelligence: A Modern Approach. Chapter 5
- 2. S. Russell’s teaching materials
Constraint Satisfaction Problems Berlin Chen 2004 References: 1. S. - - PowerPoint PPT Presentation
Constraint Satisfaction Problems Berlin Chen 2004 References: 1. S. Russell and P. Norvig. Artificial Intelligence: A Modern Approach . Chapter 5 2. S. Russells teaching materials Introduction Standard Search Problems State is a
AI 2004 – Berlin Chen 2
Derive heuristics without domain-specific knowledge
AI 2004 – Berlin Chen 3
AI 2004 – Berlin Chen 4
AI 2004 – Berlin Chen 5
AI 2004 – Berlin Chen 6
AI 2004 – Berlin Chen 7
AI 2004 – Berlin Chen 8
AI 2004 – Berlin Chen 9
AI 2004 – Berlin Chen 10
AI 2004 – Berlin Chen 11
absolute constraints
AI 2004 – Berlin Chen 12
constraint
C1 C2 C3 C4 C5 C1 C2 C3 C4 C5 auxiliary variable
AI 2004 – Berlin Chen 13
nd (n-1)d (n-1)d (n-2)d (n-2)d nd n(n-1)d2 n!dn Depth=n
Initial state: empty assignment {} Successor function: a value can be assigned to any unassigned variables, provided that no conflict occurs Goal test: the assignment is complete
Totally, dn distinct leaf nodes (because of commutativity) n(n-1) (n-2)d3 Variables (n) and Values (d)
AI 2004 – Berlin Chen 14
AI 2004 – Berlin Chen 15
AI 2004 – Berlin Chen 16
decide which variable decide which value
AI 2004 – Berlin Chen 17
AI 2004 – Berlin Chen 18
AI 2004 – Berlin Chen 19
AI 2004 – Berlin Chen 20
5 3 3 3 2 2 5 3 3 2 3 2 2 2 1 2 1 1 2 1 1 1
AI 2004 – Berlin Chen 21
Allow 1 value for SA Allow 0 value for SA
AI 2004 – Berlin Chen 22
AI 2004 – Berlin Chen 23
AI 2004 – Berlin Chen 24
Note: MRV, degree heuristic etc., were not used here after WA=red after Q=green
AI 2004 – Berlin Chen 25
after V=blue
AI 2004 – Berlin Chen 26
AI 2004 – Berlin Chen 27
AI 2004 – Berlin Chen 28
AI 2004 – Berlin Chen 29
If some values of a nodes Xi is removed, arcs pointing to it must be reinserted on the queue for checking again O(d2) O(n2) O(d)
AI 2004 – Berlin Chen 30
AI 2004 – Berlin Chen 31
AI 2004 – Berlin Chen 32
AI 2004 – Berlin Chen 33
AI 2004 – Berlin Chen 34
initialization (randomly generated or …) randomly select a variable select the value of the variable with minimum conflicts
AI 2004 – Berlin Chen 35
AI 2004 – Berlin Chen 36
AI 2004 – Berlin Chen 37
AI 2004 – Berlin Chen 38
AI 2004 – Berlin Chen 39
O(dc) O((n-c)d2)
AI 2004 – Berlin Chen 40
solutions agree with the shared variables