From this result we can analyze the run time of BuildHeap.
. The derivative of both sides,
, is equal to
Multiplying both sides of the equivalence by x we get
In our case k = h and x = 1/2.
x = 1/2.
Thus the run time is O(n * 1/2 * 2) = O(n).