W HAT CAN BE DONE WITH A SO SIMPLE LOGIC ? The facts are - - PowerPoint PPT Presentation

w hat can be done with a so simple logic
SMART_READER_LITE
LIVE PREVIEW

W HAT CAN BE DONE WITH A SO SIMPLE LOGIC ? The facts are - - PowerPoint PPT Presentation

History of SAT Modern Solvers Main Components Conclusion / Challenges T OWARDS A N EW E RA OF SAT S OLVERS Laurent Simon Inside Modern SAT Solvers Contains Materials from Joao Marques-Silva, Daniel Le Berre 1/66 History of SAT Modern


slide-1
SLIDE 1

History of SAT Modern Solvers Main Components Conclusion / Challenges

TOWARDS A NEW ERA OF SAT SOLVERS

Laurent Simon

Inside Modern SAT Solvers

Contains Materials from Joao Marques-Silva, Daniel Le Berre

1/66

slide-2
SLIDE 2

History of SAT Modern Solvers Main Components Conclusion / Challenges

PROPOSITIONAL LOGIC

KNOWLEDGE REPRESENTATION The facts : are true, or false. The variables : are ⊤, or ⊥. REASONING BY CALCULUS If we know that : A implies B B implies C The we can deduce that : A implies C If we have : ¬A ∨ B ¬B ∨ C Then, by resolution : ¬A ∨ C This logic was used more than 2300 years ago « Simple is beautiful »

2/66

slide-3
SLIDE 3

History of SAT Modern Solvers Main Components Conclusion / Challenges

PROPOSITIONAL LOGIC

KNOWLEDGE REPRESENTATION The facts : are true, or false. The variables : are ⊤, or ⊥. REASONING BY CALCULUS If we know that : A implies B B implies C The we can deduce that : A implies C If we have : ¬A ∨ B ¬B ∨ C Then, by resolution : ¬A ∨ C This logic was used more than 2300 years ago « Simple is beautiful »

2/66

slide-4
SLIDE 4

History of SAT Modern Solvers Main Components Conclusion / Challenges

PROPOSITIONAL LOGIC

KNOWLEDGE REPRESENTATION The facts : are true, or false. The variables : are ⊤, or ⊥. REASONING BY CALCULUS If we know that : A implies B B implies C The we can deduce that : A implies C If we have : ¬A ∨ B ¬B ∨ C Then, by resolution : ¬A ∨ C This logic was used more than 2300 years ago « Simple is beautiful »

2/66

slide-5
SLIDE 5

History of SAT Modern Solvers Main Components Conclusion / Challenges

PROPOSITIONAL LOGIC

KNOWLEDGE REPRESENTATION The facts : are true, or false. The variables : are ⊤, or ⊥. REASONING BY CALCULUS If we know that : A implies B B implies C The we can deduce that : A implies C If we have : ¬A ∨ B ¬B ∨ C Then, by resolution : ¬A ∨ C This logic was used more than 2300 years ago « Simple is beautiful »

2/66

slide-6
SLIDE 6

History of SAT Modern Solvers Main Components Conclusion / Challenges

PROPOSITIONAL LOGIC

KNOWLEDGE REPRESENTATION The facts : are true, or false. The variables : are ⊤, or ⊥. REASONING BY CALCULUS If we know that : A implies B B implies C The we can deduce that : A implies C If we have : ¬A ∨ B ¬B ∨ C Then, by resolution : ¬A ∨ C This logic was used more than 2300 years ago « Simple is beautiful »

2/66

slide-7
SLIDE 7

History of SAT Modern Solvers Main Components Conclusion / Challenges

PROPOSITIONAL LOGIC

KNOWLEDGE REPRESENTATION The facts : are true, or false. The variables : are ⊤, or ⊥. REASONING BY CALCULUS If we know that : A implies B B implies C The we can deduce that : A implies C If we have : ¬A ∨ B ¬B ∨ C Then, by resolution : ¬A ∨ C This logic was used more than 2300 years ago « Simple is beautiful »

2/66

slide-8
SLIDE 8

History of SAT Modern Solvers Main Components Conclusion / Challenges

THE SAT PROBLEM

DEFINITION

Input : A set of clauses built from a propositional language with n variables. Output : Is there an assignment of the n variables that satisfies all those clauses ?

EXAMPLE

C1 = {¬a ∨ b, ¬b ∨ c} = (¬a ∨ b) ∧ (¬b ∨ c) = (a′ + b).(b′ + c) C2 = C1 ∪ {a, ¬c} = C1 ∧ a ∧ ¬c For C1, the answer is yes, for C2 the answer is no C1 | = ¬(a ∧ ¬c) = ¬a ∨ c

3/66

slide-9
SLIDE 9

History of SAT Modern Solvers Main Components Conclusion / Challenges

THE SAT PROBLEM

DEFINITION

Input : A set of clauses built from a propositional language with n variables. Output : Is there an assignment of the n variables that satisfies all those clauses ?

EXAMPLE

C1 = {¬a ∨ b, ¬b ∨ c} = (¬a ∨ b) ∧ (¬b ∨ c) = (a′ + b).(b′ + c) C2 = C1 ∪ {a, ¬c} = C1 ∧ a ∧ ¬c For C1, the answer is yes, for C2 the answer is no C1 | = ¬(a ∧ ¬c) = ¬a ∨ c

3/66

slide-10
SLIDE 10

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHAT CAN BE DONE WITH A SO SIMPLE LOGIC ?

The facts are propositional variables The knowledge is a propositional formula ¬x1 ∨ ¬x2 ∨ x3 ∧ ¬x3 ∧ x1 ∨ x2 ∧ x2 ∨ x3 Variables : x1 . . . x3 ; Literals : x1, ¬x1 ; Clauses : ¬x1 ∨ ¬x2 ∨ x3 ; Formula Σ written in CNF (conjonction of clauses) ;

BIG QUESTIONS

SAT : is there an assignment of variables that makes the formula true ? UNSAT : is the theory contradictory ? PI : deduce all you can from Σ.

4/66

slide-11
SLIDE 11

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHAT CAN BE DONE WITH A SO SIMPLE LOGIC ?

The facts are propositional variables The knowledge is a propositional formula ¬x1 ∨ ¬x2 ∨ x3 ∧ ¬x3 ∧ x1 ∨ x2 ∧ x2 ∨ x3 x1 x2 x3 ⊥ ⊥ ⊥ Variables : x1 . . . x3 ; Literals : x1, ¬x1 ; Clauses : ¬x1 ∨ ¬x2 ∨ x3 ; Formula Σ written in CNF (conjonction of clauses) ;

BIG QUESTIONS

SAT : is there an assignment of variables that makes the formula true ? UNSAT : is the theory contradictory ? PI : deduce all you can from Σ.

4/66

slide-12
SLIDE 12

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHAT CAN BE DONE WITH A SO SIMPLE LOGIC ?

The facts are propositional variables The knowledge is a propositional formula ¬x1 ∨ ¬x2 ∨ x3 ∧ ¬x3 ∧ x1 ∨ x2 ∧ x2 ∨ x3 x1 x2 x3 ⊥ ⊥ ⊥ Variables : x1 . . . x3 ; Literals : x1, ¬x1 ; Clauses : ¬x1 ∨ ¬x2 ∨ x3 ; Formula Σ written in CNF (conjonction of clauses) ;

BIG QUESTIONS

SAT : is there an assignment of variables that makes the formula true ? UNSAT : is the theory contradictory ? PI : deduce all you can from Σ.

4/66

slide-13
SLIDE 13

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHAT CAN BE DONE WITH A SO SIMPLE LOGIC ?

The facts are propositional variables The knowledge is a propositional formula ¬x1 ∨ ¬x2 ∨ x3 ∧ ¬x3 ∧ x1 ∨ x2 ∧ x2 ∨ x3 x1 x2 x3 ⊥ ⊤ ⊥ Variables : x1 . . . x3 ; Literals : x1, ¬x1 ; Clauses : ¬x1 ∨ ¬x2 ∨ x3 ; Formula Σ written in CNF (conjonction of clauses) ;

BIG QUESTIONS

SAT : is there an assignment of variables that makes the formula true ? UNSAT : is the theory contradictory ? PI : deduce all you can from Σ.

4/66

slide-14
SLIDE 14

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHAT CAN BE DONE WITH A SO SIMPLE LOGIC ?

The facts are propositional variables The knowledge is a propositional formula ¬x1 ∨ ¬x2 ∨ x3 ∧ ¬x3 ∧ x1 ∨ x2 ∧ x2 ∨ x3 x1 x2 x3 ⊥ ⊤ ⊥ Variables : x1 . . . x3 ; Literals : x1, ¬x1 ; Clauses : ¬x1 ∨ ¬x2 ∨ x3 ; Formula Σ written in CNF (conjonction of clauses) ;

BIG QUESTIONS

SAT : is there an assignment of variables that makes the formula true ? UNSAT : is the theory contradictory ? PI : deduce all you can from Σ.

4/66

slide-15
SLIDE 15

History of SAT Modern Solvers Main Components Conclusion / Challenges

SAT : A BRICK IN THE COMPLEXITY THEORY

