Efficiently Reasoning about Programs

Size: px
Start display at page:

Download "Efficiently Reasoning about Programs"

Transcription

1 Efficiently Reasoning about Programs Neil Immerman College of Computer and Information Sciences University of Massachusetts, Amherst Amherst, MA, USA people.cs.umass.edu/ immerman

2 co-r.e. complete Halt co-r.e. Arithmetic Hierarchy FO(N) r.e. complete Halt FO (N) FO (N) Recursive r.e. Primitive Recursive SO[2 no(1) ] EXPTIME QSAT PSPACE complete FO[2 no(1) ] SO[n O(1) ] PSPACE co-np complete SAT co-np SO PTIME Hierarchy SO NP complete SAT SO NP co-np NP FO[n O(1) ] FO(LFP) FO[log O(1) n] Horn- SAT truly P complete P NC FO[log n] feasible AC 1 FO(CFL) FO(TC) FO(DTC) FO(REGULAR) FO(COUNT) FO 2SAT 2COLOR NL comp. L comp. LOGTIME Hierarchy sac 1 NL L NC 1 ThC 0 AC 0

3 Thm. [Turing 1936] Halt undecidable. co-r.e. complete Halt co-r.e. Arithmetic Hierarchy FO(N) r.e. complete Halt FO (N) FO (N) Recursive r.e. Primitive Recursive SO[2 no(1) ] EXPTIME QSAT PSPACE complete FO[2 no(1) ] SO[n O(1) ] PSPACE co-np complete SAT co-np SO PTIME Hierarchy SO NP complete SAT SO NP co-np NP FO[n O(1) ] FO(LFP) FO[log O(1) n] Horn- SAT truly P complete P NC FO[log n] feasible AC 1 FO(CFL) FO(TC) FO(DTC) FO(REGULAR) FO(COUNT) FO 2SAT 2COLOR NL comp. L comp. LOGTIME Hierarchy sac 1 NL L NC 1 ThC 0 AC 0

4 Halt is r.e. complete

5 Halt is r.e. complete w Σ (α(w)) M α Halt

6 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt.

7 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt. Cannot check correctness of arbitrary input program.

8 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt. Cannot check correctness of arbitrary input program. Long-Term Societal Goal:

9 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt. Cannot check correctness of arbitrary input program. Long-Term Societal Goal: Automatic help to produce programs that are

10 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt. Cannot check correctness of arbitrary input program. Long-Term Societal Goal: Automatic help to produce programs that are certified to safely and faithfully

11 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt. Cannot check correctness of arbitrary input program. Long-Term Societal Goal: Automatic help to produce programs that are certified to safely and faithfully do what they should do

12 Halt is r.e. complete w Σ (α(w)) M α Halt Any arbitrary search problem can be translated to Halt. Cannot check correctness of arbitrary input program. Long-Term Societal Goal: Automatic help to produce programs that are certified to safely and faithfully do what they should do and not do what they should not do.

13 Thm. [Turing 1936] Halt undecidable. co-r.e. complete Halt co-r.e. Arithmetic Hierarchy FO(N) r.e. complete Halt FO (N) FO (N) Recursive r.e. Primitive Recursive SO[2 no(1) ] EXPTIME QSAT PSPACE complete FO[2 no(1) ] SO[n O(1) ] PSPACE co-np complete SAT co-np SO PTIME Hierarchy SO NP complete SAT SO NP co-np NP FO[n O(1) ] FO(LFP) FO[log O(1) n] Horn- SAT truly P complete P NC FO[log n] feasible AC 1 FO(CFL) FO(TC) FO(DTC) FO(REGULAR) FO(COUNT) FO 2SAT 2COLOR NL comp. L comp. LOGTIME Hierarchy sac 1 NL L NC 1 ThC 0 AC 0

14 Thm. [Turing 1936] Halt undecidable. co-r.e. complete Halt co-r.e. Arithmetic Hierarchy FO(N) r.e. complete Halt FO (N) FO (N) Recursive r.e. Primitive Recursive SO[2 no(1) ] EXPTIME Thm. [Cook 1971] SAT is NP complete. QSAT PSPACE complete FO[2 no(1) ] SO[n O(1) ] PSPACE co-np complete SAT co-np FO[n O(1) ] FO(LFP) SO PTIME Hierarchy SO NP complete SAT SO NP co-np NP Horn- SAT P complete P FO[log O(1) n] truly NC FO[log n] feasible AC 1 FO(CFL) FO(TC) FO(DTC) FO(REGULAR) FO(COUNT) FO 2SAT 2COLOR NL comp. L comp. LOGTIME Hierarchy sac 1 NL L NC 1 ThC 0 AC 0

15 SAT is NP complete.

16 SAT is NP complete. w Σ no(1) (α(w)) ϕ α SAT

17 SAT is NP complete. w Σ no(1) (α(w)) ϕ α SAT Arbitrary exponential search problem is translated to SAT.

18 SAT is NP complete. w Σ no(1) (α(w)) ϕ α SAT Arbitrary exponential search problem is translated to SAT. SAT is not feasible in the worst case.

19 SAT is NP complete. w Σ no(1) (α(w)) ϕ α SAT Arbitrary exponential search problem is translated to SAT. SAT is not feasible in the worst case. Every reasonable search problem can be encoded as an instance of SAT.

20 SAT is NP complete. w Σ no(1) (α(w)) ϕ α SAT Arbitrary exponential search problem is translated to SAT. SAT is not feasible in the worst case. Every reasonable search problem can be encoded as an instance of SAT. Great progress in design of SAT Solvers.

21 SAT is NP complete. w Σ no(1) (α(w)) ϕ α SAT Arbitrary exponential search problem is translated to SAT. SAT is not feasible in the worst case. Every reasonable search problem can be encoded as an instance of SAT. Great progress in design of SAT Solvers. Fast, general-purpose problem solvers.

22 Verification by Reduction to SAT

23 Verification by Reduction to SAT When and why does this work?

24 Verification by Reduction to SAT When and why does this work? How general and powerful can we make it?

25 Background: Dynamic Complexity Static 1. Read entire input 2. Compute boolean query Q(input) 3. Classic Complexity Classes are static: FO, NC, P, NP,...

26 Background: Dynamic Complexity Static 1. Read entire input 2. Compute boolean query Q(input) 3. Classic Complexity Classes are static: FO, NC, P, NP, What is the fastest way upon reading the entire input, to compute the query?

27 Background: Dynamic Complexity Static 1. Read entire input 2. Compute boolean query Q(input) 3. Classic Complexity Classes are static: FO, NC, P, NP, What is the fastest way upon reading the entire input, to compute the query? Dynamic 1. Long series of Inserts, Deletes, Changes, and, Queries 2. On query, very quickly compute Q(current database) 3. Dynamic Complexity Classes: Dyn-FO, Dyn-NC

28 Background: Dynamic Complexity Static 1. Read entire input 2. Compute boolean query Q(input) 3. Classic Complexity Classes are static: FO, NC, P, NP, What is the fastest way upon reading the entire input, to compute the query? Dynamic 1. Long series of Inserts, Deletes, Changes, and, Queries 2. On query, very quickly compute Q(current database) 3. Dynamic Complexity Classes: Dyn-FO, Dyn-NC 4. What additional information should we maintain? auxiliary data structure

