A360969 Multiplicative with a(p^e) = e^2, p prime and e > 0.
1, 1, 1, 4, 1, 1, 1, 9, 4, 1, 1, 4, 1, 1, 1, 16, 1, 4, 1, 4, 1, 1, 1, 9, 4, 1, 9, 4, 1, 1, 1, 25, 1, 1, 1, 16, 1, 1, 1, 9, 1, 1, 1, 4, 4, 1, 1, 16, 4, 4, 1, 4, 1, 9, 1, 9, 1, 1, 1, 4, 1, 1, 4, 36, 1, 1, 1, 4, 1, 1, 1, 36, 1, 1, 4, 4, 1, 1, 1, 16, 16, 1, 1, 4
Offset: 1
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
f:= proc(n) local t; mul(t^2, t = ifactors(n)[2][..,2]); end proc: map(f, [$1..100]); # Robert Israel, Mar 29 2023
-
Mathematica
g[p_, e_] := e^2; a[1] = 1; a[n_] := Times @@ g @@@ FactorInteger[n]; Array[a, 100]
-
PARI
for(n=1, 100, print1(direuler(p=2, n, (1 - 2*X + 4*X^2 - X^3)/(1-X)^3)[n], ", "))
-
PARI
a(n) = my(f=factor(n)); for (k=1, #f~, f[k, 1]=f[k,2]^2; f[k, 2]=1); factorback(f); \\ Michel Marcus, Feb 27 2023
Formula
Dirichlet g.f.: zeta(s) * Product_{primes p} (1 + (3*p^s - 1) / (p^s*(p^s - 1)^2)).
Sum_{k=1..n} a(k) ~ c*n, where c = Product_{primes p} (1 + (3*p - 1) / (p*(p-1)^2)) = 8.18840474382698544967326709964388539461401085196013492328186138...
a(n) = A005361(n)^2.
Comments