Abstract
A run (or a maximal repetition) in a string is an inclusion-maximal periodic segment in a string. Let ρ(n) be the maximal number of runs in a string of length n. It has been shown in [8] that ρ(n)=O(n), the proof was very complicated and the constant coefficient in O(n) has not been given explicitly. We propose a new approach to the analysis of runs based on the properties of subperiods: the periods of periodic parts of the runs. We show that ρ(n) ≤ 5 n. Our proof is inspired by the results of [4], where the role of new periodicity lemmas has been emphasized.
Research supported by the grants 4T11C04425 and CCR-0313219.
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Crochemore, M.: An optimal algorithm for computing the repetitions in a word. Inf. Proc. Letters 42(5), 244–250 (1981)
Franek, F., Simpson, R.J., Smyth, W.F.: The maximum number of runs in a string. In: Miller, M., Park, K. (eds.) Proc. 14-th Australian Workshop on Combinatorial Algorithms, pp. 26–35 (2003)
Crochemore, M., Rytter, W.: Jewels of stringology: text algorithms. World Scientific, Singapore (2003)
Fan, K., Smyth, W.F., Simpson, R.J.: A New Periodicity Lemma. In: Apostolico, A., Crochemore, M., Park, K. (eds.) CPM 2005. LNCS, vol. 3537, pp. 257–265. Springer, Heidelberg (2005)
Franek, F., Karaman, A., Smyth, W.F.: Repetitions in Sturmian strings. TCS 249-2, 289–303 (2000)
Iliopoulos, C., Moore, D., Smyth, W.F.: A characterization of the squares in a Fibonacci string. TCS 172, 281–291 (1997)
Kolpakov, R., Kucherov, G.: On maximal repetitions in words. Journal of Discr. Algorithms 1, 159–186 (2000)
Kolpakov, R., Kucherov, G.: Finding maximal repetitions in a word in linear time, FOCS, pp. 596–604 (1999)
Lothaire,: Algebraic combinatorics on words. Cambridge University Press, Cambridge
Main, M.G., Lorentz, R.J.: An O(nlogn) algorithm for finding all repetitions in a string. Journal of Algorithms 5, 422–432 (1984)
Rytter, W.: The structure of subword graphs and suffix trees of Fibonacci words. In: Colloquium on Implementation and Application of Automata, CIAA (2005)
Smyth, W.F.: Computing patterns in strings. Addison-Wesley, Reading (2003)
Smyth, W.F.: Repetitive perhaps, but certainly not boring. TCS 249-2, 343–355 (2000)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2006 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Rytter, W. (2006). The Number of Runs in a String: Improved Analysis of the Linear Upper Bound. In: Durand, B., Thomas, W. (eds) STACS 2006. STACS 2006. Lecture Notes in Computer Science, vol 3884. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11672142_14
Download citation
DOI: https://doi.org/10.1007/11672142_14
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-32301-3
Online ISBN: 978-3-540-32288-7
eBook Packages: Computer ScienceComputer Science (R0)