# Show an $R$-module is an internal direct sum

Let $M$ be an $R$-module and $M_1,...,M_n$ be $R$-submodules of $M$. Show that $M = \oplus_{i=1}^n M_i$ if and only if there exists $R$-homomorphisms $\iota_i: M_i \to M$ and $\pi_i : M \to M_i$, $i =1,...,n$, satisfying all of the following:

(i) $\pi_i \iota_i = 1_{M_i}$for $i =1 ,...,n$.

(ii) $\pi_j \iota_i = 0$ for $i \neq j$.

(iii) $\iota_1 \pi_1 + ... + \iota_n \pi_n = 1_{ M }$.

The ''only if '' part is easy and I already done this part.

But I have trouble show the ''if '' part. I tried a lot but the best I can do is to show that $M = \oplus_{i=1}^n \text{ Im } ( \iota_i)$. Any help is appreciated.

• Is (s)he? Note that the $M_i$ are submodules of $M$. It's certainly possible for im $\iota_i \neq M_i$ if some of the $M_i$ are isomorphic (though this doesn't necessarily break the final result). Commented Feb 20, 2014 at 17:40
• Yes, that's the trouble I'm facing. Do you have any ideas how to fix it? Commented Feb 20, 2014 at 19:06

The statement is not correct$^1$. Here are two correct ones (which you have already proven):
1) Let $M_1,...,M_n$ be submodules of $M$. Let us denote by $\iota_i : M_i \to M$ the inclusion. Then $M = \oplus_i M_i$ (internal direct sum) iff there are $\pi_i : M \to M_i$ such that (i),(ii),(iii) hoold.
2) Let $M_1,\dotsc,M_n$ be modules. Then $M \cong \oplus_i M_i$ (external direct sum) iff there are $\iota_i : M_i \to M$ and $\pi_i : M \to M_i$ such that (i),(ii),(iii) hold.
$^1$Of course, 1 is not correct if we don't specify $\iota_i$ to be the inclusion. For example, let $M=R^2$, $M_1=M_2=R \times 0$. Then there are $\iota_1,\iota_2,\pi_1,\pi_2$ such that (i),(ii),(iii) hold (namely $\iota_1$ is the inclusion, whereas $\iota_2$ maps $(r,0)$ to $(0,r)$, etc.), but $M$ is not the internal direct sum of $M_1$ and $M_2$ (when $R \neq 0$).