On O(1) time algorithms for combinatorial generation

Citation
Lm. Xiang et K. Ushijima, On O(1) time algorithms for combinatorial generation, COMPUTER J, 44(4), 2001, pp. 292-302
Citations number
33
Categorie Soggetti
Computer Science & Engineering
Journal title
COMPUTER JOURNAL
ISSN journal
00104620 → ACNP
Volume
44
Issue
4
Year of publication
2001
Pages
292 - 302
Database
ISI
SICI code
0010-4620(2001)44:4<292:OOTAFC>2.0.ZU;2-0
Abstract
Takaoka has recently proposed two loopless algorithms for generating well f ormed parenthesis strings with length 2n and combinations C(r, n) of n elem ents out of r elements, respectively. O(1) time algorithms for generating C (r, n) in canonical representation that were found in the literature cannot list combinations with the Strong Minimal Change Property (SMCP), Eades an d McKay's algorithm can generate C(r, n) in canonical representation with S MCP, but needs O(n) worst-case time per combination. In this paper, we main ly discuss some orders with SMCP for C(r, n) in canonical representation, a nd give a loopless algorithm to generate C(r, n) in canonical representatio n with SMCP. We also give a loopless algorithm to list well formed parenthe sis strings with length 2n. Our two algorithms are more efficient in both s pace and time than Takaoka's two algorithms, respectively. In addition, our algorithms can be modified easily to generate objects in some different or ders.