Generating highly balanced sudoku problems as hard problems

Sudoku problems are some of the most known and enjoyed pastimes, with a never diminishing popularity, but, for the last few years those problems have gone from an entertainment to an interesting research area, a twofold interesting area, in fact. On the one side Sudoku problems, being a variant of Gerechte Designs and Latin Squares, are being actively used for experimental design, as in Bailey et al. (Am. Math. Mon. 115:383–404, 2008; J. Agron. Crop Sci. 165:121–130, 1990), Morgan (Latin squares and related experimental designs. Wiley, New York, 2008) and Vaughan (Electron. J. Comb. 16, 2009). On the other hand, Sudoku problems, as simple as they seem, are really hard structured combinatorial search problems, and thanks to their characteristics and behavior, they can be used as benchmark problems for refining and testing solving algorithms and approaches. Also, thanks to their high inner structure, their study can contribute more than studies of random problems to our goal of solving real-world problems and applications and understanding problem characteristics that make them hard to solve. In this work we use two techniques for solving and modeling Sudoku problems, namely, Constraint Satisfaction Problem (CSP) and Satisfiability Problem (SAT) approaches. To this effect we define the Generalized Sudoku Problem (GSP), where regions can be of rectangular shape, problems can be of any order, and solution existence is not guaranteed. With respect to the worst-case complexity, we prove that GSP with block regions of m rows and n columns with m≠n is NP-complete. For studying the empirical hardness of GSP, we define a series of instance generators, that differ in the balancing level they guarantee between the constraints of the problem, by finely controlling how the holes are distributed in the cells of the GSP. Experimentally, we show that the more balanced are the constraints, the higher the complexity of solving the GSP instances, and that GSP is harder than the Quasigroup Completion Problem (QCP), a problem generalized by GSP. Finally, we provide a study of the correlation between backbone variables—variables with the same value in all the solutions of an instance—and hardness of GSP.

[1]  Rémi Monasson,et al.  2+p-SAT: Relation of typical-case complexity to the nature of the phase transition , 1999, Random Struct. Algorithms.

[2]  Peter J. Cameron,et al.  Sudoku, Gerechte Designs, Resolutions, Affine Space, Spreads, Reguli, and Hamming Codes , 2008, Am. Math. Mon..

[3]  Toby Walsh,et al.  Backbones and Backdoors in Satisfiability , 2005, AAAI.

[4]  Barbara M. Smith,et al.  Sparse Constraint Graphs and Exceptionally Hard Problems , 1995, IJCAI.

[5]  Manuel Cebrián,et al.  Redundant Modeling for the QuasiGroup Completion Problem , 2003, CP.

[6]  Bart Selman,et al.  Heavy-Tailed Distributions in Combinatorial Search , 1997, CP.

[7]  Tad Hogg,et al.  Exploiting the Deep Structure of Constraint Problems , 1994, Artif. Intell..

[8]  Bart Selman,et al.  Balance and Filtering in Structured Satisfiable Problems , 2001, IJCAI.

[9]  Subhash Suri,et al.  Improved Algorithms for Optimal Winner Determination in Combinatorial Auctions and Generalizations , 2000, AAAI/IAAI.

[10]  Ian P. Gent,et al.  Minion: A Fast Scalable Constraint Solver , 2006, ECAI.

[11]  Joachim Kunert,et al.  Some comments on gerechte designs. I. Analysis for uncorrelated errors. , 1990 .

[12]  Christian Bessiere,et al.  MAC and Combined Heuristics: Two Reasons to Forsake FC (and CBJ?) on Hard Problems , 1996, CP.

[13]  Carlos Ansótegui,et al.  Exploiting multivalued knowledge in variable selection heuristics for SAT solvers , 2007, Annals of Mathematics and Artificial Intelligence.

[14]  Toby Walsh,et al.  The Backbone of the Travelling Salesperson , 2005, IJCAI.

[15]  Emil R. Vaughan,et al.  The Complexity of Constructing Gerechte Designs , 2009, Electron. J. Comb..

[16]  Sharad Malik,et al.  Chaff: engineering an efficient SAT solver , 2001, Proceedings of the 38th Design Automation Conference (IEEE Cat. No.01CH37232).

[17]  Carlos Ansótegui,et al.  Modeling Choices in Quasigroup Completion: SAT vs. CSP , 2004, AAAI.

