Sudoku puzzle generation using mathematical programming and heuristics: Puzzle construction and game development

IF 7.5 1区 计算机科学 Q1 COMPUTER SCIENCE, ARTIFICIAL INTELLIGENCE
Tugce Ates, Fatih Cavdur
{"title":"Sudoku puzzle generation using mathematical programming and heuristics: Puzzle construction and game development","authors":"Tugce Ates,&nbsp;Fatih Cavdur","doi":"10.1016/j.eswa.2025.127710","DOIUrl":null,"url":null,"abstract":"<div><div>In this study, first, a new mathematical programming formulation for generating Sudoku puzzles is proposed. It is possible to generate specially-configured puzzle instances using the proposed formulation which is flexible enough to control not only the numbers of the Sudoku matrix entries shown in each column, row and sub-matrix, but also the times each number appears by setting up the corresponding model parameters accordingly. The initially developed non-linear program with a quadratic constraint is reformulated as a linear-integer program by using appropriate variate transformations. The resulting mathematical program is then solved to generate Sudoku puzzles and its computational performance is analyzed through computational experiments. It is noted that the formulation is fast enough to generate Sudoku puzzles in reasonable time periods using a commercial solver on a personal computer. The study then discusses how to ensure the uniqueness of a solution for a puzzle instance generated by a hybrid approach that integrates the mathematical program with a heuristic algorithm. In the final part of the study, the idea of the proposed hybrid approach is extended and a backtracking algorithm-based puzzle generation procedure is designed and implemented by developing a standalone mobile-web game application.</div></div>","PeriodicalId":50461,"journal":{"name":"Expert Systems with Applications","volume":"282 ","pages":"Article 127710"},"PeriodicalIF":7.5000,"publicationDate":"2025-04-22","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Expert Systems with Applications","FirstCategoryId":"94","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S0957417425013326","RegionNum":1,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q1","JCRName":"COMPUTER SCIENCE, ARTIFICIAL INTELLIGENCE","Score":null,"Total":0}
引用次数: 0

Abstract

In this study, first, a new mathematical programming formulation for generating Sudoku puzzles is proposed. It is possible to generate specially-configured puzzle instances using the proposed formulation which is flexible enough to control not only the numbers of the Sudoku matrix entries shown in each column, row and sub-matrix, but also the times each number appears by setting up the corresponding model parameters accordingly. The initially developed non-linear program with a quadratic constraint is reformulated as a linear-integer program by using appropriate variate transformations. The resulting mathematical program is then solved to generate Sudoku puzzles and its computational performance is analyzed through computational experiments. It is noted that the formulation is fast enough to generate Sudoku puzzles in reasonable time periods using a commercial solver on a personal computer. The study then discusses how to ensure the uniqueness of a solution for a puzzle instance generated by a hybrid approach that integrates the mathematical program with a heuristic algorithm. In the final part of the study, the idea of the proposed hybrid approach is extended and a backtracking algorithm-based puzzle generation procedure is designed and implemented by developing a standalone mobile-web game application.
利用数学编程和启发式方法生成数独谜题:谜题构建和游戏开发
在本研究中,首先,提出一个新的数学规划公式生成数独谜题。使用所提出的公式可以生成特殊配置的谜题实例,该公式足够灵活,不仅可以控制每列、每行和子矩阵中显示的数独矩阵条目的数量,还可以通过设置相应的模型参数来控制每个数字出现的次数。通过使用适当的变量变换,将最初开发的具有二次约束的非线性程序重新表述为线性整数程序。然后求解得到的数学程序生成数独谜题,并通过计算实验分析其计算性能。值得注意的是,该公式足够快,可以在合理的时间内使用个人计算机上的商业解算器生成数独谜题。然后,研究讨论了如何通过将数学程序与启发式算法相结合的混合方法来确保解的唯一性。在研究的最后一部分,我们扩展了混合方法的理念,并通过开发一款独立的移动网页游戏应用设计并实现了基于回溯算法的谜题生成过程。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
Expert Systems with Applications
Expert Systems with Applications 工程技术-工程:电子与电气
CiteScore
13.80
自引率
10.60%
发文量
2045
审稿时长
8.7 months
期刊介绍: Expert Systems With Applications is an international journal dedicated to the exchange of information on expert and intelligent systems used globally in industry, government, and universities. The journal emphasizes original papers covering the design, development, testing, implementation, and management of these systems, offering practical guidelines. It spans various sectors such as finance, engineering, marketing, law, project management, information management, medicine, and more. The journal also welcomes papers on multi-agent systems, knowledge management, neural networks, knowledge discovery, data mining, and other related areas, excluding applications to military/defense systems.
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信