What is the sum of the squares of the first $n$ primes - in other words, what is:
$$\sum_{p=1}^n{ \left( \text{Prime}(p)^2 \right)}$$
Of course we're looking for the asymptotic bounds, not an actual formula.
What is the sum of the squares of the first $n$ primes - in other words, what is:
$$\sum_{p=1}^n{ \left( \text{Prime}(p)^2 \right)}$$
Of course we're looking for the asymptotic bounds, not an actual formula.
Based on this other question (and the MathOverflow post linking to it), we have as a direct consequence of the Prime Number Theorem that $$ \sum_{\substack{p\text { prime}\\ p\leq n}} p^2 = \operatorname{Li}(n^3)+ O(n^3e^{-c\sqrt{\ln x}})\operatorname*{\sim}_{n\to\infty} \frac{n^3}{3\ln n} $$ for some constant $c>0$, where $\operatorname{Li}$ is the logarithmic integral.
$$ \sum_{x\leq N} x^2 \mathbb{1}{\text{prime}}(x)\approx\frac{N^3}{\log N}-\sum{2\leq x\leq N-1}\frac{x(2x+1)}{\log x}=\frac{N^3}{3\log N}+O\left(\frac{N^3}{\log^2 N}\right) $$
– Jack D'Aurizio Oct 21 '17 at 17:52