Sum of products equals product of sums

772 Views Asked by At

Let $I_1,\dots,I_n$ be finite index sets and $a_i$ be real numbers. This might be a rather easy question, but I do not see how to prove that \begin{equation} \sum_{(i_1,\dots,i_n)\in I_1\times\dots\times I_n} a_{i_1}a_{i_2}\dots a_{i_n} = \left(\sum_{i_1\in I_1} a_{i_1}\right) \dots\left(\sum_{i_n\in I_n} a_{i_n}\right) \end{equation} holds. The formula is also mentioned in this post as a generalized distributive law. It is heuristically clear to me why the formula holds, but I do not see how to come up with a proof. Thanks in advance.