Holonomic equations and efficient random generation of binary trees - Archive ouverte HAL Accéder directement au contenu
Article Dans Une Revue Discrete Mathematics and Theoretical Computer Science Année : 2023

Holonomic equations and efficient random generation of binary trees

Résumé

Holonomic equations are recursive equations which allow computing efficiently numbers of combinatoric objects. Rémy showed that the holonomic equation associated with binary trees yields an efficient linear random generator of binary trees. I extend this paradigm to Motzkin trees and Schröder trees and show that despite slight differences my algorithm that generates random Schröder trees has linear expected complexity and my algorithm that generates Motzkin trees is in O(n) expected complexity, only if we can implement a specific oracle with a O(1) complexity. For Motzkin trees, I propose a solution which works well for realistic values (up to size ten millions) and yields an efficient algorithm.
Fichier principal
Vignette du fichier
Hol_Lin_Gen.pdf (500.15 Ko) Télécharger le fichier
Origine : Fichiers produits par l'(les) auteur(s)

Dates et versions

hal-03674690 , version 1 (20-05-2022)
hal-03674690 , version 2 (16-11-2022)
hal-03674690 , version 3 (08-01-2023)
hal-03674690 , version 4 (09-02-2023)
hal-03674690 , version 5 (03-07-2023)
hal-03674690 , version 6 (22-01-2024)

Identifiants

Citer

Pierre Lescanne. Holonomic equations and efficient random generation of binary trees. Discrete Mathematics and Theoretical Computer Science, 2023, vol. 25:2. ⟨hal-03674690v6⟩
71 Consultations
124 Téléchargements

Altmetric

Partager

Gmail Facebook X LinkedIn More