The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A053794 a(n) = (n^2 + n) modulo 8. 1
0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0, 0, 2, 6, 4, 4, 6, 2, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
COMMENTS
Periodic with period 8.
LINKS
FORMULA
From Wesley Ivan Hurt, Jun 22 2022: (Start)
a(n) = 2*A105198(n).
a(n) = a(n-1)-a(n-2)+a(n-3)-a(n-4)+a(n-5)-a(n-6)+a(n-7). (End)
MATHEMATICA
PadRight[{}, 105, {0, 2, 6, 4, 4, 6, 2, 0}] (* Michael De Vlieger, Jun 22 2022 *)
PROG
(PARI) A053794(n)=[0, 2, 6, 4, 4, 6, 2, 0][n%8+1] \\ M. F. Hasler, Aug 27 2012
(Scheme) (define (A053794 n) (modulo (+ (* n n) n) 8)) ;; Antti Karttunen, Aug 10 2017
CROSSREFS
Sequence in context: A187817 A276678 A276680 * A249913 A003077 A323482
KEYWORD
nonn,easy
AUTHOR
Stuart M. Ellerstein (ellerstein(AT)aol.com), Mar 27 2000
EXTENSIONS
More terms from James A. Sellers, Apr 08 2000
Extended to n=103 by Antti Karttunen, Aug 10 2017
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 June 10 05:56 EDT 2024. Contains 373253 sequences. (Running on oeis4.)