THE COOK THEOREM [71] : SAT IS NP-COMPLETE

It is the well-known fundamental brick of the complexity theory. Heavily Studied for its Theoretical Interests Heavily Studied for its Practical Applications A problem seems hard to solve ?

IN THE 80’S

“Reduce it to SAT : This will show that nobody can solve it !”

AT THE 21ST CENTURY...

“Reduce it to SAT : and solve it in practice”

5/66

slide-16
SLIDE 16

History of SAT Modern Solvers Main Components Conclusion / Challenges

SAT : A BRICK IN THE COMPLEXITY THEORY

THE COOK THEOREM [71] : SAT IS NP-COMPLETE

It is the well-known fundamental brick of the complexity theory. Heavily Studied for its Theoretical Interests Heavily Studied for its Practical Applications A problem seems hard to solve ?

IN THE 80’S

“Reduce it to SAT : This will show that nobody can solve it !”

AT THE 21ST CENTURY...

“Reduce it to SAT : and solve it in practice”

5/66

slide-17
SLIDE 17

History of SAT Modern Solvers Main Components Conclusion / Challenges

SAT : A BRICK IN THE COMPLEXITY THEORY

THE COOK THEOREM [71] : SAT IS NP-COMPLETE

It is the well-known fundamental brick of the complexity theory. Heavily Studied for its Theoretical Interests Heavily Studied for its Practical Applications A problem seems hard to solve ?

IN THE 80’S

“Reduce it to SAT : This will show that nobody can solve it !”

AT THE 21ST CENTURY...

“Reduce it to SAT : and solve it in practice”

5/66

slide-18
SLIDE 18

History of SAT Modern Solvers Main Components Conclusion / Challenges

SAT : A BRICK IN THE COMPLEXITY THEORY

THE COOK THEOREM [71] : SAT IS NP-COMPLETE

It is the well-known fundamental brick of the complexity theory. Heavily Studied for its Theoretical Interests Heavily Studied for its Practical Applications A problem seems hard to solve ?

IN THE 80’S

“Reduce it to SAT : This will show that nobody can solve it !”

AT THE 21ST CENTURY...

“Reduce it to SAT : and solve it in practice”

5/66

slide-19
SLIDE 19

History of SAT Modern Solvers Main Components Conclusion / Challenges

RANDOM (SAT) INSTANCES ARE ALMOST EASY

Very studied. Almost solved everywhere (for SAT instances only). In 1980 :

  • nly a few real problems ;

In 1990 : focus on the threshold ; In 2000 : models from physics theory ; In 2010 : back to Walksat (optimal noise studied).

0.2 0.4 0.6 0.8 1 3.5 4 4.5 5 5.5 6

NOWADAYS

Easy (SAT) until r = 4.25, Hard (SAT) between r = 4.25 and r = 4.267, Very Hard (UNSAT) after r = 4.267.

6/66

slide-20
SLIDE 20

History of SAT Modern Solvers Main Components Conclusion / Challenges

REGULAR INCREASING OF PERFORMANCES ON INDUSTRIAL PROBLEMS

200 400 600 800 1000 1200 20 40 60 80 100 120 140 160 180 CPU Time (in seconds) Number of problems solved Results of the SAT competition/race winners on the SAT 2009 application benchmarks, 20mn timeout Limmat (2002) Zchaff (2002) Berkmin (2002) Forklift (2003) Siege (2003) Zchaff (2004) SatELite (2005) Minisat 2 (2006) Picosat (2007) Rsat (2007) Minisat 2.1 (2008) Precosat (2009) Glucose (2009) Clasp (2009) Cryptominisat (2010) Lingeling (2010) Minisat 2.2 (2010)

7/66

slide-21
SLIDE 21

History of SAT Modern Solvers Main Components Conclusion / Challenges

SIGNIFICANT PRACTICAL AND THEORETICAL PROGRESSES

Model Checking, Static Code Analysis, Planning, Constraints, Biology, ... Logic theorems (above NP)

MOSHE VARDI

« Major progresses in logic may come from SAT »

EDMUND CLARKE

« The practical solving of SAT is a key technology for computer science in the 21st century »

8/66

slide-22
SLIDE 22

History of SAT Modern Solvers Main Components Conclusion / Challenges

SIGNIFICANT PRACTICAL AND THEORETICAL PROGRESSES

Model Checking, Static Code Analysis, Planning, Constraints, Biology, ... Logic theorems (above NP)

MOSHE VARDI

« Major progresses in logic may come from SAT »

EDMUND CLARKE

« The practical solving of SAT is a key technology for computer science in the 21st century »

8/66

slide-23
SLIDE 23

History of SAT Modern Solvers Main Components Conclusion / Challenges

SIGNIFICANT PRACTICAL AND THEORETICAL PROGRESSES

Model Checking, Static Code Analysis, Planning, Constraints, Biology, ... Logic theorems (above NP)

MOSHE VARDI

« Major progresses in logic may come from SAT »

EDMUND CLARKE

« The practical solving of SAT is a key technology for computer science in the 21st century »

8/66

slide-24
SLIDE 24

History of SAT Modern Solvers Main Components Conclusion / Challenges

SIGNIFICANT PRACTICAL AND THEORETICAL PROGRESSES

Model Checking, Static Code Analysis, Planning, Constraints, Biology, ... Logic theorems (above NP)

MOSHE VARDI

« Major progresses in logic may come from SAT »

EDMUND CLARKE

« The practical solving of SAT is a key technology for computer science in the 21st century »

8/66

slide-25
SLIDE 25

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHERE CAN WE FIND SAT TECHNOLOGY TODAY ?

Formal methods :

Hardware model checking ; Software model checking ; Termination analysis of term-rewrite systems ; Test pattern generation (testing of software & hardware) ; etc.

Artificial intelligence :

Planning ; Knowledge representation ; Games (n-queens, sudoku, social golpher’s, etc.)

Bioinformatics :

Haplotype inference ; Pedigree checking ; Analysis of Genetic Regulatory Networks ; etc.

Design automation :

Equivalence checking ; Delay computation ; Fault diagnosis ; Noise analysis ; etc.

Security :

Cryptanalysis ; Inversion attacks on hash functions ; etc.

9/66

slide-26
SLIDE 26

History of SAT Modern Solvers Main Components Conclusion / Challenges

WHERE CAN WE FIND SAT TECHNOLOGY TODAY ? II

Computationally hard problems :

Graph coloring ; Traveling salesperson ; etc.

Mathematical problems :

van der Waerden numbers ; Quasigroup open problems ; etc.

Core engine for other solvers : 0-1 ILP/Pseudo Boolean ; QBF ; #SAT ; SMT ; MAXSAT ; ... Integrated into theorem provers : HOL ; Isabelle ; ... Integrated into widely used software :

Suse 10.1 dependency manager based on a custom SAT solver. Eclipse provisioning system based on a Pseudo Boolean solver.

10/66

slide-27
SLIDE 27

History of SAT Modern Solvers Main Components Conclusion / Challenges

TODAY’S ITINARY

1 A HISTORY OF 50 YEARS OF SAT RESEARCH 2 MODERN SAT SOLVERS : CDCL 3 MAIN COMPONENTS AND FEATURES 4 CONCLUDING ON CHALLENGES

11/66

slide-28
SLIDE 28

History of SAT Modern Solvers Main Components Conclusion / Challenges

TODAY’S ITINARY

1 A HISTORY OF 50 YEARS OF SAT RESEARCH

The youth of SAT DPLL

2 MODERN SAT SOLVERS : CDCL 3 MAIN COMPONENTS AND FEATURES 4 CONCLUDING ON CHALLENGES

12/66

slide-29
SLIDE 29

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

REASONING ON BOTH CHOICES

We have f ≡ (x ∧ fx) ∨ (¬x ∧ f¬x)

(Shannon’s Decomposition) Note that x has disapeared in fx and f¬x

DP60 IDEA

Eliminate all variables, one after the other

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ has no more variables then return Σ; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

13/66

slide-30
SLIDE 30

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

REASONING ON BOTH CHOICES

We have f ≡ (x ∧ fx) ∨ (¬x ∧ f¬x)

(Shannon’s Decomposition) Note that x has disapeared in fx and f¬x

DP60 IDEA

Eliminate all variables, one after the other

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ has no more variables then return Σ; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

13/66

slide-31
SLIDE 31

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

REASONING ON BOTH CHOICES

We have f ≡ (x ∧ fx) ∨ (¬x ∧ f¬x)

(Shannon’s Decomposition) Note that x has disapeared in fx and f¬x

DP60 IDEA

Eliminate all variables, one after the other

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ has no more variables then return Σ; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

13/66

slide-32
SLIDE 32

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

REASONING ON BOTH CHOICES

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ has no more variables then return Σ; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

Calculus of Σx ∨ Σ¬x : Forget x in Σ. Performs all possible resolutions on x

THE RESOLUTION RULE (CUT) [GENTZEN 1934, ROBINSON 1965]

Let c1 = (x ∨ a1 ∨ . . . an) and c2 = (¬x ∨ b1 ∨ . . . bm) c = (a1 ∨ . . . an ∨ b1 ∨ . . . bm) is obtained by resolution on x between c1 and c2. 100% reasoning procedure

