A010673 Period 2: repeat [0, 2].
0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0, 2, 0
Offset: 0
References
- R. Carter, G. Segal, I. Macdonald, Lectures on Lie Groups and Lie Algebras, London Mathematical Society Student Texts 32, Cambridge University Press, 1995; see p. 68.
- H. S. M. Coxeter, Regular Polytopes, third ed., Dover publications, New York, 1973, p. 165.
Links
- Muniru A Asiru, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (0,1).
Crossrefs
Cf. A109613.
Programs
-
GAP
Flat(List([0..80],n->[0,2])); # Muniru A Asiru, Oct 26 2018
-
Maple
seq(op([0,2]),n=0..80); # Muniru A Asiru, Oct 26 2018
-
Mathematica
PadRight[{},120,{0,2}] (* or *) LinearRecurrence[{0,1},{0,2},120] (* Harvey P. Dale, May 29 2016 *)
-
Maxima
makelist(if evenp(n) then 0 else 2, n, 0, 30); /* Martin Ettl, Nov 11 2012 */
-
Maxima
makelist(concat(0,", ",2), n, 0, 40); /* Bruno Berselli, Nov 13 2012 */
-
PARI
a(n)=1-(-1)^n \\ Charles R Greathouse IV, Oct 07 2015
Formula
a(n) = 1 - (-1)^n.
a(n) = 2*(n mod 2). - Paolo P. Lava, Oct 20 2006
G.f.: -2*x / ((x-1)*(1+x)). - R. J. Mathar, Apr 06 2011
E.g.f.: (exp(2*x) - 1)/exp(x). - Elmo R. Oliveira, Dec 19 2023
Comments