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-3 of 3 results.

A019481 a(n) = 3*a(n-1) + a(n-2) - 2*a(n-3) (agrees with A019480 for n <= 19 only).

Original entry on oeis.org

4, 12, 37, 115, 358, 1115, 3473, 10818, 33697, 104963, 326950, 1018419, 3172281, 9881362, 30779529, 95875387, 298642966, 930245227, 2897627873, 9025842914, 28114666161, 87574585651, 272786737286, 849705465187, 2646753961545, 8244393875250
Offset: 0

Views

Author

Keywords

References

  • R. K. Guy, personal communication.

Programs

  • Magma
    I:=[4, 12, 37]; [n le 3 select I[n] else 3*Self(n-1)+Self(n-2)-2*Self(n-3): n in [1..30]]; // Vincenzo Librandi, Jan 18 2017
  • Mathematica
    LinearRecurrence[{3,1, -2}, {4, 12, 37}, 30] (* Harvey P. Dale, Jan 17 2017 *)

Formula

From R. J. Mathar, Aug 22 2008: (Start)
O.g.f.: (4 - 3*x^2)/(1 - 3*x - x^2 + 2*x^3).
a(n) = 4*A100058(n) - 3*A100058(n-2). (End)

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

Original entry on oeis.org

1, 2, 7, 21, 66, 205, 639, 1990, 6199, 19309, 60146, 187349, 583575, 1817782, 5662223, 17637301, 54938562, 171128541, 533049583, 1660400166, 5171992999, 16110279997, 50182032658, 156312391973, 486898648583, 1516644272406
Offset: 0

Views

Author

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

Keywords

Crossrefs

Programs

  • GAP
    a:=[1,2,7];; for n in [4..30] do a[n]:=3*a[n-1]+a[n-2]-2*a[n-3]; od; a; # G. C. Greubel, Oct 15 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 30); Coefficients(R!( (1-x)/(1-3*x-x^2+2*x^3) )); // G. C. Greubel, Oct 15 2019
    
  • Maple
    spec := [S,{S=Sequence(Union(Z,Prod(Union(Sequence(Z),Z,Z),Z)))},unlabeled]: seq(combstruct[count](spec,size=n), n=0..20);
  • Mathematica
    LinearRecurrence[{3,1,-2}, {1,2,7}, 30] (* G. C. Greubel, Oct 15 2019 *)
  • PARI
    my(x='x+O('x^30)); Vec((1-x)/(1-3*x-x^2+2*x^3)) \\ G. C. Greubel, Oct 15 2019
    
  • Sage
    def A052911_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P((1-x)/(1-3*x-x^2+2*x^3)).list()
    A052911_list(30) # G. C. Greubel, Oct 15 2019
    

Formula

G.f.: (1-x)/(1 - 3*x - x^2 + 2*x^3)
a(n) = 3*a(n-1) + a(n-2) - 2*a(n-3).
a(n) = Sum_{alpha=RootOf(1 - 3*z - z^2 + 2*z^3)} (1/229)*(43 + 41*alpha - 46*alpha^2)*alpha^(-1-n).
a(n) = center term in M^n * [1 1 1] where M = Hosoya's triangle considered as an upper triangular 3 X 3 matrix: [2 1 2 / 1 1 0 / 1 0 0]. E.g., a(4) = 66 since M^4 * [1 1 1] = [139 66 45]. The analogous procedure using M^n * [1 0 0] generates A100058. - Gary W. Adamson, Oct 31 2004
a(n) = A100058(n) - A100058(n-1). - R. J. Mathar, May 04 2018

Extensions

More terms from James Sellers, Jun 06 2000

A100059 First differences of A052911.

Original entry on oeis.org

1, 5, 14, 45, 139, 434, 1351, 4209, 13110, 40837, 127203, 396226, 1234207, 3844441, 11975078, 37301261, 116189979, 361921042, 1127350583, 3511592833, 10938286998, 34071752661, 106130359315, 330586256610
Offset: 1

Views

Author

Gary W. Adamson, Oct 31 2004

Keywords

Comments

a(n)/a(n-1) tends to 3.11490754148...an eigenvalue of M and a root of the characteristic polynomial x^3 - 3x^2 - x + 2.

Examples

			a(5) = 139 = rightmost term in M^5 * [1 1 1] which is [434 205 139]. 434 = a(6), while 205 = A052911(5).
a(6) = 434 = 3*a(5) + a(4) - 2*a(3) = 3*139 + 45 - 2*14.
		

References

  • Boris A. Bondarenko, Generalized Pascal Triangles and Pyramids (in Russian), FAN, Tashkent, 1990, ISBN 5-648-00738-8.

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{3,1,-2},{1,5,14},30] (* Harvey P. Dale, Apr 21 2016 *)

Formula

G.f.: (2*x^2-2*x-1)*x / (-2*x^3+x^2+3*x-1).
Recurrence: a(n) = 3*a(n-1) + a(n-2) - 2*a(n-3).
a(n) = rightmost term in M^5 * [1 1 1], where M = the 3 X 3 upper triangular matrix [2 1 2 / 1 1 0 / 1 0 0].
INVERT transform of (1, 4, 5, 6, 7, 8, 9, ...) with offset 0.

Extensions

Edited by Ralf Stephan, Nov 02 2004
Showing 1-3 of 3 results.