login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A105899
Period 6: repeat [1, 1, 2, 2, 3, 3].
4
1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2, 2, 3, 3, 1, 1, 2
OFFSET
0,3
FORMULA
G.f.: -(3*x^4+2*x^2+1)/(x-1)/(x^2+x+1)/(x^2-x+1). a(n) = A131555(n)+1. - R. J. Mathar, Nov 14 2007
From Wesley Ivan Hurt, Jun 17 2016: (Start)
a(n) = a(n-1) - a(n-2) + a(n-3) - a(n-4) + a(n-5) for n>4.
a(n) = (12-2*sqrt(3)*cos((1-4*n)*Pi/6)-6*sin((1+2*n)*Pi/6))/6. (End)
a(n) = floor(n/2) - 3*floor(n/6) + 1. - Ridouane Oudra, Sep 09 2023
MAPLE
A105899:=n->(12-2*sqrt(3)*cos((1-4*n)*Pi/6)-6*sin((1+2*n)*Pi/6))/6: seq(A105899(n), n=0..100); # Wesley Ivan Hurt, Jun 17 2016
MATHEMATICA
Flatten[Table[{1, 1, 2, 2, 3, 3}, {20}]] (* Wesley Ivan Hurt, Jun 17 2016 *)
PadRight[{}, 120, {1, 1, 2, 2, 3, 3}] (* Harvey P. Dale, May 09 2022 *)
PROG
(PARI) a(n)=1+n%6\2 \\ Jaume Oliver Lafont, Aug 30 2009
(Magma) &cat[[1, 1, 2, 2, 3, 3]: n in [0..20]]; // Wesley Ivan Hurt, Jun 17 2016
CROSSREFS
Cf. A131555.
Cf. A178308 Decimal expansion of (111+sqrt(25277))/158. [Klaus Brockhaus, May 24 2010]
Sequence in context: A288723 A071859 A135695 * A071434 A366549 A227314
KEYWORD
nonn,easy,less
AUTHOR
Paul Curtz, Aug 27 2007
EXTENSIONS
Edited by N. J. A. Sloane, Sep 15 2007
More terms from Klaus Brockhaus, May 24 2010
STATUS
approved