A minor bug: You get an IndexOutOfBoundsException for an empty list in GreaterSumTree.create(List&lt;Integer&gt; items). You don't have a comment stating you need to input a list containing at least something. Consider returning IllegalArgumentException and adding a comment.



/**
 * Computes the greater sum, provided the tree is BST.
 * If tree is not BST, then results are unpredictable.
 */
public void greaterSumTree() {
    if (root == null) {
        throw new IllegalArgumentException("root is null");
    }
    computeSum (root, new IntObject());
}


You should use IllegalStateException here. IllegalArgumentException is for when the arguments are bad. What's bad here is the internal state of your object. Alternatively, remove the check here and put it in the create function. That way you don't get bad internal states.

Transform a Binary Search Tree into a Greater Sum Tree
I'm powering a 12 V computer fan with a simple 7810 circuit shown here:



When the fan is connected to the regulator, on the output I get this wave:



When I zoom out in time, I get something that looks like this:



For those who can't be bothered to click on the image, the distance between the peaks is almost 10 ms.

When I zoom out a bit more, I can see that there is another wave here riding on top of those peaks like this:



The higher top peaks have peak voltage of 13.4 V and the lower peaks are 12 V. The peaks on the bottom side which go together with 12 V peaks are 8.8 V and the bottom peaks of 13.4 V top peaks are 8.6 V.  

So any ideas what could be causing this? 

UPDATE

Here's the input waveform with the output peaks:



The input peaks are 10 ms apart and are in phase with AC line transitions, as expected since the AC frequency here is 50 Hz. The input is coming from a diode bridge rectifier. The input voltage is a bit high since I changed the original 1N4007 diodes with STPS2H100 Schottky diodes because I initially believed that one of the input diodes developed a short.

I can't determine the exact relationship between the input and output wave. When I trigger by one of the waves, the other is flowing from left to right on the screen.
