Abstract

The shuffle of two words u and v of A⁎ is the language u⧢v consisting of all words u1v1u2v2…ukvk, where k≥0 and the ui and vi are words of A⁎ such that u=u1u2…uk and v=v1v2…vk. In other words, u⧢v is the finite set of all words obtainable from merging the words u and v from left to right, but choosing the next symbol arbitrarily from u or v. A word u∈A⁎ is a square for the shuffle product if it is the shuffle of two identical words (i.e., u∈v⧢v for some v∈A⁎).Whereas it can be decided in polynomial-time whether or not u∈v1⧢v2 for given words u, v1 and v2 (J.-C. Spehner, 1986 [19]), we show in this paper that it is NP-complete to determine whether or not a word u is a square for the shuffle product. The novelty in our approach lies in representing words as linear graphs, in which deciding whether or not a given word is a square for the shuffle product reduces to computing some inclusion-free perfect matching. Finally, we prove that it is NP-complete to determine whether or not an input word is in the shuffle of a word with its reverse.

Full Text
Paper version not known

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.