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!)
A049347 Period 3: repeat [1, -1, 0]. 133

%I #147 Jan 09 2024 22:32:12

%S 1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,

%T 0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,

%U -1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0,1,-1,0

%N Period 3: repeat [1, -1, 0].

%C G.f. 1/cyclotomic(3, x) (the third cyclotomic polynomial).

%C Self-convolution yields (-1)^n*A099254(n). - _R. J. Mathar_, Apr 06 2008

%C Hankel transform of A099324. - _Paul Barry_, Aug 10 2009

%C A057083(n) = p(-1) where p(x) is the unique degree-n polynomial such that p(k) = a(k) for k = 0..n. - _Michael Somos_, Apr 29 2012

%C a(n) appears, together with b(n) = A099837(n+3) in the formula 2*exp(2*Pi*n*I/3) = b(n) + a(n)*sqrt(3)*I, n >= 0, with I = sqrt(-1). See A164116 for the case N=5. - _Wolfdieter Lang_, Feb 27 2014

%C The binomial transf. is 1, 0, -1, -1, 0, 1, 1, 0, -1, -1.. (see A010891). The inverse binom. transf. is 1, -2, 3, -3, 0, 9, -27, 54, -81.. (see A057682). - _R. J. Mathar_, Feb 25 2023

%D A. T. Benjamin and J. J. Quinn, Proofs that really count: the art of combinatorial proof, M.A.A. 2003, id. 175.

%H Vincenzo Librandi, <a href="/A049347/b049347.txt">Table of n, a(n) for n = 0..1000</a>

%H J.P. Allouche and M. Mendes France, <a href="http://arxiv.org/abs/1202.0211">Stern-Brocot polynomials and power series</a>, arXiv preprint arXiv:1202.0211 [math.NT], 2012.

%H Elena Barcucci, Antonio Bernini, Stefano Bilotta and Renzo Pinzani, <a href="http://arxiv.org/abs/1601.07723">Non-overlapping matrices</a>, arXiv:1601.07723 [cs.DM], 2016.

%H George Beck and Karl Dilcher, <a href="https://arxiv.org/abs/2106.10400">A Matrix Related to Stern Polynomials and the Prouhet-Thue-Morse Sequence</a>, arXiv:2106.10400 [math.CO], 2021.

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

%H <a href="/index/Ch#Cheby">Index entries for sequences related to Chebyshev polynomials.</a>

%H <a href="/index/Pol#poly_cyclo_inv">Index to sequences related to inverse of cyclotomic polynomials</a>

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

%F a(n) = +1 if n mod 3 = 0, a(n) = -1 if n mod 3 = 1, else 0.

