Abstract
Let F (p) n be the set of all n-length bitstrings such that there are no p consecutive ls. F (p) n is counted with the pth order Fibonacci numbers and it may be regarded as the subsets of {1, 2,…, n} without p consecutive elements and bitstrings in F (p) n code a particular class of trees or compositions of an integer. In this paper we give a Gray code for F (p) n which can be implemented in a recursive generating algorithm, and finally in a loopless generating algorithm.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
J.R. Bitner, G. Ehrlich and E.M. Reingold, Efficient generation of the binary reflected Gray code and its applications, Commun. ACM 19 (1976), 517–521.
G. Brightwell and P. Winkler, Counting linear extensions, Order 8 (1991), 225–242.
E.R. Canfield and S.G. Williamson, A loop-free algorithm for generating linear extensions of poset, Order 12 (1995), 57–75.
P.J. Chase, Combination generation and Graylex ordering, Congr. Numer. 69 (1989), 215–242.
N. Dershowitz, A simplified loop-free algorithm for generating permutations, BIT 15 (1975), 158–164.
G. Ehrlich, Loopless algorithms for generating permutations, combinations, and other combinatorial objects, J. ACM 20 (1973), 500–513.
T.I. Fenner and G. Loizou, A binary tree representation and related algorithms for generating integer partitions, Comput. J. 23 (1980), 332–337.
P. Flajolet and R. Sedgewick, Counting and Generating Functions, Res. Rep. no. 1888, INRIA, 1993. http://pauillac.inria.fr/algo/flajolet/Publications/books.html
R.L. Graham, D.E. Knuth and O. Patashnik, Concrete Mathematics, Second Edition, Reading, Massachusetts: Addison-Wesley, 1994.
F. Gray, Pulse Code Communication, U. S. Patent 2632058 (1953).
W-J. Hsu, Fibonacci cubes - a new interconnection topology, IEEE Transactions on Parallel and Distributed Systems 4(1) (1993), 3–12.
J.T. Joichi, D.E. White and S.G. Williamson, Combinatorial Gray codes, SIAM J. Comput. 9(1) (1980), 130–141.
D.E. Knuth, The Art of Computer Programming. Vol. 3 Sorting and Searching, Addison-Wesley, 1966.
J.F. Korsh, Loopless generation of k-ary tree sequences, Information Processing Letters 52 (1994), 243–147.
J.F. Korsh and S. Lipschutz, Generating multiset permutations in constant time, J. Algorithms 25 (1997), 321–335.
J.F. Korsh and S. Lipschutz, Shifts and loopless generation of k-ary trees, Information Processing Letters 65(5) (1998), 235–240.
J.F. Korsh and P. Lafollette, Loopless generation of Gray codes for k-ary trees, Information Processing Letters 70(1) (1999), 7–11.
J.F. Korsh and P. Lafollette, Multiset permutations and loopless generation of ordered trees with specified degree sequences, J. Algorithms 34(2) (2000), 309–336.
J. Liu, W.-J. Hsu and M.J. Chung, Generalized Fibonacci cubes are mostly Hamiltonian, Journal of Graph Theory 18(8) (1994), 817–829.
J.M. Lucas, D. Roelants van baronaigien and F. Ruskey, On rotations and the generation of binary trees, J. Algorithms 15(1993), 343–366.
K. Mikawa and T. Takaoka, Generation of parenthesis strings by transpositions, in Proc. CATS’97, Sydney, Australia, February 3–4, 1997.
A. Nijenhuis and H.S. Wilf, Combinatorial Algorithms, Academic Press, 1975.
J.M. Pallo, On the listing and random generation of hybrid binary trees, Intern. J. Comput. Math. 50 (1994), 135–145.
D. Roelants van baronaigien, A loopless algorithm for generating binary tree sequences, Information Processing Letters 39 (1991), 189–194.
D. Roelants van baronaigien and F. Ruskey, Efficient generation of subsets with a given sum, JCMCC 14 (1993), 87–96.
F. Ruskey and A. Proskurowski, Generating binary trees by transpositions, J. Algorithms 11 (1990), 68–84.
N.J.A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973.
M. Squire, Gray codes for A-free strings, Electronic J. Combinatorics,3(1996), paper R17.
V. Vajnovszki, Loopless generation of well-formed parenthesis strings, Research Report Department IEM,University of Burgundy, September 1997.
V. Vajnovszki, On the loopless generation of binary tree sequences, Information Processing Letters 68(1998) 113–117.
V. Vajnovszki, Generating a Gray Code for P-sequences, to appear in International Journal of Mathematical Algorithms.
T.R. Walsh, A simple sequencing and ranking method that works on almost all Gray codes, Res. Rep. no. 243, Department of Mathematics and Computer Science, University of Quebec at Montreal, April 1995.
T.R. Walsh, Generation of well-formed parenthesis strings in constant worst-case time, Journal of Algorithms 29(1) (1998), 651–673.
H.S. Wilf, Combinatorial algorithms: An update, SIAM, CBNS 55, 1989.
J. Wu, Extended Fibonacci Cubes, IEEE Transactions on Parallel and Distributed Systems 8(12)(1997), 1203–1210.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2001 Springer-Verlag London Limited
About this paper
Cite this paper
Vajnovszki, V. (2001). A Loopless Generation of Bitstrings without p Consecutive Ones. In: Calude, C.S., Dinneen, M.J., Sburlan, S. (eds) Combinatorics, Computability and Logic. Discrete Mathematics and Theoretical Computer Science. Springer, London. https://doi.org/10.1007/978-1-4471-0717-0_19
Download citation
DOI: https://doi.org/10.1007/978-1-4471-0717-0_19
Publisher Name: Springer, London
Print ISBN: 978-1-85233-526-7
Online ISBN: 978-1-4471-0717-0
eBook Packages: Springer Book Archive