Binomial Heap

tatya922050 1,879 views 10 slides Nov 19, 2014
Slide 1
Slide 1 of 10
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10

About This Presentation

Computer science Binomial Heap and Binary Heap.
http://www.redicals.com


Slide Content

BINOMIAL HEAPS

Definition A binomial tree B k is an ordered tree defined recursively. B consists of a single node. For k≥1, B k is a pair of B k −1 trees, where the root of one B k −1 becomes the leftmost child of the other.

BINOMIAL HEAPS

Properties of Binomial Trees

The Binomial Heap A binomial heap is a collection of binomial trees that satisfies the following binomial-heap properties: No two binomial trees in the collection have the same size. Each node in each tree has a key. Each binomial tree in the collection is heap-ordered in the sense that each non-root has a key strictly less than the key of its parent.

Implementation of a Binomial Heap Keep at each node the following pieces of information: a field key for its key, a field degree for the number of children, a pointer child , which points to the leftmost-child, a pointer sibling , which points to the right-sibling, and a pointer p , which points to the parent.

Operations on Binomial Heaps creation of a new heap , search for the minimum key, uniting two binomial heaps , insertion of a node , removal of the root of a tree , decreasing a key, and removal of a node.

Binomial Heaps Example