Abstract
Following (Kolpakov et al., 2013; Gawrychowski and Manea, 2015), we continue the study of \(\alpha \) -gapped repeats in strings, defined as factors uvu with \(|uv|\le \alpha |u|\). Our main result is the \(O(\alpha n)\) bound on the number of maximal \(\alpha \)-gapped repeats in a string of length n, previously proved to be \(O(\alpha ^2 n)\) in (Kolpakov et al., 2013). For a closely related notion of maximal \(\delta \)-subrepetition (maximal factors of exponent between \(1+\delta \) and 2), our result implies the \(O(n/\delta )\) bound on their number, which improves the bound of (Kolpakov et al., 2010) by a \(\log n\) factor.
We also prove an algorithmic time bound \(O(\alpha n+S)\) (S size of the output) for computing all maximal \(\alpha \)-gapped repeats. Our solution, inspired by (Gawrychowski and Manea, 2015), is different from the recently published proof by (Tanimura et al., 2015) of the same bound. Together with our bound on S, this implies an \(O(\alpha n)\)-time algorithm for computing all maximal \(\alpha \)-gapped repeats.
Keywords
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
R. Kolpakov—The author was partially supported by Russian Foundation for Fundamental Research (Grant 15-07-03102).
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
Note that in [15], the number of maximal \(\alpha \)-gapped palindromes was conjectured to be \(O(\alpha ^2 n)\).
References
Badkobeh, G., Crochemore, M., Toopsuwan, C.: Computing the maximal-exponent repeats of an overlap-free string in linear time. In: Calderón-Benavides, L., González-Caro, C., Chávez, E., Ziviani, N. (eds.) SPIRE 2012. LNCS, vol. 7608, pp. 61–72. Springer, Heidelberg (2012)
Bannai, H., Tomohiro, I., Inenaga, S., Nakashima, Y., Takeda, M., Tsuruta, K.: A new characterization of maximal repetitions by Lyndon trees, intermediate version presented to SODA’2015 (2014). CoRR abs/1406.0263
Breslauer, D.: Efficient string algorithmics. Ph.D. thesis, Columbia University (1992)
Brodal, G.S., Lyngs, R.B., Pedersen, C.N.S., Stoye, J.: Finding maximal pairs withbounded gap. J. Discrete Algorithms 1(1), 77–104 (2000)
Crochemore, M.: An optimal algorithm for computing the repetitions in a word. Inf. Process. Lett. 12(5), 244–250 (1981)
Crochemore, M., Ilie, L., Tinta, L.: Towards a solution to the “Runs” conjecture. In: Ferragina, P., Landau, G.M. (eds.) CPM 2008. LNCS, vol. 5029, pp. 290–302. Springer, Heidelberg (2008)
Crochemore, M., Iliopoulos, C., Kubica, M., Radoszewski, J., Rytter, W., Waleń, T.: Extracting powers and periods in a string from its runs structure. In: Chavez, E., Lonardi, S. (eds.) SPIRE 2010. LNCS, vol. 6393, pp. 258–269. Springer, Heidelberg (2010)
Crochemore, M., Kolpakov, R., Kucherov, G.: Optimal searching of gapped repeats in a word (2015). CoRR abs/1509.01221
Crochemore, M., Kubica, M., Radoszewski, J., Rytter, W., Walen, T.: On the maximal sum of exponents of runs in a string. J. Discrete Algorithms 14, 29–36 (2012)
Crochemore, M., Rytter, W.: Sqares, cubes, and time-space efficient string searching. Algorithmica 13(5), 405–425 (1995)
Dumitran, M., Manea, F.: Longest gapped repeats and palindromes. In: Italiano, G.F., Pighizzini, G., Sannella, D.T. (eds.) MFCS 2015. LNCS, vol. 9234, pp. 205–217. Springer, Heidelberg (2015)
Fischer, J., Holub, S., Tomohiro, I., Lewenstein, M.: Beyond the runs theorem. CoRR abs/1502.04644 (2015)
Galil, Z., Seiferas, J.I.: Time-space-optimal string matching. J. Comput. Syst. Sci. 26(3), 280–294 (1983)
Gawrychowski, P.I.T., Inenaga, S., Köppl, D., Manea, F.: Efficiently finding all maximal \(\alpha \)-gapped repeats. CoRR abs/1509.09237 (2015)
Gawrychowski, P., Manea, F.: Longest \(\alpha \)-gapped repeat and palindrome. In: Kosowski, A., Walukiewicz, I. (eds.) FCT 2015. LNCS, vol. 9210, pp. 27–40. Springer, Heidelberg (2015)
Gusfield, D.: Algorithms on Strings, Trees, and Sequences - Computer Science and Computational Biology. Cambridge University Press, New York (1997)
Kolpakov, R.: On primary and secondary repetitions in words. Theor. Comput. Sci. 418, 71–81 (2012)
Kolpakov, R., Kucherov, G.: On maximal repetitions in words. J. Discrete Algorithms 1(1), 159–186 (2000)
Kolpakov, R., Kucherov, G.: Searching for gapped palindromes. Theor. Comput. Sci. 410(51), 5365–5373 (2009)
Kolpakov, R., Kucherov, G., Ochem, P.: On maximal repetitions of arbitrary exponent. Inf. Process. Lett. 110(7), 252–256 (2010)
Kolpakov, R., Podolskiy, M., Posypkin, M., Khrapov, N.: Searching of gapped repeats and subrepetitions in a word. In: Kulikov, A.S., Kuznetsov, S.O., Pevzner, P. (eds.) CPM 2014. LNCS, vol. 8486, pp. 212–221. Springer, Heidelberg (2014)
Kolpakov, R.M., Kucherov, G.: Finding repeats with fixed gap. In: SPIRE, pp. 162–168 (2000)
Kosolobov, D.: Lempel-Ziv factorization may be harder than computing all runs. In: Mayr, E.W., Ollinger, N. (eds.) 32nd International Symposium on Theoretical Aspects of Computer Science, STACS 4–7, 2015, Garching, Germany. LIPIcs, vol. 30, pp. 582–593. Schloss Dagstuhl - Leibniz-Zentrum fuer Informatik, March 2015
Lothaire, M.: Combinatorics on Words. Addison Wesley, Reading (1983)
Main, M., Lorentz, R.: An \(O(n \log n)\) algorithm for finding all repetitions in a string. J. Algorithms 5(3), 422–432 (1984)
Storer, J.A.: Data Compression: Methods and Theory. Computer Science Press, Rockville (1988)
Tanimura, Y., Fujishige, Y., I, T., Inenaga, S., Bannai, H., Takeda, M.: A faster algorithm for computing maximal \(\alpha \)-gapped repeats in a string. In: Iliopoulos, C., Puglisi, S., Yilmaz, E. (eds.) SPIRE 2015. LNCS, vol. 9309, pp. 124–136. Springer, Heidelberg (2015)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2016 Springer International Publishing Switzerland
About this paper
Cite this paper
Crochemore, M., Kolpakov, R., Kucherov, G. (2016). Optimal Bounds for Computing \(\alpha \)-gapped Repeats. In: Dediu, AH., Janoušek, J., Martín-Vide, C., Truthe, B. (eds) Language and Automata Theory and Applications. LATA 2016. Lecture Notes in Computer Science(), vol 9618. Springer, Cham. https://doi.org/10.1007/978-3-319-30000-9_19
Download citation
DOI: https://doi.org/10.1007/978-3-319-30000-9_19
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-29999-0
Online ISBN: 978-3-319-30000-9
eBook Packages: Computer ScienceComputer Science (R0)