1 / 9

DPLL in Coq

DPLL in Coq. Zhuang Zhong 11-05-2008. Overview. Previous work Stålmarck algorithm and Binary Decision Diagram Produce traces of proof Reconstruct proof term This work Formalization of DPLL algorithm Good use of module type Proof by reflexivity. Decision Procedure.

celine
Download Presentation

DPLL in Coq

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. DPLL in Coq Zhuang Zhong 11-05-2008

  2. Overview • Previous work • Stålmarck algorithm and Binary Decision Diagram • Produce traces of proof • Reconstruct proof term • This work • Formalization of DPLL algorithm • Good use of module type • Proof by reflexivity

  3. Decision Procedure • Make a conjunction F of all the Hypotheses • Convert F to CNF form • Convert F to f with respect to abstract model (reify) (FClause (COr (CLit (Left_idx (Left_idx End_idx), true)) (COr (CLit (Right_idx End_idx, false)) (CLit (Left_idx End_idx, false)))))

  4. Decision Procedure cont. • Measure possible steps about the formula • Compute proof_search( |- (make f))= Unsat • If equal, then proof complete • Else, it will print the counter model • The whole procedure is wrap by a tactic unsat.

  5. Model • Semantics of the abstract formula Definition model := {M : F.L.t -> Prop | wf_model M}. Definition sat_clause (M : model) (C : F.LSet.t) := exists l, M l /\ F.LSet.In l C. Definition sat_goal (M : model) (D : F.CSet.t) := forall C, F.CSet.In C D -> sat_clause M C. Definition submodel (G : F.LSet.t) (M : model) := forall l, F.LSet.In l G -> (M l /\ ~F.LSet.In (F.L.mk_not l) G). Definition incompatible (G : F.LSet.t) (D : F.CSet.t) := forall (M : model), submodel G M -> ~sat_goal M D.

  6. Interpretation • Variable • Use varmap (Require Import Quote) • Varmap is quite like a binary tree • index*bool -> lookup index varmap • Formula • Inductive type formula • reify_formula Formula varmap • Generate sequent

  7. Modularity • Module Type & Module • Module Type is a signature • Module can be parameterized with other module and instantiated to match a certain module type • In this work • Module Types • LITERAL, CNF • Module • LProp, CNFProp… • Advantage • High level abstraction • Eg. Different prop, different pick method

  8. Example • A /\ (C \/ ~B /\ (~D -> ~A)) -> B /\ ~A -> D /\ D /\ ~ A. • E -> F /\ (A -> A) \/ ~B \/ ~C /\ D -> C \/ ~C /\ ~(B \/ F) -> D \/ ~E.

  9. Conclusion • Develop a tactic in Coq like omega, ring… • What can be done: • Optimization • Combine with other decision procedure • Congruence, linear arithmetic… • Next week • Decision procedures above • Read more about this work

More Related