Journal of Heuristics

, Volume 22, Issue 5, pp 727–757 | Cite as

Iterated local search with Trellis-neighborhood for the partial Latin square extension problem

  • Kazuya HaraguchiEmail author


A partial Latin square (PLS) is a partial assignment of n symbols to an \(n\times n\) grid such that, in each row and in each column, each symbol appears at most once. The PLS extension problem is an NP-hard problem that asks for a largest extension of a given PLS. We consider the local search such that the neighborhood is defined by (pq)-swap , i.e., the operation of dropping exactly p symbols and then assigning symbols to at most q empty cells. As a fundamental result, we provide an efficient \((p,\infty )\)-neighborhood search algorithm that finds an improved solution or concludes that no such solution exists for \(p\in \{1,2,3\}\). The running time of the algorithm is \(O(n^{p+1})\). We then propose a novel swap operation, Trellis-swap, which is a generalization of (pq)-swap with \(p\le 2\). The proposed Trellis-neighborhood search algorithm runs in \(O(n^{3.5})\) time. The iterated local search (ILS) algorithm with Trellis-neighborhood is more likely to deliver a high-quality solution than not only ILSs with \((p,\infty )\)-neighborhood but also state-of-the-art optimization solvers such as IBM ILOG CPLEX and LocalSolver.


Partial Latin square extension problem Maximum independent set problem Metaheuristics Local search 



