OFFSET
1,2
COMMENTS
a(n) >= d(n), where d is the number of divisors of n (A000005).
From Bernard Schott, Aug 24 2020: (Start)
a(n) = 2 if and only if n is prime.
Also, a(2^k) = k+1 for k >= 0. (End)
FORMULA
a(n) = Sum_{d1|n, d2|n, (d1+d2)|(2*n), 2|(d1+d2)} 1.
EXAMPLE
a(6) = 5; The divisors of 6 are {1,2,3,6}. The pairs of divisors, (d1,d2), with d1 <= d2, whose average divides 6 are: (1,1), (1,3), (2,2), (3,3) and (6,6). So a(6) = 5.
a(7) = 2; The divisors of 7 are {1,7}. The pairs of divisors, (d1,d2), with d1 <= d2, whose average divides 7 are: (1,1) and (7,7). So a(7) = 2.
a(8) = 4; The divisors of 8 are {1,2,4,8}. The pairs of divisors, (d1,d2), with d1 <= d2, whose average divides 8 are: (1,1), (2,2), (4,4), and (8,8). So a(8) = 4.
a(9) = 3; The divisors of 9 are {1,3,9}. The pairs of divisors, (d1,d2), with d1 <= d2, whose average divides 9 are: (1,1), (3,3) and (9,9). So a(9) = 3.
MATHEMATICA
Table[Sum[Sum[(1 - Ceiling[(i + k)/2] + Floor[(i + k)/2]) (1 - Ceiling[2 n/(i + k)] + Floor[2 n/(i + k)]) (1 - Ceiling[n/k] + Floor[n/k]) (1 - Ceiling[n/i] + Floor[n/i]), {i, k}], {k, n}], {n, 100}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, Aug 23 2020
STATUS
approved