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!)
A176895 Period 4: repeat [1, 4, 2, 4]. 11
1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1, 4, 2, 4, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
a(n) = 4/gcd(n,4). - Michael Somos, Jan 06 2011
a(n) = 4-(1+(-1)^n)*(5+I^n)/4. - Bruno Berselli, Mar 22 2011
G.f.: ( 1+4*x+2*x^2+4*x^3 ) / ( (1-x)*(1+x)*(x^2+1) ). - R. J. Mathar, Mar 21 2011
From Wesley Ivan Hurt, Jul 11 2016: (Start)
a(n) = a(n-4) for n>3.
a(n) = 2^((5-(-I)^n-I^n-3*I^(2*n))/4) where I=sqrt(-1). (End)
MAPLE
seq(op([1, 4, 2, 4]), n=0..50); # Wesley Ivan Hurt, Jul 11 2016
MATHEMATICA
PadRight[{}, 100, {1, 4, 2, 4}] (* Wesley Ivan Hurt, Jul 11 2016 *)
PROG
(PARI) a(n)=4/gcd(n, 4) \\ Charles R Greathouse IV, Oct 07 2015
(Magma) &cat [[1, 4, 2, 4]^^30]; // Wesley Ivan Hurt, Jul 11 2016
CROSSREFS
Cf. A056594.
Sequence in context: A090976 A156199 A135513 * A335261 A351864 A256789
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, Apr 28 2010
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 May 23 00:54 EDT 2024. Contains 372758 sequences. (Running on oeis4.)