Labelled Unit Superposition for Instantiation-Based Reasoning Konstantin Korovin joint work with Christoph Sticksel 1 Instantiation, Labelled Superposition
SAT/SMT vs First-Order The problem: Show that a given formula is a theorem. Ground (SAT/SMT) First-Order ∀ x ∃ y Q ( x , y ) ∨ f ( x ) �≃ g ( f ( y )) P ( a ) ∨ f ( c ) ≃ d P ( a ) ∨ f ( d ) ≃ c ¬ P ( a ) ∨ Q ( d , c ) very expressive very efficient ground: not as efficient not very expressive resolution/superposition DPLL/congruence closure From Ground to First-Order: Efficient at ground + Expressive? 2 Instantiation, Labelled Superposition
Different approaches Gilmore (1960): generation of ground instances Robinson (1965): resolution Plaisted et al (1992): hyper-linking Weidenbach (1998): splitting in SPASS Plaisted & Zhu (2000): semantics-based instance generation Letz & Stenz (2000): disconnection tableaux-type calculus Riazanov & Voronkov splitting without backtracking Hooker et al (2002): generation of instances with sem. selection Baumgartner & Tinelli (2003): ME: Lifting of DPLL Ganzinger & Korovin (2003): Inst-Gen, modular ground reasoning Claessen (2005): Equinox Prevosto & Waldmann (2006): SPASS+T Navarro & Voronkov (2008): Resolution+Generalization Rule de Moura & Bjørner (2008): DPLL(T)+Saturation Lynch & Tran (2008): SMELS 3 Instantiation, Labelled Superposition
Overview of Inst-Gen procedure First-Order Clauses S Theorem. This process is sound and complete. 4 Instantiation, Labelled Superposition
Overview of Inst-Gen procedure First-Order Clauses ⊥ : ¯ x → ⊥ Ground Clauses S S ⊥ Theorem. This process is sound and complete. 4 Instantiation, Labelled Superposition
Overview of Inst-Gen procedure Theorem Proved S ⊥ UnSAT First-Order Clauses ⊥ : ¯ x → ⊥ Ground Clauses S S ⊥ Theorem. This process is sound and complete. 4 Instantiation, Labelled Superposition
Overview of Inst-Gen procedure Theorem Proved S ⊥ UnSAT First-Order Clauses ⊥ : ¯ x → ⊥ Ground Clauses S S ⊥ S ⊥ SAT I ⊥ | = S ⊥ = L ⊥ , L ′ σ = mgu ( L , L ′ ) I ⊥ | ⊥ Theorem. This process is sound and complete. 4 Instantiation, Labelled Superposition
Overview of Inst-Gen procedure Theorem Proved S ⊥ UnSAT First-Order Clauses ⊥ : ¯ x → ⊥ Ground Clauses S S ⊥ S ⊥ SAT I ⊥ | = S ⊥ L ′ ∨ D C ∨ L ( L ′ ∨ D ) σ ( C ∨ L ) σ = L ⊥ , L ′ σ = mgu ( L , L ′ ) I ⊥ | ⊥ Theorem. This process is sound and complete. 4 Instantiation, Labelled Superposition
Overview of Inst-Gen procedure Theorem Proved S ⊥ UnSAT First-Order Clauses ⊥ : ¯ x → ⊥ Ground Clauses S S ⊥ S ⊥ SAT I ⊥ | = S ⊥ L ′ ∨ D C ∨ L ( L ′ ∨ D ) σ ( C ∨ L ) σ = L ⊥ , L ′ σ = mgu ( L , L ′ ) I ⊥ | ⊥ Theorem. This process is sound and complete. 4 Instantiation, Labelled Superposition
Inst-Gen: Ground Abstraction and Selection First-order clauses Ground abstraction with ⊥ ¬ Q ( f ( x )) ¬ Q ( f ( ⊥ )) ¬ P ( f ( f ( y )) ¬ P ( f ( f ( ⊥ )) P ( f ( z )) ∨ Q ( z ) P ( f ( ⊥ )) ∨ Q ( ⊥ ) • Select literals which are true in ground abstraction Instantiate: ¬ P ( f ( f ( y ))) P ( f ( f ( y ))) ∨ Q ( f ( y )) • Ground model has to be refined on the conflict 5 Instantiation, Labelled Superposition
Inst-Gen: Ground Abstraction and Selection First-order clauses Ground abstraction with ⊥ ¬ Q ( f ( x )) ¬ Q ( f ( ⊥ )) ¬ P ( f ( f ( y )) ¬ P ( f ( f ( ⊥ )) P ( f ( z )) ∨ Q ( z ) P ( f ( ⊥ )) ∨ Q ( ⊥ ) • Select literals which are true in ground abstraction Instantiate: ¬ P ( f ( f ( y ))) P ( f ( f ( y ))) ∨ Q ( f ( y )) • Ground model has to be refined on the conflict 5 Instantiation, Labelled Superposition
Inst-Gen: Ground Abstraction and Selection First-order clauses Ground abstraction with ⊥ ¬ Q ( f ( x )) ¬ Q ( f ( ⊥ )) ¬ P ( f ( f ( y )) ¬ P ( f ( f ( ⊥ )) P ( f ( z )) ∨ Q ( z ) P ( f ( ⊥ )) ∨ Q ( ⊥ ) • Select literals which are true in ground abstraction Instantiate: ¬ P ( f ( f ( y ))) P ( f ( f ( y ))) ∨ Q ( f ( y )) • Ground model has to be refined on the conflict 5 Instantiation, Labelled Superposition
Inst-Gen: Ground Abstraction and Selection First-order clauses Ground abstraction with ⊥ ¬ Q ( f ( x )) ¬ Q ( f ( ⊥ )) ¬ P ( f ( f ( y )) ¬ P ( f ( f ( ⊥ )) P ( f ( z )) ∨ Q ( z ) P ( f ( ⊥ )) ∨ Q ( ⊥ ) • Select literals which are true in ground abstraction Instantiate: ¬ P ( f ( f ( y ))) P ( f ( f ( y ))) ∨ Q ( f ( y )) • Ground model has to be refined on the conflict 5 Instantiation, Labelled Superposition
Inst-Gen: Ground Abstraction and Selection First-order clauses Ground abstraction with ⊥ ¬ Q ( f ( x )) ¬ Q ( f ( ⊥ )) ¬ P ( f ( f ( y )) ¬ P ( f ( f ( ⊥ )) P ( f ( z )) ∨ Q ( z ) P ( f ( ⊥ )) ∨ Q ( ⊥ ) • Select literals which are true in ground abstraction Instantiate: ¬ P ( f ( f ( y ))) P ( f ( f ( y ))) ∨ Q ( f ( y )) • Ground model has to be refined on the conflict 5 Instantiation, Labelled Superposition
Resolution vs Inst-Gen Instantiation : Resolution : ( L ′ ∨ D ) ( L ′ ∨ D ) ( C ∨ L ) ( C ∨ L ) ( L ′ ∨ D ) σ ( C ∨ D ) σ ( C ∨ L ) σ σ = mgu ( L , L ′ ) σ = mgu ( L , L ′ ) Instantiation: Resolution: modular ground reasoning ground: not very efficient EPR: efficient EPR: not very efficient length of clauses is fixed length of clauses can grow fast no recombination recombination of clauses semantic selection redundancy elimination redundancy elim. (res/inst) Goal: preserve positive features in equational Inst-Gen. 6 Instantiation, Labelled Superposition
Example: memory verification Bounded Model Checking: fof(memoryWriteEnabledInsideRange,axiom, (nextState(VarCurr,VarNext) => (![AssociatedAddressVar] : ((mem_eq_inv_addr_range_1_to_0_addr_assoc(VarNext,AssociatedAddressVar) => (![A] : (((A = AssociatedAddressVar & mem_eq_inv_EXP_10(VarNext)) => (![B] : (((less_5(B) & (˜less_0(B))) => (mem_eq_inv_mem2_array(VarNext,A,B) <=> mem_eq_inv_data(VarNext,B))))))))))))). Equality, EPR Joint work with Zurab Khasidashvili and Andrei Voronkov 7 Instantiation, Labelled Superposition
Equality Superposition vs Inst-Gen Instantiation ? Superposition L [ l ′ ] ∨ D L [ l ′ ] ∨ D C ∨ l ≃ r C ∨ l ≃ r ( L [ l ′ ] ∨ D ) θ ( C ∨ D ∨ L [ r ]) θ ( C ∨ l ≃ r ) θ ordering restrictions ordering restrictions 8 Instantiation, Labelled Superposition
Equality Superposition vs Inst-Gen Instantiation ? Superposition L [ l ′ ] ∨ D L [ l ′ ] ∨ D C ∨ l ≃ r C ∨ l ≃ r ( L [ l ′ ] ∨ D ) θ ( C ∨ D ∨ L [ r ]) θ ( C ∨ l ≃ r ) θ ordering restrictions ordering restrictions Incomplete ! 8 Instantiation, Labelled Superposition
Superposition+Instantiation f ( h ( x )) ≃ c h ( x ) ≃ x f ( a ) �≃ c This set is inconsistent but the contradiction is not deducible by the inference system above. 9 Instantiation, Labelled Superposition
Superposition+Instantiation f ( h ( x )) ≃ c h ( x ) ≃ x f ( a ) �≃ c This set is inconsistent but the contradiction is not deducible by the inference system above. The idea is to consider proofs generated by superposition: h ( x ) ≃ x f ( h ( y )) ≃ c f ( x ) ≃ c f ( a ) �≃ c c �≃ c � 9 Instantiation, Labelled Superposition
Superposition+Instantiation f ( h ( x )) ≃ c h ( x ) ≃ x f ( a ) �≃ c This set is inconsistent but the contradiction is not deducible by the inference system above. The idea is to consider proofs generated by superposition: h ( x ) ≃ x f ( h ( y )) ≃ c [ x / y ] f ( x ) ≃ c f ( a ) �≃ c [ a / x ] c �≃ c � 9 Instantiation, Labelled Superposition
Superposition+Instantiation f ( h ( x )) ≃ c h ( x ) ≃ x f ( a ) �≃ c This set is inconsistent but the contradiction is not deducible by the inference system above. The idea is to consider proofs generated by superposition: h ( x ) ≃ x f ( h ( y )) ≃ c [ x / y ] f ( x ) ≃ c f ( a ) �≃ c [ a / x ] c �≃ c � Propagating substitutions: { h ( a ) ≃ a ; f ( h ( a )) ≃ c ; f ( a ) �≃ c } ground unsatisfiable. 9 Instantiation, Labelled Superposition
Superposition+Instantiation f ( h ( x )) ≃ ∨ C 1 ( x , y ) c h ( x ) ≃ ∨ C 2 ( x , y ) x f ( a ) �≃ ∨ C 3 ( x , y ) c This set is inconsistent but the contradiction is not deducible by the inference system above. The idea is to consider proofs generated by superposition: h ( x ) ≃ x f ( h ( y )) ≃ c [ x / y ] f ( x ) ≃ c f ( a ) �≃ c [ a / x ] c �≃ c � Propagating substitutions: { h ( a ) ≃ a ; f ( h ( a )) ≃ c ; f ( a ) �≃ c } ground unsatisfiable. 9 Instantiation, Labelled Superposition
Superposition+Instantiation f ( h ( x )) ≃ ∨ C 1 ( x , y ) f ( h ( a )) ≃ ∨ C 1 ( a , y ) c c h ( x ) ≃ ∨ C 2 ( x , y ) h ( a ) ≃ ∨ C 2 ( a , y ) x a f ( a ) �≃ ∨ C 3 ( x , y ) f ( a ) �≃ ∨ C 3 ( a , y ) c c This set is inconsistent but the contradiction is not deducible by the inference system above. The idea is to consider proofs generated by superposition: h ( x ) ≃ x f ( h ( y )) ≃ c [ x / y ] f ( x ) ≃ c f ( a ) �≃ c [ a / x ] c �≃ c � Propagating substitutions: { h ( a ) ≃ a ; f ( h ( a )) ≃ c ; f ( a ) �≃ c } ground unsatisfiable. 9 Instantiation, Labelled Superposition
Recommend
More recommend