|
ADS
Algorithms and Data Structures
|
The PRIORITYQUEUE on a heap realized as a binary tree with pointers, beyond the book, instead of the vector of section 10.1. More...
Files | |
| file | ADS/priority/LinkedHeapPriorityQueue.h |
| The PRIORITYQUEUE [see PriorityQueue.h] on a heap realized as a binary tree with pointers, beyond the book, instead of the vector of section 10.1: the nodes are those of a complete binary tree numbered by levels from 1, and the path from the root to the node \( k \) follows the bits of \( k \) after the leading one, 0 to the left and 1 to the right, so that the last leaf, where insert() adds a node and from where deleteMin() takes the one that replaces the root, is found in \( O( \log n ) \) steps. | |
Classes | |
| class | ADS::LinkedHeapPriorityQueue< T, P, L > |
| a priority queue on a heap with pointers, which keeps a pointer to the last leaf if L More... | |
The PRIORITYQUEUE on a heap realized as a binary tree with pointers, beyond the book, instead of the vector of section 10.1.
The definitions, the invariants and the costs of the area are in Theory of priority queues.