Sudoku Meets Linear Optimization

Image by Bozhin Karaivanov from Unsplash

Sudoku is a logic-based number puzzle played on a $9 \times 9$ grid, divided into nine smaller $3 \times 3$ blocks. The goal is to fill the grid with digits from $1$ to $9$ in such a way that each number appears exactly once in every row, column, and block.

The modern version of Sudoku was popularized in the late 1980s by the Japanese puzzle company Nikoli, although its roots go back earlier to a puzzle called “Number Place” published in the United States in 1979. Interestingly, the name “Sudoku” is an abbreviation of the Japanese phrase “Sūji wa dokushin ni kagiru”, which means “the digits must be single” or “the digits must occur only once”. Sudoku puzzles have since become a global phenomenon, appearing in newspapers, books, and apps, and they are enjoyed by millions for their combination of logic, pattern recognition, and problem-solving.

A valid Sudoku puzzle starts with some cells already filled, and the player must deduce the remaining numbers using logical reasoning, rather than guessing. For instance, consider the following Sudoku:

Do you dare to solve it logically before taking on the model?


The Sudoku can be formulated as a binary optimization model. Do you dare to try it?


Would you like to keep exploring the world of Operations Research? Discover more posts on the topic here.




If you found this useful, please cite this as:

Martín-Campo, F. Javier (Dec 2025). Sudoku Meets Linear Optimization. https://www.fjmartincampo.com/blog/2025/sudoku/.

or as a BibTeX entry:

@misc{martín-campo2025sudoku-meets-linear-optimization,
  title   = {Sudoku Meets Linear Optimization},
  author  = {Martín-Campo, F. Javier},
  year    = {2025},
  month   = {Dec},
  url     = {https://www.fjmartincampo.com/blog/2025/sudoku/}
}



Enjoy Reading This Article?

Here are some more articles you might like to read next:

  • A crime has been committed... in a sudoku!
  • The harmony of digits in solving Kakuro
  • Killer Sudoku, the empty board challenge that math can solve
  • Solving the Number Sums board using mathematical optimization
  • Building bridges with linear optimization, the Hashi puzzle