29 Dynamic (Incremental) Applications Databases LaTexing a file Performing a calculation Processing a visual scene Understanding a natural language Verifying a circuit Verifying and compiling a program

30 Dynamic (Incremental) Applications Databases LaTexing a file Performing a calculation Processing a visual scene Understanding a natural language Verifying a circuit Verifying and compiling a program Surviving in the wild

31 Parity Current Database: S Request Auxiliary Data: b

32 Parity Current Database: S Request Auxiliary Data: b ins(3,s)

33 Parity Current Database: S Request Auxiliary Data: b ins(3,s) 1

34 Parity Current Database: S Request Auxiliary Data: b ins(3,s) 1 ins(7,s)

35 Parity Current Database: S Request Auxiliary Data: b ins(3,s) ins(7,s) 0

36 Parity Current Database: S Request Auxiliary Data: b ins(3,s) ins(7,s) 0 del(3,s)

37 Parity Current Database: S Request Auxiliary Data: b ins(3,s) ins(7,s) del(3,s) 1

38 Parity Dyn-FO Current Database: S Request Auxiliary Data: b ins(3,s) ins(7,s) del(3,s) 1 ins(a,s) del(a,s) S (x) S(x) x = a S (x) S(x) x a b (b S(a)) b (b S(a)) ( b S(a)) ( b S(a))

39 Dynamic Examples Parity Does binary string w have an odd number of 1 s? Static: TIME[n], FO[Ω(log n/ log log n)] Dynamic: Dyn-TIME[1], Dyn-FO

40 Dynamic Examples Parity Does binary string w have an odd number of 1 s? Static: TIME[n], FO[Ω(log n/ log log n)] Dynamic: Dyn-TIME[1], Dyn-FO REACH u Is t reachable from s in undirected graph G? Static: not in FO, requires FO[Ω(log n/ log log n)] Dynamic: in Dyn-FO [Patnaik, I]

41 Dynamic Examples Parity Does binary string w have an odd number of 1 s? Static: TIME[n], FO[Ω(log n/ log log n)] Dynamic: Dyn-TIME[1], Dyn-FO REACH u Is t reachable from s in undirected graph G? Static: not in FO, requires FO[Ω(log n/ log log n)] Dynamic: in Dyn-FO [Patnaik, I] connectivity, minimum spanning trees, k-edge connectivity,... in Dyn-FO

42 Fact: [Dong & Su] REACH(acyclic) DynFO u v x y a b

43 Fact: [Dong & Su] REACH(acyclic) DynFO ins(a, b, E) : P (x, y) P(x, y) (P(x, a) P(b, y)) u v x y a b

44 Fact: [Dong & Su] REACH(acyclic) DynFO ins(a, b, E) : P (x, y) P(x, y) (P(x, a) P(b, y)) u v x y a b del(a, b, E): P (x, y) P(x, y) [ (P(x, a) P(b, y)) ( uv) ( P(x, u) E(u, v) P(v, y) P(u, a) P(v, a) (a u b v) )]

45 Reachability Problems REACH = { G G directed, s G t } NL REACH d = { G G directed, outdegree 1 s G t } L REACH u = { G G undirected, s G t } L REACH a = { G G alternating, s G t } P

46 Facts about dynamic REACHABILITY Problems: REACH(acyclic) Dyn-FO [DS] REACH d Dyn-QF [H] REACH u Dyn-FO [PI] REACH Dyn-FO(COUNT) [H] PAD(REACH a ) Dyn-FO [PI]

47 Exciting New Result Thm. REACH Dyn-FO [Samir Datta, Raghav Kulkarni, Anish Mukherjee, Thomas Schwentick, Thomas Zeume] REACH Matrix Rank Dyn-FO

48 Thm. 1 [Hesse] REACH d (acyclic) Dyn-FO proof: Maintain E, E, D (outdegree = 1). ins(a, b, E): (ignore if outdegree or acyclicity violated) E (x, y) E(x, y) (x = a y = b) D (x) D(x) x = a E (x, y) E (x, y) (E (x, a) E (b, y))

49 Thm. 1 [Hesse] REACH d (acyclic) Dyn-FO proof: Maintain E, E, D (outdegree = 1). ins(a, b, E): (ignore if outdegree or acyclicity violated) E (x, y) E(x, y) (x = a y = b) D (x) D(x) x = a E (x, y) E (x, y) (E (x, a) E (b, y)) del(a, b, E): E (x, y) E(x, y) (x a y b) D (x) D(x) x a E (x, y) E (x, y) (E (x, a) E(a, b) E (b, y))

50 Dynamic Reasoning Reasoning About reachability can we get to y from x by following a sequence of pointers n x 1 x 0 n x 2 x 3 n n y 1 y 3 x 4 n n n x y 2 y

51 Dynamic Reasoning Reasoning About reachability can we get to y from x by following a sequence of pointers is crucial for understanding programs and proving that they meet their specifications. n x 1 x 0 n x 2 x 3 n n y 1 y 3 x 4 n n n x y 2 y n

52 In general, reasoning about reachability is undecidable. Can express tilings and thus runs of Turing Machines.

53 In general, reasoning about reachability is undecidable. Can express tilings and thus runs of Turing Machines. Even worse, can express finite path and thus finite and thus standard natural numbers. Thus satisfiablity of FO(TC) is as hard as the Arithmetic Hierarchy [Avron].

54 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields.

55 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields. n(x, y) means that x points to y.

56 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields. n(x, y) means that x points to y. Use predicate symbol, n, but not n.

57 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields. n(x, y) means that x points to y. Use predicate symbol, n, but not n. The following axioms assure that n is the reflexive transitive closure of some acyclic, functional n.

58 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields. n(x, y) means that x points to y. Use predicate symbol, n, but not n. The following axioms assure that n is the reflexive transitive closure of some acyclic, functional n. acyclic xy (n (x, y) n (y, x) x = y)

59 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields. n(x, y) means that x points to y. Use predicate symbol, n, but not n. The following axioms assure that n is the reflexive transitive closure of some acyclic, functional n. acyclic xy (n (x, y) n (y, x) x = y) transitive xyz (n (x, y) n (y, z) n (x, z))

60 Itzhaky, Banerjee, Immerman, Aleks Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV For now, restrict to acyclic fields. n(x, y) means that x points to y. Use predicate symbol, n, but not n. The following axioms assure that n is the reflexive transitive closure of some acyclic, functional n. acyclic xy (n (x, y) n (y, x) x = y) transitive xyz (n (x, y) n (y, z) n (x, z)) linear xyz (n (x, y) n (x, z) n (y, z) n (z, y))

61 Effectively-Propositional Reasoning about Reachability in Linked Data Structures Assume acyclic, transitive and linear axioms, as integrity constraints.

62 Effectively-Propositional Reasoning about Reachability in Linked Data Structures Assume acyclic, transitive and linear axioms, as integrity constraints. Automatically transform a program manipulating linked lists to an correctness condition.

63 Effectively-Propositional Reasoning about Reachability in Linked Data Structures Assume acyclic, transitive and linear axioms, as integrity constraints. Automatically transform a program manipulating linked lists to an correctness condition. Using Hesse s dynqf algorithm for REACH d, these formulas are closed under weakest precondition.

64 Effectively-Propositional Reasoning about Reachability in Linked Data Structures Assume acyclic, transitive and linear axioms, as integrity constraints. Automatically transform a program manipulating linked lists to an correctness condition. Using Hesse s dynqf algorithm for REACH d, these formulas are closed under weakest precondition. The negation of the correctness condition is, thus equi-satisfiable with a propositional formula (EPR).

