OFFSET
0,1
COMMENTS
LINKS
A. Karttunen, Table of n, a(n) for n = 0..65535
FORMULA
a(n) = 1 if A165471(1+(n%65536))=+1, otherwise 0. Period 65536.
PROG
(MIT Scheme:)
(define (1+halved n) (floor->exact (/ (1+ n) 2)))
(Sage)
def A179416_list(n) : # for n <= 65536
Q = quadratic_residues(65537)
return [int(i in Q) for i in (1..n)]
A179416_list(102) # Peter Luschny, Aug 08 2012
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jul 27 2010
STATUS
approved