previous up next
Go backward to Example
Go up to Top
Go forward to Summary
RISC-Linz logo

Binary Trees

Proposition: Let T be a tree of height h where every node has an outdegree of at most 2. The number of tree nodes is less than 2h+1:

forall T: (T is tree /\  forall x in V: outdeg(x) <= 2) => |V| < 2h+1
   where V = T0, h = height(T).

Proof: Let T be a such a tree. We proceed by complete induction on the height of T.

  1. Assume the height is h = 0. Then |V| = 1 < 2 = 2h+1.
  2. Assume the height is h > 0. Consequently the root of T has a child that is the root of a tree of height h-1 and possibly a second child that is the root of a tree of height less than or equal h-1. By the induction hypothesis, we thus have
    |V| <= 1+(2h-1)+(2h-1) = 2h+1-1 < 2h+1.

Author: Wolfgang Schreiner
Last Modification: January 26, 2000

previous up next