65 Effectively-Propositional Reasoning about Reachability in Linked Data Structures Assume acyclic, transitive and linear axioms, as integrity constraints. Automatically transform a program manipulating linked lists to an correctness condition. Using Hesse s dynqf algorithm for REACH d, these formulas are closed under weakest precondition. The negation of the correctness condition is, thus equi-satisfiable with a propositional formula (EPR). Use a SAT solver to automatically prove correctness or find counter-example runs, typically in only a few seconds.

66 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete).

67 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols.

68 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols. constant symbols: c 1,..., c k

69 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols. constant symbols: c 1,..., c k ϕ = x 1... x s y 1... y t (α(x, t, c))

70 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols. constant symbols: c 1,..., c k ϕ = x 1... x s y 1... y t (α(x, t, c)) small model: ϕ FO-SAT iff has model size k + s.

71 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols. constant symbols: c 1,..., c k ϕ = x 1... x s y 1... y t (α(x, t, c)) small model: ϕ FO-SAT iff has model size k + s. EPR-SAT Σ p 2 (2nd level polynomial-time hierarchy)

72 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols. constant symbols: c 1,..., c k ϕ = x 1... x s y 1... y t (α(x, t, c)) small model: ϕ FO-SAT iff has model size k + s. EPR-SAT Σ p 2 (2nd level polynomial-time hierarchy) If t is fixed, then reducible to SAT.

73 Effectively-Propositional Reasoning (EPR) FO-SAT is undecidable (co-r.e. complete). EPR: formulas; no function symbols. constant symbols: c 1,..., c k ϕ = x 1... x s y 1... y t (α(x, t, c)) small model: ϕ FO-SAT iff has model size k + s. EPR-SAT Σ p 2 (2nd level polynomial-time hierarchy) If t is fixed, then reducible to SAT. Z3 seems to do very well for us on EPR-SAT.

74

75 Thm. 2 [Hesse] Reachability of functional graphs is in DynQF. proof idea: If adding an edge, e, would create a cycle, then we maintain relation p the path relation without the edge completing the cycle as well as E, E and D. Surprisingly this can all be maintained via quantifier-free formulas, without remembering which edges we are leaving out in computing p.

76 Thm. 2 [Hesse] Reachability of functional graphs is in DynQF. proof idea: If adding an edge, e, would create a cycle, then we maintain relation p the path relation without the edge completing the cycle as well as E, E and D. Surprisingly this can all be maintained via quantifier-free formulas, without remembering which edges we are leaving out in computing p. Using Thm. 2, the above methodology has been extended to cyclic deterministic graphs. Itzhaky, Banerjee, Immerman, Nanevski, Sagiv, Effectively-Propositional Reasoning About Reachability in Linked Data Structures CAV Itzhaky, Banerjee, Immerman, Lahav, Nanevski, Sagiv, Modular Reasoning about Heap Paths via Effectively Propositional Formulas, POPL 2014

77 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite.

78 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite. What data structures can we handle: lists, doubly linked lists, cyclic lists; binary trees,...

79 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite. What data structures can we handle: lists, doubly linked lists, cyclic lists; binary trees,... The [CAV13] and [POPL14] papers assume that correct invariants are given for each loop. On-going work to automatically generate and prove loop invariants:

80 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite. What data structures can we handle: lists, doubly linked lists, cyclic lists; binary trees,... The [CAV13] and [POPL14] papers assume that correct invariants are given for each loop. On-going work to automatically generate and prove loop invariants: Feldman, Padon, I, Sagiv, Shoham, Bounded Quantifier Instantiation for Checking Inductive Invariants [TACAS17]

81 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite. What data structures can we handle: lists, doubly linked lists, cyclic lists; binary trees,... The [CAV13] and [POPL14] papers assume that correct invariants are given for each loop. On-going work to automatically generate and prove loop invariants: Feldman, Padon, I, Sagiv, Shoham, Bounded Quantifier Instantiation for Checking Inductive Invariants [TACAS17] Padon, I, Karbyshev, Sagiv, Shoham, Decidability of Inferring Inductive Invariants [POPL16].

82 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite. What data structures can we handle: lists, doubly linked lists, cyclic lists; binary trees,... The [CAV13] and [POPL14] papers assume that correct invariants are given for each loop. On-going work to automatically generate and prove loop invariants: Feldman, Padon, I, Sagiv, Shoham, Bounded Quantifier Instantiation for Checking Inductive Invariants [TACAS17] Padon, I, Karbyshev, Sagiv, Shoham, Decidability of Inferring Inductive Invariants [POPL16]. Padon, McMillan, Panda, Sagiv, Shoham, Ivy: Safety Verification by Interactive Generalization [PLDI16].

83 Extensions Extensions to EPR: we can have functions symbols, as long as we can guarantee the the closure of the function symbols on any finite set remains finite. What data structures can we handle: lists, doubly linked lists, cyclic lists; binary trees,... The [CAV13] and [POPL14] papers assume that correct invariants are given for each loop. On-going work to automatically generate and prove loop invariants: Feldman, Padon, I, Sagiv, Shoham, Bounded Quantifier Instantiation for Checking Inductive Invariants [TACAS17] Padon, I, Karbyshev, Sagiv, Shoham, Decidability of Inferring Inductive Invariants [POPL16]. Padon, McMillan, Panda, Sagiv, Shoham, Ivy: Safety Verification by Interactive Generalization [PLDI16]. Karbyshev, Bjorner, Itzhaky, Rinetzky, Shoham, Property-Directed Inference of Universal Invariants or Proving Their Absence [CAV15].

84

85 When does this work?

86 When does this work? When doesn t this work?

87 Init Inv; Inv Tr Inv ; Inv Safe

88

89

90 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ

91 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ Cor. Complete FO-UNSATmethodology:

92 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ Cor. Complete FO-UNSATmethodology: Skolemize ϕ: ϕ S is universal: ϕ S = x (α(x)); ϕ FO-SAT ϕ S FO-SAT

93 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ Cor. Complete FO-UNSATmethodology: Skolemize ϕ: ϕ S is universal: ϕ S = x (α(x)); ϕ FO-SAT ϕ S FO-SAT grnd(α) def = { α(t) } t H

94 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ Cor. Complete FO-UNSATmethodology: Skolemize ϕ: ϕ S is universal: ϕ S = x (α(x)); ϕ FO-SAT ϕ S FO-SAT grnd(α) def = { α(t) } t H ϕ FO-UNSAT grnd(α) UNSAT

95 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ Cor. Complete FO-UNSATmethodology: Skolemize ϕ: ϕ S is universal: ϕ S = x (α(x)); ϕ FO-SAT ϕ S FO-SAT grnd(α) def = { α(t) } t H ϕ FO-UNSAT grnd(α) UNSAT Feldman, Padon, I, Sagiv, Shoham, Bounded Quantifier Instantiation for Checking Inductive Invariants [TACAS17]

