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”).

A177704
Period 4: repeat [1, 1, 1, 2].
11
1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1
OFFSET
0,4
COMMENTS
Continued fraction expansion of (3 + 2*sqrt(6))/5.
Decimal expansion of 1112/9999.
a(n) = A164115(n + 1) = (-1)^(n + 1) * A164117(n + 1) = A138191(n + 3) = A107453(n + 5).
LINKS
David Nacin, Van der Laan Sequences and a Conjecture on Padovan Numbers, J. Int. Seq., Vol. 26 (2023), Article 23.1.2.
FORMULA
a(n) = (5-(-1)^n + i*i^n-i*(-i)^n)/4 where i = sqrt(-1).
a(n) = a(n-4) for n > 3; a(0) = 1, a(1) = 1, a(2) = 1, a(3) = 2.
G.f.: (1+x+x^2+2*x^3)/(1-x^4).
a(n) = 1 + (1-(-1)^n) * (1+i^(n+1))/4 where i = sqrt(-1). - Bruno Berselli, Apr 05 2011
a(n) = 5/4 - sin(Pi*n/2)/2 - (-1)^n/4. - R. J. Mathar, Oct 08 2011
a(n) = floor((n+1)*5/4) - floor(n*5/4). - Hailey R. Olafson, Jul 23 2014
From Wesley Ivan Hurt, Jun 15 2016: (Start)
a(n+3) - a(n+2) = A219977(n).
Sum_{i=0..n-1} a(i) = A001068(n). (End)
E.g.f.: (-sin(x) + 3*sinh(x) + 2*cosh(x))/2. - Ilya Gutkovskiy, Jun 15 2016
MAPLE
A177704:=n->floor((n+1)*5/4) - floor(n*5/4): seq(A177704(n), n=0..100); # Wesley Ivan Hurt, Jun 15 2016
MATHEMATICA
Table[Floor[(n + 1)*5/4] - Floor[n*5/4], {n, 0, 100}] (* Wesley Ivan Hurt, Jun 15 2016 *)
LinearRecurrence[{0, 0, 0, 1}, {1, 1, 1, 2}, 100] (* Vincenzo Librandi, Jun 16 2016 *)
PROG
(Magma) &cat[ [1, 1, 1, 2]: k in [1..27] ];
(PARI) a(n) = if(n%4==3, 2, 1) \\ Felix Fröhlich, Jun 15 2016
KEYWORD
nonn,cofr,easy
AUTHOR
Klaus Brockhaus, May 11 2010
STATUS
approved