Franklin University 1 COMP 620 Algorithm Analysis Module 3: Advanced Data Structures Trees, Heap, Binomial Heap, Fibonacci Heap.

Slides:



Advertisements
Similar presentations
Comp 122, Spring 2004 Binary Search Trees. btrees - 2 Comp 122, Spring 2004 Binary Trees  Recursive definition 1.An empty tree is a binary tree 2.A node.
Advertisements

Chapter 4: Trees Part II - AVL Tree
Jan Binary Search Trees What is a search binary tree? Inorder search of a binary search tree Find Min & Max Predecessor and successor BST insertion.
Analysis of Algorithms CS 477/677 Binary Search Trees Instructor: George Bebis (Appendix B5.2, Chapter 12)
Binary Search Trees Many of the slides are from Prof. Plaisted’s resources at University of North Carolina at Chapel Hill.
Binary Search Trees Comp 550.
Binary Trees, Binary Search Trees CMPS 2133 Spring 2008.
Binary Trees, Binary Search Trees COMP171 Fall 2006.
A balanced life is a prefect life.
Analysis of Algorithms CS 477/677 Instructor: Monica Nicolescu.
CS 253: Algorithms Chapter 6 Heapsort Appendix B.5 Credit: Dr. George Bebis.
Fall 2007CS 2251 Trees Chapter 8. Fall 2007CS 2252 Chapter Objectives To learn how to use a tree to represent a hierarchical organization of information.
Analysis of Algorithms CS 477/677
1 Trees. 2 Outline –Tree Structures –Tree Node Level and Path Length –Binary Tree Definition –Binary Tree Nodes –Binary Search Trees.
Comp 122, Spring 2004 Heapsort. heapsort - 2 Lin / Devi Comp 122 Heapsort  Combines the better attributes of merge sort and insertion sort. »Like merge.
Data Structures, Spring 2004 © L. Joskowicz 1 Data Structures – LECTURE 7 Heapsort and priority queues Motivation Heaps Building and maintaining heaps.
© 2006 Pearson Addison-Wesley. All rights reserved11 A-1 Chapter 11 Trees.
1.1 Data Structure and Algorithm Lecture 12 Binary Search Trees Topics Reference: Introduction to Algorithm by Cormen Chapter 13: Binary Search Trees.
B + -Trees (Part 1). Motivation AVL tree with N nodes is an excellent data structure for searching, indexing, etc. –The Big-Oh analysis shows most operations.
Analysis of Algorithms CS 477/677 Instructor: Monica Nicolescu.
UMass Lowell Computer Science Analysis of Algorithms Prof. Karen Daniels Fall, 2001 Lecture 11 Tuesday, 12/4/01 Advanced Data Structures Chapters.
C o n f i d e n t i a l HOME NEXT Subject Name: Data Structure Using C Unit Title: Trees.
Binomial Heaps Melalite Ayenew Dec 14, 2000.
Binomial Heaps Referred to “MIT Press: Introduction to Algorithms 2 nd Edition”
CS Data Structures Chapter 5 Trees. Chapter 5 Trees: Outline  Introduction  Representation Of Trees  Binary Trees  Binary Tree Traversals 
Lecture 10 Trees –Definiton of trees –Uses of trees –Operations on a tree.
Spring 2010CS 2251 Trees Chapter 6. Spring 2010CS 2252 Chapter Objectives Learn to use a tree to represent a hierarchical organization of information.
Tree (new ADT) Terminology:  A tree is a collection of elements (nodes)  Each node may have 0 or more successors (called children)  How many does a.
Binary Trees, Binary Search Trees RIZWAN REHMAN CENTRE FOR COMPUTER STUDIES DIBRUGARH UNIVERSITY.
2IL50 Data Structures Fall 2015 Lecture 7: Binary Search Trees.
Lecture X Fibonacci Heaps
B + -Trees. Motivation An AVL tree with N nodes is an excellent data structure for searching, indexing, etc. The Big-Oh analysis shows that most operations.
AVL Tree Definition: Theorem (Adel'son-Vel'skii and Landis 1962):
Starting at Binary Trees
CS 473Lecture X1 CS473-Algorithms Lecture BINOMIAL HEAPS.
Prepared by- Jatinder Paul, Shraddha Rumade
Preview  Graph  Tree Binary Tree Binary Search Tree Binary Search Tree Property Binary Search Tree functions  In-order walk  Pre-order walk  Post-order.
Analysis of Algorithms CS 477/677 Instructor: Monica Nicolescu Lecture 9.
Advanced Data Structures CHAPTER 2. Jaruloj ChongstitvatanaChapter 2: Advanced Data Structures2 Outlines Binary search trees B-trees Heaps and priority.
Computer Algorithms Lecture 9 Heapsort Ch. 6, App. B.5 Some of these slides are courtesy of D. Plaisted et al, UNC and M. Nicolescu, UNR.
Trees. 2 Root leaf CHAPTER 5 3 Definition of Tree n A tree is a finite set of one or more nodes such that: n There is a specially designated node called.
CSE 5392 Fall 2005 Week 4 Devendra Patel Subhesh Pradhan.
1 Heap Sort. A Heap is a Binary Tree Height of tree = longest path from root to leaf =  (lgn) A heap is a binary tree satisfying the heap condition:
Internal and External Sorting External Searching
Foundation of Computing Systems Lecture 4 Trees: Part I.
Fibonacci Heaps.
BINARY TREES Objectives Define trees as data structures Define the terms associated with trees Discuss tree traversal algorithms Discuss a binary.
Sept Heapsort What is a heap? Max-heap? Min-heap? Maintenance of Max-heaps -MaxHeapify -BuildMaxHeap Heapsort -Heapsort -Analysis Priority queues.
Sorting Cont. Quick Sort As the name implies quicksort is the fastest known sorting algorithm in practice. Quick-sort is a randomized sorting algorithm.
Fibonacci Heaps. Fibonacci Binary insert O(1) O(log(n)) find O(1) N/A union O(1) N/A minimum O(1) O(1) decrease key O(1) O(log(n)) delete O(log(n) O(log(n))
Analysis of Algorithms
Binary Search Trees What is a binary search tree?
Balanced Search Trees Modified from authors’ slides.
Heaps, Heap Sort and Priority Queues
Lecture 22 Binary Search Trees Chapter 10 of textbook
Heap Sort Example Qamar Abbas.
Binomial Heaps Chapter 19.
Binary Trees, Binary Search Trees
Chapter 22 : Binary Trees, AVL Trees, and Priority Queues
Find in a linked list? first last 7  4  3  8 NULL
Heapsort.
Binomial Heap.
Chapter 20 Binomial Heaps
CS 583 Analysis of Algorithms
CS 583 Analysis of Algorithms
HEAPS.
Binary Search Trees Comp 122, Spring 2004.
Data Structures Using C++ 2E
NATURE VIEW OF A TREE leaves branches root. NATURE VIEW OF A TREE leaves branches root.
Tree (new ADT) Terminology: A tree is a collection of elements (nodes)
Presentation transcript:

Franklin University 1 COMP 620 Algorithm Analysis Module 3: Advanced Data Structures Trees, Heap, Binomial Heap, Fibonacci Heap

Franklin University 2 COMP 620 Algorithm Analysis Trees Definition: A tree (which is one type of a data structure) is a finite set of one or more nodes such that: There is a specially designated node called root. The remaining nodes are divided into n>=0 disjoint sets T1, T2,..... Tn where each of these sets is a tree. T1, T2,.... Tn are called the subtrees of the root. Node - represents an item of information stored in the tree. Branches - represent the links between the nodes. Root of the tree or root node - node at the top of the tree, the start of the tree. Degree of a node - the number of subtrees of the node (i.e., the number of children from any one node). Degree of a tree - the maximum degree of any of the nodes in the tree. Leaf or terminal nodes - nodes with degree 0.

Franklin University 3 COMP 620 Algorithm Analysis Tree Terminology (contd.) 7.Child/children - the roots of the subtrees of the parent node. 8.Siblings - children of the same parent. 9.Parent - a node that has subtrees (i.e., a node that has children). 10.Level of a node - defined by root = 1, children of root = 2, grandchildren of root = 3, etc. (In some textbooks, the root is defined to be at level 0, children of the root at level 1, etc.) 11.Depth or height of a tree - the maximum level of any node in the tree. 12.Binary trees are trees with no more than two-way branching from each node in the tree. A binary tree is either empty or consists of a root node and two disjoint binary trees called left and right subtrees.

Franklin University 4 COMP 620 Algorithm Analysis Tree - Example A L B K O C E F N M J I HG D Degree of the tree = Height (depth) of the tree = Terminal nodes of the tree are:

Franklin University 5 COMP 620 Algorithm Analysis Binary Trees: Properties The maximum number of nodes on level i of a binary tree is 2 (i-1), where i >= 1. The maximum number of nodes in a binary tree of depth k is 2 k –1,where k >= 1. For any non-empty binary tree, T, if n0 represents the number of leaf nodes and n2 represents the number of nodes with degree 2, then n0 = n A full binary tree of depth k is a binary tree of depth k having 2 k - 1 nodes, where k >= 1. A binary tree with n nodes and depth k is complete if and only if its nodes correspond to the nodes numbered from 1 to n in the full binary tree of depth k, filling in from left to right on each level.

Franklin University 6 COMP 620 Algorithm Analysis Full and Complete Binary Trees C GF E D B A Full Binary Tree Complete Binary Tree Array Representing Above Tree ABCDEFG Leftchild(i) is at 2i if 2i >n no left child Rightchild(i) is at 2i + 1 if 2i +1 > n no right child

Franklin University 7 COMP 620 Algorithm Analysis Neither Full nor Complete Trees A D B C E F G Array Representation of the Above Tree ABCDEFG The array representation of the tree that is neither full nor complete is very wasteful of memory

Franklin University 8 COMP 620 Algorithm Analysis Linked Representation template Class BtNode { public: BaseData info; BtNode *leftChild, *rightChild; };

Franklin University 9 COMP 620 Algorithm Analysis Traversing Trees Inorder traversal 1.Traverse the left subtree 2.Visit the root 3.Traverse the right subtree Void BinTree::inord( BtNode *rt) { if (rt != NULL) { inord(rt->leftChild); processNode(rt->info); inord(rt->rightChild); }

Franklin University 10 COMP 620 Algorithm Analysis Traversing Trees Preorder traversal 1.Visit root 2. Traverse the left subtree 3. Traverse the right subtree Void BinTree::preord( BtNode *rt) { if (rt != NULL) { processNode(rt->info); preord(rt->leftChild); preord(rt->rightChild); }

Franklin University 11 COMP 620 Algorithm Analysis Traversing Trees Postorder traversal 1.Traverse the left subtree 2.Traverse the right subtree 3.Visit the root Levelorder traversal Every node is visited in turn from left to right on every level, starting at level 1, then level 2, etc., until level n, where n represents the height (depth) of the tree.

Franklin University 12 COMP 620 Algorithm Analysis Binary Search Trees Binary search tree is of significant importance in Computer Science. Has better performance than many other data structures especially for operations like insertion, deletion, and searching. Definition: A binary search tree is a binary tree. It may be empty. If not empty, it satisfies the following properties: Every element has a key, and traditionally no two elements have the same key. Keys in a non-empty left subtree must be smaller than the key in the root of the subtree. Keys in a non-empty right subtree must be larger than the key in the root of the subtree. Left and right subtrees are also binary search trees.

Franklin University 13 COMP 620 Algorithm Analysis J O H E A F G I D B C M P N L K Binary Search Tree

Franklin University 14 COMP 620 Algorithm Analysis Binary Search Trees: Operations Searching a binary search tree: Begin at the root. If the key of the element to be searched = root key, then the search is successful. If the key of the element to be searched < root key, then search the left subtree. If the key of the element to be searched > root key, then search the right subtree. Inserting into a binary search tree: - Search for the key - If the key is not present, locate the parent node - Insert the new node as the left/right child of the parent node All insertions take place at leaf nodes.

Franklin University 15 COMP 620 Algorithm Analysis Binary Search Trees: Operations Deleting from a binary search tree: The deletion process begins with a search to find the node to be deleted from the binary search tree. Three possible scenarios exist in the deletion process: 1.Delete a leaf node. - Make the appropriate pointer in x’s parent a null pointer 2.Delete a node with 1 child. - Set the appropriate pointer in x’s parent to point to this child 3.Delete a node with 2 children. - Replace the value stored in the node x by its inorder successor (predecessor) and then delete the successor (predecessor)

Franklin University 16 COMP 620 Algorithm Analysis Binary Search Trees: Variations AVL (or height-balanced) trees A binary search tree in which the balance factor of each node is 0, 1, or –1, where the balance factor of a node x is defined as the height of the left subtree of x minus the height of x’s right subtree trees:A tree with the following properties: Each node stores at most 3 data values. Each internal node is a 2-node, 3-node, or a 4- node. All the leaves are on the same level.

Franklin University 17 COMP 620 Algorithm Analysis Motivation for AVL Tree The height of AVL tree is approximately Log 2 n What is the value of balance of each node?

Franklin University 18 COMP 620 Algorithm Analysis Tree

Franklin University 19 COMP 620 Algorithm Analysis Red Black Trees Red Black trees A binary search tree with two kinds of nodes, red and black, which satisfy the following properties: Every node is either red or black. Root is black. Every leaf (NIL) is black. If a node is red, both its children are black. Every simple path from node to descendant leaf contains the same number of black nodes. A red-black tree with n internal nodes has height at most 2log(n+1).

Franklin University 20 COMP 620 Algorithm Analysis RED-BLACK TREE

Franklin University 21 COMP 620 Algorithm Analysis B-trees B-trees of minimum degree t A tree with the following properties: - Each node stores at most 2t -1 data values. - Every node other than the root must have at least t- 1 data values. - n[x] keys in each node x stored in nondecreasing order, so that key 1 [x] <= key 2 [x].. <= key n[x] [x]. - Each internal node contains n[x] + 1 children. X contains n +1 pointers c 1 [x], c 2 [x] … c n[x]+1 [x].

Franklin University 22 COMP 620 Algorithm Analysis B-trees - The keys key i [x] separates the ranges of keys stored in each subtree: if k i is any key stored in the subtree with root c i [x] then, then k 1 <= key1[x] <= key 2 [x] <= ….<= key n[x] [x] <= k n[x]+1 - All the leaves are on the same level. - B alanced and designed to work efficiently on disks and other direct access secondary storage devices. Many database systems use B-tree. - the maximum height of a n-key B tree is log t ((n+1)/2) - insert, delete, and search time on a B-Tree is  (log n)

Franklin University 23 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 24 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 25 COMP 620 Algorithm Analysis B-tree of minimum degree t = 2 M Q T X D H Y Z V W N P F GB C J K L Is tree a B-tree? R S

Franklin University 26 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 27 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 28 COMP 620 Algorithm Analysis B-Tree Insert - locate the node where the key should be inserted - split any full nodes encountered while descending the tree Deletion Deletion is similar to Insertion. Make sure that the tree is still a B-Tree after deletion. Detailed discussion of deleting from a B-tree, refer to Section 18.3, pages , of Cormen, Leiserson, and Rivest.

Franklin University 29 COMP 620 Algorithm Analysis G M P X A C D E J K N O R S T U V Y Z (a) Initial Tree G M P X A B C D E J K N O R S T U V Y Z (b) B Inserted B-Tree Insertion - Inserts only in leaf node

Franklin University 30 COMP 620 Algorithm Analysis B-Tree Insertion - Inserts only in leaf node G M P T X A B C D E J K N O U V Y Z Q R S P G M T X A B C D E J K L N O Q R S U V Y Z (C ) Q Inserted (d ) L Inserted

Franklin University 31 COMP 620 Algorithm Analysis P C G M T X A B J K L N O Q R S U V Y Z B-Tree Insertion - Inserts only in leaf node (e ) F Inserted D E F

Franklin University 32 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 33 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 34 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 35 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 36 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 37 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 38 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 39 COMP 620 Algorithm Analysis Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Franklin University 40 COMP 620 Algorithm Analysis Heaps Heaps data structures are mostly used to support the following operations (not efficient to use for search): Insert element x Return min element Delete minimum element Union of two heaps Application: Dijkstra’s Shortest Path Prim’s MST Huffman Encoding Heap Sort

Franklin University 41 COMP 620 Algorithm Analysis Binary Heap A heap is a complete binary tree such that the value of the key in the root is greater than the value of the key in each of its children, and that both subtrees are also heaps (a recursive definition). r6/HeapSort.htm r6/HeapSort.htm Heapsort: (1) Make a heap of the elements to be sorted. (2) Convert the heap into a sorted list

Franklin University 42 COMP 620 Algorithm Analysis Heap Sort HeapSort(A) 1Build_Max_Heap(A) 2for i ← length[A] downto 2 do 3 exchange A[1] ↔ A[i] 4heap-size[A] ← heap-size[A] – 1 5Max_Heapify(A, 1) Build_Max_Heap(A) 1heap-size[A] ← length[A] 2for i ← floor(length[A]/2) downto 1 do 3Max_Heapify (A, i)

Franklin University 43 COMP 620 Algorithm Analysis HEAP SORT Heapify(A, i) 1l ← LEFT(i) 2r ← RIGHT(i) 3if l ≤ heap-size[A] and A[l] > A[i] 4then largest ← l 5else largest ← i 6if r ≤ heap-size[A] and A[r] > A[largest] 7then largest ← r 8if largest ≠ i 9then exchange A[i] ↔ A[largest] 10Max_Heapify (A, largest)

Franklin University 44 COMP 620 Algorithm Analysis HEAPS OperationLinked List Binary Heap Binomial Heap Fibonacci Heap make-heap1111 insert1Log N 1 find-minN1Log N1 delete-minNLog N decrease-key1Log N 1 deleteNLog N union1NLog N1

Franklin University 45 COMP 620 Algorithm Analysis BINOMIAL TREE Recursive Definition : B k consists of 2 binomial trees B k-1 that are linked together; the root of the one is the leftmost Child of the root of the other. B 0 B 2 B 3 B 1

Franklin University 46 COMP 620 Algorithm Analysis Binomial Tree Properties Number of nodes = 2 k Height of the tree = k There are nodes nodes at level i The root has degree k and it children are B k-1, B k-2,.. B 0 from left to right.

Franklin University 47 COMP 620 Algorithm Analysis Binomial Heap A binomial heap is a set of binomial trees Each binomial tree in H is heap-ordered key (x) >= key (parent(x)). There never exist 2 or more trees with same degree in the heap. Linked list of roots in order of increasing degree Binomial tree is stored in a left child-right sibling representation.

Franklin University 48 COMP 620 Algorithm Analysis Binomial Heap B 0 B 2 B 1 View View View the operations on binomial heap at the class web site Head Sibling Parent Child degree Key Roots of the trees connected with singly linked list Head points to the first node in the linked list

Franklin University 49 COMP 620 Algorithm Analysis Binomial Heap MAKE_BINOMIAL_HEAP() allocate(H) head[H] = NIL Insert(H, x) H’ = MAKE-BINOMIAL-HEAP() set x’s field appropriately head[H’] = x n[H’] = 1 H = BINOMIAL-HEAP-UNION(H, H’]

Franklin University 50 COMP 620 Algorithm Analysis Binomial Heap Binomial-Heap-Minimum(H) y = NIL x = head[H] min = inf while x <> NIL do if key[x] < min then min = key[x] y = x x = sibling[x] return y;

Franklin University 51 COMP 620 Algorithm Analysis Binomial Heap BINOMIAL-HEAP-UNION (H1, H2) Merge the root lists of binomial heaps H1 and H2 into a single linked linked list H that is sorted by degree into monotonically increasing order. Links roots of equal degree until at most one root remains of each degree. Binomial-Link (y,z) p[y] = z sibling[y] = child[z] child[z] = y degree [z] = degree[z] + 1

Franklin University 52 COMP 620 Algorithm Analysis Binomial Heap BINOMIAL-HEAP-EXTRACT-MIN(H) find the root x with the minimum key in the root list of H, and remove x from the root list of H H’ = MAKE-BINOMIAL-HEAP() reverse the order of the linked list of x’s children and set head[H’] to point to the head of the resulting list H = BINOMIAL-HEAP-UNION (H, H’) return (x)

Franklin University 53 COMP 620 Algorithm Analysis Fibonacci Heap A set of min-heap-ordered trees Roots of trees are connected with circular doubly linked list. Children of a node are connected with circular doubly linked list. Pointer to root of tree with minimum element. Parent Mark: Newly created nodes are unmarked. This field becomes true if the node has lost a child Since the node became a child Of another node. Left Right Child Key Degree

Franklin University 54 COMP 620 Algorithm Analysis Fibonacci Heap View the operations on Fibonacci heap at the class web site Min[H]

Franklin University 55 COMP 620 Algorithm Analysis Fibonacci Heap Make_heap() allocate(H) min[H] = NIL n[H]= 0 Insert(H, x) set x’s field appropriately add x to root list of H reset min[H] if needed n[H] = n[H] + 1

Franklin University 56 COMP 620 Algorithm Analysis Fibonacci Heap Union(H1, H2) H = new heap whose root list contains roots from H1 and H2 Min[H] = min[H1] If ( min[H1] == NIL) or (min [H2] <> NIL and min[H2] < min[H1]) then min [H] = min[H2] N[H] = n[H1] + n[H2] free the objects H1 and H2 return H

Franklin University 57 COMP 620 Algorithm Analysis Fibonacci Heap Extract-min (H) z = min[H] Add z’s children to root list Remove z from root list If root list <> {} then Consolidate H else min[H] = NIL n[H] = n[H] - 1

Franklin University 58 COMP 620 Algorithm Analysis Fibonacci Heap Consolidate (H) While 2 trees in H (T1, T2) have the same degree: if root(T1) < root (T2) then make T1 child of T2 else make T2 child of T1 for i = 0 to D(n[H] ) // D is max possible trees if tree T of degree i has root-key < min[H] then min[H] = T

Franklin University 59 COMP 620 Algorithm Analysis FIB-HEAP-DECREASE-KEY(H, x, k) 1 if k > key[x] 2 then error "new key is greater than current key" 3 key[x] ← k 4 y ← p[x] 5 if y ≠ NIL and key[x] < key[y] 6 then CUT(H, x, y) 7 CASCADING-CUT(H, y) 8 if key[x] < key[min[H]] 9 then min[H] ← x CUT(H, x, y) 1 remove x from the child list of y, decrementing degree[y] 2 add x to the root list of H 3 p[x] ← NIL 4 mark[x] ← FALSE CASCADING-CUT(H, y) 1 z ← p[y] 2 if z ≠ NIL 3 then if mark[y] = FALSE 4 then mark[y] ← TRUE 5 else CUT(H, y, z) 6 CASCADING-CUT(H, z) Fibonacci Heap Decrease Key

Franklin University 60 COMP 620 Algorithm Analysis Fibonacci Heap Decrease Key

Franklin University 61 COMP 620 Algorithm Analysis Fibonacci Heap Decrease Key a.The initial Fibonacci heap b.The node with key 46 has its key decreased to 15. The node becomes a root, and its parent ( with key 24) which had previously been unmarked, becomes marked. c-e The node with key 35 has its key decreased to 5. In part (c), the node now with key 5, becomes a root. Its parent, with key 26, is cut from its parent and made an unmarked root in (d). Another cascading cut occurs, since the node with key 24 is marked as well. This node is cut from its parent and made an unmarked root in part (e). The cascading cuts stop at this point, since the node with key 7 is a root.

Franklin University 62 COMP 620 Algorithm Analysis Fibonacci Heap Delete Node FIB-HEAP-DELETE(H, x) 1 FIB-HEAP-DECREASE-KEY(H, x, -∞) 2 FIB-HEAP-EXTRACT-MIN(H)