OFFSET
1,2
COMMENTS
For n = any odd positive integer, there are no differences (between consecutive divisors of n) that divide n.
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..20000
FORMULA
EXAMPLE
From Antti Karttunen, Feb 20 2023: (Start)
Divisors of 2*12 = 24 are: [1, 2, 3, 4, 6, 8, 12, 24]. Their first differences are: [1, 1, 1, 2, 2, 4, 12], all 7 which are divisors of 24, thus a(12) = 7.
Divisors of 2*35 = 70 are: [1, 2, 5, 7, 10, 14, 35, 70]. Their first differences are: 1, 3, 2, 3, 4, 21, 35, of which 1, 2 and 35 are divisors of 70, thus a(35) = 3.
Divisors of 2*65 = 130 are: [1, 2, 5, 10, 13, 26, 65, 130]. Their first differences are: 1, 3, 5, 3, 13, 39, 65, of which 1, 5, 13 and 65 are divisors of 130, thus a(65) = 4.
(End)
MAPLE
A138652 := proc(n) local a, dvs, i ; a := 0 ; dvs := sort(convert(numtheory[divisors](2*n), list)) ; for i from 2 to nops(dvs) do if (2*n) mod ( op(i, dvs)-op(i-1, dvs) ) = 0 then a := a+1 ; fi ; od: a ; end: seq(A138652(n), n=1..120) ; # R. J. Mathar, May 20 2008
MATHEMATICA
a = {}; For[n = 2, n < 200, n = n + 2, b = Table[Divisors[n][[i + 1]] - Divisors[n][[i]], {i, 1, Length[Divisors[n]] - 1}]; AppendTo[a, Length[Select[b, Mod[n, # ] == 0 &]]]]; a (* Stefan Steinerberger, May 18 2008 *)
PROG
(PARI) A138652(n) = { n = 2*n; my(d=divisors(n), erot = vector(#d-1, k, d[k+1] - d[k])); sum(i=1, #erot, !(n%erot[i])); }; \\ Antti Karttunen, Feb 20 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Leroy Quet, May 15 2008
EXTENSIONS
More terms from Stefan Steinerberger and R. J. Mathar, May 18 2008
Definition edited and clarified by Antti Karttunen, Feb 20 2023
STATUS
approved