login
A334112
a(n) = A332809(n) - A000005(n).
2
0, 0, 1, 0, 2, 1, 4, 0, 3, 2, 5, 1, 6, 5, 6, 0, 4, 3, 8, 2, 8, 6, 9, 1, 6, 7, 6, 6, 11, 6, 13, 0, 13, 4, 14, 3, 11, 10, 11, 2, 9, 9, 16, 7, 12, 11, 14, 1, 15, 6, 10, 8, 13, 6, 12, 7, 13, 13, 16, 6, 17, 16, 14, 0, 18, 15, 22, 4, 22, 16, 23, 3, 14, 13, 15, 12, 26, 12, 19, 2, 10, 10, 13, 10, 12, 20, 21, 8, 15, 12, 24, 13, 23
OFFSET
1,5
FORMULA
a(n) = A332809(n) - A000005(n).
a(2^n) = 0 for all n >= 0.
MATHEMATICA
Array[Block[{w = {{#}}}, While[w[[-1]] != {1}, w = Join[w, {Union@ Flatten[# - #/FactorInteger[#][[All, 1]] & /@ w[[-1]] ]}]]; Length@ Union@ Flatten@ w - DivisorSigma[0, #]] &, 93] (* Michael De Vlieger, May 09 2020, after Robert G. Wilson v at A332809 *)
PROG
(PARI)
up_to = 20000;
A332809list(up_to) = { my(v=vector(up_to)); v[1] = Set([1]); for(n=2, up_to, my(f=factor(n)[, 1]~, s=Set([n])); for(i=1, #f, s = setunion(s, v[n-(n/f[i])])); v[n] = s); apply(length, v); }
v332809 = A332809list(up_to);
A332809(n) = v332809[n];
A334112(n) = (A332809(n) - numdiv(n));
CROSSREFS
Cf. A000005, A000079 (positions of zeros), A007283, A332809.
Sequence in context: A226952 A158285 A277994 * A355625 A286238 A286237
KEYWORD
nonn
AUTHOR
Antti Karttunen, May 09 2020
STATUS
approved