Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics1 Foundations of Constraint Processing CSCE421/821, Fall 2004: www.cse.unl.edu/~choueiry/F04-421-821/

Slides:



Advertisements
Similar presentations
Slides by Peter van Beek Edited by Patrick Prosser.
Advertisements

Constraint Satisfaction Problems Russell and Norvig: Chapter
Tree Clustering for Constraint Networks 1 Chris Reeson Advanced Constraint Processing Fall 2009 By Rina Dechter & Judea Pearl Artificial Intelligence,
Foundations of Constraint Processing Lookahead Schemas 1 Foundations of Constraint Processing CSCE421/821, Spring
This lecture topic (two lectures) Chapter 6.1 – 6.4, except
1 Constraint Satisfaction Problems A Quick Overview (based on AIMA book slides)
This lecture topic (two lectures) Chapter 6.1 – 6.4, except 6.3.3
1 Finite Constraint Domains. 2 u Constraint satisfaction problems (CSP) u A backtracking solver u Node and arc consistency u Bounds consistency u Generalized.
Constraint Satisfaction problems (CSP)
Review: Constraint Satisfaction Problems How is a CSP defined? How do we solve CSPs?
Constraint Satisfaction Problems
Artificial Intelligence Constraint satisfaction Chapter 5, AIMA.
Foundations of Constraint Processing, Fall 2005 November 16, 2005nFCi1 Foundations of Constraint Processing CSCE421/821, Fall 2005:
Foundations of Constraint Processing, Fall 2005 October 20, 2005Ordering heuristics1 Foundations of Constraint Processing CSCE421/821, Fall 2005:
Constraint Satisfaction Problems
Constraint Satisfaction
Foundations of Constraint Processing, Fall 2005 Sep 20, 2005BT: A Theoretical Evaluation1 Foundations of Constraint Processing CSCE421/821, Fall 2005:
1 Bandwidth Allocation Planning in Communication Networks Christian Frei & Boi Faltings Globecom 1999 Ashok Janardhanan.
Chapter 5 Outline Formal definition of CSP CSP Examples
MAC and Combined Heuristics: Two Reasons to Forsake FC (and CBJ?) on Hard Problems Christian Bessière and Jean-Charles Régin Presented by Suddhindra Shukla.
Foundations of Constraint Processing, Fall 2005 November 2, 2005Weak Commitment1 Foundations of Constraint Processing CSCE421/821, Fall 2005:
Foundations of Constraint Processing, Fall 2004 November 18, 2004More on BT search1 Foundations of Constraint Processing CSCE421/821, Fall 2004:
Constraint Satisfaction Problems
Constraint Satisfaction Problems
1 Constraint Satisfaction Problems Slides by Prof WELLING.
Distributed Constraint Optimization Michal Jakob Agent Technology Center, Dept. of Computer Science and Engineering, FEE, Czech Technical University A4M33MAS.
Artificial Intelligence CS482, CS682, MW 1 – 2:15, SEM 201, MS 227 Prerequisites: 302, 365 Instructor: Sushil Louis,
Problem Solving with Constraints Ordering heuristics1 Foundations of Constraint Processing CSCE496/896, Fall
Constraint Satisfaction Read Chapter 5. Model Finite set of variables: X1,…Xn Variable Xi has values in domain Di. Constraints C1…Cm. A constraint specifies.
Chapter 5 Section 1 – 3 1.  Constraint Satisfaction Problems (CSP)  Backtracking search for CSPs  Local search for CSPs 2.
CP Summer School Modelling for Constraint Programming Barbara Smith 2. Implied Constraints, Optimization, Dominance Rules.
Constraint Satisfaction CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Searching by Constraint CMSC Artificial Intelligence January 24, 2008.
Problem Solving with Constraints Lookahead Schemas 1 Foundations of Constraint Processing CSCE496/896, Fall
CSCI 5582 Fall 2006 CSCI 5582 Artificial Intelligence Fall 2006 Jim Martin.
1 Chapter 5 Constraint Satisfaction Problems. 2 Outlines  Constraint Satisfaction Problems  Backtracking Search for CSPs  Local Search for CSP  The.
Wednesday, January 29, 2003CSCE Spring 2003 B.Y. Choueiry Directional Consistency Chapter 4.
Algorithm Design Methods (II) Fall 2003 CSE, POSTECH.
Chapter 5 Constraint Satisfaction Problems
Review Test1. Robotics & Future Technology Future of Intelligent Systems / Ray Kurzweil futurist Ray Kurzweil / A Long Bet A Long Bet / Robot Soccer.
Foundations of Constraint Processing Ordering heuristics1 Foundations of Constraint Processing CSCE421/821, Spring
An Introduction to Artificial Intelligence Lecture 5: Constraint Satisfaction Problems Ramin Halavati In which we see how treating.
1 Constraint Satisfaction Problems Chapter 5 Section 1 – 3 Grand Challenge:
1. 2 Outline of Ch 4 Best-first search Greedy best-first search A * search Heuristics Functions Local search algorithms Hill-climbing search Simulated.
Foundations of Constraint Processing, Spring 2009 Structure-Based Methods: An Introduction 1 Foundations of Constraint Processing CSCE421/821, Spring 2009.
Foundations of Constraint Processing, Spring 2008 Feb 11, 2008 Ordering heuristics1 Foundations of Constraint Processing CSCE421/821, Spring 2008:
Computing & Information Sciences Kansas State University Friday, 08 Sep 2006CIS 490 / 730: Artificial Intelligence Lecture 7 of 42 Friday, 08 September.
Foundations of Constraint Processing Constraint Graphical Models 1Odds & Ends Foundations of Constraint Processing CSCE421/821, Fall
ARTIFICIAL INTELLIGENCE (CS 461D) Dr. Abeer Mahmoud Computer science Department Princess Nora University Faculty of Computer & Information Systems.
Lecture 7 Constraint Satisfaction Problems
Rationale & Strategies Foundations of Constraint Processing
Foundations of Constraint Processing
Extensions to BT Search Foundations of Constraint Processing
Extensions to BT Search Foundations of Constraint Processing
Foundations of Constraint Processing
Structure-Based Methods Foundations of Constraint Processing
Foundations of Constraint Processing All questions to Piazza
Rationale & Strategies Foundations of Constraint Processing
Extensions to BT Search Foundations of Constraint Processing
Lookahead Schemas Foundations of Constraint Processing
Extensions to BT Search Foundations of Constraint Processing
Constraints and Search
Intelligent Backtracking Algorithms: A Theoretical Evaluation
Constraint Satisfaction Problems. A Quick Overview
Rationale & Strategies Foundations of Constraint Processing
Foundations of Constraint Processing All questions to Piazza
Constraint Satisfaction
Extensions to BT Search Foundations of Constraint Processing
Directional consistency Chapter 4
Constraint Satisfaction Problems
Presentation transcript:

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics1 Foundations of Constraint Processing CSCE421/821, Fall 2004: Berthe Y. Choueiry (Shu-we-ri) Avery Hall, Room 123B Tel: +1(402) Search Orders in CSPS

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics2 Context – Finite domains – Binary constraints Required reading –Chapter 6 of Tsang’s book (web accessible) Recommended reading –Dual viewpoint heuristics for binary Constraint Satisfaction Problems [Geelen, ECAI 92] In my experience the most powerful, but also the most costly (require lots of constraint checks)

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics3 Motivation for ordering heuristics In BT, fewer backtracks under some orderings than others In Lookahead, –Failure can be detected earlier under some orderings than others When searching for one solution, value ordering may speed up search as branched that have a better chance to reach a solution are explored first Dynamic ordering often remove the need for intelligent backtracking (personal experience)

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics4 Value ordering: get quickly to a solution Min-conflict heuristic: orders values according to the conflicts in which they are involved with the future variables (most popular) [Minton] Cruciality [Keng & Yu ’89] Promise (most powerful) [Geelen ’92] Etc.

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics5 Variable Ordering: Fail-first principle Recognize dead-ends ASAP to save search effort Terminology is historic, currently contested If you are on –a correct path, stay on it –an incorrect path, fail on it Problem: –How to guess whether a path is correct? Advice: –choose the ordering that reduces the branching factor, the enemy of search..

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics6 Variable ordering heuristics Least domain (LD), a.k.a. smallest domain first Minimal width ordering (MWO) Minimal bandwidth ordering (BBO) Maximal cardinality ordering (MCO) Minimal degree first (degree) Minimal ratio domain size over degree (DD) Etc. In general: –Cheap and effective –Suitable for both static and dynamic ordering

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics7 Width of a graph A graph-theoretic criterion Constraint graph Ordering of nodes how many possible orderings? Width of an ordering Width of the graph (independent of the ordering)

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics8 Minimal width ordering Reduces the chance of backtracking: Variables at the front of the ordering are in general more constrained Variables that have more variables depending on them are labeled first Finding minimum width ordering: O(n 2 ) A B C D G F E Compute width of A, B, C, D, E, F, G Compute width of G, F, E, D, C, B, A

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics9 Procedure: Width or a graph G Remove from the graph all nodes not connected to any others Set k  0 Do while there are nodes left in the graph –Set k  (k+1) –Do While there are nodes not connected to more than k others Remove such nodes from the graph, along with any edges connected to them Return k The minimal width ordering of the nodes is obtained by taking the nodes in the reverse order than they were removed

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics10 Variations on MWO 1.When removing a node, add a fill-in edge between every two nodes connected to the node but not connected between themselves 2.Remove the node that, after removal, yields the smallest number of fill-in edges 3.Etc.

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics11 Minimal bandwidth ordering Localizes/confines backtracking: The smaller the bandwidth, the sooner one could backtrack to relevant decisions Finding minimum bandwidth ordering is NP- hard  Is there an ordering of a given bandwidth k? –O(n k+1 ), i.e. polynomial

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics12 Maximal cardinality ordering An approximation of min. width ordering Choose a node arbitrarily Among the remaining nodes, choose the one that is connected to the maximum number of already chosen nodes, break ties arbitrarily Repeat… Reverse the final order

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics13 Ordering heuristics: how, when? How –Static variable, value ordering –Dynamic variable (static value) –Dynamic variable, dynamic value (dynamic vvp) When –Finding one solution –Finding all solutions

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics14 Search & ordering heuristics At a given level h of the search tree, we encounter:

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics15 Static variable, static value vvps pertaining to the same variable across a given level

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics16 Dynamic variable, static value vvps pertaining to the same variable for nodes with a common parent, but possibly to different variables for nodes with different parents

Foundations of Constraint Processing, Fall 2004 November 8, 2004Ordering heuristics17 Dynamic vvp vvps pertaining to different variables