login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A083035 a(n) = floor(sqrt(2)*n)-2*floor(n/sqrt(2)). 14
1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
FORMULA
a(n) = floor(n*sqrt(2)) mod 2. - T. D. Noe, Oct 11 2006
MATHEMATICA
Table[Floor[Sqrt[2]n]-2Floor[n/Sqrt[2]], {n, 120}] (* Harvey P. Dale, Mar 08 2017 *)
Table[Mod[Floor[Sqrt[2] n], 2], {n, 120}] (* IWABUCHI Yu(u)ki, May 01 2020 *)
PROG
(PARI) a(n)=sqrtint(2*n^2)%2 \\ Charles R Greathouse IV, Oct 14 2013
CROSSREFS
Cf. A083036, A083037, A083038, A001951 (floor(n*sqrt(2))).
Sequence in context: A285305 A028863 A089012 * A359422 A356161 A187074
KEYWORD
nonn,easy
AUTHOR
Benoit Cloitre, Apr 17 2003
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 26 21:53 EDT 2024. Contains 372004 sequences. (Running on oeis4.)