Succinct Ordinal Trees Based on Tree Covering Meng He, J. Ian Munro, University of Waterloo S. Srinivasa Rao, IT University of Copenhagen.

Slides:



Advertisements
Similar presentations
Alyce Brady CS 470: Data Structures CS 510: Computer Algorithms Post-order Traversal: Left Child - Right Child - Root Depth-First Search.
Advertisements

1 Succinct Representation of Labeled Graphs Jérémy Barbay, Luca Castelli Aleardi, Meng He, J. Ian Munro.
I/O and Space-Efficient Path Traversal in Planar Graphs Craig Dillabaugh, Carleton University Meng He, University of Waterloo Anil Maheshwari, Carleton.
Succinct Representations of Dynamic Strings Meng He and J. Ian Munro University of Waterloo.
Succinct Data Structures for Permutations, Functions and Suffix Arrays
Evaluating “find a path” reachability queries P. Bouros 1, T. Dalamagas 2, S.Skiadopoulos 3, T. Sellis 1,2 1 National Technical University of Athens 2.
Efficient Keyword Search for Smallest LCAs in XML Database Yu Xu Department of Computer Science & Engineering University of California, San Diego Yannis.
S. Sudarshan Based partly on material from Fawzi Emad & Chau-Wen Tseng
Tree Data Structures &Binary Search Tree 1. Trees Data Structures Tree  Nodes  Each node can have 0 or more children  A node can have at most one parent.
5th July 2004CPM A Simple Optimal Representation for Balanced Parentheses Richard Geary, Naila Rahman, Rajeev Raman (University of Leicester, UK)
Succinct Representation of Balanced Parentheses, Static Trees and Planar Graphs J. Ian Munro & Venkatesh Raman.
An Improved Succinct Dynamic k-Ary Tree Representation (work in progress) Diego Arroyuelo Department of Computer Science, Universidad de Chile.
Data Structures: A Pseudocode Approach with C 1 Chapter 6 Objectives Upon completion you will be able to: Understand and use basic tree terminology and.
Succinct Indexes for Strings, Binary Relations and Multi-labeled Trees Jérémy Barbay, Meng He, J. Ian Munro, University of Waterloo S. Srinivasa Rao, IT.
A Categorization Theorem on Suffix Arrays with Applications to Space Efficient Text Indexes Meng He, J. Ian Munro, and S. Srinivasa Rao University of Waterloo.
Succinct Data Structures Ian Munro University of Waterloo Joint work with David Benoit, Andrej Brodnik, D, Clark, F. Fich, M. He, J. Horton, A. López-Ortiz,
Succinct Representations of Trees S. Srinivasa Rao Seoul National University.
CS 171: Introduction to Computer Science II
Chapter 12 Trees. Copyright © 2005 Pearson Addison-Wesley. All rights reserved Chapter Objectives Define trees as data structures Define the terms.
Compact Representations of Separable Graphs From a paper of the same title submitted to SODA by: Dan Blandford and Guy Blelloch and Ian Kash.
Mike 66 Sept Succinct Data Structures: Techniques and Lower Bounds Ian Munro University of Waterloo Joint work with/ work of Arash Farzan, Alex Golynski,
Data Structures Arrays both single and multiple dimensions Stacks Queues Trees Linked Lists.
Types of Binary Trees Introduction. Types of Binary Trees There are several types of binary trees possible each with its own properties. Few important.
Succinct Representations of Trees
Space Efficient Data Structures for Dynamic Orthogonal Range Counting Meng He and J. Ian Munro University of Waterloo.
Introduction n – length of text, m – length of search pattern string Generally suffix tree construction takes O(n) time, O(n) space and searching takes.
Summer School '131 Succinct Data Structures Ian Munro.
Succinct Geometric Indexes Supporting Point Location Queries Prosenjit Bose, Eric Y. Chen, Meng He, Anil Maheshwari, Pat Morin.
Succinct Orthogonal Range Search Structures on a Grid with Applications to Text Indexing Prosenjit Bose, Carleton University Meng He, Unversity of Waterloo.
Tree Data Structures.
Succinct Data Structures Ian Munro University of Waterloo Joint work with David Benoit, Andrej Brodnik, D, Clark, F. Fich, M. He, J. Horton, A. López-Ortiz,
Compiled by: Dr. Mohammad Omar Alhawarat
Succinct Dynamic Cardinal Trees with Constant Time Operations for Small Alphabet Pooya Davoodi Aarhus University May 24, 2011 S. Srinivasa Rao Seoul National.
Compressed Prefix Sums O’Neil Delpratt Naila Rahman Rajeev Raman.
ECE 250 Algorithms and Data Structures Douglas Wilhelm Harder, M.Math. LEL Department of Electrical and Computer Engineering University of Waterloo Waterloo,
Rooted Tree a b d ef i j g h c k root parent node (self) child descendent leaf (no children) e, i, k, g, h are leaves internal node (not a leaf) sibling.
(2,4) Trees1 What are they? –They are search Trees (but not binary search trees) –They are also known as 2-4, trees.
Computer Sciences Department1.  Property 1: each node can have up to two successor nodes (children)  The predecessor node of a node is called its.
Graph Data Management Lab, School of Computer Science Branch Code: A Labeling Scheme for Efficient Query Answering on Tree
1Computer Sciences. 2 HEAP SORT TUTORIAL 4 Objective O(n lg n) worst case like merge sort. Sorts in place like insertion sort. A heap can be stored as.
Foundation of Computing Systems Lecture 4 Trees: Part I.
B-Trees Katherine Gurdziel 252a-ba. Outline What are b-trees? How does the algorithm work? –Insertion –Deletion Complexity What are b-trees used for?
ECE 250 Algorithms and Data Structures Douglas Wilhelm Harder, M.Math. LEL Department of Electrical and Computer Engineering University of Waterloo Waterloo,
Succinct Data Structures
Mehdi Kargar Department of Computer Science and Engineering
Lecture 1 (UNIT -4) TREE SUNIL KUMAR CIT-UPES.
Succinct Data Structures
Succinct Data Structures
Succinct Data Structures
Succinct Data Structures
S. Sudarshan Based partly on material from Fawzi Emad & Chau-Wen Tseng
Reducing the Space Requirement of LZ-index
Data Structures Review Session 2
Trees Another Abstract Data Type (ADT)
Tree.
Binary Trees "A tree may grow a thousand feet tall, but its leaves will return to its roots." -Chinese Proverb.
Lecture 18. Basics and types of Trees
Data Structures and Database Applications Binary Trees in C#
Find in a linked list? first last 7  4  3  8 NULL
Trees Another Abstract Data Type (ADT)
Week nine-ten: Trees Trees.
Discrete Methods in Mathematical Informatics
Trees Another Abstract Data Type (ADT)
Paolo Ferragina Dipartimento di Informatica, Università di Pisa
Succinct Representation of Labeled Graphs
Binary Tree Properties & Representation
Paolo Ferragina Dipartimento di Informatica, Università di Pisa
Succinct Data Structures
Trees.
Tree (new ADT) Terminology: A tree is a collection of elements (nodes)
Presentation transcript:

