Hostname: page-component-76fb5796d-vfjqv Total loading time: 0 Render date: 2024-04-27T11:46:01.625Z Has data issue: false hasContentIssue false

Tuning as convex optimisation: a polynomial tuner for multi-parametric combinatorial samplers

Published online by Cambridge University Press:  15 December 2021

Maciej Bendkowski
Affiliation:
Theoretical Computer Science Department, Faculty of Mathematics and Computer Science, Jagiellonian University, Łojasiewicza 6, 30-348 Kraków, Poland
Olivier Bodini
Affiliation:
Institut Galilée, Université Paris 13, 99 Avenue Jean Baptiste Clément, 93430 Villetaneuse, France.
Sergey Dovgal*
Affiliation:
Institut Galilée, Université Paris 13, 99 Avenue Jean Baptiste Clément, 93430 Villetaneuse, France.
*
*Corresponding author. E-mail: vit.north@gmail.com

Abstract

Combinatorial samplers are algorithmic schemes devised for the approximate- and exact-size generation of large random combinatorial structures, such as context-free words, various tree-like data structures, maps, tilings, RNA molecules. They can be adapted to combinatorial specifications with additional parameters, allowing for a more flexible control over the output profile of parametrised combinatorial patterns. One can control, for instance, the number of leaves, profile of node degrees in trees or the number of certain sub-patterns in generated strings. However, such a flexible control requires an additional and nontrivial tuning procedure. Using techniques of convex optimisation, we present an efficient tuning algorithm for multi-parametric combinatorial specifications. Our algorithm works in polynomial time in the system description length, the number of tuning parameters, the number of combinatorial classes in the specification, and the logarithm of the total target size. We demonstrate the effectiveness of our method on a series of practical examples, including rational, algebraic, and so-called Pólya specifications. We show how our method can be adapted to a broad range of less typical combinatorial constructions, including symmetric polynomials, labelled sets and cycles with cardinality lower bounds, simple increasing trees or substitutions. Finally, we discuss some practical aspects of our prototype tuner implementation and provide its benchmark results.

Type
Paper
Copyright
© The Author(s), 2021. Published by Cambridge University Press

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

Footnotes

Maciej Bendkowski was partially supported by the Polish National Science Center grant 2016/21/N/ST6/01032 and a French Government Scholarship awarded by the French Embassy in Poland. Olivier Bodini and Sergey Dovgal were supported by the French project ANR project MetACOnc, ANR-15-CE40-0014. The current paper is an extended version of doi:10.1137/1.9781611975062.9 presented at ANALCO’18.

References

