Computing palindromes on a trie in linear time
Takuya Mieno, Mitsuru Funakoshi, and Shunsuke Inenaga

TL;DR
This paper presents an efficient linear-time algorithm for computing all distinct and maximal palindromes in a trie, significantly improving previous methods and enabling fast palindrome queries in trie-structured data.
Contribution
The authors develop a novel linear-time algorithm for palindrome computation on tries, surpassing prior $O(n \\log h)$ solutions, and introduce a space-efficient data structure for rapid palindrome reporting.
Findings
All distinct and maximal palindromes can be computed in $O(n)$ time.
The new algorithms improve over previous $O(n \\log h)$-time methods.
The data structure allows output-optimal palindrome reporting in trie-based queries.
Abstract
A trie is a rooted tree such that each edge is labeled by a single character from the alphabet, and the labels of out-going edges from the same node are mutually distinct. Given a trie with edges, we show how to compute all distinct palindromes and all maximal palindromes on in time, in the case of integer alphabets of size polynomial in . This improves the state-of-the-art -time algorithms by Funakoshi et al. [PCS 2019], where is the height of . Using our new algorithms, the eertree with suffix links for a given trie can readily be obtained in time. Further, our trie-based -space data structure allows us to report all distinct palindromes and maximal palindromes in a query string represented in the trie , in output optimal time. This is an improvement over an…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsAlgorithms and Data Compression · Network Packet Processing and Optimization · DNA and Biological Computing
