bool.mli 1.05 KB
Newer Older
1 2 3 4
type 'a bdd

val empty : 'a bdd

5 6
module type S =
sig
7
  type elem
8
  include Custom.T
9

10
  val get: t -> (elem list * elem list) list
11

12 13 14 15 16 17
  val empty : t
  val full  : t
  val cup   : t -> t -> t
  val cap   : t -> t -> t
  val diff  : t -> t -> t
  val atom  : elem -> t
18
  val is_empty : t -> bool
19
  val iter: (elem-> unit) -> t -> unit
20

21
  val compute: empty:'b -> full:'b -> cup:('b -> 'b -> 'b)
22
    -> cap:('b -> 'b -> 'b) -> diff:('b -> 'b -> 'b) ->
23
    atom:(elem -> 'b) -> t -> 'b
24

25
  val trivially_disjoint : t -> t -> bool
26 27
end

28
module Make (X : Custom.T) : S with type elem = X.t
29

30 31
module type V =
sig
32

33 34 35
  module Atom : S

  include S with type elem = Atom.t Var.var_or_atom
36
	and type t = Atom.t Var.var_or_atom bdd
37 38 39 40 41

  val var : Var.t -> t

  (** returns the union of all leaves in the BDD *)

42
  val leafconj : t -> Atom.t
43
  val get_kind : t -> (Var.t list * Var.t list * Atom.t) list
44
  val is_empty : t -> bool
45

46
  val extract : t -> [ `Empty | `Full | `Split of (elem * t * t * t) ]
47

48 49
end

50
module MakeVar (T : S) : V with module Atom = T and type elem = T.t Var.var_or_atom