How does Dirichlet regularization assign value $-\frac{1}{12}$ to $\sum_{k=1}^{\infty} k$?
Yes, I know that $\zeta(-1) = - \frac{1}{12}$, a result that follows from the Riemann functional equation $\zeta(s) = 2^s \pi^{s-1} \sin(\frac{\pi s}{2})\, \Gamma(1 - s)\, \zeta(1-s)$.
$$\sum_{n=1}^{\infty}c^n *n$$ look around c=-1 and you got your answer of the dirichlet sum. (-1/4)
$$\sum_{n=1}^{dp} f(n)\sum_{k=1}^{d-1} (e^{\frac{2i\pi k}{d}})^{n}=\sum^p_{n=1} (d f(nd)-f(n))$$
Now we look around the limits here, given $f(n)=n$. We see at d=2 (aka c=-1 above), that it will be equal 3 times $\zeta(-1)$ so $\zeta(-1)=-1/12$