OFFSET
0,6
LINKS
Bruno Berselli, Table of n, a(n) for n = 0..1000
Toufik Mansour, Sherry H. F. Yan and Laura L. M. Yang, Counting occurrences of 231 in an involution, Discrete Mathematics 306 (2006), pages 564-572 (see Corollary 3.4)
Index entries for linear recurrences with constant coefficients, signature (6,-12,8).
FORMULA
G.f.: x^4*(1-2*x-2*x^2+4*x^3+2*x^4-5*x^5+3*x^6-x^7)/(1-6*x+12*x^2-8*x^3).
For n>8, a(n) = 2^(n-12)*(n^2+137*n-234). - Bruno Berselli, May 24 2012
MATHEMATICA
CoefficientList[Series[x^4(1-x)^2(1-3x^2-2x^3+x^4-x^5)/(1-2x)^3, {x, 0, 33}], x] (* Bruno Berselli, May 28 2012 *)
PROG
(PARI) Vec(x^4*(1-x)^2*(1-3*x^2-2*x^3+x^4-x^5)/(1-2*x)^3+O(x^34)) \\ show terms starting with 1. \\ Bruno Berselli, May 28 2012
(Maxima) makelist(coeff(taylor(x^4*(1-x)^2*(1-3*x^2-2*x^3+x^4-x^5)/(1-2*x)^3, x, 0, n), x, n), n, 0, 33); // Bruno Berselli, May 28 2012
(Magma) m:=40; R<x>:=PowerSeriesRing(Integers(), m); [0, 0, 0, 0] cat Coefficients(R!( x^4*(1-2*x-2*x^2+4*x^3+2*x^4-5*x^5+3*x^6-x^7)/(1-6*x +12*x^2-8*x^3) )); // G. C. Greubel, Jan 09 2019
(Sage) (x^4*(1-2*x-2*x^2+4*x^3+2*x^4-5*x^5+3*x^6-x^7)/(1-6*x +12*x^2- 8*x^3)).series(x, 40).coefficients(x, sparse=False) # G. C. Greubel, Jan 09 2019
(GAP) Concatenation([0, 0, 0, 0, 1, 4, 10, 24, 58], List([9..40], n -> 2^(n-12)*(n^2+137*n-234))); # G. C. Greubel, Jan 09 2019
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Jul 11 2011
STATUS
approved