We gratefully acknowledge very careful and detailed comments given by anonymous reviewers. This work is partially supported by JSPS KAKENHI Grant Number 25870661.


  1. Alidaee, B., Kochenberger, G., Wang, H.: Simple and fast surrogate constraint heuristics for the maximum independent set problem. J. Heuristics 14, 571–585 (2008)CrossRefzbMATHGoogle Scholar
  2. Andrade, D.V., Resende, M.G.C., Werneck, R.F.: Fast local search for the maximum independent set problem. J. Heuristics 18, 525–547 (2012). The preliminary version appeared in Proceedings of the 7th WEA (LNCS vol. 5038), pp. 220–234 (2008)Google Scholar
  3. Ansótegui, C., Val, A., Dotú, I., Fernández, C., Manyà, F.: Modeling choices in quasigroup completion: SAT vs. CSP. In: Proceedings of the National Conference on Artificial Intelligence, pp. 137–142 (2004)Google Scholar
  4. Appa, G., Magos, D., Mourtos, I.: Searching for mutually orthogonal latin squares via integer and constraint programming. Eur. J. Oper. Res. 173(2), 519–530 (2006a)MathSciNetCrossRefzbMATHGoogle Scholar
  5. Appa, G., Magos, D., Mourtos, I.: A new class of facets for the latin square polytope. Discret. Appl. Math. 154(6), 900–911 (2006b)MathSciNetCrossRefzbMATHGoogle Scholar
  6. Barry, R.A., Humblet, P.A.: Latin routers, design and implementation. IEEE/OSA J. Lightwave Technol. 11(5), 891–899 (1993)CrossRefGoogle Scholar
  7. Barták, R.: On generators of random quasigroup problems. Proc. CSCLP 2005, 164–178 (2006)zbMATHGoogle Scholar
  8. Colbourn, C.J.: The complexity of completing partial latin squares. Discret. Appl. Math. 8, 25–30 (1984)MathSciNetCrossRefzbMATHGoogle Scholar
  9. Colbourn, C.J., Dinitz, J.H.: Handbook of Combinatorial Designs, 2nd edn. Chapman & Hall/CRC, Boca Raton (2006)CrossRefzbMATHGoogle Scholar
  10. Crawford, B., Aranda, M., Castro, C., Monfroy, E.: Using constraint programming to solve sudoku puzzles. In: Proceedings of the ICCIT ’08, vol. 2, pp. 926–931 (2008)Google Scholar
  11. Crawford, B., Castro, C., Monfroy, E.: Solving sudoku with constraint programming. In: Cutting-Edge Research Topics on Multiple Criteria Decision Making. Communications in Computer and Information Science, vol. 35, pp. 345–348 (2009)Google Scholar
  12. Cygan, M.: Improved approximation for 3-dimensional matching via bounded pathwidth local search. In: Proceedings of the FOCS 2013, pp. 509–518 (2013)Google Scholar
  13. Eén, N., Sörensson, N.: The MiniSat Page (ver. 2.2.0)., (2010). Accessed 10 July 2015
  14. Fürer, M., Yu, H.: Approximating the \(k\)-set packing problem by local improvements. In Proceedings of the ISCO 2014. LNCS, vol. 8596, pp. 408–420 (2014)Google Scholar
  15. Garey, M.R., Johnson, D.S.: Computers and Intractability: A Guide to the Theory of NP-Completeness. W. H. Freeman & Company, New York (1979)zbMATHGoogle Scholar
  16. Gomes, C., Sellmann, M., van Es, C., van Es, H.: The challenge of generating spatially balanced scientific experiment designs. In: Proceedings of the CPAIOR 2004. LNCS, vol. 3011, pp. 387–394 (2004a)Google Scholar
  17. Gomes, C.P., Selman, B.: Problem structure in the presence of perturbations. In: Proceedings of the AAAI-97, pp. 221–227 (1997)Google Scholar
  18. Gomes, C.P., Shmoys, D.B.: Completing quasigroups or latin squares: a structured graph coloring problem. In: Proceedings of the Computational Symposium on Graph Coloring and Generalizations (2002)Google Scholar
  19. Gomes, C.P., Regis, R.G., Shmoys, D.B.: An improved approximation algorithm for the partial Latin square extension problem. Oper. Res. Lett. 32(5), 479–484 (2004b)MathSciNetCrossRefzbMATHGoogle Scholar
  20. Hajirasouliha, I., Jowhari, H., Kumar, R., Sundaram. R.: On completing latin squares. In: Proceedings of the STACS 2007. LNCS, vol. 4393, pp. 524–535 (2007)Google Scholar
  21. Haraguchi, K.: An efficient local search for the constrained symmetric Latin square construction problem. In PreparationGoogle Scholar
  22. Haraguchi, K.: A constructive algorithm for partial latin square extension problem that solves hardest instances effectively. In: Recent Advances in Computational Optimization—Results of the Workshop on Computational Optimization WCO 2013 at FedCSIS 2013, pp. 67–84 (2013)Google Scholar
  23. Haraguchi, K.: An efficient local search for partial latin square extension problem. In: Proceedings of the CPAIOR 2015. LNCS, vol. 9075, pp. 182–198 (2015)Google Scholar
  24. Haraguchi, K., Ono, H.: Approximability of latin square completion-type puzzles. In: Proceedings of the FUN 2014. LNCS, vol. 8496, pp. 218–229 (2014)Google Scholar
  25. Hopcroft, J.E., Karp, R.M.: An \(n^{5/2}\) algorithm for maximum matchings in bipartite graphs. SIAM J. Comput. 2(4), 225–231 (1973)MathSciNetCrossRefzbMATHGoogle Scholar
  26. Hurkens, C.A.J., Schrijver, A.: On the size of systems of sets every \(t\) of which have an SDR, with an application to the worst-case ratio of heuristics for packing problems. SIAM J. Discret. Math. 2(1), 68–72 (1989)MathSciNetCrossRefzbMATHGoogle Scholar
  27. Ignatiev, A., Morgado, A., Marques-Silva, J.: On reducing maximum independent set to minimum satisfiability. In: Proceedings of the SAT 2014. LNCS, vol. 8561, pp. 103–120 (2014)Google Scholar
  28. Itoyanagi, J., Hashimoto, H., Yagiura, M.: A local search algorithm with large neighborhoods for the maximum weighted independent set problem. In: Proceedings of the MIC 2011, pp. 191–200, 2011. The full paper is written in Japanese as a master thesis of the 1st author in Graduate School of Information Science, Nagoya University (2011)Google Scholar
  29. Kumar, R., Russel, A., Sundaram, R.: Approximating latin square extensions. Algorithmica 24(2), 128–138 (1999)MathSciNetCrossRefzbMATHGoogle Scholar
  30. Lambert, T., Monfroy, E., Saubion, F.: A generic framework for local search: Application to the sudoku problem. In: Proceedings of the ICCS 2006. LNCS, vol. 3991, pp. 641–648 (2006)Google Scholar
  31. Le Bras, R., Perrault, A., Gomes, C.P.: Polynomial time construction for spatially balanced latin squares. Technical report, Computing and Information Science Technical Reports, Cornell University (2012).
  32. Lewis, R.: Metaheuristics can solve sudoku puzzles. J. Heuristics 13(4), 387–401 (2007)CrossRefGoogle Scholar
  33. Li, C.M., Manyà, F., Planes, J.: New inference rules for max-sat. J. Artif. Intell. Res. 30, 321–359 (2007)MathSciNetzbMATHGoogle Scholar
  34. Li, C.M., Zhu, Z., Manyà, F., Simon, L.: Optimizing with minimum satisfiability. Artif. Intell. 190, 32–44 (2012)MathSciNetCrossRefzbMATHGoogle Scholar
  35. Ma, F., Zhang, J.: Finding orthogonal latin squares using finite model searching tools. Sci. China Inf. Sci. 56(3), 1–9 (2013)MathSciNetCrossRefGoogle Scholar
  36. Rasmussen, R.V., Trick, M.A.: Round robin scheduling: a survey. Eur. J. Oper. Res. 188(3), 617–636 (2008)MathSciNetCrossRefzbMATHGoogle Scholar
  37. Rosenhouse, J., Taalman, L.: Taking Sudoku Seriously. Oxford University Press, New York (2012)zbMATHGoogle Scholar
  38. Simonis, H.: Sudoku as a constraint problem. (2005). Accessed 10 July 2015
  39. Smith, C., Gomes, C., Fernandez, C.: Streamlining local search for spatially balanced latin squares. In: Proceedings of the IJCAI’05, pp. 1539–1541 (2005)Google Scholar
  40. Soto, R., Crawford, B., Galleguillos, C., Monfroy, E., Paredes, F.: A hybrid AC3-tabu search algorithm for solving sudoku puzzles. Expert Syst. Appl. 40(15), 5817–5821 (2013)CrossRefGoogle Scholar
  41. Tamura, N.: Sugar: a SAT-based Constraint Solver (ver. 2.2.1). (2014). Accessed 10 July 2015
  42. Vieira Jr., H., Sanchez, S., Kienitz, K.H., Belderrain, M.C.N.: Generating and improving orthogonal designs by using mixed integer programming. Eur. J. Oper. Res. 215(3), 629–638 (2011)MathSciNetCrossRefzbMATHGoogle Scholar

Copyright information

© Springer Science+Business Media New York 2016

Authors and Affiliations

  1. 1.Faculty of CommerceOtaru University of CommerceOtaruJapan

Personalised recommendations