383-Fall11-Lec11 - More Constraint Satisfaction"...

Info iconThis preview shows pages 1–11. Sign up to view the full content.

View Full Document Right Arrow Icon
1 CMPSCI 383 October 13, 2011 More Constraint Satisfaction
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2 Today ʼ s lecture A review of CSPs Local search for CSPs Taking advantage of the structure of the CSP Some applications
Background image of page 2
3 What defnes a CSP? In CSPs, states are defned by assignments oF values to a set oF variables X 1 ...X n . Each variable X i has a domain D i oF possible values. States are evaluated based on their consistency with a set oF constraints C 1 ...C m over the values oF the variables. A goal state is a complete assignment to all variables that satisfes all the constraints.
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
4 Local Consistency Node Consistency : satisfes all unary constraints Arc Consistency : satisfes all binary constraints Path Consistency : n-consistency : For any consistent assignment to any set oF n-1 variables, a consistent value can be Found For any n-th variable.
Background image of page 4
5 Arc Consistency Note: Not symmetric in general To make X ac with respect to Y, remove values from Dx To make Y ac with respect to X, remove values from Dy X is arc-consistent with respect to Y if for every value in Dx there is a value in Dy that satisFes the binary constraint on arc (X,Y).
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
6 Arc Consistency (slightly different from the book)
Background image of page 6
7 Standard Search Formulation Let's start with the straightforward approach, then fix it States are defined by the values assigned so far Initial state : the empty assignment { } Successor function : assign a value to an unassigned variable that does not conflict with current assignment fail if no legal assignments Goal test : the current assignment is complete 1. This is the same for all CSPs 2. Every solution appears at depth n with variables use depth-first search 3. Path is irrelevant, so can also use complete-state formulation 4. b = (n - k )d at depth k , hence n! · d n leaves (d is domain size)
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
8 Backtracking Search Variable assignments are commutative , i.e., [ WA = red then NT = green ] same as [ NT = green then WA = red ] Only need to consider assignments to a single variable at each node b = d and there are d n leaves Depth-first search for CSPs with single-variable assignments is called backtracking search Backtracking search is the basic uninformed algorithm for CSPs Can solve n -queens for 25
Background image of page 8
9 Backtracking Search (the book ʼ s)
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Improving backtracking efFciency Basic question: What next step should our search procedure take? Approaches
Background image of page 10
Image of page 11
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 52

383-Fall11-Lec11 - More Constraint Satisfaction"...

This preview shows document pages 1 - 11. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online