A306198 Multiplicative with a(p^e) = p^(e-1)*(p^2 - p - 1).
1, 1, 5, 2, 19, 5, 41, 4, 15, 19, 109, 10, 155, 41, 95, 8, 271, 15, 341, 38, 205, 109, 505, 20, 95, 155, 45, 82, 811, 95, 929, 16, 545, 271, 779, 30, 1331, 341, 775, 76, 1639, 205, 1805, 218, 285, 505, 2161, 40, 287, 95, 1355, 310, 2755, 45, 2071, 164, 1705, 811
Offset: 1
Links
- Jianing Song, Table of n, a(n) for n = 1..10000
- Eric Weisstein's World of Mathematics, Artin's constant.
- Wikipedia, Artin's conjecture on primitive roots.
Programs
-
Maple
P := (p, e) -> p^(e-1)*(p^2 - p - 1): a := n -> mul(P(f[1], f[2]), f in ifactors(n)[2]): seq(a(n), n=1..58); # Peter Luschny, Feb 13 2019
-
Mathematica
a[n_] := Product[{p, e} = pe; p^(e-1) (p^2-p-1), {pe, FactorInteger[n]}]; a[1] = 1; Array[a, 58] (* Jean-François Alcover, Jul 22 2019 *)
-
PARI
a(n) = my(f=factor(n)); prod(j=1, #f[, 1], my(p=f[j, 1], e=f[j, 2]); (p^2 - p - 1)*p^(e-1))
Formula
Sum_{k=1..n} a(k) ~ c * n^3, where c = (Pi^2/18) * Product_{p prime} (1 - 3/p^2 + 1/p^3 + 1/p^4) = 0.1314639252... . - Amiram Eldar, Dec 01 2022
Comments