1 Backdoor Sets in SAT Instances Ryan Williams Carnegie Mellon University Joint work in IJCAI03 with: Carla Gomes and Bart Selman Cornell University.

Slides:



Advertisements
Similar presentations
Constraint Satisfaction Problems
Advertisements

1 Constraint Satisfaction Problems A Quick Overview (based on AIMA book slides)
CPSC 422, Lecture 21Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 21 Mar, 4, 2015 Slide credit: some slides adapted from Stuart.
IBM Labs in Haifa © 2005 IBM Corporation Adaptive Application of SAT Solving Techniques Ohad Shacham and Karen Yorav Presented by Sharon Barner.
Review: Constraint Satisfaction Problems How is a CSP defined? How do we solve CSPs?
Dynamic Restarts Optimal Randomized Restart Policies with Observation Henry Kautz, Eric Horvitz, Yongshao Ruan, Carla Gomes and Bart Selman.
Tradeoffs in Backdoors: Inconsistency Detection, Dynamic Simplification, and Preprocessing Bistra Dilkina, Carla Gomes, Ashish Sabharwal Cornell University.
4 Feb 2004CS Constraint Satisfaction1 Constraint Satisfaction Problems Chapter 5 Section 1 – 3.
Statistical Regimes Across Constrainedness Regions Carla P. Gomes, Cesar Fernandez Bart Selman, and Christian Bessiere Cornell University Universitat de.
CP Formal Models of Heavy-Tailed Behavior in Combinatorial Search Hubie Chen, Carla P. Gomes, and Bart Selman
08/1 Foundations of AI 8. Satisfiability and Model Construction Davis-Putnam, Phase Transitions, GSAT Wolfram Burgard and Bernhard Nebel.
Heavy-Tailed Behavior and Search Algorithms for SAT Tang Yi Based on [1][2][3]
CPSC 322, Lecture 12Slide 1 CSPs: Search and Arc Consistency Computer Science cpsc322, Lecture 12 (Textbook Chpt ) January, 29, 2010.
1 CSE 417: Algorithms and Computational Complexity Winter 2001 Lecture 21 Instructor: Paul Beame.
Ryan Kinworthy 2/26/20031 Chapter 7- Local Search part 1 Ryan Kinworthy CSCE Advanced Constraint Processing.
Constraint Satisfaction Problems
The Theory of NP-Completeness
Master Class on Experimental Study of Algorithms Scientific Use of Experimentation Carla P. Gomes Cornell University CPAIOR Bologna, Italy 2010.
Analysis of Algorithms CS 477/677
1 Backdoors To Typical Case Complexity Ryan Williams Carnegie Mellon University Joint work with: Carla Gomes and Bart Selman Cornell University.
Carla P. Gomes CS4700 CS 4700: Foundations of Artificial Intelligence Carla P. Gomes Module: Randomization in Complete Tree Search.
Carla P. Gomes CS4700 CS 4700: Foundations of Artificial Intelligence Carla P. Gomes Module: Instance Hardness and Phase Transitions.
Accelerating Random Walks Wei Wei and Bart Selman Dept. of Computer Science Cornell University.
CP-AI-OR-02 Gomes & Shmoys 1 The Promise of LP to Boost CSP Techniques for Combinatorial Problems Carla P. Gomes David Shmoys
1 CS 4700: Foundations of Artificial Intelligence Carla P. Gomes Module: Satisfiability (Reading R&N: Chapter 7)
Chapter 5 Outline Formal definition of CSP CSP Examples
Ryan Kinworthy 2/26/20031 Chapter 7- Local Search part 2 Ryan Kinworthy CSCE Advanced Constraint Processing.
1 Combinatorial Problems in Cooperative Control: Complexity and Scalability Carla Gomes and Bart Selman Cornell University Muri Meeting March 2002.
Hardness-Aware Restart Policies Yongshao Ruan, Eric Horvitz, & Henry Kautz IJCAI 2003 Workshop on Stochastic Search.
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 4: SMT-based Bounded Model Checking of Concurrent Software.
Why SAT Scales: Phase Transition Phenomena & Back Doors to Complexity slides courtesy of Bart Selman Cornell University.
Constraint Satisfaction Problems
1.1 Chapter 1: Introduction What is the course all about? Problems, instances and algorithms Running time v.s. computational complexity General description.
Distributions of Randomized Backtrack Search Key Properties: I Erratic behavior of mean II Distributions have “heavy tails”.
CHAPTERS 7, 8 Oliver Schulte Logical Inference: Through Proof to Truth.
Explorations in Artificial Intelligence Prof. Carla P. Gomes Module 3 Logic Representations (Part 2)
Constraint Satisfaction Problems Chapter 6. Review Agent, Environment, State Agent as search problem Uninformed search strategies Informed (heuristic.
Chapter 5 Section 1 – 3 1.  Constraint Satisfaction Problems (CSP)  Backtracking search for CSPs  Local search for CSPs 2.
Heavy-Tailed Phenomena in Satisfiability and Constraint Satisfaction Problems by Carla P. Gomes, Bart Selman, Nuno Crato and henry Kautz Presented by Yunho.
Hande ÇAKIN IES 503 TERM PROJECT CONSTRAINT SATISFACTION PROBLEMS.
CSCI 3160 Design and Analysis of Algorithms Tutorial 10 Chengyu Lin.
Solving Constraint Satisfaction Problems (CSPs) using Search CPSC 322 – CSP 2 Textbook § January 31, 2011.
Solving Constraint Satisfaction Problems (CSPs) using Search
Chapter 5: Constraint Satisfaction ICS 171 Fall 2006.
Explorations in Artificial Intelligence Prof. Carla P. Gomes Module Logic Representations.
1 Chapter 34: NP-Completeness. 2 About this Tutorial What is NP ? How to check if a problem is in NP ? Cook-Levin Theorem Showing one of the most difficult.
Chapter 5 Constraint Satisfaction Problems
Quality of LP-based Approximations for Highly Combinatorial Problems Lucian Leahu and Carla Gomes Computer Science Department Cornell University.
Constraint Satisfaction Problems (Chapter 6)
SAT 2009 Ashish Sabharwal Backdoors in the Context of Learning (short paper) Bistra Dilkina, Carla P. Gomes, Ashish Sabharwal Cornell University SAT-09.
CHAPTER 5 SECTION 1 – 3 4 Feb 2004 CS Constraint Satisfaction 1 Constraint Satisfaction Problems.
Accelerating Random Walks Wei Wei and Bart Selman.
Balance and Filtering in Structured Satisfiability Problems Henry Kautz University of Washington joint work with Yongshao Ruan (UW), Dimitris Achlioptas.
1. 2 Outline of Ch 4 Best-first search Greedy best-first search A * search Heuristics Functions Local search algorithms Hill-climbing search Simulated.
Eliminating non- binary constraints Toby Walsh Cork Constraint Computation Center.
Chapter 5 Team Teaching AI (created by Dewi Liliana) PTIIK Constraint Satisfaction Problems.
Inference in Propositional Logic (and Intro to SAT) CSE 473.
Lecture. Today Problem set 9 out (due next Thursday) Topics: –Complexity Theory –Optimization versus Decision Problems –P and NP –Efficient Verification.
Formal Complexity Analysis of RoboFlag Drill & Communication and Computation in Distributed Negotiation Algorithms in Distributed Negotiation Algorithms.
1 P NP P^#P PSPACE NP-complete: SAT, propositional reasoning, scheduling, graph coloring, puzzles, … PSPACE-complete: QBF, planning, chess (bounded), …
© 2012 IBM Corporation Perfect Hashing and CNF Encodings of Cardinality Constraints Yael Ben-Haim Alexander Ivrii Oded Margalit Arie Matsliah SAT 2012.
CS 4700: Foundations of Artificial Intelligence
CSPs: Search and Arc Consistency Computer Science cpsc322, Lecture 12
NP-Completeness Yin Tat Lee
CSPs: Search and Arc Consistency Computer Science cpsc322, Lecture 12
NP-Completeness Yin Tat Lee
CS 8520: Artificial Intelligence
Constraint Satisfaction Problems
Presentation transcript:

1 Backdoor Sets in SAT Instances Ryan Williams Carnegie Mellon University Joint work in IJCAI03 with: Carla Gomes and Bart Selman Cornell University

2 Significant progress in Complete search methods! Software and hardware verification – complete methods are critical - e.g. for verifying the correctness of chip design, using SAT encodings Current methods can verify automatically the correctness of a large fraction of a Pentium IV. (Complete = always returns SAT or unSAT)

3 A “real world” example (Thanks to: Oliver Kullmann)

4 i.e. ((  x 1 ) or x 7 ) and ((  x 1 ) or x 6 ) and … etc. Bounded Model Checking instance:

5 (x 177 or x 169 or x 161 or x 153 … or x 17 or x 9 or x 1 or (  x 185 )) clauses / constraints are getting more interesting… 10 pages later: …

pages later: … ?!! a 59-cnf clause…

7 Finally, 15,000 pages later: The MiniSat solver (Een&Sorensson) solves this instance in 2 seconds. Note that:… !!!

8 Gap between Theory and Practice The good scaling behavior of state-of-the art SAT solvers seems to defy our complexity-theoretic intuition that SAT is NP-complete! How can we explain this gap between theory and practice? What makes this possible? Our answer: Hidden tractable substructure in real-world problems. Can we make this more precise? Proposal: We consider structures we call backdoor sets. Idea came out of study of heavy-tailed phenomena in runtime distributions for some SAT solvers.

9 Backdoor Sets – Initial Motivation Explains why restarting a solver often is an effective strategy Implies a wide range of possible solution times, often including short runs How to explain short runs? Heavy-tailed distributions and Randomization. Certain problems, when solved by randomized backtracking, yield a runtime distribution that is heavy-tailed Pr[solution found in time t] ~ 1/t^c, 0 < c < 2

Explaining short runs: Backdoors to tractability Informally: A backdoor set to a given problem instance is a subset of its variables such that, once assigned values, the remaining instance simplifies to a tractable class. Formally: We define notion of a “sub-solver” (handles tractable substructure of problem instance) backdoor set and strong backdoor set

11 Defining a sub-solver Definition is general enough to encompass many polynomial time propagation methods. (Also those for which we do not know a clean characterization of the tractable subclass.) Valid for other encoding languages besides SAT: e.g., Mixed Integer Programming and Constraint Satisfaction Problems

12 Backdoor set (for satisfiable instances): Strong backdoor set (applies to satisfiable or inconsistent instances): Defining backdoors

Backdoors can be surprisingly small: Backdoors help explain how a solver can get “lucky” on certain runs: backdoor sets are identified early on in backtracking search. Most recent: Other combinatorial domains. E.g. Graphplan planning, near constant size backdoors (2 or 3 variables) in certain domains. (Hoffman, Gomes, Selman ’03) Backdoors capture critical problem resources (bottlenecks).

14 Constraint Satisfaction Problem The Constraint Satisfaction Problem (CSP): A finite set of n variables is given and with each variable is associated a non-empty finite domain. A constraint on k variables X 1,…,X k is a relation R(X 1,…,X k )  D 1 x …x D k. A solution to a CSP is an assignment of values to all the variables, satisfying all the constraints. (Satisfaction of a constraint = the relation holds) (Dechter 86, Freuder 82, Mackworth 77, Tsang 93, van Beek and Dechter 97)

15 Explicit Algorithms for Finding/Exploiting Backdoor Sets We cover three kinds of strategies for dealing with instances with small backdoor sets: A deterministic algorithm A randomized algorithm –Provably better worst-case performance over the deterministic one A heuristic randomized algorithm –Assumes existence of a good heuristic for choosing variables to branch on –We believe this is close to what happens in practice

16 Deterministic Generalized Iterative Deepening

17 Assumption: There exists a backdoor whose size is bounded by a function of n (call it B(n)) Idea: Repeatedly choose random subsets of variables that are slightly larger than B(n), searching these subsets for the backdoor Randomized Generalized Iterative Deepening

18 Randomized Generalized Iterative Deepening

19 Deterministic Versus Randomized Deterministic algorithm Randomized algorithm Suppose variables have 2 possible values (e.g. SAT) k For B(n) = n/k, algorithm runtime is c n c

20 Complete Randomized Depth First Search with Heuristic Assume we have the following. DFS, a generic depth first search randomized backtrack search solver with: (polytime) sub-solver A Heuristic H that (randomly) chooses variables to branch on, in polynomial time  H has probability 1/h of choosing a backdoor variable (h is a fixed constant) Call this ensemble (DFS, H, A)

21 Polytime Restart Strategy for (DFS, H, A) Essentially: If there is a small backdoor, then (DFS, H, A) has a restart strategy that runs in polytime.

Runtime Table for Algorithms DFS,H,A B(n) = upper bound on the size of a backdoor, given n variables When the backdoor is a constant fraction of n, there is an exponential improvement between the randomized and deterministic algorithm

Summary Introduced notion of a “backdoor set” of variables. 1)More closely captures combinatorics of a problem instance, as dealt with in practice. 2)Provides insight into restart strategies. 3) Backdoors can be surprisingly small in practice. 4) Search heuristics + randomization can be used to find them, provably efficiently.