%F a(n) = S(n, -1) = U(n, -1/2) (Chebyshev's U(n, x) polynomials.)

%F a(n) = 2*sqrt(3)*cos(2*Pi*n/3 + Pi/6)/3. - _Paul Barry_, Mar 15 2004

%F a(n) = Sum_{k >= 0} (-1)^(n-k)*C(n-k, k).

%F Given g.f. A(x), then B(x) = x * A(x) satisfies 0 = f(B(x), B(x^2)) where f(u, v) = u^2 - v + 2*u*v. - _Michael Somos_, Oct 03 2006

%F Euler transform of length 3 sequence [-1, 0, 1]. - _Michael Somos_, Oct 03 2006

%F a(n) = b(n+1) where b(n) is multiplicative with b(3^e) = 0^e, b(p^e) = 1 if p == 1 (mod 3), b(p^e) = (-1)^e if p == 2 (mod 3). - _Michael Somos_, Oct 03 2006

%F From _Michael Somos_, Oct 03 2006: (Start)

%F G.f.: (1 - x) /(1 - x^3).

%F a(n) = -a(1-n) = -a(n-1) - a(n-2) = a(n-3). (End)

%F From _Michael Somos_, Apr 29 2012: (Start)

%F G.f.: 1 / (1 + x / ( 1 - x / (1 + x))).

%F a(n) = (-1)^n * A010892(n).

%F a(n) * n! = A194770(n+1).

%F Revert transform of A001006. Convolution inverse of A130716. MOBIUS transform of A002324. EULER transform is A111317. BIN1 transform of itself. STIRLING transform is A143818(n+2). (End)

%F a(-n) = A057078(n). a(n) = A106510(n+1) unless n=0. - _Michael Somos_, Oct 15 2008

%F G.f. A(x) = 1/(1+x+x^2) = Q(0); Q(k) = 1- x/(1 - x^2/(x^2 - 1 + x/(x - 1 + x^2/(x^2 - 1/Q(k+1))))); (continued fraction 3 kind, 5-step ). - _Sergei N. Gladkovskii_, Jun 19 2012

%F a(n) = -1 + floor(67/333*10^(n+1)) mod 10. - _Hieronymus Fischer_, Jan 03 2013

%F a(n) = -1 + floor(19/26*3^(n+1)) mod 3. - _Hieronymus Fischer_, Jan 03 2013

%F a(n) = ceiling((n-1)/3) - ceiling(n/3) + floor(n/3) - floor((n-1)/3). - _Wesley Ivan Hurt_, Dec 06 2013

%F a(n) = n + 1 - 3*floor((n+2)/3). - _Mircea Merca_, Feb 04 2014

%F a(n) = A102283(n+1) for all n in Z. - _Michael Somos_, Sep 24 2019

%F E.g.f.: exp(-x/2)*(3*cos(sqrt(3)*x/2) - sqrt(3)*sin(sqrt(3)*x/2))/3. - _Stefano Spezia_, Oct 26 2022

%e G.f. = 1 - x + x^3 - x^4 + x^6 - x^7 + x^9 - x^10 + x^12 - x^13 + x^15 + ...

%p A049347 := proc(n)

%p op(modp(n,3)+1,[1,-1,0]) ;

%p end proc:

%p seq(A049347(n),n=0..100) ; # _R. J. Mathar_, Aug 06 2016

%t Flatten[Table[{1, -1, 0}, {27}]] (* _Alonso del Arte_, Feb 07 2013 *)

%t CoefficientList[Series[1/Cyclotomic[3, x], {x, 0, 100}], x] (* _Vincenzo Librandi_, Apr 03 2014 *)

%t LinearRecurrence[{-1, -1}, {1, -1}, 90] (* _Ray Chandler_, Sep 15 2015 *)

%t Table[DirichletCharacter[3, 2, n + 1], {n, 0, 29}] (* _Steven Foster Clark_, May 29 2019 *)

%t Table[Mod[n + 2, 3] - 1, {n, 0, 20}] (* _Michael Somos_, Sep 24 2019 *)

%t Table[ChebyshevU[n, -1/2], {n, 0, 20}] (* _Eric W. Weisstein_, Jan 09 2024 *)

%t ChebyshevU[Range[0, 20], -1/2] (* _Eric W. Weisstein_, Jan 09 2024 *)

%o (PARI) {a(n) = n++; kronecker( -3, n)} /* _Michael Somos_, Oct 03 2006 */

%o (PARI) {a(n) = [1, -1, 0][n%3 + 1]} /* _Michael Somos_, Oct 15 2008 */

%o (PARI) a(n)=(n+2)%3-1 /* _Jaume Oliver Lafont_, Mar 24 2009 */

%o (Maxima) A049347(n) := block(

%o [1,-1,0][1+mod(n,3)]

%o )$ /* _R. J. Mathar_, Mar 19 2012 */

%o (Sage)

%o def A049347():

%o x, y = 1, -1

%o while True:

%o yield x

%o x, y = y, -x - y

%o a = A049347(); [next(a) for i in range(40)] # _Peter Luschny_, Jul 11 2013

%o (Magma) &cat[[1,-1,0]: n in [0..90]]; // _Vincenzo Librandi_, Apr 03 2014

%Y Cf. A001006, A010892, A057078, A057083, A102283, A106510, A130716, A143818, A194770.

%Y Alternating row sums of A049310 (Chebyshev-S). [_Wolfdieter Lang_, Nov 04 2011]

%K easy,sign

%O 0,1

%A _Wolfdieter Lang_

%E Edited by _Charles R Greathouse IV_, Mar 23 2010

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 23 20:33 EDT 2024. Contains 371916 sequences. (Running on oeis4.)