96 Herbrand Thm. ϕ universal ϕ FO-SAT ϕ has Herbrand model, H = ϕ Cor. Complete FO-UNSATmethodology: Skolemize ϕ: ϕ S is universal: ϕ S = x (α(x)); ϕ FO-SAT ϕ S FO-SAT grnd(α) def = { α(t) } t H ϕ FO-UNSAT grnd(α) UNSAT Feldman, Padon, I, Sagiv, Shoham, Bounded Quantifier Instantiation for Checking Inductive Invariants [TACAS17] Can Understand Decidability of Checking FO Inductive Invariants, via bounded depth of nesting of functions in t needed for unsatisfiability.

97 Thank You! Anindya Banerjee, Bill Hesse, Yotam Feldman, Shachar Itzhaky, Aleksandr Karbyshev, Ori Lahav, Aleksandar Nanevski, Oded Padon, Sushant Patnaik, Mooly Sagiv, Sharon Shoham

Reasoning about Reachability at Tom Rep s 60th Birthday Celebration

Reasoning about Reachability at Tom Rep s 60th Birthday Celebration Reasoning about Reachability at Tom Rep s 60th Birthday Celebration Neil Immerman College of Information and Computer Sciences UMass Amherst people.cs.umass.edu/ immerman/ 1978: Tom 22 Neil 24 @Cornell

More information

Inductive Synthesis. Neil Immerman. joint work with Shachar Itzhaky, Sumit Gulwani, and Mooly Sagiv

Inductive Synthesis. Neil Immerman.   joint work with Shachar Itzhaky, Sumit Gulwani, and Mooly Sagiv www.cs.umass.edu joint work with Shachar Itzhaky, Sumit Gulwani, and Mooly Sagiv : Goal Write specification, ϕ, in high level logical language, e.g., SO. : Goal Write specification, ϕ, in high level logical

More information

Effectively-Propositional Modular Reasoning about Reachability in Linked Data Structures CAV 13, POPL 14 Shachar Itzhaky

Effectively-Propositional Modular Reasoning about Reachability in Linked Data Structures CAV 13, POPL 14 Shachar Itzhaky Effectively-Propositional Modular Reasoning about Reachability in Linked Data Structures CAV 13, POPL 14 Shachar Itzhaky Anindya Banerjee Neil Immerman Ori Lahav Aleks Nanevski Mooly Sagiv http://www.cs.tau.ac.il/~shachar/afwp.html

More information

We ve studied the main models and concepts of the theory of computation:

We ve studied the main models and concepts of the theory of computation: CMPSCI 601: Summary & Conclusions Lecture 27 We ve studied the main models and concepts of the theory of computation: Computability: what can be computed in principle Logic: how can we express our requirements

More information

Tree Interpolation in Vampire

Tree Interpolation in Vampire Tree Interpolation in Vampire Régis Blanc 1, Ashutosh Gupta 2, Laura Kovács 3, and Bernhard Kragl 4 1 EPFL 2 IST Austria 3 Chalmers 4 TU Vienna Abstract. We describe new extensions of the Vampire theorem

More information

Property-Directed Shape Analysis

Property-Directed Shape Analysis Property-Directed Shape Analysis S. Itzhaky 1, N. Bjørner 2, T. Reps 3,4, M. Sagiv 1, and A. Thakur 3 1 Tel Aviv University, Tel Aviv, Israel 2 Microsoft Research, USA 3 University of Wisconsin Madison,

More information

Ivy: Safety Verification by Interactive Generalization

Ivy: Safety Verification by Interactive Generalization Consistent * Complete * Well Documented * Easy to Reuse * * Evaluated * PLDI * Artifact * AEC Ivy: Safety Verification by Interactive Generalization Oded Padon Tel Aviv University, Israel odedp@mail.tau.ac.il

More information

A Retrospective on Datalog 1.0

A Retrospective on Datalog 1.0 A Retrospective on Datalog 1.0 Phokion G. Kolaitis UC Santa Cruz and IBM Research - Almaden Datalog 2.0 Vienna, September 2012 2 / 79 A Brief History of Datalog In the beginning of time, there was E.F.

More information

Reference Sheet for CO142.2 Discrete Mathematics II

Reference Sheet for CO142.2 Discrete Mathematics II Reference Sheet for CO14. Discrete Mathematics II Spring 017 1 Graphs Defintions 1. Graph: set of N nodes and A arcs such that each a A is associated with an unordered pair of nodes.. Simple graph: no

More information

The Invariant Problem for Binary String Structures and the Parallel Complexity Theory of Queries

The Invariant Problem for Binary String Structures and the Parallel Complexity Theory of Queries The Invariant Problem for Binary String Structures and the Parallel Complexity Theory of Queries Steven Lindell Haverford College Haverford, PA 19041-1392 1 Introduction A fundamental problem in finite

More information

Tel Aviv University Raymond and Beverly Sackler Faculty of Exact Sciences The Blavatnik School of Computer Science. Asya Frumkin

Tel Aviv University Raymond and Beverly Sackler Faculty of Exact Sciences The Blavatnik School of Computer Science. Asya Frumkin Tel Aviv University Raymond and Beverly Sackler Faculty of Exact Sciences The Blavatnik School of Computer Science PROPERTY DIRECTED REACHABILITY FOR PROVING ABSENCE OF CONCURRENT MODIFICATION ERRORS by

More information

Parallel Computation: Many computations at once, we measure parallel time and amount of hardware. (time measure, hardware measure)

Parallel Computation: Many computations at once, we measure parallel time and amount of hardware. (time measure, hardware measure) CMPSCI 601: Recall From Last Time Lecture 24 Parallel Computation: Many computations at once, we measure parallel time and amount of hardware. Models: (time measure, hardware measure) Parallel RAM: number

More information

Dynamic Complexity Theory Revisited

Dynamic Complexity Theory Revisited Dynamic Complexity Theory Revisited Volker Weber and Thomas Schwentick Philipps-Universität Marburg, FB Mathematik und Informatik {webervo,tick}@informatik.uni-marburg.de Abstract. Dynamic complexity asks

More information

Property Directed Reachability for Proving Absence of Concurrent Modification Errors

Property Directed Reachability for Proving Absence of Concurrent Modification Errors Property Directed Reachability for Proving Absence of Concurrent Modification Errors Asya Frumkin 1, Yotam M. Y. Feldman 1, Ondřej Lhoták 2, Oded Padon 1, Mooly Sagiv 1, and Sharon Shoham 1 1 Tel Aviv

More information

Chapter 2 Dynamic Complexity: Definitions and Examples

Chapter 2 Dynamic Complexity: Definitions and Examples Chapter 2 Dynamic Complexity: Definitions and Examples In this chapter the dynamic complexity framework is defined formally; and many examples for its expressive power are presented. As the dynamic complexity

More information

Deductive Methods, Bounded Model Checking

Deductive Methods, Bounded Model Checking Deductive Methods, Bounded Model Checking http://d3s.mff.cuni.cz Pavel Parízek CHARLES UNIVERSITY IN PRAGUE faculty of mathematics and physics Deductive methods Pavel Parízek Deductive Methods, Bounded

More information

Umans Complexity Theory Lectures

Umans Complexity Theory Lectures Introduction Umans Complexity Theory Lectures Lecture 5: Boolean Circuits & NP: - Uniformity and Advice, - NC hierarchy Power from an unexpected source? we know P EXP, which implies no polytime algorithm

More information

VS 3 : SMT Solvers for Program Verification

VS 3 : SMT Solvers for Program Verification VS 3 : SMT Solvers for Program Verification Saurabh Srivastava 1,, Sumit Gulwani 2, and Jeffrey S. Foster 1 1 University of Maryland, College Park, {saurabhs,jfoster}@cs.umd.edu 2 Microsoft Research, Redmond,

