login
A188795
a(n) counts all integers k in [2,floor(sqrt(n))] such that the number of divisors d>1 of n-k with k|(n-d) equals A188550(n).
1
1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 2, 1, 1, 2, 2, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 3, 2, 1, 1, 1, 1, 1, 1, 6, 1, 1, 1, 1, 1, 3, 1, 2, 2, 3, 2, 1, 1, 1, 1, 1, 1, 4, 2, 2, 1, 1, 1, 1, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 3, 1, 1
OFFSET
4,8
LINKS
MAPLE
with(numtheory):
a:= proc(n) option remember; local c, h, k, m;
m, c:= 0, 0;
for k from 2 to floor(sqrt(n)) do
h:= nops(select(x-> irem(x, k)=0,
[seq (n-d, d=divisors(n-k) minus{1})]));
if h=m then c:=c+1 elif h>m then m, c:= h, 1 fi
od; c
end:
seq(a(n), n=4..120); # Alois P. Heinz, Apr 10 2011
MATHEMATICA
b[n_] := Max @ Table[Length @ Select[Table[n-d, {d, Divisors[n-k] // Rest} ], Mod[#, k] == 0&], {k, 2, Floor[Sqrt[n]]}];
a[n_] := a[n] = Count[Range[2, Floor[Sqrt[n]]], k_ /; Count[Rest @ Divisors[n-k], d_ /; Divisible[n-d, k]] == b[n]];
Table[a[n], {n, 4, 120}] (* Jean-François Alcover, Mar 27 2017, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Shevelev, Apr 10 2011
STATUS
approved