Succinct Ordinal Trees Based on Tree Covering Meng He, J. Ian Munro, University of Waterloo S. Srinivasa Rao, IT University of Copenhagen

Background: Succinct Data Structures The problem Modern applications often process huge amounts of data Examples Web search engines: Google, Altavista, etc. Bioinformatics application XML databases Spatial databases …

The Solution: Succinct Data Structures What are succinct data structures Representing data structures using preferably information-theoretic minimum space Supporting efficient navigational operations History of Succinct Data Structures Jacobson 1989

The number of different ordinal trees of n nodes: ( )/(n+1) ≈ 4 n /( π n) 3/2 Information-theoretic minimum: 2n- O(lg n) bits Explicit, pointer-based representation: Θ(n lg n) bits Trees 2n n

Succinct Ordinal Trees Level order unary degree sequence (LOUDS): Jacobson 1989 Balanced parentheses (BP): Munro & Raman 1997 Depth first unary degree sequence (DFUDS): Benoit et al Tree covering (TC): Geary et al. 2004

3 Preorder and DFUDS order

Navigational Operations Considered Parent Child Level_ancestor Depth Subtree_size LCA …all in O(1) time with 2n+o(n) bits on the word RAM

Motivations and Objectives Three main representations: BP, DFUDS, TC The fact: different representation supports different operations on trees Example: height, node_rank DFUDS, node_rank post New problem: a representation supporting all the navigational operations

