OFFSET
1,6
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..20000
MATHEMATICA
Map[Denominator@ Mean[Total /@ #] &, #] &@ Nest[Function[{a, n}, Append[a, Join @@ Table[Flatten@ Prepend[#, n] & /@ a[[n - n/p]], {p, FactorInteger[n][[All, 1]]}]]] @@ {#, Length@ # + 1} &, {{{1}}}, 104] (* Michael De Vlieger, Apr 15 2020 *)
PROG
(PARI)
up_to = 20000;
A333003list(up_to) = { my(u=vector(up_to), v=vector(up_to)); u[1] = v[1] = 1; for(n=2, up_to, my(ps=factor(n)[, 1]~); u[n] = vecsum(apply(p -> u[n-n/p], ps)); v[n] = (u[n]*n)+vecsum(apply(p -> v[n-n/p], ps))); vector(up_to, n, denominator(v[n]/u[n])); };
v333003 = A333003list(up_to);
A333003(n) = v333003[n];
CROSSREFS
KEYWORD
nonn,frac
AUTHOR
Antti Karttunen, Apr 06 2020
STATUS
approved