I'm trying to understand how to implement Fibonacci heap operations. Given we have the following heap:
How would we decrease 35 to 27, for example? The order is not preserved since 27 is not greater than 30, so we must rebuild the heap. So where does 27 go? Under 5?
In a Fibonacci heap, decrease-key actually cuts out any nodes from a tree whose key decreases below the parent's key. In your case, the node would be put up into the root list as a singleton node.
More generally, decrease-key works as follows:
Hope this helps!