More information

Lecture 6: Arithmetic and Threshold Circuits

Lecture 6: Arithmetic and Threshold Circuits IAS/PCMI Summer Session 2000 Clay Mathematics Undergraduate Program Advanced Course on Computational Complexity Lecture 6: Arithmetic and Threshold Circuits David Mix Barrington and Alexis Maciel July

More information

W[1]-hardness. Dániel Marx. Recent Advances in Parameterized Complexity Tel Aviv, Israel, December 3, 2017

W[1]-hardness. Dániel Marx. Recent Advances in Parameterized Complexity Tel Aviv, Israel, December 3, 2017 1 W[1]-hardness Dániel Marx Recent Advances in Parameterized Complexity Tel Aviv, Israel, December 3, 2017 2 Lower bounds So far we have seen positive results: basic algorithmic techniques for fixed-parameter

More information

Automatic Software Verification

Automatic Software Verification Automatic Software Verification Instructor: Mooly Sagiv TA: Oded Padon Slides from Eran Yahav and the Noun Project, Wikipedia Course Requirements Summarize one lecture 10% one lecture notes 45% homework

More information

DATABASE THEORY. Lecture 11: Introduction to Datalog. TU Dresden, 12th June Markus Krötzsch Knowledge-Based Systems

DATABASE THEORY. Lecture 11: Introduction to Datalog. TU Dresden, 12th June Markus Krötzsch Knowledge-Based Systems DATABASE THEORY Lecture 11: Introduction to Datalog Markus Krötzsch Knowledge-Based Systems TU Dresden, 12th June 2018 Announcement All lectures and the exercise on 19 June 2018 will be in room APB 1004

More information

Foundations of Computer Science Spring Mathematical Preliminaries

Foundations of Computer Science Spring Mathematical Preliminaries Foundations of Computer Science Spring 2017 Equivalence Relation, Recursive Definition, and Mathematical Induction Mathematical Preliminaries Mohammad Ashiqur Rahman Department of Computer Science College

More information

Property-Directed Shape Analysis

Property-Directed Shape Analysis Property-Directed Shape Analysis Shachar Itzhaky 1, Nikolaj Bjørner 2, Thomas Reps 3,4, Mooly Sagiv 1, and Aditya Thakur 3 1 Tel Aviv University, Tel Aviv, Israel 2 Microsoft Research, USA 3 University

More information

NP-Completeness. Algorithms

NP-Completeness. Algorithms NP-Completeness Algorithms The NP-Completeness Theory Objective: Identify a class of problems that are hard to solve. Exponential time is hard. Polynomial time is easy. Why: Do not try to find efficient

More information

Chapter 8. NP and Computational Intractability. Slides by Kevin Wayne. Copyright 2005 Pearson-Addison Wesley. All rights reserved.

Chapter 8. NP and Computational Intractability. Slides by Kevin Wayne. Copyright 2005 Pearson-Addison Wesley. All rights reserved. Chapter 8 NP and Computational Intractability Slides by Kevin Wayne. Copyright 2005 Pearson-Addison Wesley. All rights reserved. 1 Algorithm Design Patterns and Anti-Patterns Algorithm design patterns.

More information

8.1 Polynomial-Time Reductions

8.1 Polynomial-Time Reductions 8.1 Polynomial-Time Reductions Classify Problems According to Computational Requirements Q. Which problems will we be able to solve in practice? A working definition. Those with polynomial-time algorithms.

More information

SAT-CNF Is N P-complete

SAT-CNF Is N P-complete SAT-CNF Is N P-complete Rod Howell Kansas State University November 9, 2000 The purpose of this paper is to give a detailed presentation of an N P- completeness proof using the definition of N P given

More information

CS 151 Complexity Theory Spring Final Solutions. L i NL i NC 2i P.

CS 151 Complexity Theory Spring Final Solutions. L i NL i NC 2i P. CS 151 Complexity Theory Spring 2017 Posted: June 9 Final Solutions Chris Umans 1. (a) The procedure that traverses a fan-in 2 depth O(log i n) circuit and outputs a formula runs in L i this can be done

More information

Chapter 3 Complexity of Classical Planning

Chapter 3 Complexity of Classical Planning Lecture slides for Automated Planning: Theory and Practice Chapter 3 Complexity of Classical Planning Dana S. Nau CMSC 722, AI Planning University of Maryland, Spring 2008 Licensed under the Creative Commons

More information

Lectures 20, 21: Axiomatic Semantics

Lectures 20, 21: Axiomatic Semantics Lectures 20, 21: Axiomatic Semantics Polyvios Pratikakis Computer Science Department, University of Crete Type Systems and Static Analysis Based on slides by George Necula Pratikakis (CSD) Axiomatic Semantics

More information

Planning as Search. Progression. Partial-Order causal link: UCPOP. Node. World State. Partial Plans World States. Regress Action.

Planning as Search. Progression. Partial-Order causal link: UCPOP. Node. World State. Partial Plans World States. Regress Action. Planning as Search State Space Plan Space Algorihtm Progression Regression Partial-Order causal link: UCPOP Node World State Set of Partial Plans World States Edge Apply Action If prec satisfied, Add adds,

More information

Graph algorithms based on infinite automata: logical descriptions and usable constructions

Graph algorithms based on infinite automata: logical descriptions and usable constructions Graph algorithms based on infinite automata: logical descriptions and usable constructions Bruno Courcelle (joint work with Irène Durand) Bordeaux-1 University, LaBRI (CNRS laboratory) 1 Overview Algorithmic

More information

NP and computational intractability. Kleinberg and Tardos, chapter 8

NP and computational intractability. Kleinberg and Tardos, chapter 8 NP and computational intractability Kleinberg and Tardos, chapter 8 1 Major Transition So far we have studied certain algorithmic patterns Greedy, Divide and conquer, Dynamic programming to develop efficient

More information

Boolean Functions (Formulas) and Propositional Logic

Boolean Functions (Formulas) and Propositional Logic EECS 219C: Computer-Aided Verification Boolean Satisfiability Solving Part I: Basics Sanjit A. Seshia EECS, UC Berkeley Boolean Functions (Formulas) and Propositional Logic Variables: x 1, x 2, x 3,, x

More information

CIS 1.5 Course Objectives. a. Understand the concept of a program (i.e., a computer following a series of instructions)

CIS 1.5 Course Objectives. a. Understand the concept of a program (i.e., a computer following a series of instructions) By the end of this course, students should CIS 1.5 Course Objectives a. Understand the concept of a program (i.e., a computer following a series of instructions) b. Understand the concept of a variable

More information

Posets, graphs and algebras: a case study for the fine-grained complexity of CSP s

Posets, graphs and algebras: a case study for the fine-grained complexity of CSP s Posets, graphs and algebras: a case study for the fine-grained complexity of CSP s Part 1: Preliminaries on Complexity and CSP s Benoit Larose 1 2 1 Department of Mathematics and Statistics Concordia University,

More information

Exercises Computational Complexity

Exercises Computational Complexity Exercises Computational Complexity March 22, 2017 Exercises marked with a are more difficult. 1 Chapter 7, P and NP Exercise 1. Suppose some pancakes are stacked on a surface such that no two pancakes

More information

