A120757 Expansion of x^2*(2+x)/(1-3*x-4*x^2-x^3).
0, 2, 7, 29, 117, 474, 1919, 7770, 31460, 127379, 515747, 2088217, 8455018, 34233669, 138609296, 561217582, 2272323599, 9200450421, 37251863241, 150829715006, 610697048403, 2472661868474, 10011603514040, 40536155064419
Offset: 1
Examples
a(7)=1919 because M^7= [1919,3458,4312;3458,6231,7770;4312,7770,9689].
References
- R. Witula, E. Hetmaniok and D. Slota, Sums of the powers of any order roots taken from the roots of a given polynomial, Proceedings of the Fifteenth International Conference on Fibonacci Numbers and Their Applications, Eger, Hungary, 2012.
Links
- G. C. Greubel, Table of n, a(n) for n = 1..1000
- P. Steinbach, Golden fields: a case for the heptagon, Math. Mag. 70 (1997), no. 1, 22-31, MR 1439165
- Roman Witula, Ramanujan Type Trigonometric Formulas: The General Form for the Argument 2*Pi/7, Journal of Integer Sequences, Vol. 12 (2009), Article 09.8.5.
- Roman Witula, Full Description of Ramanujan Cubic Polynomials, Journal of Integer Sequences, Vol. 13 (2010), Article 10.5.7.
- Roman Witula, Ramanujan Cubic Polynomials of the Second Kind, Journal of Integer Sequences, Vol. 13 (2010), Article 10.7.5.
- Roman Witula, Ramanujan Type Trigonometric Formulae, Demonstratio Math. 45 (2012) 779-796.
- Index entries for linear recurrences with constant coefficients, signature (3,4,1).
Programs
-
Magma
a:=[0,2,7]; [ n le 3 select a[n] else 3*Self(n-1) + 4*Self(n-2) + Self(n-3): n in [1..25]]; // Marius A. Burtea, Oct 03 2019
-
Maple
with(linalg): M[1]:=matrix(3,3,[0,1,1,1,1,2,1,2,2]): for n from 2 to 25 do M[n]:=multiply(M[1],M[n-1]) od: seq(M[n][1,1],n=1..25);
-
Mathematica
LinearRecurrence[{3,4,1},{0,2,7},40] (* Roman Witula, Aug 02 2012 *)
-
PARI
a(n)=([0,1,0; 0,0,1; 1,4,3]^(n-1)*[0;2;7])[1,1] \\ Charles R Greathouse IV, Jun 22 2016
-
SageMath
@CachedFunction def a(n): # a = A120757 if (n<3): return (0,2,7)[n] else: return 3*a(n-1) + 4*a(n-2) + a(n-3) [a(n) for n in range(40)] # G. C. Greubel, Nov 25 2022
Formula
a(n) = 3*a(n-1) + 4*a(n-2) + a(n-3) (follows from the minimal polynomial of the matrix M). See also the o.g.f. given in the name.
Extensions
Edited by N. J. A. Sloane, Dec 03 2006
New name, old name as comment; o.g.f.; reference.
Comments