OFFSET
1,4
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
Multiplicative with a(p) = 1 and a(p^e) = 2^A000120(e) for e >= 2.
a(n) >= 1, with equality if and only if n is squarefree (A005117).
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = Product_{p prime} f(1/p) = 1.89684906463124350536..., where f(x) = (1-x) * (Product_{k>=0} (1 + 2*x^(2^k)) - x).
MATHEMATICA
f[p_, e_] := If[e == 1, 1, 2^DigitCount[e, 2, 1]]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
PROG
(PARI) a(n) = vecprod(apply(x -> if(x == 1, 1, 2^hammingweight(x)), factor(n)[, 2]));
CROSSREFS
KEYWORD
nonn,easy,mult
AUTHOR
Amiram Eldar, Dec 12 2023
STATUS
approved