Implemented trickleDown() and debugged bubbleUp()

Managed to swap for each of two functions, but still don't know if they
work or not.