OFFSET
0,3
COMMENTS
REFERENCES
B. Fine and G. Rosenberger, Number theory: an introduction via the distribution of primes, Birkhäuser, Boston, Basel, Berlin, 2007.
LINKS
Indranil Ghosh, Table of n, a(n) for n = 0..1000
FORMULA
a(n) = number of positive numbers <= n relatively prime to 7, n >= 1. a(0)=1.
a(n) = Sum_{k=1..n} A109720(k), n >= 1.
a(n) = Sum_{d|7} mu(d)*floor(n/d), n >= 1, with the Moebius function mu(n) = A008683(n) (Legendre formula for the sieve of Eratosthenes (here for m=7). See, e.g., the Fine and Rosenberger reference, p. 200.
O.g.f.: x*(1+x+x^2+x^3+x^4+x^5)/((1-x^7)*(1-x)).
a(n) = ceiling(6*n/7) = n - floor(n/7). - Wesley Ivan Hurt, Sep 29 2017
Sum_{n>=1} (-1)^(n+1)/a(n) = (15 - 4*sqrt(3))*Pi/36. - Amiram Eldar, Sep 30 2022
MATHEMATICA
Table[Sum[MoebiusMu[d] Floor[n/d], {d, Divisors[7]}], {n, 0, 74}] (* Indranil Ghosh, Mar 15 2017 *)
PROG
(PARI) for(n=0, 74, print1(sumdiv(7, d, moebius(d) * floor(n/d)), ", ")) \\ Indranil Ghosh, Mar 15 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Wolfdieter Lang Feb 05 2009
STATUS
approved