383-Fall11-Lec11

# 383-Fall11-Lec11 - More Constraint Satisfaction CMPSCI 383...

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

1 CMPSCI 383 October 13, 2011 More Constraint Satisfaction

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

View Full Document
2 Today ʼ s lecture A review of CSPs Local search for CSPs Taking advantage of the structure of the CSP Some applications
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.

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

View Full Document
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.
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).

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

View Full Document
6 Arc Consistency (slightly different from the book)
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)

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

View Full Document
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
9 Backtracking Search (the book ʼ s)

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

View Full Document
Improving backtracking efFciency Basic question: What next step should our search procedure take? Approaches
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 11/29/2011 for the course COMPSCI 383 taught by Professor Andrewbarto during the Fall '11 term at UMass (Amherst).

### Page1 / 52

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

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

View Full Document
Ask a homework question - tutors are online