Generalized Sum with Finite Non-zero Summands

Theorem
Let $G$ be a commutative topological semigroup with identity $0_G$.

Let $I$ be an indexing set.

Let $g : I \to G$ be a mapping.

Let $n \in \N$.

Let $\sequence{i_1, i_2, \cdots, i_n}$ be a finite sequence in $I$:
 * $\set{g_{i_1}, g_{i_2}, \cdots, g_{i_n}} = \set{g_i \in G : i \in I, g_i \ne 0_G}$

Then the generalized sum $\ds \sum_{i \in I} g_i$ converges and:
 * $\ds \sum_{i \in I} g_i = \sum_{j = 1}^n g_{i_j}$