[18]  Bart Selman,et al.  Heavy-Tailed Phenomena in Satisfiability and Constraint Satisfaction Problems , 2000, Journal of Automated Reasoning.

[19]  Rhyd Lewis,et al.  Metaheuristics can solve sudoku puzzles , 2007, J. Heuristics.

[20]  Jörg Hoffmann,et al.  Structure and Problem Hardness: Goal Asymmetry and DPLL Proofs in SAT-Based Planning , 2006, Log. Methods Comput. Sci..

[21]  Feng Luo,et al.  Exploring the k-colorable landscape with Iterated Greedy , 1993, Cliques, Coloring, and Satisfiability.

[22]  Prasad Tetali,et al.  Simple Markov-chain algorithms for generating bipartite graphs and tournaments , 1997, SODA '97.

[23]  Joseph C. Culberson,et al.  Camouflaging independent sets in quasi-random graphs , 1993, Cliques, Coloring, and Satisfiability.

[24]  Xu Rugen,et al.  Sudoku Square — a New Design in Field , 2008 .

[25]  Inês Lynce,et al.  Haplotype Inference with Boolean Satisfiability , 2008, Int. J. Artif. Intell. Tools.

[26]  Bart Selman,et al.  Generating Satisfiable Problem Instances , 2000, AAAI/IAAI.

[27]  Niklas Sörensson,et al.  An Extensible SAT-solver , 2003, SAT.

[28]  P. Matthews,et al.  Generating uniformly distributed random latin squares , 1996 .

[29]  Joël Ouaknine,et al.  Sudoku as a SAT Problem , 2006, ISAIM.

[30]  Ke Xu,et al.  Random constraint satisfaction: Easy generation of hard (satisfiable) instances , 2007, Artif. Intell..

[31]  Tad Hogg Exploiting the Deep Structure of Constraint Satisfaction Problems with Quantum Computers , 1997, AAAI/IAAI.

[32]  J. Culberson,et al.  Consistency and Random Constraint Satisfaction Models , 2007, J. Artif. Intell. Res..

[33]  Carlos Ansótegui,et al.  The Impact of Balancing on Problem Hardness in a Highly Structured Domain , 2006, AAAI.

[34]  Matthew W. Moskewicz,et al.  Cha : Engineering an e cient SAT solver , 2001, DAC 2001.

[35]  Josep Argelich,et al.  CNF Instances from the Software Package Installation Problem , 2008, RCRA.

[36]  Ulrich Endriss,et al.  Bidding Languages and Winner Determination for Mixed Multi-unit Combinatorial Auctions , 2007, EUMAS.

[37]  Bertram Felgenhauer,et al.  Mathematics of Sudoku I , 2006 .

[38]  H. Simonis,et al.  Sudoku as a Constraint Problem , 2005 .

[39]  Carlos Ansótegui,et al.  On Balanced CSPs with High Treewidth , 2007, AAAI.

[40]  S. Kirkpatrick,et al.  2+p-SAT: relation of typical-case complexity to the nature of the phase transition , 1999 .

[41]  Carlos Ansótegui,et al.  From High Girth Graphs to Hard Instances , 2008, CP.

[42]  Bart Selman,et al.  Formal Models of Heavy-Tailed Behavior in Combinatorial Search , 2001, CP.

[43]  Toby Walsh,et al.  The TSP Phase Transition , 1996, Artif. Intell..

[44]  Latin squares and related experimental designs 1 Introduction , 2007 .

[45]  T. Yato,et al.  Complexity and Completeness of Finding Another Solution and Its Application to Puzzles , 2003, IEICE Trans. Fundam. Electron. Commun. Comput. Sci..

[46]  Bart Selman,et al.  Problem Structure in the Presence of Perturbations , 1997, AAAI/IAAI.

[47]  Chu Min Li,et al.  Look-Ahead Versus Look-Back for Satisfiability Problems , 1997, CP.

[48]  Peter Jeavons,et al.  Symmetry Definitions for Constraint Satisfaction Problems , 2005, CP.

[49]  Wei Li,et al.  Exact Phase Transitions in Random Constraint Satisfaction Problems , 2000, J. Artif. Intell. Res..

[50]  Jean-Paul Delahaye The science behind Sudoku. , 2006, Scientific American.