OFFSET
1,4
COMMENTS
a(n) is the number of terms of A084087 not exceeding n.
The construction of the largest subset is to choose all numbers n/3 < m <= n such that the 2-valuation of m is even.
LINKS
Paolo Xausa, Table of n, a(n) for n = 1..10000
FORMULA
Limit_{n->oo} a(n)/n = 4/9.
EXAMPLE
For n = 7, the largest such subset is {3, 4, 5, 7}, so a(7) = 4.
MATHEMATICA
Array[A394865, 100] (* Paolo Xausa, Jun 17 2026 *)
(* Alternative: *)
Accumulate[Array[Boole[!Divisible[#, 3] && EvenQ[IntegerExponent[#, 2]]] &, 100]] (* Paolo Xausa, Jun 17 2026 *)
PROG
(PARI) lista(nn) = {my(cnt = 0); for(n = 1, nn, if(gcd(n, 3) == 1 && valuation(n, 2) % 2 == 0, cnt++); if(n > 1, print1(", ")); print1(cnt); ); }
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Yifan Xie, Jun 12 2026
STATUS
approved
