Statistical theory of two-dimensional grain growth—I. The topological foundation