OFFSET
1,2
COMMENTS
Number of divisors of n not congruent to 0 mod 5.
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
Multiplicative with a(5^e)=1 and a(p^e)=e+1 for p<>5.
Moebius transform is period 5 sequence A011558. - Michael Somos, Oct 31 2006
G.f.: Sum_{k>=1} x^k*(1 + x^k + x^(2*k) + x^(3*k))/(1 - x^(5*k)). - Ilya Gutkovskiy, Sep 11 2019
a(n) = tau(5*n) - tau(n). - Ridouane Oudra, Sep 05 2020
From Amiram Eldar, Nov 27 2022: (Start)
Dirichlet g.f.: zeta(s)^2 * (1 - 1/5^s).
Sum_{k=1..n} a(k) ~ (4*n*log(n) + (8*gamma + log(5) - 4)*n)/5, where gamma is Euler's constant (A001620). (End)
MAPLE
for n from 1 to 500 do a := ifactors(n):s := 1:for k from 1 to nops(a[2]) do p := a[2][k][1]:e := a[2][k][2]: if p=5 then b := 1:else b := e+1:fi:s := s*b:od:printf(`%d, `, s); od:
MATHEMATICA
Table[Count[Divisors[n], _?(!Divisible[#, 5]&)], {n, 110}] (* Harvey P. Dale, Apr 08 2015 *)
f[5, e_] := 1; f[p_, e_] := e+1; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 26 2020 *)
PROG
(PARI) {a(n)=if(n<1, 0, sumdiv(n, d, d%5>0))} /* Michael Somos, Oct 31 2006 */
(PARI) {a(n)=if(n<1, 0, direuler(p=2, n, 1/(1-X)/if(p==5, 1, 1-X))[n])} /* Michael Somos, Oct 31 2006 */
(Magma) [NumberOfDivisors(n)/Valuation(5*n, 5): n in [1..100]]; // Vincenzo Librandi, Jun 03 2019
CROSSREFS
KEYWORD
nonn,mult,easy
AUTHOR
EXTENSIONS
Additional comments from Vladeta Jovovic, Oct 26 2001
STATUS
approved