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.

Showing 1-2 of 2 results.

A215917 a(n) = -3*a(n-1) + a(n-3), with a(0)=0, a(1)=6, and a(2)=-15.

Original entry on oeis.org

0, 6, -15, 45, -129, 372, -1071, 3084, -8880, 25569, -73623, 211989, -610398, 1757571, -5060724, 14571774, -41957751, 120812529, -347865813, 1001639688, -2884106535, 8304453792, -23911721688, 68851058529, -198248721795, 570834443697, -1643652272562
Offset: 0

Views

Author

Roman Witula, Aug 27 2012

Keywords

Comments

The Berndt-type sequence number 9 for the argument 2Pi/9 defined by the first relation from the section "Formula" below.
We have a(n) = 3*(-1)^(n+1)*A215448(n+1). From the recurrence formula for a(n) it follows that all a(3*n) are divisible by 9, a(3*n+1)/3 are congruent to 2 modulo 3, and a(3*n+2)/3 are congruent to 1 modulo 3. In the consequence also all sums a(n)+a(n+1)+a(n+2) are divisible by 9.
From general recurrence X(n) = -3*X(n-1) + X(n-3) the following formula can be deduced: 3*Sum_{k=2..n-1} X(k) = -X(n)-X(n-1)-X(n-2)+X(2)+X(1)+X(0). Hence, in the case of a(n) we obtain 3*Sum_{k=2..n-1} a(k) = -a(n)-a(n-1)-a(n-2)-9.
If we set X(n) = -3*X(n-1) + X(n-3), n in Z, with a(n) = X(n) for n=0,1,... then X(-n) = abs(A215666(n)) = (-1)^n*A215666(n), for every n=0,1,...
The following decomposition holds true (X - c(1)*(-c(4))^(-n))*(X - c(2)*(-c(1))^(-n))*(X - c(4)*(-c(2))^(-n)) = X^3 - a(n)*X^2 + (-1)^n*(A215665(n) - A215664(n))*X + 1.

References

  • D. Chmiela and R. Witula, Two parametric quasi-Fibonacci numbers of the ninth order, (submitted, 2012).
  • R. Witula, Ramanujan type formulas for arguments 2Pi/7 and 2Pi/9, Demonstratio Math. (in press, 2012).

Crossrefs

Programs

  • Maple
    We have a(3) + 3*a(2) = 0, a(8) + 24*a(5) = 48 = a(3) + a(1)/2.
  • Mathematica
    LinearRecurrence[{-3,0,1}, {0,6,-15}, 50]
  • PARI
    concat(0,Vec(3*(x+2)/(1+3*x-x^3)+O(x^99))) \\ Charles R Greathouse IV, Oct 01 2012

Formula

a(n) = c(1)*(-c(4))^(-n) + c(2)*(-c(1))^(-n) + c(4)*(-c(2))^(-n), where c(j) := 2*cos(2*Pi*j/9).
a(n) = (-1)^n*(A215885(n+1) - A215885(n)).
G.f.: 3*x(x+2)/(1+3*x-x^3).

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

Original entry on oeis.org

1, 1, 4, 11, 32, 92, 265, 763, 2197, 6326, 18215, 52448, 151018, 434839, 1252069, 3605189, 10380728, 29890115, 86065156, 247814740, 713554105, 2054597159, 5915976737, 17034376106, 49048531159, 141229616740, 406654474114
Offset: 0

Views

Author

encyclopedia(AT)pommard.inria.fr, Jan 25 2000

Keywords

Comments

(1, 4, 11, 32, ...) = INVERT transform of (1, 3, 4, 5, 6, 7, ...).

Crossrefs

Cf. A215448. First differences of A052536.

Programs

  • GAP
    a:=[1,1,4];; for n in [4..40] do a[n]:=3*a[n-1]-a[n-3]; od; a; # G. C. Greubel, May 08 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 40); Coefficients(R!( (1-x)^2/(1-3*x+x^3) )); // G. C. Greubel, May 08 2019
    
  • Maple
    spec := [S,{S=Sequence(Prod(Z,Union(Z,Sequence(Z)),Sequence(Z)))},unlabeled]: seq(combstruct[count](spec,size=n), n=0..20);
  • Mathematica
    LinearRecurrence[{3,0,-1}, {1,1,4}, 40] (* G. C. Greubel, May 08 2019 *)
  • PARI
    my(x='x+O('x^40)); Vec((1-x)^2/(1-3*x+x^3)) \\ G. C. Greubel, May 08 2019
    
  • Python
    TOP = 33
    a = [1]*TOP
    a[2]=4
    for n in range(3,TOP):
        print(a[n-3], end=',')
        a[n] = 3*a[n-1] - a[n-3]
    # Alex Ratushnyak, Aug 10 2012
    
  • Sage
    ((1-x)^2/(1-3*x+x^3)).series(x, 40).coefficients(x, sparse=False) # G. C. Greubel, May 08 2019
    

Formula

G.f.: (1-x)^2/(1-3*x+x^3).
a(n) = 3*a(n-1) - a(n-3), with a(0)=a(1)=1, a(2)=4.
a(n) = Sum_{alpha = RootOf(1-3*x+x^3)} (-1/9 * (-1+2*alpha^2-2*alpha) * alpha^(-1-n)).
a(n) = A076264(n) - 2*A076264(n-1) + A076264(n-2). - R. J. Mathar, Nov 28 2011
Showing 1-2 of 2 results.