`sig
module type S =
sig
type t
module V :
sig
type t
val compare : Sig_pack.S.V.t -> Sig_pack.S.V.t -> int
val hash : Sig_pack.S.V.t -> int
val equal : Sig_pack.S.V.t -> Sig_pack.S.V.t -> bool
type label = int
val create : Sig_pack.S.V.label -> Sig_pack.S.V.t
val label : Sig_pack.S.V.t -> Sig_pack.S.V.label
end
type vertex = Sig_pack.S.V.t
module E :
sig
type t
val compare : Sig_pack.S.E.t -> Sig_pack.S.E.t -> int
val src : Sig_pack.S.E.t -> Sig_pack.S.V.t
val dst : Sig_pack.S.E.t -> Sig_pack.S.V.t
type label = int
val create :
Sig_pack.S.V.t ->
Sig_pack.S.E.label -> Sig_pack.S.V.t -> Sig_pack.S.E.t
val label : Sig_pack.S.E.t -> Sig_pack.S.E.label
type vertex = Sig_pack.S.V.t
end
type edge = Sig_pack.S.E.t
val is_directed : bool
val create : ?size:int -> unit -> Sig_pack.S.t
val clear : Sig_pack.S.t -> unit
val copy : Sig_pack.S.t -> Sig_pack.S.t
val add_vertex : Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val remove_vertex : Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val add_edge : Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.V.t -> unit
val add_edge_e : Sig_pack.S.t -> Sig_pack.S.E.t -> unit
val remove_edge :
Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.V.t -> unit
val remove_edge_e : Sig_pack.S.t -> Sig_pack.S.E.t -> unit
module Mark :
sig
type graph = Sig_pack.S.t
type vertex = Sig_pack.S.V.t
val clear : Sig_pack.S.t -> unit
val get : Sig_pack.S.V.t -> int
val set : Sig_pack.S.V.t -> int -> unit
end
val is_empty : Sig_pack.S.t -> bool
val nb_vertex : Sig_pack.S.t -> int
val nb_edges : Sig_pack.S.t -> int
val out_degree : Sig_pack.S.t -> Sig_pack.S.V.t -> int
val in_degree : Sig_pack.S.t -> Sig_pack.S.V.t -> int
val mem_vertex : Sig_pack.S.t -> Sig_pack.S.V.t -> bool
val mem_edge : Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.V.t -> bool
val mem_edge_e : Sig_pack.S.t -> Sig_pack.S.E.t -> bool
val find_edge :
Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.V.t -> Sig_pack.S.E.t
val find_all_edges :
Sig_pack.S.t ->
Sig_pack.S.V.t -> Sig_pack.S.V.t -> Sig_pack.S.E.t list
val succ : Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.V.t list
val pred : Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.V.t list
val succ_e : Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.E.t list
val pred_e : Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.E.t list
val iter_vertex : (Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val iter_edges :
(Sig_pack.S.V.t -> Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val fold_vertex :
(Sig_pack.S.V.t -> 'a -> 'a) -> Sig_pack.S.t -> 'a -> 'a
val fold_edges :
(Sig_pack.S.V.t -> Sig_pack.S.V.t -> 'a -> 'a) ->
Sig_pack.S.t -> 'a -> 'a
val map_vertex :
(Sig_pack.S.V.t -> Sig_pack.S.V.t) -> Sig_pack.S.t -> Sig_pack.S.t
val iter_edges_e : (Sig_pack.S.E.t -> unit) -> Sig_pack.S.t -> unit
val fold_edges_e :
(Sig_pack.S.E.t -> 'a -> 'a) -> Sig_pack.S.t -> 'a -> 'a
val iter_succ :
(Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val iter_pred :
(Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val fold_succ :
(Sig_pack.S.V.t -> 'a -> 'a) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> 'a -> 'a
val fold_pred :
(Sig_pack.S.V.t -> 'a -> 'a) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> 'a -> 'a
val iter_succ_e :
(Sig_pack.S.E.t -> unit) -> Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val fold_succ_e :
(Sig_pack.S.E.t -> 'a -> 'a) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> 'a -> 'a
val iter_pred_e :
(Sig_pack.S.E.t -> unit) -> Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val fold_pred_e :
(Sig_pack.S.E.t -> 'a -> 'a) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> 'a -> 'a
val find_vertex : Sig_pack.S.t -> int -> Sig_pack.S.V.t
val transitive_closure :
?reflexive:bool -> Sig_pack.S.t -> Sig_pack.S.t
val add_transitive_closure :
?reflexive:bool -> Sig_pack.S.t -> Sig_pack.S.t
val mirror : Sig_pack.S.t -> Sig_pack.S.t
val complement : Sig_pack.S.t -> Sig_pack.S.t
val intersect : Sig_pack.S.t -> Sig_pack.S.t -> Sig_pack.S.t
val union : Sig_pack.S.t -> Sig_pack.S.t -> Sig_pack.S.t
module Dfs :
sig
val iter :
?pre:(Sig_pack.S.V.t -> unit) ->
?post:(Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val prefix : (Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val postfix : (Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val iter_component :
?pre:(Sig_pack.S.V.t -> unit) ->
?post:(Sig_pack.S.V.t -> unit) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val prefix_component :
(Sig_pack.S.V.t -> unit) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val postfix_component :
(Sig_pack.S.V.t -> unit) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> unit
val has_cycle : Sig_pack.S.t -> bool
end
module Bfs :
sig
val iter : (Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val iter_component :
(Sig_pack.S.V.t -> unit) ->
Sig_pack.S.t -> Sig_pack.S.V.t -> unit
end
module Marking :
sig
val dfs : Sig_pack.S.t -> unit
val has_cycle : Sig_pack.S.t -> bool
end
module Classic :
sig
val divisors : int -> Sig_pack.S.t
val de_bruijn : int -> Sig_pack.S.t
val vertex_only : int -> Sig_pack.S.t
val full : ?self:bool -> int -> Sig_pack.S.t
end
module Rand :
sig
val graph : ?loops:bool -> v:int -> e:int -> unit -> Sig_pack.S.t
val labeled :
(Sig_pack.S.V.t -> Sig_pack.S.V.t -> Sig_pack.S.E.label) ->
?loops:bool -> v:int -> e:int -> unit -> Sig_pack.S.t
end
module Components :
sig
val scc : Sig_pack.S.t -> int * (Sig_pack.S.V.t -> int)
val scc_array : Sig_pack.S.t -> Sig_pack.S.V.t list array
val scc_list : Sig_pack.S.t -> Sig_pack.S.V.t list list
end
val shortest_path :
Sig_pack.S.t ->
Sig_pack.S.V.t -> Sig_pack.S.V.t -> Sig_pack.S.E.t list * int
val ford_fulkerson :
Sig_pack.S.t ->
Sig_pack.S.V.t -> Sig_pack.S.V.t -> (Sig_pack.S.E.t -> int) * int
val goldberg :
Sig_pack.S.t ->
Sig_pack.S.V.t -> Sig_pack.S.V.t -> (Sig_pack.S.E.t -> int) * int
val bellman_ford :
Sig_pack.S.t -> Sig_pack.S.V.t -> Sig_pack.S.E.t list
module PathCheck :
sig
type path_checker
val create : Sig_pack.S.t -> Sig_pack.S.PathCheck.path_checker
val check_path :
Sig_pack.S.PathCheck.path_checker ->
Sig_pack.S.V.t -> Sig_pack.S.V.t -> bool
end
module Topological :
sig
val fold : (Sig_pack.S.V.t -> 'a -> 'a) -> Sig_pack.S.t -> 'a -> 'a
val iter : (Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
val fold_stable :
(Sig_pack.S.V.t -> 'a -> 'a) -> Sig_pack.S.t -> 'a -> 'a
val iter_stable : (Sig_pack.S.V.t -> unit) -> Sig_pack.S.t -> unit
end
val spanningtree : Sig_pack.S.t -> Sig_pack.S.E.t list
val dot_output : Sig_pack.S.t -> string -> unit
val display_with_gv : Sig_pack.S.t -> unit
val parse_gml_file : string -> Sig_pack.S.t
val parse_dot_file : string -> Sig_pack.S.t
val print_gml : Format.formatter -> Sig_pack.S.t -> unit
val print_gml_file : Sig_pack.S.t -> string -> unit
end
end`