! Greed. O(n log n) interval scheduling. ! Divide-and-conquer. O(n log n) FFT. ! Dynamic programming. O(n 2 ) edit distance.

! Greed. O(n log n) interval scheduling. ! Divide-and-conquer. O(n log n) FFT. ! Dynamic programming. O(n 2 ) edit distance. Algorithm Design Patterns and Anti-Patterns 8. NP and Computational Intractability Algorithm design patterns. Ex.! Greed. O(n log n) interval scheduling.! Divide-and-conquer. O(n log n) FFT.! Dynamic programming.

More information

Chapter 9 Graph Algorithms

Chapter 9 Graph Algorithms Introduction graph theory useful in practice represent many real-life problems can be if not careful with data structures Chapter 9 Graph s 2 Definitions Definitions an undirected graph is a finite set

More information

! Greed. O(n log n) interval scheduling. ! Divide-and-conquer. O(n log n) FFT. ! Dynamic programming. O(n 2 ) edit distance.

! Greed. O(n log n) interval scheduling. ! Divide-and-conquer. O(n log n) FFT. ! Dynamic programming. O(n 2 ) edit distance. Algorithm Design Patterns and Anti-Patterns Chapter 8 NP and Computational Intractability Algorithm design patterns. Ex.! Greed. O(n log n) interval scheduling.! Divide-and-conquer. O(n log n) FFT.! Dynamic

More information

Analysis of Boolean Programs TACAS 2013

Analysis of Boolean Programs TACAS 2013 Analysis of Boolean Programs Patrice Godefroid Microsoft Research Mihalis Yannakakis Columbia University Page 1 March 2013 What is a Boolean Program? All variables have Boolean type, recursive procedures

More information

Symbolic and Concolic Execution of Programs

Symbolic and Concolic Execution of Programs Symbolic and Concolic Execution of Programs Information Security, CS 526 Omar Chowdhury 10/7/2015 Information Security, CS 526 1 Reading for this lecture Symbolic execution and program testing - James

More information

µz An Efficient Engine for Fixed Points with Constraints

µz An Efficient Engine for Fixed Points with Constraints µz An Efficient Engine for Fixed Points with Constraints Kryštof Hoder, Nikolaj Bjørner, and Leonardo de Moura Manchester University and Microsoft Research Abstract. The µz tool is a scalable, efficient

More information

F-Soft: Software Verification Platform

F-Soft: Software Verification Platform F-Soft: Software Verification Platform F. Ivančić, Z. Yang, M.K. Ganai, A. Gupta, I. Shlyakhter, and P. Ashar NEC Laboratories America, 4 Independence Way, Suite 200, Princeton, NJ 08540 fsoft@nec-labs.com

More information

The Pointer Assertion Logic Engine

The Pointer Assertion Logic Engine The Pointer Assertion Logic Engine [PLDI 01] Anders Mφller Michael I. Schwartzbach Presented by K. Vikram Cornell University Introduction Pointer manipulation is hard Find bugs, optimize code General Approach

More information

Chapter 9 Graph Algorithms

Chapter 9 Graph Algorithms Chapter 9 Graph Algorithms 2 Introduction graph theory useful in practice represent many real-life problems can be if not careful with data structures 3 Definitions an undirected graph G = (V, E) is a

More information

CS 267: Automated Verification. Lecture 13: Bounded Model Checking. Instructor: Tevfik Bultan

CS 267: Automated Verification. Lecture 13: Bounded Model Checking. Instructor: Tevfik Bultan CS 267: Automated Verification Lecture 13: Bounded Model Checking Instructor: Tevfik Bultan Remember Symbolic Model Checking Represent sets of states and the transition relation as Boolean logic formulas

More information

Minimum Satisfying Assignments for SMT. Işıl Dillig, Tom Dillig Ken McMillan Alex Aiken College of William & Mary Microsoft Research Stanford U.

Minimum Satisfying Assignments for SMT. Işıl Dillig, Tom Dillig Ken McMillan Alex Aiken College of William & Mary Microsoft Research Stanford U. Minimum Satisfying Assignments for SMT Işıl Dillig, Tom Dillig Ken McMillan Alex Aiken College of William & Mary Microsoft Research Stanford U. 1 / 20 Satisfiability Modulo Theories (SMT) Today, SMT solvers

More information

Prove, where is known to be NP-complete. The following problems are NP-Complete:

Prove, where is known to be NP-complete. The following problems are NP-Complete: CMPSCI 601: Recall From Last Time Lecture 21 To prove is NP-complete: Prove NP. Prove, where is known to be NP-complete. The following problems are NP-Complete: SAT (Cook-Levin Theorem) 3-SAT 3-COLOR CLIQUE

More information

The Dynamic Descriptive Complexity of

The Dynamic Descriptive Complexity of The Dynamic Descriptive Complexity of k-clique Thomas Zeume TU Dortmund University thomas.zeume@cs.tu-dortmund.de Abstract. In this work the dynamic descriptive complexity of the k- clique query is studied

More information

CS357 Lecture: BDD basics. David Dill

CS357 Lecture: BDD basics. David Dill CS357 Lecture: BDD basics David Dill BDDs (Boolean/binary decision diagrams) BDDs are a very successful representation for Boolean functions. A BDD represents a Boolean function on variables x, x 2,...

More information

8.1 Polynomial-Time Reductions

8.1 Polynomial-Time Reductions Algorithm Design Patterns and Anti-Patterns Analysis of Algorithms Algorithm design patterns. Ex. Greed. O(n 2 ) Dijkstra s SSSP (dense) Divide-and-conquer. O(n log n) FFT. Dynamic programming. O(n 2 )

More information

CS521 \ Notes for the Final Exam

CS521 \ Notes for the Final Exam CS521 \ Notes for final exam 1 Ariel Stolerman Asymptotic Notations: CS521 \ Notes for the Final Exam Notation Definition Limit Big-O ( ) Small-o ( ) Big- ( ) Small- ( ) Big- ( ) Notes: ( ) ( ) ( ) ( )

More information

Logic and Computation

Logic and Computation Logic and Computation From Conceptualization to Formalization Here's what we do when we build a formal model (or do a computation): 0. Identify a collection of objects/events in the real world. This is

More information

Program verification. Generalities about software Verification Model Checking. September 20, 2016

Program verification. Generalities about software Verification Model Checking. September 20, 2016 Program verification Generalities about software Verification Model Checking Laure Gonnord David Monniaux September 20, 2016 1 / 43 The teaching staff Laure Gonnord, associate professor, LIP laboratory,

More information

11/22/2016. Chapter 9 Graph Algorithms. Introduction. Definitions. Definitions. Definitions. Definitions

11/22/2016. Chapter 9 Graph Algorithms. Introduction. Definitions. Definitions. Definitions. Definitions Introduction Chapter 9 Graph Algorithms graph theory useful in practice represent many real-life problems can be slow if not careful with data structures 2 Definitions an undirected graph G = (V, E) is

More information

Chapter 9 Graph Algorithms

Chapter 9 Graph Algorithms Chapter 9 Graph Algorithms 2 Introduction graph theory useful in practice represent many real-life problems can be slow if not careful with data structures 3 Definitions an undirected graph G = (V, E)

More information

Research Summary. Mooly Sagiv December 2015

Research Summary. Mooly Sagiv December 2015 Research Summary Mooly Sagiv December 2015 1 Research Interests My research focuses on easing the task of developing reliable and efficient programs via program analysis. The aim is to create powerful

