cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A078070 Expansion of (1-x)/(1 + 2*x + 2*x^2 + x^3).

Original entry on oeis.org

1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3, 4, -3, 1, 0, 1, -3
Offset: 0

Views

Author

N. J. A. Sloane, Nov 17 2002

Keywords

Comments

Period 6: repeat [1, -3, 4, -3, 1, 0].
The unsigned sequence is the r=3 member in the r-family of sequences S_r(n) defined in A092184 where more information can be found. |a(n)| = 2-2*T(n,1/2), with twice the Chebyshev polynomials of the first kind 2*T(n,x=1/2) = A057079(n+1) = S(n+1,1) + S(n,1) with S(n,1)= A010892(n).
Working with an offset of 1, this sequence is a divisibility sequence, i.e., a(n) divides a(m) whenever n divides m. Case P1 = -3, P2 = 2, Q = 1 of the 3 parameter family of 4th-order linear divisibility sequences found by Williams and Guy. - Peter Bala, Mar 25 2014

Examples

			G.f. = 1 - 3*x + 4*x^2 - 3*x^3 + x^4 + x^6 - 3*x^7 + 4*x^8 - 3*x^9 + x^10 + ...
		

Crossrefs

Programs

  • Mathematica
    a[ n_] := {-3, 4, -3, 1, 0, 1}[[Mod[ n, 6, 1]]]; (* Michael Somos, Aug 05 2015 *)
    CoefficientList[Series[(1-x)/(1+2x+2x^2+x^3),{x,0,120}],x] (* or *) PadRight[ {},120,{1,-3,4,-3,1,0}] (* or *) LinearRecurrence[{-2,-2,-1},{1,-3,4},120] (* Harvey P. Dale, Jan 06 2016 *)
  • PARI
    Vec((1-x)/(1+2*x+2*x^2+x^3)+O(x^99)) \\ Charles R Greathouse IV, Sep 26 2012
    
  • PARI
    {a(n) = [1, -3, 4, -3, 1, 0][n%6 + 1]}; /* Michael Somos, Aug 05 2015 */

Formula

abs(a(n)) = 2 + 2*cos(Pi*n/3 - 2*Pi/3). - Paul Barry, Mar 14 2004
Euler transform of finite sequence [-3, 1, 1]. - Michael Somos, Sep 17 2004
a(n) = (n+1)*(Sum_{k=0..floor((n+1)/2)} (-1)^k*binomial(n-k+1, k)*(-1)^(n-2k+1)/(n-k+1)) + 2*(-1)^n; a(n) = 2*T(n+1, -1/2) + 2(-1)^n. - Paul Barry, Dec 12 2004
From Peter Bala, Mar 25 2014: (Start)
The following formulas assume an offset of 1.
Let {u_j(n)}, j = 0 or j = 1, be two Lucas sequences in the quadratic integer ring Z[w], where w = exp(2*Pi*i/3), defined by the recurrences u_j(0) = 0, u_j(1) = 1 and u_j(n) = (-1)^j*sqrt(3)*u(n-1) - u(n-2) for n >= 2. Then a(n) = u_0(n)*u_1(n).
Equivalently, a(n) = U(n-1,sqrt(3)/2)*U(n-1,-sqrt(3)/2), where U(n,x) denotes the Chebyshev polynomial of the second kind.
a(n) = - ( ((sqrt(3) + i)/2)^n - ((sqrt(3) - i)/2)^n )*( ((-sqrt(3) + i)/2)^n - ((-sqrt(3) - i)/2)^n ) = w^n + w^(2*n) - 2*(-1)^n = 2*cos(2*n*Pi/3) - 2*(-1)^n.
a(n) = the bottom left entry of the 2 X 2 matrix T(n, M), where M is the 2 X 2 matrix [0, -1/2; 1, -3/2] and T(n,x) denotes the Chebyshev polynomial of the first kind.
See the remarks in A100047 for the general connection between Chebyshev polynomials of the first kind and 4th-order linear divisibility sequences. (End)
a(n) = a(n+6) = a(-2-n) for all n in Z. - Michael Somos, Aug 05 2015
a(n) = (-1)^n * A254745(n). - Michael Somos, Jul 16 2017

Extensions

Chebyshev comment and related formulas from Wolfdieter Lang, Sep 10 2004