Maze Generation Algorithms: A Comparative Research with a Focus on Recursive Backtracking in OCaml
Jiahao Li
2025
Abstract
Maze generation is a well-studied domain in computer science, widely applied in game development, robotic navigation, and procedural content generation. This paper provides a comprehensive overview of several maze generation algorithms with a specific focus on recursive backtracking implemented in OCaml. The foundational concepts of maze generation are first discussed, followed by an evaluation of multiple popular algorithms, such as Binary Tree, Prim’s, Kruskal’s, and Aldous–Broder methods. The recursive backtracking algorithm, despite its simplicity, demonstrates effectiveness in generating perfect mazes with high spatial uniformity. This algorithm is implemented in OCaml, addressing the functional paradigm’s treatment of mutable state, randomness, and grid structures. The review highlights the practical strengths of recursive backtracking in both educational and experimental settings. Algorithmic characteristics such as coverage, path uniqueness, and efficiency are compared across methods. The paper concludes by outlining future directions, including enhanced visualization, algorithmic hybrids, and game-level complexity additions. Additionally, this comparative analysis aims to support informed decisions for selecting maze generation techniques in specific application scenarios.
DownloadPaper Citation
in Harvard Style
Li J. (2025). Maze Generation Algorithms: A Comparative Research with a Focus on Recursive Backtracking in OCaml. In Proceedings of the 2nd International Conference on Engineering Management, Information Technology and Intelligence - Volume 1: EMITI; ISBN 978-989-758-792-4, SciTePress, pages 432-437. DOI: 10.5220/0014360800004718
in Bibtex Style
@conference{emiti25,
author={Jiahao Li},
title={Maze Generation Algorithms: A Comparative Research with a Focus on Recursive Backtracking in OCaml},
booktitle={Proceedings of the 2nd International Conference on Engineering Management, Information Technology and Intelligence - Volume 1: EMITI},
year={2025},
pages={432-437},
publisher={SciTePress},
organization={INSTICC},
doi={10.5220/0014360800004718},
isbn={978-989-758-792-4},
}
in EndNote Style
TY - CONF
JO - Proceedings of the 2nd International Conference on Engineering Management, Information Technology and Intelligence - Volume 1: EMITI
TI - Maze Generation Algorithms: A Comparative Research with a Focus on Recursive Backtracking in OCaml
SN - 978-989-758-792-4
AU - Li J.
PY - 2025
SP - 432
EP - 437
DO - 10.5220/0014360800004718
PB - SciTePress