The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A131556 Period 6: repeat [1, -2, 1, -1, 2, -1]. 7
 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1, 1, -2, 1, -1, 2, -1 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,2 LINKS Index entries for linear recurrences with constant coefficients, signature (0,0,-1). FORMULA a(n) = (1/6)*{-2*(n mod 6)+3*[(n+1) mod 6]-3*[(n+2) mod 6]+2*[(n+3) mod 6]-3*[(n+4) mod 6]+3*[(n+5) mod 6]}. - Paolo P. Lava, Aug 28 2007 G.f.: (x-1)^2/(x+1)/(x^2-x+1). - R. J. Mathar, Nov 14 2007 a(n) = (-1)^n * A131534(n). - R. J. Mathar, Apr 02 2011 a(n) = -cos(Pi*n/3)/3 -sin(Pi*n/3)/sqrt(3) +4*(-1)^n/3. - R. J. Mathar, Oct 08 2011 a(n) + a(n-3) = 0 for n>2. - Wesley Ivan Hurt, Jun 19 2016 MAPLE A131556:=n->[1, -2, 1, -1, 2, -1][(n mod 6)+1]: seq(A131556(n), n=0..100); # Wesley Ivan Hurt, Jun 19 2016 MATHEMATICA PadRight[{}, 100, {1, -2, 1, -1, 2, -1}] (* Wesley Ivan Hurt, Jun 19 2016 *) PROG (PARI) a(n)=[1, -2, 1, -1, 2, -1][n%6+1] \\ Charles R Greathouse IV, Jun 02 2011 (MAGMA) &cat[[1, -2, 1, -1, 2, -1]^^20]; // Wesley Ivan Hurt, Jun 19 2016 CROSSREFS Cf. A131534. Sequence in context: A100063 A057079 A132419 * A107751 A132367 A087204 Adjacent sequences:  A131553 A131554 A131555 * A131557 A131558 A131559 KEYWORD sign,easy,less AUTHOR Paul Curtz, Aug 27 2007 EXTENSIONS Edited by N. J. A. Sloane, Sep 15 2007 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
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified April 4 05:34 EDT 2020. Contains 333212 sequences. (Running on oeis4.)