Balanced parentheses strike back

  • Authors:
  • Hsueh-I Lu;Chia-Chi Yeh

  • Affiliations:
  • National Taiwan University, Taiwan, Republic of China;National Taiwan University, Taiwan, Republic of China

  • Venue:
  • ACM Transactions on Algorithms (TALG)
  • Year:
  • 2008

Quantified Score

Hi-index 0.00

Visualization

Abstract

An ordinal tree is an arbitrary rooted tree where the children of each node are ordered. Succinct representations for ordinal trees with efficient query support have been extensively studied. The best previously known result is due to Geary et al. [2004b, pages 1--10]. The number of bits required by their representation for an n-node ordinal tree T is 2n + o(n), whose first-order term is information-theoretically optimal. Their representation supports a large set of O(1)-time queries on T. Based upon a balanced string of 2n parentheses, we give an improved 2n + o(n)-bit representation for T. Our improvement is two-fold: First, the set of O(1)-time queries supported by our representation is a proper superset of that supported by the representation of Geary, Raman, and Raman. Second, it is also much easier for our representation to support new queries by simply adding new auxiliary strings.