More information

A. Arratia Program Schemes 1. Program Schemes. Reunión MOISES, 3 Septiembre Argimiro Arratia. Universidad de Valladolid

A. Arratia Program Schemes 1. Program Schemes. Reunión MOISES, 3 Septiembre Argimiro Arratia. Universidad de Valladolid A. Arratia Program Schemes 1 Program Schemes Reunión MOISES, 3 Septiembre 2004 Argimiro Arratia Universidad de Valladolid arratia@mac.uva.es A. Arratia Program Schemes 2 A program scheme ρ NPS(τ) involves

More information

VeriCon: Towards Verifying Controller Programs in SDNs

VeriCon: Towards Verifying Controller Programs in SDNs VeriCon: Towards Verifying Controller Programs in SDNs Thomas Ball, Nikolaj Bjorner, Aaron Gember, Shachar Itzhaky, Aleksandr Karbyshev, Mooly Sagiv, Michael Schapira, Asaf Valadarsky 1 Guaranteeing network

More information

Ufo: A Framework for Abstraction- and Interpolation-Based Software Verification

Ufo: A Framework for Abstraction- and Interpolation-Based Software Verification Ufo: A Framework for Abstraction- and Interpolation-Based Software Verification Aws Albarghouthi 1, Yi Li 1, Arie Gurfinkel 2, and Marsha Chechik 1 1 Department of Computer Science, University of Toronto,

More information

Expressive Power and Abstraction in Essence

Expressive Power and Abstraction in Essence Expressive Power and Abstraction in Essence David G. Mitchell and Eugenia Ternovska Computational Logic Laboratory Simon Fraser University {mitchell,ter}@cs.sfu.ca Abstract Development of languages for

More information

THE DESIGN AND ANALYSIS OF COMPUTER ALGORITHMS

THE DESIGN AND ANALYSIS OF COMPUTER ALGORITHMS 2008 AGI-Information Management Consultants May be used for personal purporses only or by libraries associated to dandelon.com network. THE DESIGN AND ANALYSIS OF COMPUTER ALGORITHMS Alfred V. Aho Bell

More information

Complete Instantiation of Quantified Formulas in Satisfiability Modulo Theories. ACSys Seminar

Complete Instantiation of Quantified Formulas in Satisfiability Modulo Theories. ACSys Seminar Complete Instantiation of Quantified Formulas in Satisfiability Modulo Theories Yeting Ge Leonardo de Moura ACSys Seminar 2008.12 Motivation SMT solvers have been successful Quantified smt formulas are

More information

Foundations of AI. 9. Predicate Logic. Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution

Foundations of AI. 9. Predicate Logic. Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution Foundations of AI 9. Predicate Logic Syntax and Semantics, Normal Forms, Herbrand Expansion, Resolution Wolfram Burgard, Andreas Karwath, Bernhard Nebel, and Martin Riedmiller 09/1 Contents Motivation

More information

PSPACE Problems. The Class PSPACE. PSPACE Problems are interesting since: They form the first interesting class potentially

PSPACE Problems. The Class PSPACE. PSPACE Problems are interesting since: They form the first interesting class potentially PSPACE Problems Space Complexity: If an algorithm A solves a problem X by using O(f(n)) bits of memory where n is the size of the input we say that X SPACE(f(n)). The Class PSPACE Def: X PSPACE if and

More information

W[1]-hardness. Dániel Marx 1. Hungarian Academy of Sciences (MTA SZTAKI) Budapest, Hungary

W[1]-hardness. Dániel Marx 1. Hungarian Academy of Sciences (MTA SZTAKI) Budapest, Hungary W[1]-hardness Dániel Marx 1 1 Institute for Computer Science and Control, Hungarian Academy of Sciences (MTA SZTAKI) Budapest, Hungary School on Parameterized Algorithms and Complexity Będlewo, Poland

More information

MATHEMATICAL STRUCTURES FOR COMPUTER SCIENCE

MATHEMATICAL STRUCTURES FOR COMPUTER SCIENCE MATHEMATICAL STRUCTURES FOR COMPUTER SCIENCE A Modern Approach to Discrete Mathematics SIXTH EDITION Judith L. Gersting University of Hawaii at Hilo W. H. Freeman and Company New York Preface Note to the

More information

Integration of SMT Solvers with ITPs There and Back Again

Integration of SMT Solvers with ITPs There and Back Again Integration of SMT Solvers with ITPs There and Back Again Sascha Böhme and University of Sheffield 7 May 2010 1 2 Features: SMT-LIB vs. Yices Translation Techniques Caveats 3 4 Motivation Motivation System

More information

Building Program Verifiers from Compilers and Theorem Provers

Building Program Verifiers from Compilers and Theorem Provers Building Program Verifiers from Compilers and Theorem Provers Software Engineering Institute Carnegie Mellon University Pittsburgh, PA 15213 Arie Gurfinkel based on joint work with Teme Kahsai, Jorge A.

More information

Computer Science Technical Report

Computer Science Technical Report Computer Science Technical Report Feasibility of Stepwise Addition of Multitolerance to High Atomicity Programs Ali Ebnenasir and Sandeep S. Kulkarni Michigan Technological University Computer Science

More information

SMT-Based Modular Analysis of Sequential Systems Code

SMT-Based Modular Analysis of Sequential Systems Code SMT-Based Modular Analysis of Sequential Systems Code Shuvendu K. Lahiri Microsoft Research Abstract. In this paper, we describe a few challenges that accompany SMTbased precise verification of systems

More information

TVLA: A SYSTEM FOR GENERATING ABSTRACT INTERPRETERS*

