4 th Nov, 2002. Oct 23 rd Happy Deepavali!. 10/23 SAT & CSP.

Slides:



Advertisements
Similar presentations
Hybrid BDD and All-SAT Method for Model Checking Orna Grumberg Joint work with Assaf Schuster and Avi Yadgar Technion – Israel Institute of Technology.
Advertisements

1 Constraint Satisfaction Problems A Quick Overview (based on AIMA book slides)
Dana Nau: Lecture slides for Automated Planning Licensed under the Creative Commons Attribution-NonCommercial-ShareAlike License:
MBD and CSP Meir Kalech Partially based on slides of Jia You and Brian Williams.
Artificial Intelligence Constraint satisfaction problems Fall 2008 professor: Luigi Ceccaroni.
UIUC CS 497: Section EA Lecture #2 Reasoning in Artificial Intelligence Professor: Eyal Amir Spring Semester 2004.
Propositional and First Order Reasoning. Terminology Propositional variable: boolean variable (p) Literal: propositional variable or its negation p 
Proofs from SAT Solvers Yeting Ge ACSys NYU Nov
Methods of Proof Chapter 7, second half.. Proof methods Proof methods divide into (roughly) two kinds: Application of inference rules: Legitimate (sound)
CPSC 422, Lecture 21Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 21 Mar, 4, 2015 Slide credit: some slides adapted from Stuart.
1/30 SAT Solver Changki PSWLAB SAT Solver Daniel Kroening, Ofer Strichman.
Planning with Constraints Graphplan & SATplan Yongmei Shi.
Review: Constraint Satisfaction Problems How is a CSP defined? How do we solve CSPs?
Properties of SLUR Formulae Ondřej Čepek, Petr Kučera, Václav Vlček Charles University in Prague SOFSEM 2012 January 23, 2012.
Constraint Logic Programming Ryan Kinworthy. Overview Introduction Logic Programming LP as a constraint programming language Constraint Logic Programming.
Presented by Ed Clarke Slides borrowed from P. Chauhan and C. Bartzis
Constraint Satisfaction Problems
GRASP-an efficient SAT solver Pankaj Chauhan. 6/19/ : GRASP and Chaff2 What is SAT? Given a propositional formula in CNF, find an assignment.
Existential Graphs and Davis-Putnam April 3, 2002 Bram van Heuveln Department of Cognitive Science.
Python logic Tell me what you do with witches? Burn And what do you burn apart from witches? More witches! Shh! Wood! So, why do witches burn? [pause]
GRASP SAT solver Presented by Constantinos Bartzis Slides borrowed from Pankaj Chauhan J. Marques-Silva and K. Sakallah.
Search in the semantic domain. Some definitions atomic formula: smallest formula possible (no sub- formulas) literal: atomic formula or negation of an.
Python logic Tell me what you do with witches? Burn And what do you burn apart from witches? More witches! Shh! Wood! So, why do witches burn? [pause]
Python logic Tell me what you do with witches? Burn And what do you burn apart from witches? More witches! Shh! Wood! So, why do witches burn? [pause]
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
Knowledge Representation II (Inference in Propositional Logic) CSE 473 Continued…
GRASP: A Search Algorithm for Propositional Satisfiability EE878C Homework #2 2002/11/1 KAIST, EECS ICS Lab Lee, Dongsoo.
10/28 Homework 3 returned Homework 4 socket opened (No office hours today) Where hard problems are Phase Transition.
SAT Solving Presented by Avi Yadgar. The SAT Problem Given a Boolean formula, look for assignment A for such that.  A is a solution for. A partial assignment.
Logic - Part 2 CSE 573. © Daniel S. Weld 2 Reading Already assigned R&N ch 5, 7, 8, 11 thru 11.2 For next time R&N 9.1, 9.2, 11.4 [optional 11.5]
Constraint Satisfaction Problems
Logics for Data and Knowledge Representation Propositional Logic: Reasoning Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto.
Boolean Satisfiability and SAT Solvers
Quantified Formulas - Decision Procedure Daniel Kroening, Ofer Strichman Presented by Changki Hong 07 NOV 08.
SAT and SMT solvers Ayrat Khalimov (based on Georg Hofferek‘s slides) AKDV 2014.
CHAPTERS 7, 8 Oliver Schulte Logical Inference: Through Proof to Truth.
INTRODUCTION TO ARTIFICIAL INTELLIGENCE COS302 MICHAEL L. LITTMAN FALL 2001 Satisfiability.
Explorations in Artificial Intelligence Prof. Carla P. Gomes Module 3 Logic Representations (Part 2)
Solvers for the Problem of Boolean Satisfiability (SAT) Will Klieber Aug 31, 2011 TexPoint fonts used in EMF. Read the TexPoint manual before you.
Motivation & Goal SAT and Constraint Processing (CP) are fundamental areas of Computer Science that address the same computational questions. Compare SAT.
1 Agenda Modeling problems in Propositional Logic SAT basics Decision heuristics Non-chronological Backtracking Learning with Conflict Clauses SAT and.
Constraint Satisfaction Problems Chapter 6. Review Agent, Environment, State Agent as search problem Uninformed search strategies Informed (heuristic.
Explorations in Artificial Intelligence Prof. Carla P. Gomes Module Logic Representations.
LDK R Logics for Data and Knowledge Representation Propositional Logic: Reasoning First version by Alessandro Agostini and Fausto Giunchiglia Second version.
On the Relation between SAT and BDDs for Equivalence Checking Sherief Reda Rolf Drechsler Alex Orailoglu Computer Science & Engineering Dept. University.
First-Order Logic and Inductive Logic Programming.
SAT 2009 Ashish Sabharwal Backdoors in the Context of Learning (short paper) Bistra Dilkina, Carla P. Gomes, Ashish Sabharwal Cornell University SAT-09.
CPSC 422, Lecture 21Slide 1 Intelligent Systems (AI-2) Computer Science cpsc422, Lecture 21 Oct, 30, 2015 Slide credit: some slides adapted from Stuart.
Planning as Satisfiability (SAT-Plan). SAT-Plan Translate the planning problem into a satisfiability problem for length n of Plan garb 0 (proposition)present.
Solving the Logic Satisfiability problem Solving the Logic Satisfiability problem Jesus De Loera.
Satisfiability and SAT Solvers CS 270 Math Foundations of CS Jeremy Johnson.
Chapter 5 Team Teaching AI (created by Dewi Liliana) PTIIK Constraint Satisfaction Problems.
Inference in Propositional Logic (and Intro to SAT) CSE 473.
1 Boolean Satisfiability (SAT) Class Presentation By Girish Paladugu.
Knowledge Repn. & Reasoning Lecture #9: Propositional Logic UIUC CS 498: Section EA Professor: Eyal Amir Fall Semester 2005.
Dana Nau: Lecture slides for Automated Planning Licensed under the Creative Commons Attribution-NonCommercial-ShareAlike License:
Inference in Propositional Logic (and Intro to SAT)
Hybrid BDD and All-SAT Method for Model Checking
Inference and search for the propositional satisfiability problem
First-Order Logic and Inductive Logic Programming
Introduction to the Boolean Satisfiability Problem
ECE 667 Synthesis and Verification of Digital Circuits
Logics for Data and Knowledge Representation
Artificial Intelligence: Agents and Propositional Logic.
Introduction to the Boolean Satisfiability Problem
Constraint satisfaction problems
GRASP-an efficient SAT solver
Constraint satisfaction problems
Presentation transcript:

4 th Nov, Oct 23 rd Happy Deepavali!

10/23 SAT & CSP

Average: 33 St Dev: 13.2 Max: 55.5 Min: Midterm Histogram Marks

Entailment by model checking We said entailment can be checked by truth table enumeration. Can we do the check without full enumeration? –SAT problem Given a set of propositions And a set of (CNF) clauses Find a model (an assignment of t/f values to propositions) that satisfies all clauses –k-SAT is a SAT problem where all clauses are length less than or equal to k »SAT is NP-complete; »1-SAT and 2-SAT are polynomial »k-SAT for k> 2 is NP-complete –If we have a procedure for solving SAT problems, we can use it to compute entailment The senstence S is entailed, if negation of S, when added to the KB, gives a SAT theory that is unsatisfiable (NO MODEL) –CO-NP-Complete –SAT is useful for modeling many other “assignment” problems We will see use of SAT for planning; it can also be used for Graph coloring, n- queens, Scheduling and Circuit verification etc (the last thing makes SAT VERY interesting for Electrical Engineering folks) Review

Compiling Planning into SAT Init: At-R-E-0 & At-A-E-0 & At-B-E-0 Goal: In-A-1 & In-B-1 Graph: “cond at k => one of the supporting actions at k” In-A-1 => Load-A-1 In-B-1 => Load-B-1 At-R-M-1 => Fly-R-1 At-R-E-1 => P-At-R-E-1 Load-A-1 => At-R-E-0 & At-A-E-0 “Actions at k => preconds at k-1” Load-B-1 => At-R-E-0 & At-B-E-0 P-At-R-E-1 => At-R-E-0h ~In-A-1 V ~ At-R-M-1 ~In-B-1 V ~At-R-M-1 “Mutexes” Goals: In(A),In(B) One way of finding a k-length plan is to grow a k-length planning graph (with mutexes) and looking for a valid subgraph of this graph. If it is not found, extend the graph and try again Review

Planning as SAT (another example) Init: J-0 Goal: P-2 & Q-2 Do the following for every cond; action and mutex at every level Graph: “cond at k => one of the supporting actions at k” P-2=> O1-2 V p-P-2 Q-2 => O2-2 V p-Q-2…. “Actions at k => preconds at k-1” O2-2 => J-1 p-P-2 => P-1 Mutexes ~P-2 V ~J-2 ~P-1 V ~Q-1 …. A solution assignment will be J-0; O2-1; Q-1; p-Q-2; O1-2; P-2; Q-2;

SAT as Search Search in the space of “partial assignments” (P=T,Q=F..) –Extend a partial assignment by picking a variable and generating the t/f children of the assignment Nodes: partial assignments Operators: assigning values to variables –We can assign variables in any order (commutative). So no need to consider more than one order –If a partial assignment is already inconsistent, you can kill the search –Depth first search is good enough depth of the search tree is finite (= number of propositions) all satisfying models are equally good. All assignments are at depth d (d = # propositions)

Improvements? Need hints on –Which prop to pick for assignment next? –Which value to try for it next? –Can we detect inevitable failures early on? Involves inference –Notice the “circularity” »Inference can be done by SAT which involves inference (which can be done by SAT which involves inference… –Can we avoid previously encountered failures? –Can we improve the mobility of the search?

DPLL—does lookahead by unit propagation DPLL is a procedure that basically implements this with 2 enhancements: –Unit propagation [Trying to detect inevitable failure early] Before expanding a partial assignment, run unit resolution to completion –Apply inference of type [P ; ~P V Q VJ ] => Q V J repeatedly –Whenever a unit clause is found, set the corresponding variable to True, and remove all clauses that have that variable –If an empty clause is detected, the node is “dead”--Backtrack –Pure-literal elimination If a proposition appears with the same polarity in all clauses it appears, set its value to that polarity, and remove all the clauses that it is part of. –Makes sense only if all satisfying assignments are equally desirable – E.g. be-god V study; be-god V practice

Davis-Putnam-Logeman-Loveland Procedure  detect failure

Improvements to DPLL Order in which propositions are selected –Select the most constraining prop first (the one that takes part in most clauses) –Select the prop which, when set, leads to most unit-propagation cascade [Costly, but works wonders—e.g SATZ) Learning from mistakes (“Nogood” learning) –If we are forced to backtrack over particular partial assignment, remember the reason so if that reason holds in another branch, we can cut search. –Problem: Need to carefully control the amount of nogoods you remember (storage and matching costs). Works great in RelSAT. Using random-restart policies to increase the “mobility” of the search Many many many more.. (still continuing) Read the overview paper on the quest for efficient boolean solvers