Let $(R, +, \cdot)$ be a ring with identity $1_R$ and consider the ring of integers $(\mathbb Z, +, \cdot)$ with the usual operations.
Define the map $f:\mathbb Z\longrightarrow R$ as:
$$f(m):=\left\{\begin{array}{lcl} \underbrace{1_R+\ldots+1_R}_m & \textrm{if}& m>0\\ 0 & \textrm{if} & m=0\\ \underbrace{-1_R-\ldots-1_R}_{-m} & \textrm{if} &m<0 \end{array}\right..$$ How can I show that $\mathsf{Ker}(f)=n\mathbb Z$ where $n$ is the characteristic of $R$?
The inclusion $n\mathbb Z\subset \mathsf{Ker}(f)$ is immediate but how about the reverse inclusion?
Thanks
Remark. The characteristic of a ring is the least positive integer $n$ such that:
$$\underbrace{1_R+\ldots+1_R}_n=0.$$ If there is not such integer, we say the ring has zero characteristic.
Let $m\in\mathbb Z$ and suppose that $m\in\ker f$. Write $m$ as $qn+r$, with $r\in\{0,1,\ldots,n-1\}$. Then$$0=f(m)=f(qn+r)=f(r),$$since $f(n)=0$. But you can't have $f(r)=0$ unless $r=0$, since otherwise $r\in\{1,2,\ldots,n-1\}$. So, $r=0$, and it follows then from $m=bq+r$ that $m\in n\mathbb Z$.