TVLA: A SYSTEM FOR GENERATING ABSTRACT INTERPRETERS* TVLA: A SYSTEM FOR GENERATING ABSTRACT INTERPRETERS* Tal Lev-Ami, Roman Manevich, and Mooly Sagiv Tel Aviv University {tla@trivnet.com, {rumster,msagiv}@post.tau.ac.il} Abstract TVLA (Three-Valued-Logic

More information

Lecture Notes on Real-world SMT

Lecture Notes on Real-world SMT 15-414: Bug Catching: Automated Program Verification Lecture Notes on Real-world SMT Matt Fredrikson Ruben Martins Carnegie Mellon University Lecture 15 1 Introduction In the previous lecture we studied

More information

( A(x) B(x) C(x)) (A(x) A(y)) (C(x) C(y))

( A(x) B(x) C(x)) (A(x) A(y)) (C(x) C(y)) 1 Introduction Finite model theory studies the expressive power of logics on finite models. Classical model theory, on the other hand, concentrates on infinite structures: its origins are in mathematics,

More information

6. Hoare Logic and Weakest Preconditions

6. Hoare Logic and Weakest Preconditions 6. Hoare Logic and Weakest Preconditions Program Verification ETH Zurich, Spring Semester 07 Alexander J. Summers 30 Program Correctness There are many notions of correctness properties for a given program

More information

Finite Model Generation for Isabelle/HOL Using a SAT Solver

Finite Model Generation for Isabelle/HOL Using a SAT Solver Finite Model Generation for / Using a SAT Solver Tjark Weber webertj@in.tum.de Technische Universität München Winterhütte, März 2004 Finite Model Generation for / p.1/21 is a generic proof assistant: Highly

More information

Boolean Representations and Combinatorial Equivalence

Boolean Representations and Combinatorial Equivalence Chapter 2 Boolean Representations and Combinatorial Equivalence This chapter introduces different representations of Boolean functions. It then discusses the applications of these representations for proving

More information

Hoare Logic. COMP2600 Formal Methods for Software Engineering. Rajeev Goré

Hoare Logic. COMP2600 Formal Methods for Software Engineering. Rajeev Goré Hoare Logic COMP2600 Formal Methods for Software Engineering Rajeev Goré Australian National University Semester 2, 2016 (Slides courtesy of Ranald Clouston) COMP 2600 Hoare Logic 1 Australian Capital

More information

Week 4. COMP62342 Sean Bechhofer, Uli Sattler

Week 4. COMP62342 Sean Bechhofer, Uli Sattler Week 4 COMP62342 Sean Bechhofer, Uli Sattler sean.bechhofer@manchester.ac.uk, uli.sattler@manchester.ac.uk Today Some clarifications from last week s coursework More on reasoning: extension of the tableau

More information

Improving Coq Propositional Reasoning Using a Lazy CNF Conversion

Improving Coq Propositional Reasoning Using a Lazy CNF Conversion Using a Lazy CNF Conversion Stéphane Lescuyer Sylvain Conchon Université Paris-Sud / CNRS / INRIA Saclay Île-de-France FroCoS 09 Trento 18/09/2009 Outline 1 Motivation and background Verifying an SMT solver

More information

Lecture 14: Lower Bounds for Tree Resolution

Lecture 14: Lower Bounds for Tree Resolution IAS/PCMI Summer Session 2000 Clay Mathematics Undergraduate Program Advanced Course on Computational Complexity Lecture 14: Lower Bounds for Tree Resolution David Mix Barrington and Alexis Maciel August

More information

1 Introduction... 1 1.1 A Database Example... 1 1.2 An Example from Complexity Theory...................... 4 1.3 An Example from Formal Language Theory................. 6 1.4 An Overview of the Book.................................

More information

Lecture 4. First order logic is a formal notation for mathematics which involves:

Lecture 4. First order logic is a formal notation for mathematics which involves: 0368.4435 Automatic Software Verification April 14, 2015 Lecture 4 Lecturer: Mooly Sagiv Scribe: Nimrod Busany, Yotam Frank Lesson Plan 1. First order logic recap. 2. The SMT decision problem. 3. Basic

More information

More Untyped Lambda Calculus & Simply Typed Lambda Calculus

More Untyped Lambda Calculus & Simply Typed Lambda Calculus Concepts in Programming Languages Recitation 6: More Untyped Lambda Calculus & Simply Typed Lambda Calculus Oded Padon & Mooly Sagiv (original slides by Kathleen Fisher, John Mitchell, Shachar Itzhaky,

More information

The Relational Model

The Relational Model The Relational Model David Toman School of Computer Science University of Waterloo Introduction to Databases CS348 David Toman (University of Waterloo) The Relational Model 1 / 28 The Relational Model

More information

Symbolic Model Checking

Symbolic Model Checking Bug Catching 5-398 Symbolic Model Checking Hao Zheng Dept. of Computer Science & Eng. Univ. of South Florida Overview CTL model checking operates on sets. Calculates the fix points over finite state sets.

More information

Decidable Verification of Uninterpreted Programs

Decidable Verification of Uninterpreted Programs Decidable Verification of Uninterpreted Programs UMANG MATHUR, University of Illinois, Urbana Champaign, USA P. MADHUSUDAN, University of Illinois, Urbana Champaign, USA MAHESH VISWANATHAN, University

More information

Expressiveness and Complexity of a Graph Logic

Expressiveness and Complexity of a Graph Logic 1 Expressiveness and Complexity of a Graph Logic (Cambridge) joint work with Philippa Gardner (Imperial College) and Giorgio Ghelli (Pisa) 2 A View of Process Algebras A term algebra T given by a functional

More information

LOGIC AND DISCRETE MATHEMATICS

LOGIC AND DISCRETE MATHEMATICS LOGIC AND DISCRETE MATHEMATICS A Computer Science Perspective WINFRIED KARL GRASSMANN Department of Computer Science University of Saskatchewan JEAN-PAUL TREMBLAY Department of Computer Science University

More information

Computability Theory

Computability Theory CS:4330 Theory of Computation Spring 2018 Computability Theory Other NP-Complete Problems Haniel Barbosa Readings for this lecture Chapter 7 of [Sipser 1996], 3rd edition. Sections 7.4 and 7.5. The 3SAT

More information

Having a BLAST with SLAM

Having a BLAST with SLAM Having a BLAST with SLAM Meeting, CSCI 555, Fall 20 Announcements Homework 0 due Sat Questions? Move Tue office hours to -5pm 2 Software Model Checking via Counterexample Guided Abstraction Refinement

More information

Overview. Discrete Event Systems - Verification of Finite Automata. What can finite automata be used for? What can finite automata be used for?

Overview. Discrete Event Systems - Verification of Finite Automata. What can finite automata be used for? What can finite automata be used for? Computer Engineering and Networks Overview Discrete Event Systems - Verification of Finite Automata Lothar Thiele Introduction Binary Decision Diagrams Representation of Boolean Functions Comparing two

More information

An Annotated Language

An Annotated Language Hoare Logic An Annotated Language State and Semantics Expressions are interpreted as functions from states to the corresponding domain of interpretation Operators have the obvious interpretation Free of

More information

Formal Syntax and Semantics of Programming Languages

Formal Syntax and Semantics of Programming Languages Formal Syntax and Semantics of Programming Languages Mooly Sagiv Reference: Semantics with Applications Chapter 2 H. Nielson and F. Nielson http://www.daimi.au.dk/~bra8130/wiley_book/wiley.html The While

More information

OWL 2 Profiles. An Introduction to Lightweight Ontology Languages. Markus Krötzsch University of Oxford. Reasoning Web 2012

OWL 2 Profiles. An Introduction to Lightweight Ontology Languages. Markus Krötzsch University of Oxford. Reasoning Web 2012 University of Oxford Department of Computer Science OWL 2 Profiles An Introduction to Lightweight Ontology Languages Markus Krötzsch University of Oxford Reasoning Web 2012 Remark for the Online Version

More information

Introduction. Preliminaries. Original IC3. Tree-IC3. IC3 on Control Flow Automata. Conclusion

Introduction. Preliminaries. Original IC3. Tree-IC3. IC3 on Control Flow Automata. Conclusion .. Introduction Preliminaries Original IC3 Tree-IC3 IC3 on Control Flow Automata Conclusion 2 of 22 Lifting IC3 to Control Flow Automata Tim Lange tim.lange@cs.rwth-aachen.de Introduction Preliminaries

More information

Database Theory VU , SS Codd s Theorem. Reinhard Pichler

Database Theory VU , SS Codd s Theorem. Reinhard Pichler Database Theory Database Theory VU 181.140, SS 2011 3. Codd s Theorem Reinhard Pichler Institut für Informationssysteme Arbeitsbereich DBAI Technische Universität Wien 29 March, 2011 Pichler 29 March,

More information

Formally Certified Satisfiability Solving

Formally Certified Satisfiability Solving SAT/SMT Proof Checking Verifying SAT Solver Code Future Work Computer Science, The University of Iowa, USA April 23, 2012 Seoul National University SAT/SMT Proof Checking Verifying SAT Solver Code Future

More information