Internal Quasiperiod Queries

Internal pattern matching requires one to answer queries about factors of a given string. Many results are known on answering internal period queries, asking for the periods of a given factor. In this paper we investigate (for the first time) internal queries asking for covers (also known as quasiperiods) of a given factor. We propose a data structure that answers such queries in $O(\log n \log \log n)$ time for the shortest cover and in $O(\log n (\log \log n)^2)$ time for a representation of all the covers, after $O(n \log n)$ time and space preprocessing.

[1]  Costas S. Iliopoulos,et al.  Optimal Superprimitivity Testing for Strings , 1991, Inf. Process. Lett..

[2]  Wojciech Rytter,et al.  Extracting Powers and Periods in a String from Its Runs Structure , 2010, SPIRE.

[3]  Gad M. Landau,et al.  Dynamic text and static pattern matching , 2007, TALG.

[4]  Wojciech Rytter,et al.  Efficient Data Structures for the Factor Periodicity Problem , 2012, SPIRE.

[5]  Kazuya Tsuruta,et al.  The "Runs" Theorem , 2014, SIAM J. Comput..

[6]  Gregory Kucherov,et al.  Finding maximal repetitions in a word in linear time , 1999, 40th Annual Symposium on Foundations of Computer Science (Cat. No.99CB37039).

[7]  Costas S. Iliopoulos,et al.  The subtree max gap problem with application to parallel string covering , 1994, SODA '94.

[8]  Michael A. Bender,et al.  The LCA Problem Revisited , 2000, LATIN.

[9]  Costas S. Iliopoulos,et al.  Covering a String , 1993, CPM.

[10]  Wojciech Rytter,et al.  Extracting powers and periods in a word from its runs structure , 2014, Theor. Comput. Sci..

[11]  Wojciech Rytter,et al.  The Maximum Number of Squares in a Tree , 2012, CPM.

[12]  Dany Breslauer,et al.  An On-Line String Superprimitivity Test , 1992, Inf. Process. Lett..

[13]  Yin Li,et al.  Computing the Cover Array in Linear Time , 2001, Algorithmica.

[14]  Jakub Radoszewski,et al.  Experimental Evaluation of Algorithms for Computing Quasiperiods , 2019, Theor. Comput. Sci..

[15]  Milan Ruzic,et al.  Constructing Efficient Dictionaries in Close to Sorting Time , 2008, ICALP.

[16]  Wojciech Rytter,et al.  Shortest Covers of All Cyclic Shifts of a String , 2020, WALCOM.

[17]  William F. Smyth,et al.  An Optimal Algorithm to Compute all the Covers of a String , 1994, Inf. Process. Lett..

[18]  Tomasz Kociumaka Efficient data structures for internal queries in texts , 2019 .

[19]  Wojciech Rytter,et al.  Efficient Representation and Counting of Antipower Factors in Words , 2018, LATA.

[20]  Jakub Radoszewski,et al.  Quasi-Periodicity in Streams , 2019, CPM.

[21]  Wojciech Rytter,et al.  A Linear-Time Algorithm for Seeds Computation , 2011, SODA.

[22]  Dany Breslauer,et al.  Testing String Superprimitivity in Parallel , 1994, Inf. Process. Lett..

[23]  Wojciech Rytter,et al.  Internal Pattern Matching Queries in a Text and Applications , 2013, SODA.

[24]  Peter Sanders,et al.  Linear work suffix array construction , 2006, JACM.

[25]  William F. Smyth,et al.  A Correction to "An Optimal Algorithm to Compute all the Covers of a String" , 1995, Inf. Process. Lett..