[Math] Why does a full binary tree of $n$ leaves have $2n-1$ nodes

graph theory

A complete binary tree is defined as a tree where each node has either $2$ or $0$ children.

A variety of sources have described the relation between nodes and leaves to be $2n-1$ where $n$ is the number of leaves. I haven't however been able to find a description of how this relation was derived.

Best Answer

Any full binary tree can be seen as the structure of a single elimination tournament with $n$ teams corresponding to the leaves. Each non-leaf is a game in which the loser goes home and the winner goes up to the next round. There is one final champion, who wins the root game, and so there must be $(n-1)$ non-leaf nodes since every other team loses exactly once. Hence $n + (n-1) = 2n-1$ nodes altogether.