A101787 a(n) = |S(n)| where S(n) = {i : 1 <= i <= n and 4*i-1 and 8*i-1 are primes}.
1, 1, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10
Offset: 1
Programs
-
Mathematica
Accumulate[Table[Boole[And @@ PrimeQ[{4, 8}*i - 1]], {i, 1, 100}]] (* Amiram Eldar, May 23 2024 *)
Extensions
Name corrected by Amiram Eldar, May 23 2024
Comments