Sum and Product inversion Under what conditions on $a_{i,j}$ when $i\in\{1,2...,n\}$ and $j\in\{1,2...,m\}$  this relation holds:
$$\sum_{i=1}^{n}{\prod_{j=1}^{m}{a_{i,j}}}= \prod_{j=1}^{m}{\sum_{i=1}^{n}{a_{i,j}}}$$
Addendum
The context is the following. In this proof of Euler’s Identity i.e $\sum_{d|n}{\phi(d)}=n$ this inversion is used that’s why my question.
By unique factorisation theorem:
$n=\prod_{k=1}^{m}{p_k^{\alpha_k}}$ and $d=\prod_{k=1}^{m}{p_k^{\beta_k}}$ where $0\leq \beta_k\leq \alpha_k$ so: 
\begin{align}
\sum_{d|n}{\phi(d)}&=\sum_{0\leq \beta_k\leq \alpha_k}{\phi\left(\prod_{k=1}^{m}{p_k^{\beta_k}}\right)}\\
&= \sum_{0\leq \beta_k\leq \alpha_k}{\prod_{k=1}^{m}\phi({p_k^{\beta_k})}}\\
&=\sum_{0\leq \beta_k\leq \alpha_k}{\prod_{k=1}^{m}{(p_k^{\beta_k}-p_k^{\beta_k-1}})}\\
&=\prod_{k=1}^{m}{\sum_{0\leq \beta_k\leq \alpha_k}{(p_k^{\beta_k}-p_k^{\beta_k-1}}})\\
&= \prod_{k=1}^{m}{p_k^{\alpha_k}}\\
&=n.
\end{align}
 A: The proof only uses the multiplicativity of the $\ \phi()\ $ function. Suppose that $\ f()\ $ is any multiplicative function, $\ p\ $ and $\ q\ $ are any two primes, and $\ n = p q^2.$ By definition of summation over divisors
$$ \sum_{d|n}\ f(d) = f(1) + f(p) + f(q) + f(p\ q) + f(q^2) + f(p\ q^2), \tag{1} $$ and then by definition of multiplicativity of $\ f()\ $
$$ = f(1) + f(p) + f(q) + f(p)f(q) + f(q^2) + f(p)f(q^2), \tag{2} $$
and by the distributivity of multiplication over addition we get
$$ = (f(1) + f(p))(f(1) + f(q) + f(q^2)) \tag{3} $$
which can be written using summation over divisors as
$$ = \Big(\sum_{u|p}\ u\Big)\Big(\sum_{v|q^2}\ v\Big). \tag{4} $$
The general case for any positive integer $\ n\ $ is exactly similar. 
A: Let's try a simple case
$n=m=2$.
$\sum_{i=1}^{n}{\prod_{j=1}^{m}{a_{i,j}}}= \prod_{j=1}^{m}{\sum_{i=1}^{n}{a_{i,j}}}
$
becomes
$$\sum_{i=1}^{2}{\prod_{j=1}^{2}{a_{i,j}}}
= \prod_{j=1}^{2}{\sum_{i=1}^{2}{a_{i,j}}}
$$
or
$$\sum_{i=1}^{2}a_{i,1}a_{i,2}
= \prod_{j=1}^{2}(a_{i,1}+a_{i,2})
$$
or
$$a_{1,1}a_{1,2}+a_{2,1}a_{2,2}
= (a_{1,1}+a_{1,2})(a_{2,1}+a_{2,2})
$$
Writing $a, b, c, d$
for the indexed values,
this is
$$ab+cd
= (a+b)(c+d)
=ac+ad+bc+bd
$$
or
$ab-ac-ad
=bc+bd-cd
$
or
$a(b-c-d)
=bc+bd-cd
$
or
$a
=\dfrac{bc+bd-cd}{b-c-d}
$.
Essentially,
you can solve for
one of the variables
in terms of the others.
I'm not sure
if this means anything else.
