OFFSET
1
COMMENTS
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..100000
FORMULA
a(n) = [A053669(n) == -1 (mod 6)], where [ ] is the Iverson bracket.
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = Sum_{p prime, p == 5 (mod 6)} ((p-1)/(Product_{q prime, q <= p} q)) = 0.1376937818... . - Amiram Eldar, Apr 16 2024
EXAMPLE
For n = 6 = 2*3, the smallest prime that does not divide it is 5, which is of the form 6m-1, therefore a(6) = 1.
For n = 30 = 2*3*5, the smallest prime that does not divide it is 7, which is of the form 6m+1, therefore a(30) = 0.
For n = 210 = 2*3*5*7, the smallest prime that does not divide it is 11, which is of the form 6m-1, therefore a(210) = 1.
For n = 2310 = 2*3*5*7*11, the smallest prime that does not divide it is 13, which is of the form 6m+1, therefore a(2310) = 0.
For n = 30030 = 2*3*5*7*11*13, the smallest prime that does not divide it is 17, which is of the form 6m-1, therefore a(30030) = 1.
For n = 223092870 = 2*3*5*7*11*13*17*19*23, the smallest nondividing prime is 29, which is of the form 6m-1, therefore a(223092870) = 1. This is also the least n where this sequence differs from the characteristic function of the even terms of A342051, (numbers k such that k is even and A276084(k) is also even).
MATHEMATICA
a[n_] := Module[{p = 2}, While[Divisible[n, p], p = NextPrime[p]]; Boole[Mod[p, 6] == 5]]; Array[a, 100] (* Amiram Eldar, Apr 16 2024 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Dec 03 2022
STATUS
approved