Fibonacci Heap Decrease-Key
Cut the node to the root list; cascading cuts keep the potential bounded.
Decision · step 2 of 4Binomial and Fibonacci Heaps: Decrease-key: one cut
41 becomes 9. Its parent is 23, which is now larger: heap order is broken between exactly these two nodes, so 9 is cut and joins the root list, and the parent takes a mark.
What you will see
A node detaches and joins the root list; marked ancestors cascade.
Cost
| Best | O(1) |
|---|---|
| Average | O(1) amortized |
| Worst | O(log n) |
| Space | O(1) |
How you work with it here
play it through, step one change at a time, scrub to any step, run it on your own input, predict what happens next, try operations in any order.
Screen readers: Nodes announce value, parent and children; each step announces the comparison and whether the value moves up or down.
Reduced motion: Swaps become value crossfades in both the tree and the array view.
Before this
Taught by the same lesson
Binomial and Fibonacci Heaps covers these too, in the same run.