OFFSET
1,6
COMMENTS
a(n) = 1 iff n is prime or n is the square of a prime (A000430). - Bernard Schott, Jan 30 2021
FORMULA
a(n) = Sum_{d1|n, d2|n} (1 - sign(floor(d1*d2/sqrt(n)))).
EXAMPLE
a(24) = 5; (1,1), (1,2), (1,3), (1,4), (2,2).
a(25) = 1; (1,1).
a(26) = 3; (1,1), (1,2), (2,2).
a(27) = 2; (1,1), (1,3).
MATHEMATICA
Table[Sum[Sum[(1 - Sign[Floor[(i*k)/Sqrt[n]]]) (1 - Ceiling[n/k] + Floor[n/k]) (1 - Ceiling[n/i] + Floor[n/i]), {i, k}], {k, n}], {n, 80}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Wesley Ivan Hurt, Jan 28 2021
STATUS
approved