Academic Journal
Quasi-linear-time algorithm for a longest common circular factor.
| Τίτλος: | Quasi-linear-time algorithm for a longest common circular factor. |
|---|---|
| Συγγραφείς: | Alzamel, Mai1 (AUTHOR) malzamel@ksu.edu.sa, Crochemore, Maxime2,3 (AUTHOR) maxime.crochemore@kcl.ac.uk, Iliopoulos, Costas S.1,2 (AUTHOR), Kociumaka, Tomasz4 (AUTHOR) tomasz.kociumaka@mpi-inf.mpg.de, Radoszewski, Jakub1,5 (AUTHOR) jrad@mimuw.edu.pl, Rytter, Wojciech5 (AUTHOR) rytter@mimuw.edu.pl, Straszyński, Juliusz5 (AUTHOR) j.straszynski@mimuw.edu.pl, Waleń, Tomasz5 (AUTHOR) walen@mimuw.edu.pl, Zuba, Wiktor5 (AUTHOR) w.zuba@mimuw.edu.pl |
| Πηγή: | Theoretical Computer Science. Jun2026, Vol. 1075, pN.PAG-N.PAG. 1p. |
| Θεματικοί όροι: | *Algorithms, *Time complexity, *Computational complexity |
| Περίληψη: | • We introduce a string similarity measure called longest common circular factor (LCCF). • It is a variant of the longest common factor where we allow rotating the factor. • The LCCF of two strings of length n can be computed in near-linear time. • The space complexity of the algorithm is linear. We consider the Longest Common Circular Factor (LCCF) problem in which, given strings S and T of length at most n , we are to compute the longest factor of S whose cyclic shift is a factor of T. This new similarity measure is an extension of the classic Longest Common Factor. We show an algorithm solving the LCCF problem in O (n log 3 n log (r + 2)) time, where r ≤ n is the length of the output, using O (n) space. A naive algorithm works in Ω(n 2) time, and no O (n polylog n) -time solution was known prior to our work. Our result constitutes yet another application of string synchronizing sets of Kempa and Kociumaka (STOC 2019). Compared to the preliminary version published at CPM 2019, we significantly simplified the algorithm and improved the space complexity from O (n log 2 n) to O (n). We achieved that with new algorithmic insights into a certain geometric intersection problem, solved by suitably decomposing intervals. [ABSTRACT FROM AUTHOR] |
| Βάση Δεδομένων: | Academic Search Index |
καταχωρήστε σχόλιο πρώτοι!