4

Knuth's dancing links solver is featured prominently on the Wikipedia page of the Exact Cover Problem. A more recent version for exact cover with colors using Dancing cells was released by Knuth. This was discussed Don Knuth's 27th Annual Christmas Tree Lecture .

Is this solver competitive on exact cover problems against SAT solvers, Constraint Satisfaction programming solvers and MILP solvers on modern multi-core hardware for problems with non-negliable run times or is it more an academic curiousity ?

2 Answers2

2

I have used Knuth's various XCC solvers for many large-scale combinatorial problems, including polyomino tiling puzzles, the longest uncrossed knight's path, and some queen problems on chessboards. In my personal experience, there are a few examples where the XCC solvers beat the state-of-the-art SAT and MILP solvers at finding a solution, but they excel at finding all solutions to a problem.

However, one should keep in mind that most SAT/MILP/CSP solvers are simply not designed to exhaustively search for all solutions, so this points not necessarily to an inherent advantage of the XCC approach.

Tobi
  • 153
  • 4
2

Tobi is right in that Knuth's XCC solvers are usually advertised as efficient if you want to enumerate all covers. For that reason, a comparison with model counters may be more relevant. These extend SAT solvers to count (and sometimes enumerate) all models of a formula.

I found a 2010 comparison of model counters on encodings of XCC instances against Knuth's dancing links algorithm (DLX):

https://link.springer.com/chapter/10.1007/978-3-642-15396-9_25

the solvers considered include:

  • Cachet
  • sharpSAT
  • Satz
  • relsat
  • clasp
  • c2d (non-DPLL based)

The authors seem to conclude that DLX (or at least the libexact implementation of the algorithm) runs faster than the alternatives on most of the benchmarks they considered. They close the paper with: "instances of exact cover translated into satisfiability present challenging benchmarks for the development of practical #SAT solvers."