13/66

slide-33
SLIDE 33

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

REASONING ON BOTH CHOICES

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ has no more variables then return Σ; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

Calculus of Σx ∨ Σ¬x : Forget x in Σ. Performs all possible resolutions on x

THE RESOLUTION RULE (CUT) [GENTZEN 1934, ROBINSON 1965]

Let c1 = (x ∨ a1 ∨ . . . an) and c2 = (¬x ∨ b1 ∨ . . . bm) c = (a1 ∨ . . . an ∨ b1 ∨ . . . bm) is obtained by resolution on x between c1 and c2. 100% reasoning procedure

13/66

slide-34
SLIDE 34

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

REASONING ON BOTH CHOICES

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ has no more variables then return Σ; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

Calculus of Σx ∨ Σ¬x : Forget x in Σ. Performs all possible resolutions on x

THE RESOLUTION RULE (CUT) [GENTZEN 1934, ROBINSON 1965]

Let c1 = (x ∨ a1 ∨ . . . an) and c2 = (¬x ∨ b1 ∨ . . . bm) c = (a1 ∨ . . . an ∨ b1 ∨ . . . bm) is obtained by resolution on x between c1 and c2. 100% reasoning procedure

13/66

slide-35
SLIDE 35

History of SAT Modern Solvers Main Components Conclusion / Challenges

GETTING AN INTUITION ON RANDOM INSTANCES

TOO MANY PRODUCED CLAUSES

1 6 11 16 21 26 500 1000 1500 2000 2500

Cut Number (||=30) Number of Clauses (A). 3CNF with 130 Clauses, 30 Variables; 1000 trials

Max.

  • Std. Dev.

Mean Min. 1 6 11 16 21 26 2000 4000 6000 8000 10000

Cut Number (||=30) Number of Clauses (B). 3CNF with 280 Clauses, 30 Variables; 1000 trials

Max.

  • Std. Dev.

Mean Min.

14/66

slide-36
SLIDE 36

History of SAT Modern Solvers Main Components Conclusion / Challenges

  • BUT. . . WE PROGRESSED !

Truth Tables Ordered Resolution (DP60) ... (...) ... (...) ... (...) ... (...)

15/66

slide-37
SLIDE 37

History of SAT Modern Solvers Main Components Conclusion / Challenges

  • BUT. . . WE PROGRESSED !

Truth Tables Ordered Resolution (DP60) ... (...) ... (...) ... (...) ... (...)

15/66

slide-38
SLIDE 38

History of SAT Modern Solvers Main Components Conclusion / Challenges

  • BUT. . . WE PROGRESSED !

Truth Tables Ordered Resolution (DP60) ... (...) ... (...) ... (...) ... (...)

15/66

slide-39
SLIDE 39

History of SAT Modern Solvers Main Components Conclusion / Challenges

VARIABLE ELIMINATION – AN EXAMPLE

( x1 ∨ ¬x2 ∨ ¬x3) ∧ ( ¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)

  • ( ¬x2 ∨ ¬x3) ∧ ( x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • ( x3 ∨ ¬x3 ) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • (x3 ∨ x4 ) ∧ (x3 ∨ ¬x4 )
  • x3

Formula is SAT

16/66

slide-40
SLIDE 40

History of SAT Modern Solvers Main Components Conclusion / Challenges

VARIABLE ELIMINATION – AN EXAMPLE

( x1 ∨ ¬x2 ∨ ¬x3) ∧ ( ¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)

  • ( ¬x2 ∨ ¬x3) ∧ ( x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • ( x3 ∨ ¬x3 ) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • (x3 ∨ x4 ) ∧ (x3 ∨ ¬x4 )
  • x3

Formula is SAT

16/66

slide-41
SLIDE 41

History of SAT Modern Solvers Main Components Conclusion / Challenges

VARIABLE ELIMINATION – AN EXAMPLE

( x1 ∨ ¬x2 ∨ ¬x3) ∧ ( ¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)

  • ( ¬x2 ∨ ¬x3) ∧ ( x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • ( x3 ∨ ¬x3 ) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • (x3 ∨ x4 ) ∧ (x3 ∨ ¬x4 )
  • x3

Formula is SAT

16/66

slide-42
SLIDE 42

History of SAT Modern Solvers Main Components Conclusion / Challenges

VARIABLE ELIMINATION – AN EXAMPLE

( x1 ∨ ¬x2 ∨ ¬x3) ∧ ( ¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)

  • ( ¬x2 ∨ ¬x3) ∧ ( x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • ( x3 ∨ ¬x3 ) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • (x3 ∨ x4 ) ∧ (x3 ∨ ¬x4 )
  • x3

Formula is SAT

16/66

slide-43
SLIDE 43

History of SAT Modern Solvers Main Components Conclusion / Challenges

VARIABLE ELIMINATION – AN EXAMPLE

( x1 ∨ ¬x2 ∨ ¬x3) ∧ ( ¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)

  • ( ¬x2 ∨ ¬x3) ∧ ( x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • ( x3 ∨ ¬x3 ) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • (x3 ∨ x4 ) ∧ (x3 ∨ ¬x4 )
  • x3

Formula is SAT

16/66

slide-44
SLIDE 44

History of SAT Modern Solvers Main Components Conclusion / Challenges

VARIABLE ELIMINATION – AN EXAMPLE

( x1 ∨ ¬x2 ∨ ¬x3) ∧ ( ¬x1 ∨ ¬x2 ∨ ¬x3) ∧ (x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)

  • ( ¬x2 ∨ ¬x3) ∧ ( x2 ∨ x3) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • ( x3 ∨ ¬x3 ) ∧ (x3 ∨ x4) ∧ (x3 ∨ ¬x4)
  • (x3 ∨ x4 ) ∧ (x3 ∨ ¬x4 )
  • x3

Formula is SAT

16/66

slide-45
SLIDE 45

History of SAT Modern Solvers Main Components Conclusion / Challenges

THE DAVIS AND PUTNAM PROCEDURE : THE REFINEMENTS

Add specific cases to order variable elimination steps Iteratively apply the following steps :

Apply the pure literal rule and unit propagation Select variable x Apply resolution between every pair of clauses of the form (x ∨ α) and (¬x ∨ β) Remove all clauses containing either x or ¬x

Terminate when either the empty clause or the empty formula is derived

17/66

slide-46
SLIDE 46

History of SAT Modern Solvers Main Components Conclusion / Challenges

PURE LITERALS

A literal is pure if only occurs as a positive literal or as a negative literal in a CNF formula

Example : ϕ = ( ¬x1 ∨ x2) ∧ ( x3 ∨ ¬x2) ∧ (x4 ∨ ¬x5) ∧ (x5 ∨ ¬x4) ¬x1 and x3 are pure literals

Pure literal rule : eliminate first pure literals because no resolvant are produced ! applying a variable elimination step on a pure literal strictly reduces the number of clauses ! Preserve satisfiability, not logical equivalency !

18/66

slide-47
SLIDE 47

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION

Specific case of resolution : only shorten clauses. unit resolution: x1 ∨ x2 ∨ x3 ¬x2 x1 ∨ x3 Preserve logical equivalency : (x1 ∨ x2 ∨ x3) ∧ ¬x2 ≡ (x1 ∨ x3) ∧ ¬x2 Since clauses are shortened, new unit clauses may appear. Empty clauses also ! Unit propagation : apply unit resolution while new unit clauses are produced.

19/66

slide-48
SLIDE 48

History of SAT Modern Solvers Main Components Conclusion / Challenges

DP60 : THE LIMITS

The approach runs easily out of memory. Even recent attempts using a ROBDD representation [Simon and Chatalic 2000] does not scale well. The solution : using backtrack search !

20/66

slide-49
SLIDE 49

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

TOO MUCH REASONING

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ = ∅ then return true; if Σ = {⊥} then return false; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

PROBLEMS

each step of rewritting Σ′ = Σx ∨ Σ¬x in CNF is quadratic memory blow-up too powerfull for SAT (but usefull for Prime Implicates / Model Counting / ...) Solution : Change the ∨ into an alternative (OR).

21/66

slide-50
SLIDE 50

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

TOO MUCH REASONING

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ = ∅ then return true; if Σ = {⊥} then return false; Let x be a variable of Σ; return DP(Σx ∨ Σ¬x); end

PROBLEMS

each step of rewritting Σ′ = Σx ∨ Σ¬x in CNF is quadratic memory blow-up too powerfull for SAT (but usefull for Prime Implicates / Model Counting / ...) Solution : Change the ∨ into an alternative (OR).

21/66

slide-51
SLIDE 51

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

TOO MUCH REASONING

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ = ∅ then return true; if Σ = {⊥} then return false; Let x be a variable of Σ; return DP(Σx) OR DP(Σ¬x); end

PROBLEMS

each step of rewritting Σ′ = Σx ∨ Σ¬x in CNF is quadratic memory blow-up too powerfull for SAT (but usefull for Prime Implicates / Model Counting / ...) Solution : Change the ∨ into an alternative (OR).

21/66

slide-52
SLIDE 52

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS AND PUTNAM 1960 [DP60]

TOO MUCH REASONING

DP(Σ) In : Σ a formula f under CNF Out : ∅ if a model exists, {⊥} otherwise begin Take care of all subsumed clauses of Σ; if Σ = ∅ then return true; if Σ = {⊥} then return false; Let l be a literal of Σ; return DP(Σl) OR DP(Σ¬l); end

PROBLEMS

each step of rewritting Σ′ = Σx ∨ Σ¬x in CNF is quadratic memory blow-up too powerfull for SAT (but usefull for Prime Implicates / Model Counting / ...) Solution : Change the ∨ into an alternative (OR).

21/66

slide-53
SLIDE 53

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS, LOGEMANN ET LOVELAND, 1962 [DPLL62]

ESSAYER LES CHOIX POSSIBLES, SYSTÉMATIQUEMENT

DPLL(Σ,(I)) In : Σ (CNF), I (partial interpretation) Out : SAT / UNSAT begin if Σ|I is empty then return SAT ; if Σ|I contains ⊥ then return UNSAT ; if Σ|I contains a pure literal l then return DPLL(Σ, I.l); if Σ|I contains a unit clause l then return DPLL(Σ, I.l); Let l a literal in Σ|I; if DPLL(Σ, I.l) returned SAT then return SAT ; return DPLL(Σ, I.¬l) end Note : Σ|I if the formula simplified by I

22/66

slide-54
SLIDE 54

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS, LOGEMANN ET LOVELAND, 1962 [DPLL62]

ESSAYER LES CHOIX POSSIBLES, SYSTÉMATIQUEMENT

DPLL(Σ,(I)) In : Σ (CNF), I (partial interpretation) Out : SAT / UNSAT begin if Σ|I is empty then return SAT ; if Σ|I contains ⊥ then return UNSAT ; if Σ|I contains a pure literal l then return DPLL(Σ, I.l); if Σ|I contains a unit clause l then return DPLL(Σ, I.l); Let l a literal in Σ|I; if DPLL(Σ, I.l) returned SAT then return SAT ; return DPLL(Σ, I.¬l) end Note : Σ|I if the formula simplified by I

22/66

slide-55
SLIDE 55

History of SAT Modern Solvers Main Components Conclusion / Challenges

DAVIS, LOGEMANN ET LOVELAND, 1962 [DPLL62]

ESSAYER LES CHOIX POSSIBLES, SYSTÉMATIQUEMENT

DPLL(Σ,(I)) In : Σ (CNF), I (partial interpretation) Out : SAT / UNSAT begin if Σ|I is empty then return SAT ; if Σ|I contains ⊥ then return UNSAT ; if Σ|I contains a pure literal l then return DPLL(Σ, I.l); if Σ|I contains a unit clause l then return DPLL(Σ, I.l); Let l a literal in Σ|I; if DPLL(Σ, I.l) returned SAT then return SAT ; return DPLL(Σ, I.¬l) end Note : Σ|I if the formula simplified by I

22/66

slide-56
SLIDE 56

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) ... (...) ... (...) ... (...)

23/66

slide-57
SLIDE 57

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) ... (...) ... (...) ... (...)

23/66

slide-58
SLIDE 58

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) ... (...) ... (...) ... (...)

23/66

slide-59
SLIDE 59

History of SAT Modern Solvers Main Components Conclusion / Challenges

PURE LITERALS IN BACKTRACK SEARCH

Pure literal rule : Clauses containing pure literals can be removed from the formula (i.e. just satisfy those pure literals) Example : ϕ = ( ¬x1 ∨ x2) ∧ ( x3 ∨ ¬x2) ∧ (x4 ∨ ¬x5) ∧ (x5 ∨ ¬x4) The resulting formula becomes : ϕ¬x1,x3 = (x4 ∨ ¬x5) ∧ (x5 ∨ ¬x4) if l is a pure literal in Σ, then Σl ⊂ Σ Preserve satisfiability, not logical equivalency !

24/66

slide-60
SLIDE 60

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4)

25/66

slide-61
SLIDE 61

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4)

