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

A142702
Period 4: repeat [5, 2, 5, 8].
0
5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8, 5, 2, 5, 8
OFFSET
1,1
COMMENTS
From Balmer spectrum of hydrogen.
FORMULA
a(n) = 5+3*cos(n*Pi/2). [From PARI program of Lafont, Aug 30 2009].
G.f.: ( 5-3*x+8*x^2 ) / ( (1-x)*(1+x^2) ). - R. J. Mathar, Apr 02 2011
a(n) = a(n-1) - a(n-2) + a(n-3) for n>3. - Wesley Ivan Hurt, Jul 08 2016
MAPLE
seq(op([5, 2, 5, 8]), n=1..50); # Wesley Ivan Hurt, Jul 08 2016
MATHEMATICA
PadRight[{}, 100, {5, 2, 5, 8}] (* Harvey P. Dale, Dec 09 2013 *)
PROG
(PARI) a(n)=5+3*cos(n*Pi/2) \\ [Jaume Oliver Lafont, Aug 30 2009]
(Magma) &cat [[5, 2, 5, 8]^^30]; // Wesley Ivan Hurt, Jul 08 2016
CROSSREFS
Sequence in context: A087300 A074455 A339161 * A236184 A201530 A085997
KEYWORD
nonn,easy
AUTHOR
Paul Curtz, Sep 23 2008
EXTENSIONS
Edited by N. J. A. Sloane, Sep 27 2008
STATUS
approved