|
|
A053866
|
|
Parity of A000203(n), the sum of the divisors of n; a(n) = 1 when n is a square or twice a square, 0 otherwise.
|
|
44
|
|
|
1, 1, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
It appears that this is also the parity of A067742, the number of middle divisors of n. - Omar E. Pol, Mar 18 2018
|
|
LINKS
|
|
|
FORMULA
|
a(n) = A000203(n) mod 2. a(n)=1 iff n>0 is a square or twice a square.
Multiplicative with a(2^e)=1, a(p^e)=1 if e even, 0 otherwise.
a(n) = floor(sqrt(n)) + floor(sqrt(n/2)) - floor(sqrt(n-1))-floor(sqrt((n-1)/2)). - Enrique Pérez Herrero, Oct 15 2013
|
|
MAPLE
|
A053866:= (n -> numtheory[sigma](n) mod 2):
|
|
MATHEMATICA
|
|
|
PROG
|
(PARI) {a(n) = if( n<1, 0, issquare(n) || issquare(2*n))} /* Michael Somos, Apr 12 2004 */
(Python)
from sympy.ntheory.primetest import is_square
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,mult
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|