25/66

slide-62
SLIDE 62

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4)

25/66

slide-63
SLIDE 63

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4)

25/66

slide-64
SLIDE 64

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4)

25/66

slide-65
SLIDE 65

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4)

25/66

slide-66
SLIDE 66

History of SAT Modern Solvers Main Components Conclusion / Challenges

UNIT PROPAGATION IN BACKTRACK SEARCH

Unit clause rule in backtrack search : Given a unit clause, its only unassigned literal must be assigned value True for the clause to be satisfied Example : for unit clause (x1 ∨ ¬x2 ∨ ¬x3), x3 must be assigned value False Unit propagation Iterated application of the unit clause rule (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ x4) (x1 ∨ ¬x2 ∨ ¬x3) ∧ (¬x1 ∨ ¬x3 ∨ x4) ∧ (¬x1 ∨ ¬x2 ∨ ¬x4) Unit propagation can satisfy clauses but can also unsatisfy clauses (i.e. conflicts)

25/66

slide-67
SLIDE 67

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

a

26/66

slide-68
SLIDE 68

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

b conflict a

26/66

slide-69
SLIDE 69

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

conflict b a

26/66

slide-70
SLIDE 70

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

conflict a c b

26/66

slide-71
SLIDE 71

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

conflict a c b

26/66

slide-72
SLIDE 72

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

b conflict a c

26/66

slide-73
SLIDE 73

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

b solution a c b conflict

26/66

slide-74
SLIDE 74

History of SAT Modern Solvers Main Components Conclusion / Challenges

AN EXAMPLE OF DPLL

ϕ = (a ∨ ¬b ∨ d) ∧ (a ∨ ¬b ∨ e) ∧ (¬b ∨ ¬d ∨ ¬e) ∧ (a ∨ b ∨ c ∨ d) ∧ (a ∨ b ∨ c ∨ ¬d) ∧ (a ∨ b ∨ ¬c ∨ e) ∧ (a ∨ b ∨ ¬c ∨ ¬e)

26/66

slide-75
SLIDE 75

History of SAT Modern Solvers Main Components Conclusion / Challenges

DP, DLL OR DPLL ?

DPLL = DP + DLL Acknowledge the principles in DP60 and their memory efficient implementation in DP62 DPLL commonly used to denote complete solvers for SAT : no longer true for modern complete SAT solvers. The focus of researchers in the 90’s was mainly to improve the heuristics to select the variables to branch on on randomly generated formulas. Introduction of non chronological backtracking and learning to solve structured/real world formulas

27/66

slide-76
SLIDE 76

History of SAT Modern Solvers Main Components Conclusion / Challenges

DPLL : THE LOOK-AHEAD WORLD

WE CANNOT ALWAYS WIN, BUT WE CAN LIMIT THE LOSS

On UNSAT problems : We must visit both alternatives On SAT problems : What is the chance to pick the right direction ? In all the cases : we need to reduce both sizes of subtrees Most frequent variables in short clauses Variable that will propagate many literals Variable in backbones / backdoors / ... Unexpected problems : needs to maintain many counters Only possible on « normal » problems

28/66

slide-77
SLIDE 77

History of SAT Modern Solvers Main Components Conclusion / Challenges

DPLL : THE LOOK-AHEAD WORLD

WE CANNOT ALWAYS WIN, BUT WE CAN LIMIT THE LOSS

On UNSAT problems : We must visit both alternatives On SAT problems : What is the chance to pick the right direction ? In all the cases : we need to reduce both sizes of subtrees Most frequent variables in short clauses Variable that will propagate many literals Variable in backbones / backdoors / ... Unexpected problems : needs to maintain many counters Only possible on « normal » problems

28/66

slide-78
SLIDE 78

History of SAT Modern Solvers Main Components Conclusion / Challenges

DPLL : THE LOOK-AHEAD WORLD

WE CANNOT ALWAYS WIN, BUT WE CAN LIMIT THE LOSS

On UNSAT problems : We must visit both alternatives On SAT problems : What is the chance to pick the right direction ? In all the cases : we need to reduce both sizes of subtrees Most frequent variables in short clauses Variable that will propagate many literals Variable in backbones / backdoors / ... Unexpected problems : needs to maintain many counters Only possible on « normal » problems

28/66

slide-79
SLIDE 79

History of SAT Modern Solvers Main Components Conclusion / Challenges

DPLL : THE LOOK-AHEAD WORLD

WE CANNOT ALWAYS WIN, BUT WE CAN LIMIT THE LOSS

On UNSAT problems : We must visit both alternatives On SAT problems : What is the chance to pick the right direction ? In all the cases : we need to reduce both sizes of subtrees Most frequent variables in short clauses Variable that will propagate many literals Variable in backbones / backdoors / ... Unexpected problems : needs to maintain many counters Only possible on « normal » problems

28/66

slide-80
SLIDE 80

History of SAT Modern Solvers Main Components Conclusion / Challenges

DPLL : THE LOOK-AHEAD WORLD

WE CANNOT ALWAYS WIN, BUT WE CAN LIMIT THE LOSS

