OFFSET
0,2
COMMENTS
Nearest integer to sqrt(pi(10^n)) where pi(10^n) is the number of primes < 10^n (A006880).
FORMULA
a(n) = round(sqrt(A006880(n))).
MATHEMATICA
Array[Round@ Sqrt@ PrimePi[10^#] &, 17, 0] (* Michael De Vlieger, Mar 19 2021 *)
PROG
(PARI) a(n) = round(sqrt(primepi(10^n))); \\ Michel Marcus, Mar 19 2021
(Python)
from math import isqrt
from sympy import primepi
def A221205(n): return (m:=isqrt(k:=int(primepi(10**n))))+int(k-m*(m+1)>=1) # Chai Wah Wu, Jul 31 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Pletser, Jan 04 2013
EXTENSIONS
a(21) to a(24) added by Vladimir Pletser, Feb 27 2013 (recovered by Georg Fischer, Jan 20 2019)
a(25)-a(28), obtained using A006880, added by Eduard Roure Perdices, Apr 16 2021
a(29), obtained using A006880, added by Chai Wah Wu, Jul 31 2022
STATUS
approved