CSE507. Introduction. Computer-Aided Reasoning for Software. Emina Torlak courses.cs.washington.edu/courses/cse507/17wi/

Similar documents
CSE507. Course Introduction. Computer-Aided Reasoning for Software. Emina Torlak

The Calculus of Computation: Decision Procedures with Applications to Verification. Part I: FOUNDATIONS. by Aaron Bradley Zohar Manna

Automated Program Verification and Testing 15414/15614 Fall 2016 Lecture 2: Propositional Logic

CS156: The Calculus of Computation

Overview, cont. Overview, cont. Logistics. Optional Reference #1. Optional Reference #2. Workload and Grading

CS156: The Calculus of Computation Zohar Manna Autumn 2008

Lecture 2 Propositional Logic & SAT

A brief introduction to Logic. (slides from

COMP219: Artificial Intelligence. Lecture 20: Propositional Reasoning

Solvers for the Problem of Boolean Satisfiability (SAT) Will Klieber Aug 31, 2011

Comp487/587 - Boolean Formulas

Propositional and First Order Reasoning

First-Order Logic First-Order Theories. Roopsha Samanta. Partly based on slides by Aaron Bradley and Isil Dillig

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication

Propositional logic. Programming and Modal Logic

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example

Lecture Notes on SAT Solvers & DPLL

Classical Propositional Logic

Part 1: Propositional Logic

Formal Verification Methods 1: Propositional Logic

Warm-Up Problem. Is the following true or false? 1/35

Tutorial 1: Modern SMT Solvers and Verification

Propositional Logic. Methods & Tools for Software Engineering (MTSE) Fall Prof. Arie Gurfinkel

CSE507. Satisfiability Modulo Theories. Computer-Aided Reasoning for Software. Emina Torlak

Language of Propositional Logic

LOGIC PROPOSITIONAL REASONING

SAT Solvers: Theory and Practice

02 Propositional Logic

Foundations of Artificial Intelligence

Introduction to Artificial Intelligence Propositional Logic & SAT Solving. UIUC CS 440 / ECE 448 Professor: Eyal Amir Spring Semester 2010

Computational Logic. Davide Martinenghi. Spring Free University of Bozen-Bolzano. Computational Logic Davide Martinenghi (1/30)

The Calculus of Computation

WHAT IS AN SMT SOLVER? Jaeheon Yi - April 17, 2008

Propositional Logic: Models and Proofs

Knowledge base (KB) = set of sentences in a formal language Declarative approach to building an agent (or other system):

1 Propositional Logic

Logic in AI Chapter 7. Mausam (Based on slides of Dan Weld, Stuart Russell, Subbarao Kambhampati, Dieter Fox, Henry Kautz )

PROPOSITIONAL LOGIC. VL Logik: WS 2018/19

Propositional Logic: Evaluating the Formulas

Price: $25 (incl. T-Shirt, morning tea and lunch) Visit:

Chapter 7 R&N ICS 271 Fall 2017 Kalev Kask

7. Propositional Logic. Wolfram Burgard and Bernhard Nebel

Propositional Reasoning

Propositional logic. Programming and Modal Logic

Decision Procedures for Satisfiability and Validity in Propositional Logic

Automated Program Verification and Testing 15414/15614 Fall 2016 Lecture 3: Practical SAT Solving

Logic and Inferences

Logic in AI Chapter 7. Mausam (Based on slides of Dan Weld, Stuart Russell, Dieter Fox, Henry Kautz )

CS 512, Spring 2017, Handout 10 Propositional Logic: Conjunctive Normal Forms, Disjunctive Normal Forms, Horn Formulas, and other special forms

Propositional and Predicate Logic. jean/gbooks/logic.html

Foundations of Artificial Intelligence

Propositional Logic: Methods of Proof (Part II)

Description Logics. Foundations of Propositional Logic. franconi. Enrico Franconi

Introduction to SAT (constraint) solving. Justyna Petke

Intelligent Agents. Pınar Yolum Utrecht University

EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS

CS1021. Why logic? Logic about inference or argument. Start from assumptions or axioms. Make deductions according to rules of reasoning.

Clause/Term Resolution and Learning in the Evaluation of Quantified Boolean Formulas

Inference in Propositional Logic

Inf2D 06: Logical Agents: Knowledge Bases and the Wumpus World

Conjunctive Normal Form and SAT

Propositional and Predicate Logic - II

COMP3702/7702 Artificial Intelligence Week 5: Search in Continuous Space with an Application in Motion Planning " Hanna Kurniawati"

Advanced Topics in LP and FP

Propositional Logic Basics Propositional Equivalences Normal forms Boolean functions and digital circuits. Propositional Logic.

Propositional Logic. Testing, Quality Assurance, and Maintenance Winter Prof. Arie Gurfinkel

Pythagorean Triples and SAT Solving

Knowledge representation DATA INFORMATION KNOWLEDGE WISDOM. Figure Relation ship between data, information knowledge and wisdom.

Propositional Logic: Methods of Proof (Part II)

Conjunctive Normal Form and SAT

Tecniche di Verifica. Introduction to Propositional Logic

Chapter 4: Classical Propositional Semantics

Part 1: Propositional Logic

Computation and Inference

Lecture 1: Logical Foundations

Logic: Propositional Logic (Part I)

Logical Agents. Chapter 7

Course Staff. Textbook

Foundations of Artificial Intelligence

Foundations of Artificial Intelligence

Introduction to Artificial Intelligence. Logical Agents

Agenda. Artificial Intelligence. Reasoning in the Wumpus World. The Wumpus World

Conjunctive Normal Form and SAT

Logical Inference. Artificial Intelligence. Topic 12. Reading: Russell and Norvig, Chapter 7, Section 5

NP-Completeness Part II

Deliberative Agents Knowledge Representation I. Deliberative Agents

ECE473 Lecture 15: Propositional Logic

Class Assignment Strategies

A New 3-CNF Transformation by Parallel-Serial Graphs 1

CSE 20 DISCRETE MATH WINTER

CSE 311: Foundations of Computing I. Lecture 1: Propositional Logic

Lecture 4: Proposition, Connectives and Truth Tables

Propositional Logic: Methods of Proof. Chapter 7, Part II

Learning Goals of CS245 Logic and Computation

Satisfiability Modulo Theories

Propositional Resolution Introduction

Solutions to Homework I (1.1)

Propositional logic. First order logic. Alexander Clark. Autumn 2014

3 Propositional Logic

Kecerdasan Buatan M. Ali Fauzi

Transcription:

Computer-Aided Reasoning for Software CSE507 courses.cs.washington.edu/courses/cse507/17wi/ Introduction Emina Torlak emina@cs.washington.edu

Today What is this course about? Course logistics Review of propositional logic A basic SAT solver! 2elcome

about Tools for building better software, more easily

more reliable, faster, more energy efficient Tools for building better software, more easily

Tools for building better software, more easily automatic verification, debugging & synthesis

Tools for building better software, more easily class List { Node head; void reverse() { Node near = head; Node mid = near.next; Node far = mid.next; Is this list reversal procedure correct? } } near.next = far; while (far!= null) { mid.next = near; near = mid; mid = far; far = far.next; } mid.next = near; head = mid; class Node { Node next; String data; } 4

Tools for building better software, more easily class List { Node head; void reverse() { Node near = head; Node mid = near.next; Node far = mid.next; verification Is this list reversal procedure correct? near.next = far; while (far!= null) { mid.next = near; near = mid; mid = far; far = far.next; } this head n2 data: s1 next n1 data: s2 next n0 data: null next null } } mid.next = near; head = mid; class Node { Node next; String data; } n2 data: s1 next n1 data: s2 next next n0 data: null head this 4

Tools for building better software, more easily class List { Node head; void reverse() { Node near = head; Node mid = near.next; Node far = mid.next; Which lines of code are responsible for the buggy behavior? near.next = far; while (far!= null) { mid.next = near; near = mid; mid = far; far = far.next; } this head n2 data: s1 next n1 data: s2 next n0 data: null next null } } mid.next = near; head = mid; class Node { Node next; String data; } n2 data: s1 next n1 data: s2 next next n0 data: null head this 5

Tools for building better software, more easily class List { Node head; debugging void reverse() { Node near = head; Node mid = near.next; Node far = mid.next; Which lines of code are responsible for the buggy behavior? near.next = far; while (far!= null) { mid.next = near; near = mid; mid = far; far = far.next; } this head n2 data: s1 next n1 data: s2 next n0 data: null next null } } mid.next = near; head = mid; class Node { Node next; String data; } n2 data: s1 next n1 data: s2 next next n0 data: null head this 5

Tools for building better software, more easily class List { Node head; void reverse() { Node near = head; Node mid = near.next; Node far = mid.next; near.next =??; while (far!= null) { mid.next = near; near = mid; mid = far; far = far.next; } Is there a way to complete this code so that it is correct? } } mid.next = near; head = mid; class Node { Node next; String data; } 6

Tools for building better software, more easily class List { Node head; synthesis void reverse() { Node near = head; Node mid = near.next; Node far = mid.next; near.next = null; while (far!= null) { mid.next = near; near = mid; mid = far; far = far.next; } this Is there a way to complete this code so that it is correct? head n2 data: s1 next n1 data: s2 next n0 data: null next null } } mid.next = near; head = mid; class Node { Node next; String data; } null next n2 data: s1 next n1 data: s2 next n0 data: null head this 6

goal By the end of this course, you ll be able to build computer-aided tools for any domain!

biology education goal By the end of this course, you ll be able to build computer-aided tools for any domain! hardware systems security networking databases low-power computing high-performance computing

logistics Topics, structure, people

Course overview program question tools logic automated reasoning engine 9

Course overview program question verifier, synthesizer, fault localizer logic SAT, SMT, model finders 10

Course overview program question verifier, synthesizer, fault localizer logic SAT, SMT, model finders Drawing from Decision Procedures by Kroening & Strichman 10

Course overview program question study (part I) verifier, synthesizer, fault localizer logic SAT, SMT, model finders Drawing from Decision Procedures by Kroening & Strichman 10

Course overview program question study (part I) verifier, synthesizer, fault localizer logic build! (part II) SAT, SMT, model finders Drawing from Decision Procedures by Kroening & Strichman 10

Grading 3 individual homework assignments (75%) conceptual problems & proofs (TeX) study (part I) implementations (Racket) completed on your own (may discuss HWs with course staff only) Course project (25%) build a computer-aided reasoning tool for a domain of your choice teams of 2-3 people see the course web page for timeline, deliverables and other details build! (part II) 11

Reading and references Required readings posted on the course web page Complete each reading before the lecture for which it is assigned Recommended text books Bradley & Manna, The Calculus of Computation Kroening & Strichman, Decision Procedures Related courses Isil Dillig: Automated Logical Reasoning (2013) Viktor Kuncak: Synthesis, Analysis, and Verification (2013) Sanjit Seshia: Computer-Aided Verification (2016) 12

Advice for doing well in 507 Come to class (prepared) Lecture slides are enough to teach from, but not enough to learn from Participate Ask and answer questions Meet deadlines Turn homework in on time Start homework and project sooner than you think you need to Follow instructions for submitting code (we have to be able to run it) No proof should be longer than a page (most are ~1 paragraph) 13

People instructor TA Emina Torlak PLSE CSE 596 Thursdays 9-10 James Bornholt PLSE CSE 218 Fridays 11-12 14

People instructor TA students! Your name Research area Emina Torlak PLSE CSE 596 Thursdays 9-10 James Bornholt PLSE CSE 218 Fridays 11-12 15

review Let s get started! A review of propositional logic Syntax Semantics Satisfiability and validity Proof methods Semantic judgments Normal forms (NNF, DNF, CNF)

Syntax of propositional logic Atom truth symbols: ( true ), ( false ) propositional variables: p, q, r, Literal an atom α or its negation α Formula a literal or the application of a logical connective to formulas F, F1, F2: F not (negation) F1 F2 and (conjunction) F1 F2 or (disjunction) F1 F2 implies (implication) if and only if (iff) F1 F2 ( p ) (q ) 17

Syntax of propositional logic ( p ) (q ) Atom truth symbols: ( true ), ( false ) propositional variables: p, q, r, Literal an atom α or its negation α Formula a literal or the application of a logical connective to formulas F, F1, F2: F not (negation) F1 F2 and (conjunction) F1 F2 or (disjunction) F1 F2 implies (implication) if and only if (iff) F1 F2 17

Syntax of propositional logic ( p ) (q ) Atom truth symbols: ( true ), ( false ) propositional variables: p, q, r, Literal an atom α or its negation α Formula a literal or the application of a logical connective to formulas F, F1, F2: F not (negation) F1 F2 and (conjunction) F1 F2 or (disjunction) F1 F2 implies (implication) if and only if (iff) F1 F2 17

Syntax of propositional logic ( p ) (q ) Atom truth symbols: ( true ), ( false ) propositional variables: p, q, r, Literal an atom α or its negation α Formula a literal or the application of a logical connective to formulas F, F1, F2: F not (negation) F1 F2 and (conjunction) F1 F2 or (disjunction) F1 F2 implies (implication) if and only if (iff) F1 F2 17

Semantics of propositional logic: interpretations An interpretation I for a propositional formula F maps every variable in F to a truth value: I : { p true, q false, } 18

Semantics of propositional logic: interpretations An interpretation I for a propositional formula F maps every variable in F to a truth value: I : { p true, q false, } I is a satisfying interpretation of F, written as I F, if F evaluates to true under I. I is a falsifying interpretation of F, written as I F, if F evaluates to false under I. 18

Semantics of propositional logic: definition Base cases: I I I p iff I[p] = true I p iff I[p] = false 19

Semantics of propositional logic: definition Base cases: I Inductive cases: I I p iff I[p] = true I p iff I[p] = false 19

Semantics of propositional logic: definition Base cases: I Inductive cases: I F iff I F I I p iff I[p] = true I p iff I[p] = false 19

Semantics of propositional logic: definition Base cases: I I Inductive cases: I F iff I F I F1 F2 iff I F1 and I F2 I p iff I[p] = true I p iff I[p] = false 19

Semantics of propositional logic: definition Base cases: I I I p iff I[p] = true I p iff I[p] = false Inductive cases: I F iff I F I F1 F2 iff I F1 and I F2 I F1 F2 iff I F1 or I F2 I F1 F2 iff I F1 or I F2 I F1 F2 iff I F1 and I F2, or I F1 and I F2 19

Semantics of propositional logic: example F: (p q) (p q) I: {p true, q false}? 20

Semantics of propositional logic: example F: (p q) (p q) I: {p true, q false} I F 20

Satisfiability & validity of propositional formulas F is satisfiable iff I F for some I. F is valid iff I F for all I. 21

Satisfiability & validity of propositional formulas F is satisfiable iff I F for some I. F is valid iff I F for all I. Duality of satisfiability and validity: F is valid iff F is unsatisfiable. 21

Satisfiability & validity of propositional formulas F is satisfiable iff I F for some I. F is valid iff I F for all I. Duality of satisfiability and validity: If we have a procedure for checking satisfiability, then we can also check validity of propositional formulas, and vice versa. F is valid iff F is unsatisfiable. 21

Techniques for deciding satisfiability & validity Search Deduction SAT solver 22

Techniques for deciding satisfiability & validity Search Enumerate all interpretations (i.e., build a truth table), and check that they satisfy the formula. Deduction SAT solver 22

Techniques for deciding satisfiability & validity Search Enumerate all interpretations (i.e., build a truth table), and check that they satisfy the formula. Deduction Assume the formula is invalid, apply proof rules, and check for contradiction in every branch of the proof tree. SAT solver 22

Proof by search (truth tables) F: (p q) (p q) p q p q q p q F 0 0 0 1 1 1 0 1 0 0 0 1 1 0 0 1 1 1 1 1 1 0 1 1 23

Proof by search (truth tables) F: (p q) (p q) p q p q q p q F 0 0 0 1 1 1 Valid. 0 1 0 0 0 1 1 0 0 1 1 1 1 1 1 0 1 1 23

Proof by deduction (semantic arguments) Example proof rules: I F I F I F1 F2 I F1 I F2 I F I F I F1 F2 I F1 I F2 24

Proof by deduction (semantic arguments) Example proof rules: F: p q I F I F I F1 F2 I F1 I F2 I F I F I F1 F2 I F1 I F2 24

Proof by deduction (semantic arguments) Example proof rules: F: p q I F I F I F1 F2 I F1 I F2 1. I p q (assumption) I F I F I F1 F2 I F1 I F2 24

Proof by deduction (semantic arguments) Example proof rules: F: p q I F I F I F1 F2 I F1 I F2 1. I p q (assumption) a. I p (1, ) I F I F I F1 F2 I F1 I F2 24

Proof by deduction (semantic arguments) Example proof rules: F: p q I F I F I F1 F2 I F1 I F2 1. I p q (assumption) a. I p (1, ) b. I q (1, ) I F I F I F1 F2 I F1 I F2 24

Proof by deduction (semantic arguments) Example proof rules: F: p q I F I F I F I F I F1 F2 I F1 I F2 I F1 F2 I F1 I F2 1. I p q (assumption) a. I p (1, ) b. I q (1, ) i. I q (1b, ) 24

Proof by deduction (semantic arguments) Example proof rules: F: p q I F I F I F I F I F1 F2 I F1 I F2 I F1 F2 I F1 I F2 1. I p q (assumption) a. I p (1, ) b. I q (1, ) i. I q (1b, ) Invalid; I is a falsifying interpretation. 24

Semantic judgements Formulas F1 and F2 are equivalent, written F1 F2, iff F1 F2 is valid. Formula F1 implies F2, written F1 F2, iff F1 F2 is valid. F1 F2 and F1 F2 are not propositional formulas (not part of syntax). They are properties of formulas, just like validity or satisfiability. 25

Semantic judgements Formulas F1 and F2 are equivalent, written F1 F2, iff F1 F2 is valid. Formula F1 implies F2, written F1 F2, iff F1 F2 is valid. If we have a procedure for checking satisfiability, then we can also check for equivalence and implication of propositional formulas. 26

Semantic judgements Formulas F1 and F2 are equivalent, written F1 F2, iff F1 F2 is valid. Formula F1 implies F2, written F1 F2, iff F1 F2 is valid. Why do we care? If we have a procedure for checking satisfiability, then we can also check for equivalence and implication of propositional formulas. 26

Getting ready for SAT solving with normal forms A normal form for a logic is a syntactic restriction such that every formula in the logic has an equivalent formula in the normal form. 27

Getting ready for SAT solving with normal forms A normal form for a logic is a syntactic restriction such that every formula in the logic has an equivalent formula in the normal form. Assembly language for a logic. 27

Getting ready for SAT solving with normal forms A normal form for a logic is a syntactic restriction such that every formula in the logic has an equivalent formula in the normal form. Three important normal forms for propositional logic: Negation Normal Form (NNF) Disjunctive Normal Form (DNF) Conjunctive Normal Form (CNF) Assembly language for a logic. 27

Negation Normal Form (NNF) Atom := Variable Literal := Atom Atom Formula := Literal Formula op Formula op := 28

Negation Normal Form (NNF) Atom := Variable Literal := Atom Atom Formula := Literal Formula op Formula op := The only allowed connectives are,, and. can appear only in literals. 28

Negation Normal Form (NNF) Atom := Variable Literal := Atom Atom Formula := Literal Formula op Formula op := The only allowed connectives are,, and. can appear only in literals. Conversion to NNF performed using DeMorgan s Laws: (F G) F G (F G) F G 28

Disjunctive Normal Form (DNF) Atom := Variable Literal := Atom Atom Formula := Clause Formula Clause := Literal Literal Clause 29

Disjunctive Normal Form (DNF) Atom := Variable Literal := Atom Atom Formula := Clause Formula Clause := Literal Literal Clause Disjunction of conjunction of literals. 29

Disjunctive Normal Form (DNF) Atom := Variable Literal := Atom Atom Formula := Clause Formula Clause := Literal Literal Clause Disjunction of conjunction of literals. To convert to DNF, convert to NNF and distribute over : (F (G H)) (F G) (F H) ((G H) F) (G F) (H F) 29

Disjunctive Normal Form (DNF) Atom := Variable Literal := Atom Atom Formula := Clause Formula Clause := Literal Literal Clause Disjunction of conjunction of literals. Deciding satisfiability of a DNF formula is trivial. To convert to DNF, convert to NNF and distribute over : (F (G H)) (F G) (F H) ((G H) F) (G F) (H F) 29

Disjunctive Normal Form (DNF) Atom := Variable Literal := Atom Atom Formula := Clause Formula Clause := Literal Literal Clause Disjunction of conjunction of literals. Deciding satisfiability of a DNF formula is trivial. Why not SAT solve by conversion to DNF? To convert to DNF, convert to NNF and distribute over : (F (G H)) (F G) (F H) ((G H) F) (G F) (H F) 29

Conjunctive Normal Form (CNF) Atom := Variable Literal := Atom Atom Formula := Clause Formula Clause := Literal Literal Clause Conjunction of disjunction of literals. Deciding the satisfiability of a CNF formula is hard. SAT solvers use CNF as their input language. To convert to CNF, convert to NNF and distribute over (F (G H)) (F G) (F H) ((G H) F) (G F) (H F) 30

Conjunctive Normal Form (CNF) Atom := Variable Conjunction of disjunction of literals. Literal := Atom Atom Why CNF? Doesn't the Deciding the satisfiability of a Formula := Clause Formula conversion explode just as CNF formula is hard. badly as DNF? Clause := Literal Literal Clause SAT solvers use CNF as their input language. To convert to CNF, convert to NNF and distribute over (F (G H)) (F G) (F H) ((G H) F) (G F) (H F) 30

Equisatisfiability and Tseitin s transformation 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. Key idea: introduce auxiliary variables to represent the output of subformulas, and constrain those variables using CNF clauses. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. x (y z) Key idea: introduce auxiliary variables to represent the output of subformulas, and constrain those variables using CNF clauses. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. x (y z) a1 a1 (x a2) a2 (y z) Key idea: introduce auxiliary variables to represent the output of subformulas, and constrain those variables using CNF clauses. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. x (y z) a1 a1 (x (x a2) a2) (x a2) a1 a2 (y z) a2 (y z) Key idea: introduce auxiliary variables to represent the output of subformulas, and constrain those variables using CNF clauses. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. x (y z) a1 a1 (x x (x a2) a2) a2 (x a2) (y a1 z) a2 (y z) Key idea: introduce auxiliary variables to represent the output of subformulas, and constrain those variables using CNF clauses. 31

Equisatisfiability and Tseitin s transformation Formulas F and G are equisatisfiable if they are both satisfiable or they are both unsatisfiable. Tseitin s transformation converts a propositional formula F into an equisatisfiable CNF formula that is linear in the size of F. x (y z) a1 a1 (x x (x a2) a2) a2 (x x a1 a2) (y a1 z) a2 a1 (y z) a2 (y z) Key idea: introduce auxiliary variables to represent the output of subformulas, and constrain those variables using CNF clauses. 31

dpll A basic SAT solver!

Davis-Putnam-Logemann-Loveland (1962) // Returns true if the CNF formula F is // satisfiable; otherwise returns false. DPLL(F) G BCP(F) if G = then return true if G = then return false p choose(vars(g)) return DPLL(G{p }) DPLL(G{p }) 33

Davis-Putnam-Logemann-Loveland (1962) // Returns true if the CNF formula F is // satisfiable; otherwise returns false. DPLL(F) G BCP(F) if G = then return true if G = then return false p choose(vars(g)) return DPLL(G{p }) DPLL(G{p }) Boolean constraint propagation applies unit resolution until fixed point: lit lit clause[lit] clause[ lit] clause[ ] 33

Summary Today Course overview & logistics Review of propositional logic A basic SAT solver Next Lecture A modern SAT solver Read Chapter 1 of Bradley & Manna 34