On UNSAT problems : We must visit both alternatives On SAT problems : What is the chance to pick the right direction ? In all the cases : we need to reduce both sizes of subtrees Most frequent variables in short clauses Variable that will propagate many literals Variable in backbones / backdoors / ... Unexpected problems : needs to maintain many counters Only possible on « normal » problems

28/66

slide-81
SLIDE 81

History of SAT Modern Solvers Main Components Conclusion / Challenges

TODAY’S ITINARY

1 A HISTORY OF 50 YEARS OF SAT RESEARCH 2 MODERN SAT SOLVERS : CDCL

Principles of Clause Learning and Backjumping (Giant) Industrial Problems The CDCL solvers

3 MAIN COMPONENTS AND FEATURES 4 CONCLUDING ON CHALLENGES

29/66

slide-82
SLIDE 82

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-83
SLIDE 83

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-84
SLIDE 84

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-85
SLIDE 85

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-86
SLIDE 86

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-87
SLIDE 87

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-88
SLIDE 88

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-89
SLIDE 89

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE LEARNING

During backtrack search, for each conflict learn new clause, which explains and prevents repetition of the same conflict ϕ = ( a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f ) . . .

Assume decisions c = False and f = False Assign a = False and imply assignments A conflict is reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬a ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ a ∨ c ∨ f Learn new clause (a ∨ c ∨ f)

30/66

slide-90
SLIDE 90

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-91
SLIDE 91

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-92
SLIDE 92

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-93
SLIDE 93

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-94
SLIDE 94

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-95
SLIDE 95

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-96
SLIDE 96

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-97
SLIDE 97

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-98
SLIDE 98

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

During backtrack search, for each conflict backtrack to one of the causes

  • f the conflict

ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f )∧ (a ∨ c ∨ f ) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k)

Assume decisions c = False, f = False, h = False and i = False Assignment a = False caused conflict ⇒ learnt clause (a ∨ c ∨ f) implies a A conflict is again reached : (¬d ∨ ¬e ∨ f) is unsatisfied ϕ ∧ ¬c ∧ ¬f ⇒ ⊥ ϕ ⇒ c ∨ f Learn new clause (c ∨ f)

31/66

slide-99
SLIDE 99

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

i h f a

(c + f ) (a + c + f )

c

32/66

slide-100
SLIDE 100

History of SAT Modern Solvers Main Components Conclusion / Challenges

NON-CHRONOLOGICAL BACKTRACKING

i h f a

(c + f ) (a + c + f )

c

Learnt clause : (c ∨ f) Need to backtrack, given new clause Backtrack to most recent decision : f = False Clause learning and non-chronological backtracking are hallmarks of modern SAT solvers

32/66

slide-101
SLIDE 101

History of SAT Modern Solvers Main Components Conclusion / Challenges

HOW TO IMPLEMENT NCB AND LEARNING ? RESOLUTION !

Perform resolution steps in reverse order of the assignments. Propagations deriving from a : g,b,d, e ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e ) ∧ (¬d ∨ ¬e ∨ f)∧ (a ∨ c ∨ f) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k) Learned : (a ∨ c ∨ f) (¬d ∨ ¬e ∨ f)

33/66

slide-102
SLIDE 102

History of SAT Modern Solvers Main Components Conclusion / Challenges

HOW TO IMPLEMENT NCB AND LEARNING ? RESOLUTION !

Perform resolution steps in reverse order of the assignments. Propagations deriving from a : g,b, d ,e ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d ) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f)∧ (a ∨ c ∨ f) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k) Learned : (a ∨ c ∨ f) (¬b ∨ ¬d ∨ f)

33/66

slide-103
SLIDE 103

History of SAT Modern Solvers Main Components Conclusion / Challenges

HOW TO IMPLEMENT NCB AND LEARNING ? RESOLUTION !

Perform resolution steps in reverse order of the assignments. Propagations deriving from a : g, b ,d,e ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f)∧ (a ∨ c ∨ f) ∧ (¬a ∨ g) ∧ (¬g ∨ b ) ∧ (¬h ∨ j) ∧ (¬i ∨ k) Learned : (a ∨ c ∨ f) ( ¬b ∨ c ∨ f)

33/66

slide-104
SLIDE 104

History of SAT Modern Solvers Main Components Conclusion / Challenges

HOW TO IMPLEMENT NCB AND LEARNING ? RESOLUTION !

Perform resolution steps in reverse order of the assignments. Propagations deriving from a : g ,b,d,e ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f)∧ (a ∨ c ∨ f) ∧ (¬a ∨ g ) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k) Learned : (a ∨ c ∨ f) ( ¬g ∨ c ∨ f)

33/66

slide-105
SLIDE 105

History of SAT Modern Solvers Main Components Conclusion / Challenges

HOW TO IMPLEMENT NCB AND LEARNING ? RESOLUTION !

Perform resolution steps in reverse order of the assignments. Propagations deriving from a : g,b,d,e ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f)∧ (a ∨ c ∨ f) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k) Learned : ( a ∨ c ∨ f) ( ¬a ∨ c ∨ f)

33/66

slide-106
SLIDE 106

History of SAT Modern Solvers Main Components Conclusion / Challenges

HOW TO IMPLEMENT NCB AND LEARNING ? RESOLUTION !

Perform resolution steps in reverse order of the assignments. Propagations deriving from a : g,b,d,e ϕ = (a ∨ b) ∧ (¬b ∨ c ∨ d) ∧ (¬b ∨ e) ∧ (¬d ∨ ¬e ∨ f)∧ (a ∨ c ∨ f) ∧ (¬a ∨ g) ∧ (¬g ∨ b) ∧ (¬h ∨ j) ∧ (¬i ∨ k) Learned : ( a ∨ c ∨ f) (c ∨ f)

33/66

slide-107
SLIDE 107

History of SAT Modern Solvers Main Components Conclusion / Challenges

IMPLEMENTATION OF NCB AND LEARNING FOR SAT

Two approaches developed independently in two different research communities : GRASP/EDA by Marques-Silva and Sakallah (1996)

Resolution graph seen as a circuit Conflict analysis thought as detecting faults in a circuit Other sophisticated conflict analysis methods based on truth maintenance systems

RELSAT/CSP by Bayardo and Schrag (1997)

Introduction of CSP based techniques into a SAT solver Conflict Directed Backjumping aka non chronological backtracking [Prosser 93] Size based and relevance based learning schemes

Main difference : in GRASP’s framework, the conflict analysis drives the search, while in RELSAT it is the heuristics (more later).

34/66

slide-108
SLIDE 108

History of SAT Modern Solvers Main Components Conclusion / Challenges

YEARS 2000, SAT ENTERS INTO ITS INDUSTRIAL ERA

Unit propagations are important, Maintaining good heuristics (for look-ahead) is costly, The Try/Think compromise is not clear

Heuristics (think) are too costly Heuristics are some kind of search On some problems, naive heuristics can give good performances...

Grasp brought the learning mecanism to SAT But industrial problems are still not there....

35/66

slide-109
SLIDE 109

History of SAT Modern Solvers Main Components Conclusion / Challenges

YEARS 2000, SAT ENTERS INTO ITS INDUSTRIAL ERA

Unit propagations are important, Maintaining good heuristics (for look-ahead) is costly, The Try/Think compromise is not clear

Heuristics (think) are too costly Heuristics are some kind of search On some problems, naive heuristics can give good performances...

Grasp brought the learning mecanism to SAT But industrial problems are still not there....

35/66

slide-110
SLIDE 110

History of SAT Modern Solvers Main Components Conclusion / Challenges

INDUSTRIAL PROBLEMS : UNROLLING SEPS (IBM)

36/66

slide-111
SLIDE 111

History of SAT Modern Solvers Main Components Conclusion / Challenges

INDUSTRIAL PROBLEMS : UNROLLING SEPS (IBM)

T i m e u n r

  • l

l i n g

36/66

slide-112
SLIDE 112

History of SAT Modern Solvers Main Components Conclusion / Challenges

INDUSTRIAL PROBLEMS : UNROLLING SEPS (IBM)

T i m e u n r

  • l

l i n g

Backdoors

36/66

slide-113
SLIDE 113

History of SAT Modern Solvers Main Components Conclusion / Challenges

CHAFF CHANGED THE WAY WE THINK

GIANT FORMULAS ARE HERE

Pragmatic solution : data structures. We only detect unit propagation once they are fired (but not a single step before) Chaff: Engineering an Efficient SAT Solver

Matthew W. Moskewicz Department of EECS UC Berkeley moskewcz@alumni.princeton.edu Conor F. Madigan Department of EECS MIT cmadigan@mit.edu Ying Zhao, Lintao Zhang, Sharad Malik Department of Electrical Engineering Princeton University {yingzhao, lintaoz, sharad}@ee.princeton.edu

CONSEQUENCES

Algorithms are blind The whole CDCL architecture is turned to learning (look-back)

37/66

slide-114
SLIDE 114

History of SAT Modern Solvers Main Components Conclusion / Challenges

CHAFF CHANGED THE WAY WE THINK

GIANT FORMULAS ARE HERE

Pragmatic solution : data structures. We only detect unit propagation once they are fired (but not a single step before) Chaff: Engineering an Efficient SAT Solver

