8 research outputs found

    EERTREE: An Efficient Data Structure for Processing Palindromes in Strings

    Full text link
    We propose a new linear-size data structure which provides a fast access to all palindromic substrings of a string or a set of strings. This structure inherits some ideas from the construction of both the suffix trie and suffix tree. Using this structure, we present simple and efficient solutions for a number of problems involving palindromes.Comment: 21 pages, 2 figures. Accepted to IWOCA 201

    The Number of Distinct Subpalindromes in Random Words

    Full text link
    We prove that a random word of length n over a k-Ary fixed alphabet contains, on expectation, Θ(√n) distinct palindromic factors. We study this number of factors, E(n, k), in detail, showing that the limit limn→∞(n,k)/√n does not exist for any k ≥ 2, liminfn→∞(n,k)/ √n=Θ(1), and limsupn→∞(n,k)/ √n=Θ(k). Such a complicated behaviour stems from the asymmetry between the palindromes of even and odd length. We show that a similar, but much simpler, result on the expected number of squares in random words holds. We also provide some experimental data on the number of palindromic factors in random words

    EERTREE: An efficient data structure for processing palindromes in strings

    Full text link
    We propose a new linear-size data structure which provides a fast access to all palindromic substrings of a string or a set of strings. This structure inherits some ideas from the construction of both the suffix trie and suffix tree. Using this structure, we present simple and efficient solutions for a number of problems involving palindromes. © 2017 Elsevier Lt

    Palk is linear recognizable online

    Full text link
    Given a language L that is online recognizable in linear time and space, we construct a linear time and space online recognition algorithm for the language L・Pal, where Pal is the language of all nonempty palindromes. Hence for every fixed positive k, Palk is online recognizable in linear time and space. Thus we solve an open problem posed by Galil and Seiferas in 1978. © Springer-Verlag Berlin Heidelberg 2015

    Palindromic k-Factorization in Pure Linear Time

    Get PDF
    Given a string s of length n over a general alphabet and an integer k, the problem is to decide whether s is a concatenation of k nonempty palindromes. Two previously known solutions for this problem work in time O(kn) and O(nlog n) respectively. Here we settle the complexity of this problem in the word-RAM model, presenting an O(n)-time online deciding algorithm. The algorithm simultaneously finds the minimum odd number of factors and the minimum even number of factors in a factorization of a string into nonempty palindromes. We also demonstrate how to get an explicit factorization of s into k palindromes with an O(n)-time offline postprocessing

    28th Annual Symposium on Combinatorial Pattern Matching : CPM 2017, July 4-6, 2017, Warsaw, Poland

    Get PDF
    Peer reviewe
    corecore