Abstract

We consider a generalization of the Dyck language. We have a set of opening and a set of closing brackets and a relation that gives the pairs of brackets that can be used in the generalized Dyck language. This Dyck language is a handy coding for several classes of labeled trees.We present an algorithm that generates all words of length 2n of the generalized Dyck language lexicographically. Thereby, each word is computed from its predecessor according to the lexicographical order without any knowledge about the words generated before. Additionally, we introduce a condition on the relation for the generalized Dyck language to be simply generated, which means that an algorithm needs to read only the suffix to be changed in order to compute the successor of a word according to the lexicographical order. We present an algorithm that checks whether a Dyck language is simply generated or not.For an arbitrary relation, we compute the sth moments of the random variable describing the length of the suffix to be cha...

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.