module Dlx:Knuth's dancing links (aka DLX) see http://en.wikipedia.org/wiki/Dancing_Linkssig
..end
type
t
val create : ?primary:int -> bool array array -> t
true
for primary
columns and at most one true
value for secondary columns.
If primary
is given, it means that the first primary
columns are
primary; otherwise, all columns are primary columns.
val get_first_solution : t -> int list
Not_found
if the problem has no solution.val count_solutions : t -> int
val get_solution_array : t -> int list array
val get_solution_list : t -> int list list
type
solution
val iter_solution : (solution -> unit) -> t -> unit
iter_solution f p
applies f
on each solution of the problem p
,
one at a timeval list_of_solution : solution -> int list
val print_solution : Format.formatter -> solution -> unit