• DocumentCode
    545355
  • Title

    Ranking and unranking of well-formed parenthesis strings in diverse representations

  • Author

    Wu, Ro Yu ; Chang, Jou Ming

  • Author_Institution
    Dept. of Ind. Manage., Lunghwa Univ. of Sci. & Technol., Taoyuan, Taiwan
  • Volume
    1
  • fYear
    2011
  • fDate
    11-13 March 2011
  • Firstpage
    71
  • Lastpage
    75
  • Abstract
    Well-formed parenthesis (w.f.p.) strings can be represented by different types of integer sequences including P-sequences, X-sequences, and T-sequences. In this paper, we introduce a new class of sequences called L-sequences which comes from the so-called RD-sequences for representing k-ary trees. We then search out the relationships among these representations and deal with the problems of ranking and unranking of w.f.p. strings in lexicographic order under these diverse representations. A result shows that the ranking and unranking of w.f.p. strings can be done in O(n) time for all such representations, where n is the number of pairs of balanced parentheses.
  • Keywords
    computational complexity; sequences; tree data structures; L-sequence; RD-sequence; diverse representation; integer sequence; k-ary trees; well-formed parenthesis string ranking; well-formed parenthesis string unranking; Algorithm design and analysis; Binary trees; Computers; Encoding; Information processing; Reflective binary codes; Tin; lexicographic order; ranking algorithms; unranking algorithms; well-formed parenthesis strings;
  • fLanguage
    English
  • Publisher
    ieee
  • Conference_Titel
    Computer Research and Development (ICCRD), 2011 3rd International Conference on
  • Conference_Location
    Shanghai
  • Print_ISBN
    978-1-61284-839-6
  • Type

    conf

  • DOI
    10.1109/ICCRD.2011.5763976
  • Filename
    5763976