Motivations and Objectives (Continued) The assumption: there may be new operations supported by one of these representations New problem: one representation that can compute an arbitrary word of all the other representations

The Tree Covering Algorithm by Geary et al. The idea Cover the tree with a set of mini-trees Cover each mini-tree with a set of micro-trees Compute the set of mini-trees (micro-trees) in a bottom-up, greedy fashion Properties Any two mini-trees (micro-trees) can only share their root Size of a mini-tree (micro-tree): M~3M-4 (M’ ~3M’-4) Parameters: M = lg 4 n, M’ = lg n / 24

The Tree Covering Algorithm: An Example M = 8, M’ = 3

Operations supported on TC by Geary et al. The old TC (Geary et al. 2004) child child_rank depth level_anc nbdesc degree node_rank PRE, node_select PRE node_rank POST, node_select POST

New Definitions and Properties: Preorder Changers Tier-1 preorder changers: Number of Tier-1 preorder changers: at most twice the number of mini-trees Tier-2 preorder changers are similar

DFUDS Order Changers Tier-1 DFUDS order changers: Number of Tier-1 DFUDS order changers: at most four times the number of mini-trees Tier-2 DFUDS order changers are similar

τ * -name of a Node Preorder numbers: node x τ -names: τ (x)= τ * -names: τ * (x)= Node 29 τ (29)=<3, τ * (29)= 1,5>

Supporting node_select DFUDS From the DFUDS number to the τ * - name From the τ * -name to the τ -name Table lookup From the τ -name to the preorder number Geary et al. 2004

Computing τ 1 (x) … 1 Nodes (DFUDS #) τ 1 ’s stored … 212 Example: x=8 th node in DFUDS τ 1 (x)=2 10

Computing τ 1 (x) (Continued) Dictionary Universe: n size: O(n / lg 4 n) Space cost: o(n) bits (Raman et al, 2002) τ 1 ’s stored Number of elements stored: O(n / lg 4 n) Each element: O(lg n) bits Space cost: o(n) bits

Computing τ 2 (x) and τ 3 * (x) … 1 Nodes τ2τ2 … 112 τ 2 (x)= τ3*τ3* … τ 3 * (x)=4

Computing τ 2 (x) and τ 3 * (x) (Continued) Dictionary Universe: n size: O(n / lg n) Space cost: o(n) bits (Raman et al, 2002) τ 2 ’s and τ 3 * ’s stored Number of elements stored: O(n / lg n) Each element: O(lglg n) bits Space cost: o(n) bits

Other Operations Supported height LCA distance leaf_rank and leaf_select leftmost_leaf and rightmost_leaf leaf_size node_rank DFUDS level_leftmost and level_rightmost level_succ and level_pred

Data Abstraction: Computing a subsequence of BP and DFUDS The problem: store the tree using TC, and support the computation of a word of its BP or DFUDS sequence Results: Time: compute a word (Θ(lg n) bits) of the BP or DFUDS sequence in O(f(n)) time Space: n/f(n) additional bits

Conclusions A succinct representation of ordinal trees using 2n+o(n) bits that support all the navigational operations Our representation also supports level- order traversal, a useful ordering previously supported only with a very limited set of operations Our encoding schemes supports BP and DFUDS as abstract data types

Open Problems Support new operations that are not supported by BP, DFUDS or TC Constant-time computation of a word of BP or DFUDS using o(n) additional bits (or is this possible at all?)

Thank you!