login
A348336
Number of positive integers <= n that have no middle divisors.
2
0, 0, 1, 1, 2, 2, 3, 3, 3, 4, 5, 5, 6, 7, 7, 7, 8, 8, 9, 9, 10, 11, 12, 12, 12, 13, 14, 14, 15, 15, 16, 16, 17, 18, 18, 18, 19, 20, 21, 21, 22, 22, 23, 24, 24, 25, 26, 26, 26, 26, 27, 28, 29, 29, 30, 30, 31, 32, 33, 33, 34, 35, 35, 35, 36, 36, 37, 38, 39, 39, 40, 40, 41, 42, 43, 44
OFFSET
1,5
COMMENTS
a(n) is also the number of positive integers k <= n whose symmetric representation of sigma(k) has an even number of parts.
EXAMPLE
For n = 10 there are four positive integers <= 10 that have no middle divisors, they are [3, 5, 7, 10], so a(10) = 4.
On the other hand for n = 10 there are four positive integers k <= 10 whose symmetric representation of sigma(k) has an even number of parts, they are [3, 5, 7, 10], so a(10) = 4.
MATHEMATICA
f[n_] := Boole[DivisorSum[n, 1 &, n/2 <= #^2 < 2*n &] == 0]; Accumulate @ Array[f, 100] (* Amiram Eldar, Oct 13 2021 *)
PROG
(PARI) is(n, f=factor(n))=my(t=(n+1)\2); fordiv(f, d, if(d^2>=t, return(d^2>2*n))); 0 ; \\ A071561
a(n) = sum(k=1, n, is(k)); \\ Michel Marcus, Oct 14 2021
KEYWORD
nonn
AUTHOR
Omar E. Pol, Oct 13 2021
STATUS
approved