How to find sum of $\sum_{n=1}^{\infty }\frac{(n)\mod(k)}{n(n+1)}$ I know that if $n \bmod k \le k-1$ then this sum is converge then it has finite sum, I just guess it's $\ln(k)$ because when $k=1$ sum is $0=ln(1)$. I really don't know how to find it. Please help me.
 A: Continuing xpaul's answer
\begin{align*}
& \sum\limits_{r = 1}^{k - 1} {\frac{r}{k}\left[ {\psi ^{(0)} \left( {\frac{{r + 1}}{k}} \right) - \psi ^{(0)} \left( {\frac{r}{k}} \right)} \right]}  = \sum\limits_{r = 1}^{k - 1} {\frac{r}{k}\psi ^{(0)} \left( {\frac{{r + 1}}{k}} \right)}  - \sum\limits_{r = 1}^{k - 1} {\frac{r}{k}\psi ^{(0)} \left( {\frac{r}{k}} \right)} 
\\ &
 = \sum\limits_{r = 1}^{k - 1} {\frac{{r + 1}}{k}\psi ^{(0)} \left( {\frac{{r + 1}}{k}} \right)}  - \sum\limits_{r = 1}^{k - 1} {\frac{r}{k}\psi ^{(0)} \left( {\frac{r}{k}} \right)}  - \sum\limits_{r = 1}^{k - 1} {\frac{1}{k}\psi ^{(0)} \left( {\frac{{r + 1}}{k}} \right)} 
\\ &
 = \sum\limits_{r = 2}^k {\frac{r}{k}\psi ^{(0)} \left( {\frac{r}{k}} \right)}  - \sum\limits_{r = 1}^{k - 1} {\frac{r}{k}\psi ^{(0)} \left( {\frac{r}{k}} \right)}  - \frac{1}{k}\sum\limits_{r = 2}^k {\psi ^{(0)} \left( {\frac{r}{k}} \right)} 
\\ &
 = \psi ^{(0)} (1) - \frac{1}{k}\sum\limits_{r = 1}^k {\psi ^{(0)} \left( {\frac{r}{k}} \right)}  =  - \gamma  + \gamma  + \log k = \log k.
