This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A381018 #12 Feb 13 2025 12:16:19 %S A381018 1,2,3,3,3,4,5,6,6,7,7,7,7,8,9,10,10,11,12,12,13,13,13,13,13,13,13,13, %T A381018 13,13,14,15,15,15,16,16,16,17,17,17,18,18,18,18,19,19,19,20,20,20,20, %U A381018 20,20,20,20,20,20,20,20,20,21,21,21,22,22,22,22,22,22,23,23,23 %N A381018 a(n) is the number of primes in A000328 for r <= n. %C A381018 Number of Gauss circle primes for r <= n. %H A381018 Thomas Ehrenborg, <a href="https://arxiv.org/abs/2502.06804">Gauss Circle Primes</a>, arXiv:2502.06804 [math.GM], 2025. See Table 2 p. 4. %o A381018 (PARI) a(n) = sum(k=0, n, isprime(1 + 4*sum(j=0, k^2\4, k^2\(4*j+1) - k^2\(4*j+3)))); %o A381018 (Python) %o A381018 from math import isqrt %o A381018 from sympy import isprime %o A381018 def A381018(n): return sum(1 for m in range(1,n+1) if isprime(1+(sum(isqrt(k*((m<<1)-k)) for k in range(1,m+1))<<2))) # _Chai Wah Wu_, Feb 13 2025 %Y A381018 Cf. A000328, A000720, A381017, A381020. %K A381018 nonn %O A381018 1,2 %A A381018 _Michel Marcus_, Feb 12 2025