type elt = tThe type of the elements in the set.
type tThe type of sets.
val empty : tThe empty set.
val full : tThe set of all elements (of type elm).
val is_empty : t -> boolTest whether a set is empty or not.
val is_full : t -> boolTest whether a set contains the whole type or not.
val mem : elt -> t -> boolmem x s tests whether x belongs to the set s.
val singleton : elt -> tsingleton x returns the one-element set containing only x.
val add : elt -> t -> tadd x s returns a set containing all elements of s, plus x. If x was already in s, then s is returned unchanged.
val remove : elt -> t -> tremove x s returns a set containing all elements of s, except x. If x was not in s, then s is returned unchanged.
val union : t -> t -> tSet union.
val inter : t -> t -> tSet intersection.
val diff : t -> t -> tSet difference.
val complement : t -> tSet complement.
val equal : t -> t -> boolequal s1 s2 tests whether the sets s1 and s2 are equal, that is, contain equal elements.
val subset : t -> t -> boolsubset s1 s2 tests whether the set s1 is a subset of the set s2.
val elements : t -> bool * elt listGives a finite representation of the predicate: if the boolean is false, then the predicate is given in extension. if it is true, then the complement is given