OFFSET
1,1
LINKS
FORMULA
For n >= 0, a(4n+2) = a(2n+1).
Sum_{k=1..n} a(k) ~ c * n^2, where c = (1/2) * Product_{p prime} ((p^2-p)/(p^2-q(p))) + 3/Pi^2 = 0.524667479..., where q(p) = prevprime(p) (A151799) if p > 2 and q(2) = 1. - Amiram Eldar, Dec 21 2023
MATHEMATICA
f1[p_, e_] := (p - 1)*p^(e - 1); f2[p_, e_] := If[p == 2, 1, NextPrime[p, -1]^e]; a[1] = 2; a[n_] := Times @@ f1 @@@ (f = FactorInteger[n]) + Times @@ f2 @@@ f; Array[a, 80] (* Amiram Eldar, May 07 2022 *)
PROG
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, May 06 2022
STATUS
approved