Simple Balanced Binary Search Trees

نویسنده

  • Prabhakar Ragde
چکیده

Efficient implementations of sets and maps (dictionaries) are important in computer science, and balanced binary search trees are the basis of the best practical implementations. Pedagogically, however, they are often quite complicated, especially with respect to deletion. I present complete code (with justification and analysis not previously available in the literature) for a purely-functional implementation based on AA trees, which is the simplest treatment of the subject of which I am aware.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

P´olya Urn Models and Connections to Random Trees: A Review

This paper reviews P´olya urn models and their connection to random trees. Basic results are presented, together with proofs that underly the historical evolution of the accompanying thought process. Extensions and generalizations are given according to chronology: • P´olya-Eggenberger’s urn • Bernard Friedman’s urn • Generalized P´olya urns • Extended urn schemes • Invertible urn schemes ...

متن کامل

On Digital Search Trees - A Simple Method for Constructing Balanced Binary Trees

This paper presents digital search trees, a binary tree data structure that can produce well-balanced trees in the majority of cases. Digital search tree algorithms are reviewed, and a novel algorithm for building sorted trees is introduced. It was found that digital search trees are simple to implement because their code is similar to the code for ordinary binary search trees. Experimental eva...

متن کامل

New Combinatorial Properties and Algorithms for AVL Trees

In this thesis, new properties of AVL trees and a new partitioning of binary search trees named core partitioning scheme are discussed, this scheme is applied to three binary search trees namely AVL trees, weight-balanced trees, and plain binary search trees. We introduce the core partitioning scheme, which maintains a balanced search tree as a dynamic collection of complete balanced binary tre...

متن کامل

Balanced Search Trees Made Simple

As a contribution to the recent debate on simple implementa tions of dictionaries we present new maintenance algorithms for balanced trees In terms of code simplicity our algorithms compare favourably with those for deterministic and probabilistic skip lists

متن کامل

Average-Case Analysis on Simple Families of Trees Using a Balanced Probability Model

Casas. R., J. Diaz and C. Martinez, Average-case analysis on simple families of trees using a balanced probability model, Theoretical Computer Science 117 (1993) 99-112. We extend the binary search tree model of probability to simply generated families of trees. In the resulting statistics, well-balanced trees are more likely than linear trees. Using this balanced model, analyses are more compl...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2014