Albert, M. H. and Atkinson, M. D. (2005) Simple permutations and pattern restricted permutations. Disc. Math. 300(1–3) 1–15.Google Scholar
Arts, T., Hughes, J., Norell, U. and Svensson, H. (2015) Testing AUTOSAR software with QuickCheck. In 2015 IEEE Eighth International Conference on Software Testing, Verification and Validation Workshops (ICSTW), pp. 1–4.Google Scholar
Banderier, C., Bodini, O., Ponty, Y. and Bouzid, H.T. (2012) On the diversity ofpattern distributions in rational language. In Proceedings of the Ninth Workshop on Analytic Alg. and Combinatorics, pp. 107–115.Google Scholar
Barabási, A.-L. (2016) Network Science. Cambridge University Press.Google Scholar
Bassino, F., Bouvel, M., Pierrot, A., Pivoteau, C. and Rossin, D. (2017) An algorithm computing combinatorial specifications of permutation classes. Disc. Appl. Math. 224 16–44.Google Scholar
Bendkowski, M., Bodini, O. and Dovgal, S. (2018) Polynomial tuning of multiparametric combinatorial samplers. In 2018 Proceedings of the Fifteenth Workshop on Analytic Algorithmics and Combinatorics (ANALCO), pp. 92–106. eprint: https://epubs.siam.org/doi/pdf/10.1137/1.9781611975062.9.CrossRefGoogle Scholar
Bacher, A., Bodini, O. and Jacquot, A. (2013) Exact-size sampling for Motzkin trees in linear time via Boltzmann samplers and holonomic specification. InProceedings of the Meeting on Analytic Algorithmics and Combinatorics, pp. 52–61.Google Scholar
Bouillard, A., Bušic, A. and Rovetta, C. (2014) Perfect sampling for closed queueing networks. Perform. Eval. 79 146–159.Google Scholar
Bodini, O., David, J. and Marchal, P. (2016) Random-bit optimal uniform sampling for rooted planar trees with given sequence of degrees and applications. In Conference on Algorithms and Discrete Applied Mathematics, pp. 97–114.CrossRefGoogle Scholar
Bendkowski, M., Grygiel, K., Lescanne, P. and Zaionc, M. (2017) Combinatorics of $\lambda$ -terms: a natural approach. J. Logic Comput. CrossRefGoogle Scholar
Bodini, O., Fusy, é. and Pivoteau, C. (2010) Random sampling of plane partitions. Comb. Prob. Comput. 19(2) 201–226.CrossRefGoogle Scholar
Bernstein, M., Fahrbach, M. and Randall, D. (2018) Analyzing Boltzmann samplers for Bose–Einstein condensates with Dirichlet generating functions. In 2018 Proceedings of the Fifteenth Workshop on Analytic Algorithmics and Combinatorics (ANALCO), pp. 107–117. eprint: https://epubs.siam.org/doi/pdf/10.1137/1.9781611975062.10.Google Scholar
Bernardi, O. and Giménez, O. (2012). A linear algorithm for the random sampling from regular languages. Algorithmica 62(1) 130–145.Google Scholar
Bodini, O., Genitrini, A. and Rolin, N. (2015) Pointed versus singular Boltzmann samplers: a comparative analysis. Pure Math. Appl. 25(2) 115–131.Google Scholar
Bergeron, F., Labelle, G. and Leroux, P. (1998). Combinatorial Species and Tree-Like Structures. Vol. 67. Cambridge University Press.Google Scholar
Bodini, O., Lumbroso, J. and Rolin, N. (2015) Analytic samplers and the combinatorial rejection method. In Proceedings of the Meeting on Analytic Algorithmics and Combinatorics, pp. 40–50.Google Scholar
Bodirsky, M., Fusy, É., Kang, M. and Vigerske, S. (2011) Boltzmann samplers, Pólya theory, and cycle pointing. SIAM J. Comp. 40(3) 721–769.CrossRefGoogle Scholar
Bodini, O., Dien, M., Fontaine, X., Genitrini, A. and Hwang, H.-K. (2016) Increasing diamonds. In Latin American Symposium on Theoretical Informatics, pp. 207–219.Google Scholar
Bodini, O. (2010) Autour de la génération aléatoire sous modèle de Boltzmann [On random generation under Boltzmann models]. Habilitation. Université Pierre et Marie Curie.Google Scholar
Bodini, O. and Ponty, Y. (2010) Multi-dimensional Boltzmann sampling of context-free languages. In 21st International Meeting on Probabilistic, Combinatorial, and Asymptotic Methods in the Analysis of Algorithms (AofA 2010). Vol. AM.CrossRefGoogle Scholar
Bender, E. A. and Bruce Richmond, L. (1983) Central and local limit theorems applied to asymptotic enumeration II: Multivariate generating functions. J. Comb. Theory, A 34(3) 255–265.CrossRefGoogle Scholar
Bodini, O., Roussel, O. and Soria, M. (2012) Boltzmann samplers for first-order differential specifications. Disc. App. Math. 160(18) 2563–2572.CrossRefGoogle Scholar
de Bruijn, N. G. (1972) Lambda calculus notation with nameless dummies, a tool for automatic formula manipulation, with application to the Church-Rosser theorem. Indagationes Mathematicae (Proceedings) 75(5) 381392.CrossRefGoogle Scholar
Claessen, K. and Hughes, J. (2000) QuickCheck: A lightweight tool for random testing of Haskell programs. In Proceedings of the Fifth ACM SIGPLAN International Conference on Functional Programming, pp. 268–279.CrossRefGoogle Scholar
Clarke, E., Grumberg, O., Jha, S., Lu, Y. and Veith, H. (2000) Counterexample-guided abstraction refinement. Computer Aided Verification (Emerson, E. A. and Sistla, A. P., eds), Springer Berlin Heidelberg, pp. 154–169. ISBN: 978-3-540-45047-4.Google Scholar
Chase, K. C., Mekjian, A. Z. and Zamick, L. (1999) ‘Canonical and microcanonical ensemble approaches to Bose-Einstein condensation: The thermodynamics of particles in harmonic traps. Euro. Phys. J. B-Conden. Matt. Comp. Syst. 8(2) 281–285.CrossRefGoogle Scholar
Chauve, C., Ponty, Y. and Wallner, M. (2020) Counting and sampling gene family evolutionary histories in the duplication-loss and duplication-loss-transfer models. J. Math. Biol., 1–36.Google Scholar
Domahidi, A., Chu, E. and Boyd, S. (2013) ECOS: An SOCP solver for embedded systems. In 2013 European Control Conference (ECC). IEEE, pp. 3071–3076.CrossRefGoogle Scholar
Drmota, M. (1997) Systems of functional equations. Rand. Struct. & Alg. 10(1–2) 103124.3.0.CO;2-Z>CrossRefGoogle Scholar
Denise, A., Roques, O. and Termier, M. (2000) Random generation of words of contextfree languages according to the frequencies of letters. In Mathematics and Computer Science. Springer, pp. 113–125.CrossRefGoogle Scholar
Duchon, P., Flajolet, P., Louchard, G. and Schaeffer, G. (2004) Boltzmann samplers for the random generation of combinatorial structures. Comb. Prob. Comput. 13(4–5) 577–625.CrossRefGoogle Scholar
Denise, A. and Zimmermann, P. (1999) Uniform random generation of decomposable structures using floating-point arithmetic. Theor. Comput. Sci. 218(2) 233–248.CrossRefGoogle Scholar
Flajolet, P., Fusy, é. and Pivoteau, C. (2007) Boltzmann sampling of unlabelled structures. In Proceedings of the Meeting on Analytic Algorithmics and Combinatorics, pp. 201–211.Google Scholar
Flajolet, P. and Sedgewick, R. (2009) Analytic Combinatorics. Cambridge University Press. ISBN: 978-0-521-89806-5.Google Scholar
Fusy, é. (2005) Quadratic exact size and linear approximate size random generation of planargraphs. Discr. Math. & Theor. Comp. Sci., 125–138.Google Scholar
Fichtner, M., Voigt, K. and Schuster, S. (2017) The tip and hidden part of the iceberg: Proteinogenic and non-proteinogenic aliphatic amino acids. Biochimica et Biophysica Acta (BBA)-Gen. Sub. 1861(1) 3258–3269.CrossRefGoogle Scholar
Flajolet, P., Zimmermann, P. and Van Cutsem, B. (1994) A calculus for the random generation of labelled combinatorial structures. Theor. Comput. Sci. 132(1) 1–35.Google Scholar
Grant, M., Boyd, S. and Ye, Y. (2006) Disciplined convex programming. InGlobal Optimization, pp. 155–210.CrossRefGoogle Scholar
Gittenberger, B. and GoŁebiewski, Z. (2016) On the number of lambda terms with prescribed size of their de Bruijn representation. In 33rd Symposium on Theoretical Aspects of Computer Science, STACS, pp. 40:1–40:13.Google Scholar
Hammer, S., Wang, W., Will, S. and Ponty, Y. (2019) Fixed-parameter tractable sampling for RNA design with multiple target structures. BMC Bioinform. 20(1) 209.Google Scholar
Haugset, T., Haugerud, H. and Andersen, J. O. (1997) Bose-Einstein condensation in anisotropic harmonic traps. Phys. Rev. A 55(4) 2922.Google Scholar
Jerrum, M. R., Valiant, L. G. and Vazirani, V. V. (1986) Random generation of combinatorial structures from a uniform distribution. Theor. Comput. Sci. 43 169–188.Google Scholar
Karmarkar, N. A new polynomial-time algorithm for linear programming. In Proceedings of the Sixteenth Annual ACM Symposium on Theory of Computing, pp. 302–311.Google Scholar
Kamada, T. and Kawai, S. (1989) An algorithm for drawing general undirected graphs. Inform. Process. Lett. 31(1) 7–15.CrossRefGoogle Scholar
Knuth, D. and Yao, A. (1976) Algorithms and Complexity: New Directions and Recent Results. Academic Press. Chap. The complexity of nonuniform random number generation.Google Scholar
Lairez, P. (2017) A deterministic algorithm to compute approximate roots of polynomial systems in polynomial average time. Found. Comput. Math. 17(5) 12651292.CrossRefGoogle Scholar
Landau, D. P. and Binder, K. (2014). A Guide to Monte Carlo Simulations in Statistical Physics. Cambridge University Press.Google Scholar
Lucietti, J. and Rangamani, M. (2008) Asymptotic counting of BPS operators in superconformal field theories. J. Math. Phys. 49(8) 082301.Google Scholar
Mullier, O., Chapoutot, A. and dit Sandretto, J. A. (2018) Validated computation of the local truncation error of Runge–Kutta methods with automatic differentiation. Optim. Methods Softw. 33(4–6) 718–728.CrossRefGoogle Scholar
Nemirovski, A. (2004) Interior Point Polynomial Time Methods in Convex Programming. Lecture Notes.Google Scholar
Nesterov, Y. (1998) Introductory lectures on convex programming volume I: Basic course. Lecture Notes 3(4) 5.Google Scholar
Nesterov, Y. and Nemirovskii, A. (1994) Interior-Point Polynomial Algorithms in Convex Programming. SIAM.CrossRefGoogle Scholar
Nijenhuis, A. and Wilf, H. S. (1978). Combinatorial Algorithms. 2nd ed. Academic Press.Google Scholar
O’Donoghue, B., Chu, E., Parikh, N. and Boyd, S. (2016) Conic optimization via operator splitting and homogeneous self-dual embedding. J. Opt. Th. & App. 169(3) 1042–1068.Google Scholar
Otter, R. (1948) The number of trees. Ann. Math., 583–599.CrossRefGoogle Scholar
PaŁka, M. H., Claessen, K., Russo, A. and Hughes, J. (2011) Testing an optimising compiler by generating random lambda terms. In Proceedings of the 6th International Workshop on Automation of Software Test, AST 2011. ACM, pp. 91–97. ISBN: 978-1-4503-0592-1.Google Scholar
Pałka, M. H. (2012) Random structured test data generation for black-box testing. PhD thesis. Chalmers University of Technology.Google Scholar
Paraskevopoulou, Z., Hrttcu, C., Dénès, M., Lampropoulos, L. and Pierce, B. C. (2015) Foundational property-based testing. In Interactive Theorem Proving, C. Urban and X. Zhang, eds. Springer International Publishing, pp. 325–343. ISBN: 978-3-319-22102-1.CrossRefGoogle Scholar
Penny, D. (1982) Testing the theory of evolution by comparing phylogenetic trees constructed from five different protein sequences. Nature 297 197200.CrossRefGoogle ScholarPubMed
Pivoteau, C., Salvy, B. and Soria, M. (2012) Algorithms for combinatorial structures: Well-founded systems and Newton iterations. J. Comb. Th. A 119(8) 1711–1773.CrossRefGoogle Scholar
Potra, F. A. and Wright, S. J. (2000) Interior-point methods. J. Comput. Appl. Math. 124(1–2) 281–302.CrossRefGoogle Scholar
Propp, J. G. and Wilson, D. B. (1996) Exact sampling with coupled Markov chains and applications to statistical mechanics. Random Struct. Algor. 9(1–2) 223–252.3.0.CO;2-O>CrossRefGoogle Scholar
Rémy, J.-L. (1985) Un procédé itératif de dénombrement d’arbres binaires et son application À leur génération aléatoire. ITA 19(2) 179195.Google Scholar
Runciman, C., Naylor, M. and Lindblad, F. (2008) Smallcheck and lazy smallcheck: Automatic exhaustive testing for small values. In Proceedings of the First ACM SIGPLAN Symposium on Haskell, Haskell ’08. ACM, pp. 37–48. ISBN: 978-1-60558-064-7.Google Scholar
Shen, X., Diamond, S., Gu, Y. and Boyd, S. (2016) Disciplined convex-concave programming. In 2016 IEEE 55th Conference on Decision and Control (CDC), pp. 1009–1014.CrossRefGoogle Scholar
Smale, S. (1998) Mathematical problems for the next century. Math. Intell. 20(2) 715.CrossRefGoogle Scholar
Vershik, A. M. (1996) Statistical mechanics of combinatorial partitions, and their limit shapes. Funct. Anal. Appl. 30(2) 90105.CrossRefGoogle Scholar
Welsh, D. and Gale, A. (2001) The complexity of counting problems. Asp. Compl. de Gruyter Ser. Log. Appl., pp. 115–154.Google Scholar
Zeng, Z. (2005) Computing multiple roots of inexact polynomials. Math. Comput. 74(250) 869903.CrossRefGoogle Scholar