We refer to positive lattice paths as to paths in the discrete plane constituted by different kinds of steps (north-east, east and south-east), starting from the origin and never going under the x-axis. They have been deeply studied both from a combinatorial and an algorithmic point of view. We propose some algorithms for the exhaustive generation of positive paths which are Motzkin and Schröder paths and their prefixes, according to their length. For each kind of paths we define a recursive algorithm as well as an iterative one, specifying which path follows a given one in the lexicographic order. Furthermore we study the complexity of these algorithms by using the relations between the number of paths of a given size and the number of final north-east or south-east steps.
Exhaustive generation of some lattice paths and their prefixes / Barcucci, Elena; Bernini, Antonio; Pinzani, Renzo. - In: THEORETICAL COMPUTER SCIENCE. - ISSN 0304-3975. - STAMPA. - 878-879:(2021), pp. 47-52. [10.1016/j.tcs.2020.12.013]
Exhaustive generation of some lattice paths and their prefixes
Barcucci, Elena;Bernini, Antonio;Pinzani, Renzo
2021
Abstract
We refer to positive lattice paths as to paths in the discrete plane constituted by different kinds of steps (north-east, east and south-east), starting from the origin and never going under the x-axis. They have been deeply studied both from a combinatorial and an algorithmic point of view. We propose some algorithms for the exhaustive generation of positive paths which are Motzkin and Schröder paths and their prefixes, according to their length. For each kind of paths we define a recursive algorithm as well as an iterative one, specifying which path follows a given one in the lexicographic order. Furthermore we study the complexity of these algorithms by using the relations between the number of paths of a given size and the number of final north-east or south-east steps.File | Dimensione | Formato | |
---|---|---|---|
1-s2.0-S0304397520307180-main.pdf
Accesso chiuso
Tipologia:
Pdf editoriale (Version of record)
Licenza:
Tutti i diritti riservati
Dimensione
247.04 kB
Formato
Adobe PDF
|
247.04 kB | Adobe PDF | Richiedi una copia |
TCS_BBPrev.pdf
accesso aperto
Tipologia:
Versione finale referata (Postprint, Accepted manuscript)
Licenza:
Open Access
Dimensione
206.57 kB
Formato
Adobe PDF
|
206.57 kB | Adobe PDF |
I documenti in FLORE sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.