\end{align*}
A: Note that $n=mk+r$, $r=0,1,\cdots k-1$. So
\begin{eqnarray}
&&\sum_{n=1}^{\infty }\frac{(n)\mod(k)}{n(n+1)}=\sum_{m=0}^{\infty }\sum_{r=1}^{k-1}\frac{(mk+r)\mod(k)}{(mk+r)(mk+r+1)}\\
&=&\sum_{m=0}^{\infty }\sum_{r=1}^{k-1}\frac{r}{(mk+r)(mk+r+1)}=\sum_{r=1}^{k-1}r\sum_{m=0}^{\infty }\frac{1}{(mk+r)(mk+r+1)}\\
&=&\sum_{r=1}^{k-1}r\sum_{m=0}^{\infty }\bigg(\frac{1}{mk+r}-\frac{1}{mk+r+1}\bigg)=\sum_{r=1}^{k-1}\frac{r}{k}\sum_{m=0}^{\infty }\bigg(\frac{1}{m+\frac{r}{k}}-\frac{1}{m+\frac{r+1}{k}}\bigg)\\
&=&\sum_{r=1}^{k-1}\frac{r}{k}\sum_{m=1}^{\infty }\bigg(\frac{1}{m+\frac{r}{k}-1}-\frac{1}{m+\frac{r+1}{k}-1}\bigg)\\
&=&\sum_{r=1}^{k-1}\frac{r}{k}\sum_{m=1}^{\infty }\bigg[\bigg(\frac1m-\frac{1}{m+\frac{r+1}{k}-1}\bigg)-\bigg(\frac{1}{m}-\frac{1}{m+\frac{r}{k}-1}\bigg)\bigg]\\
&=&\sum_{r=1}^{k-1}\frac{r}{k}\bigg[\psi ^{(0)}\left(\frac{r+1}{k}\right)-\psi ^{(0)}\left(\frac{r}{k}\right)\bigg].
\end{eqnarray}
Here the Digamma function
$$ \psi^{(0)}(z+1)=-\gamma+\sum_{n=1}^\infty\bigg(\frac1n-\frac{1}{n+z}\bigg) $$
is used from here. 
Update: Now @Gary proves
$$ \sum_{r=1}^{k-1}\frac{r}{k}\bigg[\psi ^{(0)}\left(\frac{r+1}{k}\right)-\psi ^{(0)}\left(\frac{r}{k}\right)\bigg]=\ln k. $$
Thank you, Gary.
A: Also,  @xpaul 's computation shows that the initial sum is asymptotically equal to $\log k$. Indeed, @xpaul derived
\begin{eqnarray}
&&\sum_{n=1}^{\infty }\frac{(n)\mod(k)}{n(n+1)}=\sum_{m=0}^{\infty }\sum_{r=1}^{k-1}\frac{(mk+r)\mod(k)}{(mk+r)(mk+r+1)}\\
&=&\sum_{m=0}^{\infty }\sum_{r=1}^{k-1}\frac{r}{(mk+r)(mk+r+1)}=\sum_{r=1}^{k-1}r\sum_{m=0}^{\infty }\frac{1}{(mk+r)(mk+r+1)}
\end{eqnarray}
and we can estimate the inner sum as follows
$$
\frac{1}{r(r+1)}<\sum_{m=0}^{\infty }\frac{1}{(mk+r)(mk+r+1)}< \frac{1}{r(r+1)} + 
\sum_{m=1}^{\infty }\frac{1}{(mk)^2}< \frac{1}{r(r+1)}+\frac{10}{k^2}.
$$
Plugging this to the previous expression we get
\begin{align*}
\sum_{n=1}^{\infty }\frac{(n)\mod(k)}{n(n+1)}=\sum_{r=1}^{k-1}\frac{1}{r+1}+\mathcal{O}(k^{-1})=\log k +\mathcal{O}(1)
\end{align*}
A: Using the same ideas as in a recent answer (https://math.stackexchange.com/a/4024522/198592) here is a solution which is very close to that of @xpaul and @Gary but more elementary in the final step (without polygamma functions).
We will prove that
$$s(k):=\sum _{n=1}^{\infty } \frac{n \bmod k}{n (n+1)}=\log (k)\tag{1}$$

*

*simplify the mod function letting

$$n = m k +j, m=0,1,2,..., j=1, 2, ..., k-1\tag{2}$$
notice that $j$ runs only up to $k-1$ because $(m k + k) mod(k) = 0$.
Then  $n \bmod k = j$ and defining
$$u(k,j) = \sum_{m=0}^{\infty} \frac{j}{(m k+j)(m k+j+1)}\tag{3}$$
we get
$$s(k) = \sum_{j=1}^{k-1} u(k,j)\tag{4}$$


*Calculate $u$
Instead of doing the $m$-sum directly which leads to polygamma functions we prefer to represent denominators by integrals using the formula $\frac{1}{a}=\int_{0}^{\infty} e^{-a t}\,dt$
After partial fraction decomposition
$$\frac{j}{(j+k m) (j+k m+1)}=\frac{j}{j+k m}-\frac{j}{j+k m+1}$$
this gives after also doing the $m$-sum
$$u(k,j) = \int_{0}^{\infty} j\sum_{m=0}^{\infty}\left(e^{-t(j+m k)}-e^{-t(1+j+m k)}  \right)\,dt=\int_{0}^{\infty} j\left( \frac{e^{k t-j t}}{e^{k t}-1}-\frac{e^{k t-(j+1) t}}{e^{k t}-1}\right)\,dt\tag{5}$$


*do the $j$-sum under the integral gives for the integrand

$$\sum_{j=1}^{k-1} j\left( \frac{e^{k t-j t}}{e^{k t}-1}-\frac{e^{k t-(j+1) t}}{e^{k t}-1}\right) = \frac{k \left(-e^t\right)+e^{k t}+k-1}{\left(e^t-1\right) \left(e^{k t}-1\right)}=\frac{1}{e^t-1}-\frac{k}{e^{k t}-1}\tag{6}$$


*the final step is to calculate the $t$-integral

$$s(k) = i(k) := \int_{0}^{\infty} \left(\frac{1}{e^t-1}-\frac{k}{e^{k t}-1}\right)\,dt\tag{7}$$
The indefinte integral (antderivative) is
$$a(t) = \int \left(\frac{1}{e^t-1}-\frac{k}{e^{k t}-1}\right)\,dt\\
=-t+k t+\log \left(\frac{e^t-1}{e^{k t}-1}\right)\tag{8}$$
and for the limits at the integration boundaries we find
$$a(t \to \infty) = 0, a(t \to 0) = \log(\frac{1}{k})\tag{9}$$
Hence the integral $(7)$ becomes $i(k)=\log(k)$ which completes the proof.
Details of the limits
$$\begin{align}
a(t \to 0) : 
& -t + k t+\log \left(\frac{e^t-1}{e^{k t}-1}\right)\\
& \to  \log \left(\frac{\left(1+t+...\right)-1}{\left(1+k t +...\right)-1}\right)\\
& \to \log \left(\frac{1}{k}\right)
\end{align}\tag{10a}$$
$$\begin{align}
a(t \to \infty) : 
& -t + k t+\log \left(\frac{e^t-1}{e^{k t}-1}\right)\\
& \to -t +k t+\log \left(\frac{e^t \left(1-e^{-t}\right)}{e^{k t} \left(1-e^{-k t}\right)}\right)\\
& \to -t+k t+\log \left(\frac{e^t}{e^{k t}}\right)+\log \left(\frac{1-e^{-t}}{1-e^{-k t}}\right)\\
& = \log \left(\frac{1-e^{-t}}{1-e^{-k t}}\right) \to 0
\end{align}\tag{10b}$$
Discussion
The integral $i(k)$ extends the domain of $s(k)$ to real values of $k$.
A: My idea is:
$\sum \frac{nmodk}{n(n+1)}=\frac{1}{1.2}+\frac{2}{2.3}+...+\frac{k-1}{(k-1)k}+...=\frac{1}{1}-\frac{1}{2}+\frac{2}{2}-\frac{2}{3}+...$
$=(\frac{\:1}{1\:}+\frac{1}{2}+\frac{1}{3}+...+\frac{1}{k-1}+\frac{k-1}{k})+(\frac{\:1}{k+1\:}+\frac{1}{k+2}+\frac{1}{k+3}+...+\frac{1}{2k-1}+\frac{k-1}{2k})+...$
$=\sum _{n=1}^{\infty }\left(\frac{1}{\left(n-1\right)k+1}+\frac{1}{\left(n-1\right)k+2}+...+\frac{1}{\left(n-1\right)k+k-1}-\frac{k-1}{\left(n-1\right)k+k}\right)$
But it still not work
