Results 1 -
5 of
5
Constructing Red-Black Trees
, 1999
"... This paper explores the structure of red-black trees by solving an apparently simple problem: given an ascending sequence of elements, construct a red-black tree which contains the elements in symmetric order. Several extreme red-black tree shapes are characterized: trees of minimum and maximum heig ..."
Abstract
-
Cited by 9 (3 self)
- Add to MetaCart
This paper explores the structure of red-black trees by solving an apparently simple problem: given an ascending sequence of elements, construct a red-black tree which contains the elements in symmetric order. Several extreme red-black tree shapes are characterized: trees of minimum and maximum height, trees with a minimal and with a maximal proportion of red nodes. These characterizations are obtained by relating tree shapes to various number systems. In addition, connections to left-complete trees, AVL trees, and half-balanced trees are highlighted. 1 Introduction Red-black trees are an elegant search-tree scheme that guarantees O(log n) worstcase running time of basic dynamic-set operations. Recently, C. Okasaki (1998; 1999) presented an impressively simple functional implementation of red-black trees. In this paper we plunge deeper into the structure of red-black trees by solving an apparently simple problem: given an ascending sequence of elements, construct a red-black tree whic...
A Simple Implementation Technique for Priority Search Queues
- Proceedings of the 2001 International Conference on Functional Programming
, 2001
"... This paper presents a new implementation technique for priority search queues. This abstract data type is an amazing blend of finite maps and priority queues. Our implementation supports logarithmic access to a binding with a given key and constant access to a binding with the minimum value. Priorit ..."
Abstract
-
Cited by 7 (2 self)
- Add to MetaCart
This paper presents a new implementation technique for priority search queues. This abstract data type is an amazing blend of finite maps and priority queues. Our implementation supports logarithmic access to a binding with a given key and constant access to a binding with the minimum value. Priority search queues can be used, for instance, to give a simple, purely functional implementation of Dijkstra's single-source shortest-paths algorithm.
Functional Pearls: Explaining Binomial Heaps
, 1999
"... This paper explains binomial heaps, a beautiful data structure for priority queues, using the functional programming language Haskell (Peterson & Hammond, 1997). We largely follow a deductive approach: using the metaphor of a tennis tournament we show that binomial heaps arise naturally through a nu ..."
Abstract
-
Cited by 5 (4 self)
- Add to MetaCart
This paper explains binomial heaps, a beautiful data structure for priority queues, using the functional programming language Haskell (Peterson & Hammond, 1997). We largely follow a deductive approach: using the metaphor of a tennis tournament we show that binomial heaps arise naturally through a number of logical steps. Haskell supports the deductive style of presentation very well: new types are introduced at ease, algorithms can be expressed clearly and succinctly, and Haskell's type classes allow to capture common algorithmic patterns. The paper aims at the level of an undergraduate student who has experience in reading and writing Haskell programs, and who is familiar with the concept of a priority queue. 2 Priority queues
Project proposal: A meldable, iterator-valid priority queue, CPH
, 2005
"... Abstract. The Standard Template Library (STL) is a library of generic algorithms and data structures that has been incorporated in the C++ standard and ships with all modern C++ compilers. In the CPH STL project the goal is to implement an enhanced edition of the STL. The priority-queue class of the ..."
Abstract
-
Cited by 2 (2 self)
- Add to MetaCart
Abstract. The Standard Template Library (STL) is a library of generic algorithms and data structures that has been incorporated in the C++ standard and ships with all modern C++ compilers. In the CPH STL project the goal is to implement an enhanced edition of the STL. The priority-queue class of the STL is just an adapter that makes any resizable array to a queue in which the elements stored are arranged according to a given ordering function. In the C++ standard no compulsory support for the operations delete(), increase(), or meld() is demanded even if those are utilized in many algorithms solving graph-theoretic or geometric problems. In this project, the goal is to implement a CPH STL extension of the priority-queue class which provides, in addition to the normal priority-queue functionality, the operations delete(), increase(), and meld(). To make the first two of these operations possible, the class must also guarantee that external references to compartments inside the data structure are kept valid at all times.

