Tuesday 19 September 2017

Sum of the first n Prime numbers



Let $P_i$ denote the i-th prime number. Is there any formula for expressing



$$S= \sum_{i=1}^m P_i.$$




We know that there are around $\frac{P_m}{\ln(P_m)}$ prime numbers less than or equal to $P_m$. So, we have:



$$S\le m\times P_m\le \frac{P_m^2}{\ln(P_m)}.$$



I want to know, if there is a better bound for $S$, in the litrature.


Answer



Summation by parts gives
$$
\begin{align}

\sum_{p\le n}p
&=\sum_{k=1}^n(\pi(k)-\pi(k-1))\,k\\
&=n\,\pi(n)+\sum_{k=1}^{n-1}\pi(k)(k-(k+1))\\
&=n\,\pi(n)-\sum_{k=1}^{n-1}\pi(k)\tag{1}
\end{align}
$$
We have that $\pi(k)=\dfrac{k}{\log(k)}\left(1+O\left(\frac1{\log(k)}\right)\right)$ and so using the Euler-Maclaurin Sum Formula, we get that
$$
\sum_{k=1}^{n-1}\pi(k)=\frac12\frac{n^2}{\log(n)}+O\left(\frac{n^2}{\log(n)^2}\right)\tag{2}
$$

Therefore, we get
$$
\sum_{p\le n}p=\frac12\frac{n^2}{\log(n)}+O\left(\frac{n^2}{\log(n)^2}\right)\tag{3}
$$
Setting $n=P_m$ should give you a closer estimate.


No comments:

Post a Comment

real analysis - How to find $lim_{hrightarrow 0}frac{sin(ha)}{h}$

How to find $\lim_{h\rightarrow 0}\frac{\sin(ha)}{h}$ without lhopital rule? I know when I use lhopital I easy get $$ \lim_{h\rightarrow 0}...