module type S = Res_intf.S
module St:Solver_types.S
exception Insuficient_hyps
typeatom =
St.atom
typeclause =
St.clause
typelemma =
St.proof
type
proof
type
proof_node = {
|
conclusion : |
(* |
The conclusion of the proof
| *) |
|
step : |
(* |
The reasoning step used to prove the conclusion
| *) |
type
step =
| |
Hypothesis |
(* |
The conclusion is a user-provided hypothesis
| *) |
| |
Assumption |
(* |
The conclusion has been locally assumed by the user
| *) |
| |
Lemma of |
(* |
The conclusion is a tautology provided by the theory, with associated proof
| *) |
| |
Resolution of |
(* |
The conclusion can be deduced by performing a resolution between the conclusions
of the two given proofs. The atom on which to perform the resolution is also given.
| *) |
val to_list : clause -> atom list
val merge : atom list -> atom list -> atom list
val resolve : atom list -> atom list * atom list
resolve (List.merge l1 l2)
where l1
and l2
are sorted atom lists should return the pair
[a], l'
, where l'
is the result of the resolution of l1
and l2
over a
.val prove : clause -> proof
Insuficient_hyps
if it does not succeed.val prove_unsat : clause -> proof
c
, returns a proof of the empty clause.Insuficient_hyps
if it does not succeed.val prove_atom : atom -> proof option
a
, returns a proof of the clause [a]
if a
is true at level 0val expand : proof -> proof_node
val fold : ('a -> proof_node -> 'a) -> 'a -> proof -> 'a
fold f acc p
, fold f
over the proof p
and all its node. It is guaranteed that
f
is executed exactly once on each proof ndoe in the tree, and that the execution of
f
on a proof node happens after the execution on the children of the nodes.val unsat_core : proof -> clause list
fold
function since it has access to the internal representation of proofsval check : proof -> unit
val print_clause : Format.formatter -> clause -> unit