[Math] Proving that the height of a 2-3 tree is between $\log_3 N$ and $\lg N$

algorithmstrees

I am stuck on the problem of trying to prove the upper and lower bounds of a 2-3 tree. I think the most natural recourse is to use induction. However, my instructor told me that this was unnecessary and messy.

For those who are unfamiliar with 2-3 trees, its a tree which guarantees $\lg N$ height by grouping at most two elements in a node, thereby ensuring that each level is filled with the maximum number of leaves.

Here is what I have so far: The minimum height occurs in a 2-3 tree only when each node is a 3 node. The maximum height occurs only when each node is a 2 node.

For the lower bound where all nodes are 3 nodes, then the number of elements at each level can be determined by $2 \times 3^h$ where $h$ is the height of the level.
Therefore, the total amount of nodes for a given $h$ should be $\sum\limits_{i=0}^h 2\times 3^h$.

From here I am stuck and I don't know how to go on.

Best Answer

Hint: a tree of height $h$ has at least $1+2+\cdots+2^h = 2^{h+1}-1$ nodes and at most $1+3+\cdots+3^h = (3^{h+1}-1)/2$ nodes, i.e. $$ 2^{h+1}-1 \leq N \leq \frac{3^{h+1}-1}{2}. $$