TY - JOUR
T1 - Efficiently computing runs on a trie
AU - Sugahara, Ryo
AU - Nakashima, Yuto
AU - Inenaga, Shunsuke
AU - Bannai, Hideo
AU - Takeda, Masayuki
N1 - Funding Information:
This work was supported by JSPS KAKENHI Grant Numbers JP18K18002 (YN), JP17H01697 (SI), JP20H04141 (HB), JP18H04098 (MT), JST ACT-X Grant Number JPMJAX200K (YN), and JST PRESTO Grant Number JPMJPR1922 (SI).
Publisher Copyright:
© 2021 The Authors
PY - 2021/10/2
Y1 - 2021/10/2
N2 - A maximal repetition, or run, in a string, is a maximal periodic substring whose smallest period is at most half the length of the substring. In this paper, we consider runs that correspond to a path on a trie, or in other words, on a rooted edge-labeled tree where each edge is labeled with a single symbol, and the endpoints of the path must be a descendant/ancestor of the other. For a trie with n edges, we show that the number of runs is less than n. We also show an asymptotic lower bound on the maximum density of runs in tries: limn→∞ρT(n)/n>0.9932348 where ρT(n) is the maximum number of runs in a trie with n edges. Furthermore, we also show an O(nloglogn) time and O(n) space algorithm for finding all runs.
AB - A maximal repetition, or run, in a string, is a maximal periodic substring whose smallest period is at most half the length of the substring. In this paper, we consider runs that correspond to a path on a trie, or in other words, on a rooted edge-labeled tree where each edge is labeled with a single symbol, and the endpoints of the path must be a descendant/ancestor of the other. For a trie with n edges, we show that the number of runs is less than n. We also show an asymptotic lower bound on the maximum density of runs in tries: limn→∞ρT(n)/n>0.9932348 where ρT(n) is the maximum number of runs in a trie with n edges. Furthermore, we also show an O(nloglogn) time and O(n) space algorithm for finding all runs.
UR - http://www.scopus.com/inward/record.url?scp=85111058949&partnerID=8YFLogxK
UR - http://www.scopus.com/inward/citedby.url?scp=85111058949&partnerID=8YFLogxK
U2 - 10.1016/j.tcs.2021.07.011
DO - 10.1016/j.tcs.2021.07.011
M3 - Article
AN - SCOPUS:85111058949
VL - 887
SP - 143
EP - 151
JO - Theoretical Computer Science
JF - Theoretical Computer Science
SN - 0304-3975
ER -