login
This site is supported by donations to The OEIS Foundation.

 

Logo

Annual appeal: Please make a donation to keep the OEIS running! Over 6000 articles have referenced us, often saying "we discovered this result with the help of the OEIS".
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A083035 a(n)=floor(sqrt(2)*n)-2*floor(n/sqrt(2)). 13
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

Benoit Cloitre, Fractal walk starting at (0,0) with step of unit length turning right if a(n)=0 and left otherwise for n=1 up to 10^6

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 *)

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: A078650 A028863 A089012 * A187074 A051341 A057211

Adjacent sequences:  A083032 A083033 A083034 * A083036 A083037 A083038

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 | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified November 19 03:32 EST 2017. Contains 294912 sequences.