OFFSET
1,5
COMMENTS
Convolution of A000720 with itself.
LINKS
Mathematics Stack Exchange, A curious equality of integrals involving the prime counting function?
Eric Weisstein's World of Mathematics, Prime Counting Function
FORMULA
G.f.: (1/(1 - x)^2) * (Sum_{k>=1} x^prime(k))^2.
a(n) = Sum_{k=1..n} k * A073610(n-k+1).
From Jianing Song, Sep 27 2023: (Start)
a(n-1) = Integral_{0..n} pi(x) * pi(n-x) dx, since Integral_{0..n} pi(x) * pi(n-x) dx = Sum_{k=1..n} Integral_{k-1..k} pi(x) * pi(n-x) dx = Sum_{k=1..n} pi(k-1) * pi(n-k) = Sum_{k=0..n-1} pi(k) * pi(n-1-k) = a(n-1).
a(n) = (a(n-1) + a(n+1))/2 for n == 4 (mod 6) with n > 4, as shown in the Mathematics Stack Exchange link. (End)
MATHEMATICA
Table[Sum[PrimePi[k] PrimePi[n - k], {k, n}], {n, 50}]
nmax = 50; CoefficientList[Series[(1/(1 - x)^2) Sum[x^Prime[k], {k, 1, nmax}]^2, {x, 0, nmax}], x] // Rest
PROG
(PARI) a(n) = sum(k=1, n, primepi(k)*primepi(n-k)); \\ Michel Marcus, Apr 03 2020
CROSSREFS
KEYWORD
nonn
AUTHOR
Ilya Gutkovskiy, Apr 02 2020
STATUS
approved