OFFSET
1,2
COMMENTS
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
Multiplicative with a(p^e) = p^max{k=1..e, k odious}.
a(n) <= n, with equality if and only if n is exponentially odious number (A270428).
Sum_{k=1..n} a(k) ~ c*n^2, where c = (1/2) * Product_{p prime} (1 + Sum_{e>=1} (p^f(e) - p^(f(e-1)+1))/p^(2*e)) = 0.4636829525..., f(e) = max{k=1..e, k odious} for e >= 1, and f(0) = 0.
MATHEMATICA
maxOdious[e_] := Module[{k = e}, While[EvenQ[DigitCount[k, 2, 1]], k--]; k]; f[p_, e_] := p^maxOdious[e]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
PROG
(PARI) s(n) = {my(k = n); while(!(hammingweight(k)%2), k--); k; }
a(n) = {my(f = factor(n)); prod(i = 1, #f~, f[i, 1]^s(f[i, 2])); }
CROSSREFS
KEYWORD
nonn,easy,mult
AUTHOR
Amiram Eldar, Oct 27 2023
STATUS
approved