Matthew W. Moskewicz Department of EECS UC Berkeley moskewcz@alumni.princeton.edu Conor F. Madigan Department of EECS MIT cmadigan@mit.edu Ying Zhao, Lintao Zhang, Sharad Malik Department of Electrical Engineering Princeton University {yingzhao, lintaoz, sharad}@ee.princeton.edu

CONSEQUENCES

Algorithms are blind The whole CDCL architecture is turned to learning (look-back)

37/66

slide-115
SLIDE 115

History of SAT Modern Solvers Main Components Conclusion / Challenges

CHAFF CHANGED THE WAY WE THINK

GIANT FORMULAS ARE HERE

Pragmatic solution : data structures. We only detect unit propagation once they are fired (but not a single step before) Chaff: Engineering an Efficient SAT Solver

Matthew W. Moskewicz Department of EECS UC Berkeley moskewcz@alumni.princeton.edu Conor F. Madigan Department of EECS MIT cmadigan@mit.edu Ying Zhao, Lintao Zhang, Sharad Malik Department of Electrical Engineering Princeton University {yingzhao, lintaoz, sharad}@ee.princeton.edu

CONSEQUENCES

Algorithms are blind The whole CDCL architecture is turned to learning (look-back)

37/66

slide-116
SLIDE 116

History of SAT Modern Solvers Main Components Conclusion / Challenges

CHAFF CHANGED THE WAY WE THINK

GIANT FORMULAS ARE HERE

Pragmatic solution : data structures. We only detect unit propagation once they are fired (but not a single step before) Chaff: Engineering an Efficient SAT Solver

Matthew W. Moskewicz Department of EECS UC Berkeley moskewcz@alumni.princeton.edu Conor F. Madigan Department of EECS MIT cmadigan@mit.edu Ying Zhao, Lintao Zhang, Sharad Malik Department of Electrical Engineering Princeton University {yingzhao, lintaoz, sharad}@ee.princeton.edu

CONSEQUENCES

Algorithms are blind The whole CDCL architecture is turned to learning (look-back)

37/66

slide-117
SLIDE 117

History of SAT Modern Solvers Main Components Conclusion / Challenges

CHAFF CHANGED THE WAY WE THINK

GIANT FORMULAS ARE HERE

Pragmatic solution : data structures. We only detect unit propagation once they are fired (but not a single step before) Chaff: Engineering an Efficient SAT Solver

Matthew W. Moskewicz Department of EECS UC Berkeley moskewcz@alumni.princeton.edu Conor F. Madigan Department of EECS MIT cmadigan@mit.edu Ying Zhao, Lintao Zhang, Sharad Malik Department of Electrical Engineering Princeton University {yingzhao, lintaoz, sharad}@ee.princeton.edu

CONSEQUENCES

Algorithms are blind The whole CDCL architecture is turned to learning (look-back)

37/66

slide-118
SLIDE 118

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9

38/66

slide-119
SLIDE 119

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1]

38/66

slide-120
SLIDE 120

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1]

38/66

slide-121
SLIDE 121

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1] DL 2 x3 x3,x8[φ2], x12[φ3]

38/66

slide-122
SLIDE 122

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1] DL 2 x3 x3,x8[φ2], x12[φ3]

38/66

slide-123
SLIDE 123

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1] DL 2 x3 x3,x8[φ2], x12[φ3]

38/66

slide-124
SLIDE 124

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1] DL 2 x3 x3,x8[φ2], x12[φ3] DL 3 x2 x2, x11[φ4]

38/66

slide-125
SLIDE 125

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

DECISIONS – PROPAGATIONS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1,x4[φ1] DL 2 x3 x3,x8[φ2], x12[φ3] DL 3 x2 x2, x11[φ4] DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7]

38/66

slide-126
SLIDE 126

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

CONFLICT ANALYSIS

DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9

39/66

slide-127
SLIDE 127

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

CONFLICT ANALYSIS

DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] β1 = res(x9, φ7, φ6) = x3 ∨ x8∨ x7 ∨ x13 φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9

39/66

slide-128
SLIDE 128

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

CONFLICT ANALYSIS

DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] β1 = res(x9, φ7, φ6) = x3 ∨ x8∨ x7 ∨ x13 β = res(x13, β1, φ5) = x3 ∨ x8∨ x7 φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9

39/66

slide-129
SLIDE 129

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

CONFLICT ANALYSIS

DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] β1 = res(x9, φ7, φ6) = x3 ∨ x8∨ x7 ∨ x13 β = res(x13, β1, φ5) = x3 ∨ x8∨ x7 Stops as soon as the resolvant has a unique literal from the last decision level (FUIP). β is added to the clauses databases (ensure a systematic search)

39/66

slide-130
SLIDE 130

History of SAT Modern Solvers Main Components Conclusion / Challenges

A REAL IMPLICATION GRAPH

40/66

slide-131
SLIDE 131

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

NON CHRONOLOGICAL BACKTRACKINGS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1, x4[φ1] DL 2 x3 x3, x8[φ2], x12[φ3], x7[β]... DL 3 x2 x2, x11[φ4] DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] β = x3 ∨ x8 ∨ x7

41/66

slide-132
SLIDE 132

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

NON CHRONOLOGICAL BACKTRACKINGS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1, x4[φ1] DL 2 x3 x3, x8[φ2], x12[φ3], x7[β]... DL 3 x2 x2, x11[φ4] DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] β = x3 ∨ x8 ∨ x7

41/66

slide-133
SLIDE 133

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

NON CHRONOLOGICAL BACKTRACKINGS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1, x4[φ1] DL 2 x3 x3, x8[φ2], x12[φ3], x7[β]... DL 3 x2 x2, x11[φ4] DL 4 x7 x7, x13[φ5], x9[φ6], x9[φ7] β = x3 ∨ x8 ∨ x7

41/66

slide-134
SLIDE 134

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL PRINCIPLES AT A GLANCE

NON CHRONOLOGICAL BACKTRACKINGS

φ1 = x1 ∨ x4 φ2 = x1 ∨ x3 ∨ x8 φ3 = x1 ∨ x8 ∨ x12 φ4 = x2 ∨ x11 φ5 = x3 ∨ x7 ∨ x13 φ6 = x3 ∨ x7 ∨ x13 ∨ x9 φ7 = x8 ∨ x7 ∨ x9 DL 1 x1 x1, x4[φ1] DL 2 x3 x3, x8[φ2], x12[φ3], x7[β]... β = x3 ∨ x8 ∨ x7

41/66

slide-135
SLIDE 135

History of SAT Modern Solvers Main Components Conclusion / Challenges

THE “MODERN” SAT SOLVERS

BEFORE zchaff [2001] : lookahead

« if we want to know where to go, we must know where we are » Balance both subtrees sizes Maintain heuristics counters

AFTER zchaff [2001] : lookback

« we know what we have done, but not where we are » Learning, lazy unit propagation Ultra-Rapid Restarts Ultra-Dynamic Heuristics (1/10s life) Efficient (and smart) Pre-Processing ...

42/66

slide-136
SLIDE 136

History of SAT Modern Solvers Main Components Conclusion / Challenges

THE “MODERN” SAT SOLVERS

BEFORE zchaff [2001] : lookahead

« if we want to know where to go, we must know where we are » Balance both subtrees sizes Maintain heuristics counters

AFTER zchaff [2001] : lookback

« we know what we have done, but not where we are » Learning, lazy unit propagation Ultra-Rapid Restarts Ultra-Dynamic Heuristics (1/10s life) Efficient (and smart) Pre-Processing ...

42/66

slide-137
SLIDE 137

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN AND AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) General Resolution (CDCL01) Bounded Depth (AIGER ?,BDD ?) Extended Resolution (ER)

43/66

slide-138
SLIDE 138

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN AND AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) General Resolution (CDCL01) Bounded Depth (AIGER ?,BDD ?) Extended Resolution (ER)

43/66

slide-139
SLIDE 139

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN AND AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) General Resolution (CDCL01) Bounded Depth (AIGER ?,BDD ?) Extended Resolution (ER)

43/66

slide-140
SLIDE 140

History of SAT Modern Solvers Main Components Conclusion / Challenges

WE PROGRESS... AGAIN AND AGAIN !

Truth tables Ordered Resolution (DP60) Tree-like Resolution (DPLL62) General Resolution (CDCL01) Bounded Depth (AIGER ?,BDD ?) Extended Resolution (ER)

43/66

slide-141
SLIDE 141

History of SAT Modern Solvers Main Components Conclusion / Challenges

TODAY’S ITINARY

1 A HISTORY OF 50 YEARS OF SAT RESEARCH 2 MODERN SAT SOLVERS : CDCL 3 MAIN COMPONENTS AND FEATURES

SAT Solver Components PreProcessing Branching Heuristics Restarts Conflict Analysis Clause Database Cleaning

4 CONCLUDING ON CHALLENGES

44/66

slide-142
SLIDE 142

History of SAT Modern Solvers Main Components Conclusion / Challenges

SAT SOLVER COMPONENTS

Preprocessing Restarting Branching Conflict Analysis Clause Data- base Cleaning

45/66

slide-143
SLIDE 143

History of SAT Modern Solvers Main Components Conclusion / Challenges

