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!)
A132367 Period 6: repeat [1, 1, 2, -1, -1, -2]. 5

%I #26 Dec 12 2023 08:54:38

%S 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,

%T -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,

%U 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

%N Period 6: repeat [1, 1, 2, -1, -1, -2].

%C Nonsimple continued fraction expansion of 1+1/sqrt(3) = 1 + A020760. - _R. J. Mathar_, Mar 08 2012

%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,-1).

%F a(n) = cos(Pi*n/3)/3+sqrt(3)*sin(Pi*n/3)+2*(-1)^n/3. - _R. J. Mathar_, Oct 08 2011

%F From _Wesley Ivan Hurt_, Jun 19 2016: (Start)

%F G.f.: (1+x+2*x^2)/(1+x^3).

%F a(n) + a(n-3) = 0 for n>2. (End)

%p A132367:=n->[1, 1, 2, -1, -1, -2][(n mod 6)+1]: seq(A132367(n), n=0..100); # _Wesley Ivan Hurt_, Jun 19 2016

%t PadRight[{}, 120, {1,1,2,-1,-1,-2}] (* _Harvey P. Dale_, Jul 28 2012 *)

%o (PARI) a(n)=[1,1,2,-1,-1,-2][n%6+1] \\ _Charles R Greathouse IV_, Jun 02 2011

%o (Magma) &cat[[1, 1, 2, -1, -1, -2]^^20]; // _Wesley Ivan Hurt_, Jun 19 2016

%Y Cf. A020760, A061347, A100051, A100063, A122876.

%K sign,easy,less

%O 0,3

%A _Paul Curtz_, Nov 09 2007

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 25 07:41 EDT 2024. Contains 371964 sequences. (Running on oeis4.)