OFFSET
1,5
LINKS
Gheorghe Coserea, Table of n, a(n) for n = 1..10000
FORMULA
a(n) ~ n/3. - Amiram Eldar, Feb 24 2021
EXAMPLE
The first 10 squarefree numbers are: 1, 2, 3, 5, 6=2*3, 7, 10=2*5, 11, 13 and 14=2*7: 2, 6, 10 and 14 are divisible by 2, therefore a(10)=4.
MATHEMATICA
Accumulate[If[Divisible[#, 2], 1, 0]&/@Select[Range[100], SquareFreeQ]] (* Vincenzo Librandi, Aug 23 2015 *)
PROG
(PARI)
n = 77; k = 0; bag = List(); a = vector(n);
until(n == 0, k++; if (issquarefree(k), listput(bag, k); n--));
for (i=2, #bag, a[i] = a[i-1] + (bag[i] % 2 == 0)); print(a); \\ Gheorghe Coserea, Aug 22 2015
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Jul 08 2002
EXTENSIONS
Name clarified by Gheorghe Coserea, Aug 22 2015
STATUS
approved