CONFLICT CLAUSE MINIMIZATION

MINISAT 1.13, N. SÖRENSSON, A. BIERE. MINIMIZING LEARNED CLAUSES. IN PROC. 12TH INTL.

  • CONF. ON THEORY AND APPLICATIONS OF SATISFIABILITY TESTING (SAT’09), LECTURE NOTES IN

COMPUTER SCIENCE (LNCS) VOL. 5584, PAGES 237-243, SPRINGER 2009.

Clauses generated using the 1st UIP scheme can be simplified Using simple direct self subsumption (direct dependencies among the clause’s literals outside current decision level) : self subsumption: x1@1 ∨ x2@1 ∨ x3@2 x1@1 ∨ ¬x2@1 x1@1 ∨ x3@2 Using a chain of resolution steps

46/66

slide-144
SLIDE 144

Recursively Minimizing Learned Clause

Minimizing Learned Clauses [S¨

  • renssonBiere-SAT’09]

30

a = 1 @ 0 = 1 @ 2 f l = 1 @ 3 = 1 @ 1 c k = 1 @ 3 r = 1 @ 4

top−level decision decision decision unit decision

= 1 @ 4 !

conflict

y s g d = 1 @ 4 = 1 @ 2 = 1 @ 1 t z = 1 @ 4 x = 1 @ 4 = 1 @ 4 = 1 @ 2 i = 1 @ 2 h

unit

b e = 1 @ 0 = 1 @ 1 (b) (d ∨b∨e) (e∨g∨h) (d ∨g∨s∨h) (e∨d ∨g∨s) (b∨d ∨g∨s) (d ∨g∨s)

SAT, SMT and Applications – LPNMR’09 Armin Biere – FMV – JKU Linz

slide-145
SLIDE 145

History of SAT Modern Solvers Main Components Conclusion / Challenges

PREPROCESSING

NIKLAS EÉN, ARMIN BIERE : EFFECTIVE PREPROCESSING IN SAT THROUGH VARIABLE AND CLAUSE

  • ELIMINATION. SAT 2005 : 61-75

Variable elimination

as in DP60 if the number of clauses does not increase by substitution if a definition such as x ↔ y1 ∨ ... ∨ yn or x ↔ y1 ∧ ... ∧ yn is detected.

Clause subsumption

self subsumption classical subsumption

SatELite : de-facto standard pre-processor since 2005 Included in Minisat 2 (better integration with the SAT solver) Still used by SAT solver designers that do not want to implement their

  • wn

48/66

slide-146
SLIDE 146

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE MINIMIZATION AND PREPROCESSING @SAT COMP. 2005

50 100 150 200 250 300 2000 4000 6000 8000 10000 12000 14000 wllsatv1 hsat.5 vallst.sh sat4j.jar compsat zchaff zchaffrand csat HaifaSat Jerusat1.31B minisatstatic SatELiteGTI

#Solved CPUTime needed (s)

Second Stage: All solvers on renamed Industrial benchmarks

wllsatv1 (92) hsat.5 (153) vallst.sh (154) sat4j.jar (180) compsat (189) zchaff (197) zchaffrand (226) csat (231) HaifaSat (242) Jerusat1.31B (243) minisatstatic (250) SatELiteGTI (267)

49/66

slide-147
SLIDE 147

History of SAT Modern Solvers Main Components Conclusion / Challenges

BRANCHING HEURISTICS

CDCL SOLVERS ARE STILL EXPLORING A SEARCH TREE

IN CHAFF’S MIND

We must try to satisfy a litteral that occured a lot in recent learnt clauses

IN MINISAT

Branch on variables seen during recents conflict analysis Last improvement : Phase saving

OPEN QUESTIONS

Find a good first assignment Why variables are importants (and not literals ?) Have two heuristics : One for SAT, one for UNSAT

50/66

slide-148
SLIDE 148

History of SAT Modern Solvers Main Components Conclusion / Challenges

RESTARTS, COMMON IDEA

Restarts are commonly used in local search algorithms. Idea : when the search failed, look at another part of the search space (looking for a solution). Heavy Tailed Phenomenon Observed on Search Trees

51/66

slide-149
SLIDE 149

History of SAT Modern Solvers Main Components Conclusion / Challenges

RESTARTS, COMMON IDEA

Restarts are commonly used in local search algorithms. Idea : when the search failed, look at another part of the search space (looking for a solution). Heavy Tailed Phenomenon Observed on Search Trees

51/66

slide-150
SLIDE 150

History of SAT Modern Solvers Main Components Conclusion / Challenges

RESTARTS, COMMON IDEA

Restarts are commonly used in local search algorithms. Idea : when the search failed, look at another part of the search space (looking for a solution). Restarts are introduced to fight against this phenomenon Note : Learning allows frequent restarts. The completeness is still guarantee.

51/66

slide-151
SLIDE 151

History of SAT Modern Solvers Main Components Conclusion / Challenges

NOW : ULTRA-RAPID RESTARTS

LAST PROGRESS

Luby-law restarts (1,2,1,2,4,1,2,1,2,4,8,1,2,1,2,4,1,2,1,2,4,8,16,...) Multiplied by a constant (32, 64, 128, 512).

OTHER EXOTIC STATEGIES

decision levels / LBD based / agility Idea When the solver does not make any progress, restart Important thing : restart a lot (optimal : Luby 6), use in conjonction with phase-saving

52/66

slide-152
SLIDE 152

History of SAT Modern Solvers Main Components Conclusion / Challenges

NOW : ULTRA-RAPID RESTARTS

LAST PROGRESS

Luby-law restarts (1,2,1,2,4,1,2,1,2,4,8,1,2,1,2,4,1,2,1,2,4,8,16,...) Multiplied by a constant (32, 64, 128, 512).

OTHER EXOTIC STATEGIES

decision levels / LBD based / agility Idea When the solver does not make any progress, restart Important thing : restart a lot (optimal : Luby 6), use in conjonction with phase-saving

52/66

slide-153
SLIDE 153

History of SAT Modern Solvers Main Components Conclusion / Challenges

OPEN QUESTIONS ON RESTARTS

Luby’s strategy is optimal... When we blindly exploite/explore a process !

RESTARTS DO NOT RESTART SEARCH

Heuristics are maintained during a restarts. The solver directly goes to the same search space, but with a distinct path.

OPEN QUESTIONS

When to restart ? Relationship with learning (selecting a variable on the top of the search tree means that will probably don’t use it during resolution steps). What kind of decomposition branching achieves ?

53/66

slide-154
SLIDE 154

History of SAT Modern Solvers Main Components Conclusion / Challenges

COMPARISON OF A FEW DIFFERENT RESTARTS STRATEGIES

54/66

slide-155
SLIDE 155

History of SAT Modern Solvers Main Components Conclusion / Challenges

EFFECT OF RAPID RESTARTS IN SAT4J

Using the SAT Race 2006 benchmarks set (100 benchmarks), with a timeout

  • f 900 seconds per benchmark :

Configuration Total SAT UNSAT Time MiniSAT 58 29 29 835 Luby (factor 32) 59 24 35 790 Luby (factor 512, no PS, no CCM) 48 19 29 947 Luby (factor 512, no CCM) 55 26 29 866 Luby scheme (factor 512) 61 29 32 788 Armin 61 27 34 790 Time is given in minutes, on a PIV 3GHz, 1.5GB of RAM, Java 6 VM under Mandriva Linux 2007.1.

55/66

slide-156
SLIDE 156

History of SAT Modern Solvers Main Components Conclusion / Challenges

ADAPTATIVE RESTARTS DURING THE SAT 2009 COMPETITION

PICOSAT A. Biere. Adaptive Restart Control for Conflict Driven SAT

  • Solvers. In Proc. 11th Intl. Conf. on Theory and Applications
  • f Satisfiability Testing (SAT’08), Lecture Notes in Computer

Science (LNCS) vol. 4996, Springer 2008. MINISAT09Z Carsten Sinz, Markus Iser : Problem-Sensitive Restart Heuristics for the DPLL Procedure. SAT 2009 : 356-362 LYSAT Youssef Hamadi, Said Jabbour, and Lakhdar Sais. ManySAT : a Parallel SAT Solver. Volume 6 (2009), pages 245-262.

GLUCOSE Predicting Learnt Clauses Quality in Modern SAT Solver G.

Audemard, L. Simon, in Twenty-first International Joint Conference on Artificial Intelligence (IJCAI’09), july 2009.

56/66

slide-157
SLIDE 157

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-158
SLIDE 158

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-159
SLIDE 159

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-160
SLIDE 160

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-161
SLIDE 161

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-162
SLIDE 162

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-163
SLIDE 163

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-164
SLIDE 164

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-165
SLIDE 165

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-166
SLIDE 166

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-167
SLIDE 167

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-168
SLIDE 168

History of SAT Modern Solvers Main Components Conclusion / Challenges

LET’S GET BACK TO CONFLICT ANALYSIS

¬x1 x4 ¬x7 ¬x10 “reason” side x16 ¬x16 “conflict” side x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 “FUIP” cut ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

57/66

slide-169
SLIDE 169

