This is a basic concept for calculating minimum height for Binary Trees.
Hope you know A Complete Binary tree corresponds to maximum possible number of nodes in any tree.
When Nodes are maximum (Fully dense tree) then this also corresponds to minimum hight of the tree.
Now lets derive the formula
At level 0 Number of nodes possible --------->>>>> 1 (Root) // 2^{0}
At level 1 Number of nodes possible--------->>>>>2 // 2^{1}
At level 2 Number of nodes possible--------->>>>>4 // 2^{2}
At level 3 Number of nodes possible--------->>>>>8 // 2^{3}
At level 4 Number of nodes possible--------->>>>>16 // 2^{4}
so Ultimately we can generalize it like at Level H (height) Number of nodes possible--------->>>>> 2^{H}
So to know total possible number of nodes add the maximum possible nodes at each individual level
Total number of possible nodes in level 'H' binary tree ---->>> 2^{0}+2^{1}+2^{2}+2^{3}+2^{4}.....+2^{H}
So maximum nodes possible would be 2^{h+1}-1
so n<= 2^{h+1}-1 Now the log work you can do..