A calculus of random generation (original) (raw)

Abstract

A systematic approach to the random generation of labelled combinatorial objects is presented. It applies to structures that are decomposable, i.e., formally specifiable by grammars involving union, product, set, sequence, and cycle constructions. A general strategy is developed for solving the random generation problem with two closely related types of methods: for structures of size n, the boustrophedonic algorithms exhibit a worst-case behaviour of the form \(\mathcal{O}\left( {n\log n} \right)\); the sequential algorithms have worst case \(\mathcal{O}\left( {n^2 } \right)\), while offering good potential for optimizations in the average case. (Both methods appeal to precomputed numerical tables of linear size).

A companion calculus permits to systematically compute the average case cost of the sequential generation algorithm associated to a given specification. Using optimizations dictated by the cost calculus, several random generation algorithms are developed, based on the sequential principle; most of them have expected complexity 1/2 n log n, thus being only slightly superlinear. The approach is exemplified by the random generation of a number of classical combinatorial structures including Cayley trees, hierarchies, the cycle decomposition of permutations, binary trees, functional graphs, surjections, and set partitions.

Preview

Unable to display preview. Download preview PDF.

Similar content being viewed by others

References

  1. Flajolet, P., and Odlyzko, A. M. Singularity analysis of generating functions. SIAM Journal on Discrete Mathematics 3, 2 (1990), 216–240.
    Google Scholar
  2. Flajolet, P., Salvy, B., and Zimmermann, P. Automatic average-case analysis of algorithms. Theoretical Computer Science, Series A 79, 1 (Feb. 1991), 37–109.
    Google Scholar
  3. Flajolet, P., Zimmerman, P., and Van Cutsem, B. A calculus for the random generation of labelled combinatorial structures. Research Report 1830, Institut National de Recherche en Informatique et en Automatique, Jan. 1993. 29 pages. Accepted for publication in Theoretical Computer Science.
    Google Scholar
  4. Greene, D. H. Labelled formal languages and their uses. PhD thesis, Stanford University, June 1983. Available as Report No. STAN-CS-83-982.
    Google Scholar
  5. Greene, D. H., And Knuth, D. E.Mathematics for the analysis of algorithms. Birkhauser, Boston, 1981.
    Google Scholar
  6. Hickey, T., And Cohen, J. Uniform random generation of strings in a contextfree language. SIAM Journal on Computing 12, 4 (1983), 645–655.
    Google Scholar
  7. Joyal, A. Une théorie combinatoire des séries formelles. Advances in Mathematics 42, 1 (1981), 1–82.
    Google Scholar
  8. Knuth, D. E. Mathematical analysis of algorithms. In Information Processing 71 (1972), North Holland Publishing Company, pp. 19–27. Proceedings of IFIP Congress, Ljubljana, 1971.
    Google Scholar
  9. Meir, A., And Moon, J. W. On the altitude of nodes in random trees. Canadian Journal of Mathematics 30 (1978), 997–1015.
    Google Scholar
  10. Nijenhus, A., And Wilf, H. S. Combinatorial Algorithms, second ed. Academic Press, 1978.
    Google Scholar
  11. Wilf, H. S.Combinatorial Algorithms: An Update. No. 55 in CBMS-NSF Regional Conference Series. Society for Industrial and Applied Mathematics, Philadelphia, 1989.
    Google Scholar

Download references

Author information

Authors and Affiliations

  1. Algorithms Project, INRIA Rocquencourt, F-78153, Le Chesnay, France
    Philippe Flajolet
  2. INRIA Lorraine, 615 rue du Jardin Botanique, F-54600, Villers-les-Nancy, France
    Paul Zimmermann
  3. Laboratoire de Modélisation et Calcul, Université Joseph Fourier, BP 53X, F-38041, Grenoble Cedex, France
    Bernard van Cutsem

Authors

  1. Philippe Flajolet
  2. Paul Zimmermann
  3. Bernard van Cutsem

Editor information

Thomas Lengauer

Rights and permissions

© 1993 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Flajolet, P., Zimmermann, P., van Cutsem, B. (1993). A calculus of random generation. In: Lengauer, T. (eds) Algorithms—ESA '93. ESA 1993. Lecture Notes in Computer Science, vol 726. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-57273-2\_53

Download citation

Keywords

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Publish with us