History of SAT Modern Solvers Main Components Conclusion / Challenges

CONFLICT ANALYSIS

NOT SO MUCH PROGRESS THERE

First UIP is still the best strategy It is optimal in the backjump level It is optimal for the LBD score Question : Do we have to learn all clauses ? Some clause have a very small life time... are they still usefull ?

OPEN QUESTIONS

How to separate heuritics update from conflict analysis (sometimes we learn, sometimes we just update the heuristics, sometimes we do both). Conflict analysis is implied by decisions. Can’t we do the opposite ?

58/66

slide-170
SLIDE 170

History of SAT Modern Solvers Main Components Conclusion / Challenges

CONFLICT ANALYSIS

NOT SO MUCH PROGRESS THERE

First UIP is still the best strategy It is optimal in the backjump level It is optimal for the LBD score Question : Do we have to learn all clauses ? Some clause have a very small life time... are they still usefull ?

OPEN QUESTIONS

How to separate heuritics update from conflict analysis (sometimes we learn, sometimes we just update the heuristics, sometimes we do both). Conflict analysis is implied by decisions. Can’t we do the opposite ?

58/66

slide-171
SLIDE 171

History of SAT Modern Solvers Main Components Conclusion / Challenges

CLAUSE DATABASE CLEANING

MOST OF THE PROGRESSES MADE LAST YEARS CAME FROM HERE

Revisits the initial idea of CDCL. Learning was important for completeness. glucose removes 95% of its learnt clauses. Where is its completeness ?

OPEN QUESTIONS

Why removing so many clauses is good ? Can we learn bad clauses ?

59/66

slide-172
SLIDE 172

History of SAT Modern Solvers Main Components Conclusion / Challenges

LEARNING TOO MANY CLAUSES : A PROBLEM OF CDCL SOLVERS

CDCL solvers are very fast They learn thousands of clauses a second ; They must run for thousands of seconds ; They fill very quickly the memory ; They degrade their unit-propagation speed ;

KEEPING AS MANY CLAUSES IS GOOD

Guarantee the completeness of the search ; Match the initial idea of the learning scheme ;

FORGETTING IS GOOD

Allows to be fast Danger : forgetting important clauses Before Glucose : no clues about what makes a good clause

60/66

slide-173
SLIDE 173

History of SAT Modern Solvers Main Components Conclusion / Challenges

LEARNING TOO MANY CLAUSES : A PROBLEM OF CDCL SOLVERS

CDCL solvers are very fast They learn thousands of clauses a second ; They must run for thousands of seconds ; They fill very quickly the memory ; They degrade their unit-propagation speed ;

KEEPING AS MANY CLAUSES IS GOOD

Guarantee the completeness of the search ; Match the initial idea of the learning scheme ;

FORGETTING IS GOOD

Allows to be fast Danger : forgetting important clauses Before Glucose : no clues about what makes a good clause

60/66

slide-174
SLIDE 174

History of SAT Modern Solvers Main Components Conclusion / Challenges

LEARNING TOO MANY CLAUSES : A PROBLEM OF CDCL SOLVERS

CDCL solvers are very fast They learn thousands of clauses a second ; They must run for thousands of seconds ; They fill very quickly the memory ; They degrade their unit-propagation speed ;

KEEPING AS MANY CLAUSES IS GOOD

Guarantee the completeness of the search ; Match the initial idea of the learning scheme ;

FORGETTING IS GOOD

Allows to be fast Danger : forgetting important clauses Before Glucose : no clues about what makes a good clause

60/66

slide-175
SLIDE 175

History of SAT Modern Solvers Main Components Conclusion / Challenges

LEARNING TOO MANY CLAUSES : A PROBLEM OF CDCL SOLVERS

CDCL solvers are very fast They learn thousands of clauses a second ; They must run for thousands of seconds ; They fill very quickly the memory ; They degrade their unit-propagation speed ;

KEEPING AS MANY CLAUSES IS GOOD

Guarantee the completeness of the search ; Match the initial idea of the learning scheme ;

FORGETTING IS GOOD

Allows to be fast Danger : forgetting important clauses Before Glucose : no clues about what makes a good clause

60/66

slide-176
SLIDE 176

History of SAT Modern Solvers Main Components Conclusion / Challenges

GLUCOSE : QUALITY (OF CLAUSES) IS GUARANTEED

¬x1 x4 ¬x7 ¬x10 Côté « raison » x16 ¬x16 Côté « conflictuel » x2 ¬x3 ¬x5 x6 ¬x8 x9 x11 ¬x12 x15 x14 ¬x13 ¬x16 ∨ x16 x13 ∨ ¬x14 ∨ ¬x15 ¬x6 ∨ x12 Coupure « FUIP » ¬x6 ∨ x8 ∨ ¬x11 x1 ∨ ¬x4 ∨ x7 ∨ x10 1 2 3 4

61/66

slide-177
SLIDE 177

History of SAT Modern Solvers Main Components Conclusion / Challenges

GLUCOSE : QUALITY (OF CLAUSES) IS GUARANTEED

BASIC IDEA

A learnt clause will link together blocs of propagated literals ; Stronger links are better ; Score : Number of decision levels in the clause

IMPACT

Allows to aggressively clean up the clause database Now embedded in many solvers A particular case : the “glues” clauses

2 3 4 5 LBD 2452 295 136 80 Size 1827 884 305 195

#times a clause was used during conflict analysis (Avg)

61/66

slide-178
SLIDE 178

History of SAT Modern Solvers Main Components Conclusion / Challenges

GLUCOSE : QUALITY (OF CLAUSES) IS GUARANTEED

BASIC IDEA

A learnt clause will link together blocs of propagated literals ; Stronger links are better ; Score : Number of decision levels in the clause

IMPACT

Allows to aggressively clean up the clause database Now embedded in many solvers A particular case : the “glues” clauses

2 3 4 5 LBD 2452 295 136 80 Size 1827 884 305 195

#times a clause was used during conflict analysis (Avg)

61/66

slide-179
SLIDE 179

History of SAT Modern Solvers Main Components Conclusion / Challenges

GLUCOSE : QUALITY (OF CLAUSES) IS GUARANTEED

BASIC IDEA

A learnt clause will link together blocs of propagated literals ; Stronger links are better ; Score : Number of decision levels in the clause

IMPACT

Allows to aggressively clean up the clause database Now embedded in many solvers A particular case : the “glues” clauses

2 3 4 5 LBD 2452 295 136 80 Size 1827 884 305 195

#times a clause was used during conflict analysis (Avg)

61/66

slide-180
SLIDE 180

History of SAT Modern Solvers Main Components Conclusion / Challenges

GLUCOSE : QUALITY (OF CLAUSES) IS GUARANTEED

BASIC IDEA

A learnt clause will link together blocs of propagated literals ; Stronger links are better ; Score : Number of decision levels in the clause

IMPACT

Allows to aggressively clean up the clause database Now embedded in many solvers A particular case : the “glues” clauses

2 3 4 5 LBD 2452 295 136 80 Size 1827 884 305 195

#times a clause was used during conflict analysis (Avg)

61/66

slide-181
SLIDE 181

History of SAT Modern Solvers Main Components Conclusion / Challenges

GLUCOSE : QUALITY (OF CLAUSES) IS GUARANTEED

BASIC IDEA

A learnt clause will link together blocs of propagated literals ; Stronger links are better ; Score : Number of decision levels in the clause

IMPACT

Allows to aggressively clean up the clause database Now embedded in many solvers A particular case : the “glues” clauses

2 3 4 5 LBD 2452 295 136 80 Size 1827 884 305 195

#times a clause was used during conflict analysis (Avg)

61/66

slide-182
SLIDE 182

History of SAT Modern Solvers Main Components Conclusion / Challenges

TODAY’S ITINARY

1 A HISTORY OF 50 YEARS OF SAT RESEARCH 2 MODERN SAT SOLVERS : CDCL 3 MAIN COMPONENTS AND FEATURES 4 CONCLUDING ON CHALLENGES

Why CDCL are so efficient ? The challenges

62/66

slide-183
SLIDE 183

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL SOLVERS ARE SLOWLY MOVING

Nowadays solvers are more and more incomplete. glucose removes a lot of clauses PSM sees the phase saving has a global assignment. Slowly moving, but really changing the face of the SAT world

63/66

slide-184
SLIDE 184

History of SAT Modern Solvers Main Components Conclusion / Challenges

CDCL : TWO OPPOSITES FORCES

SPLIT IN SUBPROBLEMS (DECOMPOSITION)

CDCL solvers still explore search trees Heuristics can smartly do it (very reactive)

LINK SUBPROBLEMS

Learning is based on resolution It links independant subproblems togethers

64/66

slide-185
SLIDE 185

History of SAT Modern Solvers Main Components Conclusion / Challenges

THREE SUCCESS REASONS (TENTATIVE)

(1) Splits and Merges at the same time (2) Reactive Balance between think and try (3) Search for an “easy” proof

65/66

slide-186
SLIDE 186

History of SAT Modern Solvers Main Components Conclusion / Challenges

SAT CHALLENGES

Use parallel architectures Solve QBF instances More powerfull proof systems Understand CDCL

66/66