1 / 12

CSP Search Techniques

CSP Search Techniques. Backtracking Forward checking Partially Look Ahead Fully look Ahead Back Checking Back Marking Modified Forward checking. Q. BT. Q. Q. Q. Q. Q. Q. Q. Q. Q. Q. Q. BT. Q. BT. Q. Q. Q. BT. BT. BT. BT. Q. Q. Q. Q. Q. Q. Q. BT. Q. BT. Q.

kinac
Download Presentation

CSP Search Techniques

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CSP Search Techniques • Backtracking • Forward checking • Partially Look Ahead • Fully look Ahead • Back Checking • Back Marking • Modified Forward checking

  2. Q • BT • Q • Q • Q • Q • Q • Q • Q • Q • Q • Q • Q • BT • Q • BT • Q • Q • Q • BT • BT • BT • BT • Q • Q • Q • Q • Q • Q • Q • BT • Q • BT • Q • Q • Q • Q • BT • BT • Q • BT • Q • Q • Q • Q • BT • Q • Q • Q • Q • Q Backtracking

  3. Problems with backtracking • Thrashing: keep repeating the same failed variable assignments • Consistency checking can help • Intelligent backtracking schemes can also help • Inefficiency: can explore areas of the search space that aren’t likely to succeed • Variable ordering can help

  4. Q • BT • Q • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • BT • BT • Q • BT • Q • Q • Q • Q • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • BT • FC • FC • Q • Q • FC • Q • FC • Q • Q • FC • FC • Q • Q • FC • FC • FC • FC • FC • Q • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • Q • FC • FC • FC • FC • FC • FC • Q • FC • FC • BT • Q • FC • FC • FC • FC • FC • FC Forward Checking

  5. Q • BT • Q • FC • FC • FC • PL • FC • FC • FC • PL • FC • FC • FC • FC • FC • FC • Q • BT • BT • BT • Q • Q • Q • FC • FC • FC • FC • FC • FC • FC • FC • PL • FC • FC • FC • Q • FC • Q • Q • FC • Q • FC • Q • FC • Q • FC • FC • FC • PL • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • Q • FC • FC • FC • FC Partially Look Ahead

  6. Q • BT • Q • FC • FC • FC • FL • FC • FC • FC • FL • FC • FL • FC • FC • FC • FC • FC • BT • BT • BT • Q • Q • Q • FC • FC • FC • FC • FC • FC • FC • FC • FC • Q • FC • Q • FC • Q • FC • Q • Q • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • FC • Q • FC • FC • FC Fully Look Ahead

  7. Rest of CLP Search Techniques • Back Checking: • Remembering Previous failures • Back Marking: • Remembering Previous failures and successes • Modified Forward Checking: • Representing constraints as bit patterns and using AND/OR operations to test the patterns

  8. K-Satisfiablity • A CLP Problem with n variables is K-satisfiable, (k < = n), if for every subset of K variables, there exists a k-label (values for k variables) that satisfies all the problem constraints • If a problem is k-satisfiable, then it is also k-1 satisfiable, too.

  9. Consistency • Node consistency • A node X is node-consistent if every value in the domain of X is consistent with X’s unary constraints • A graph is node-consistent if all nodes are node-consistent • Arc consistency • An arc (X, Y) is arc-consistent if, for every value x of X, there is a value y for Y that satisfies the constraint represented by the arc. • A graph is arc-consistent if all arcs are arc-consistent • To create arc consistency, we perform constraint propagation: that is, we repeatedly reduce the domain of each variable to be consistent with its arcs

  10. K-consistency • K- consistency generalizes the notion of arc consistency to sets of more than two variables. • A graph is K-consistent if, for legal values of any K-1 variables in the graph, and for any Kth variable Vk, there is a legal value for Vk • Strong K-consistency = J-consistency for all J<=K • Node consistency = strong 1-consistency • Arc consistency = strong 2-consistency • Path consistency = strong 3-consistency

  11. Width of a constraint graph • We can have different orderings of a constraint graph • The number of backward arcs of a node, in an specific ordering, is called the node’s width • An ordering width is the maximum width of its nodes • A graph width is the minimum width of its different orderings

  12. Why do we care? • If the width of the constraint graph of a CSP is D and it is strongly K-consistent, then if K > D, we can solve the CSP without backtracking, if we use an appropriate variable ordering (i.e., one with Minimal width ordering)

More Related