OFFSET
5,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 5..1000
S. Kitaev, J. Remmel and M. Tiefenbruck, Marked mesh patterns in 132-avoiding permutations I, arXiv preprint arXiv:1201.6243 [math.CO], 2012-2014.
Index entries for linear recurrences with constant coefficients, signature (9,-30,46,-33,9).
FORMULA
From Vaclav Kotesovec, Nov 25 2012: (Start)
a(n) = ((2*n-11)*3^(n-2)+2*n^2-2*n+3)/16
Recurrence: a(n) = 9*a(n-1) - 30*a(n-2) + 46*a(n-3) - 33*a(n-4) + 9*a(n-5)
G.f.: -((1-9*x+30*x^2-46*x^3+33*x^4)/(9*(-1+x)^3*(-1+3*x)^2))
(End)
MATHEMATICA
CCC[t] = (1 - (1 - 4*t)^(1/2))/(2*t); NQ0[t, x] = ((1 + t - t*x) - ((1 + t - t*x)^2 - 4*t)^(1/2))/(2*t); NQ1[t, x] = 1/(1 - t*NQ0[t, x]); NQ2[t, x] = 1/(1 - t*NQ1[t, x]); NQ3[t, x] = 1/(1 - t*NQ2[t, x]); NQ4[t, x] = 1/(1 - t*NQ3[t, x]); CoefficientList[Coefficient[Simplify[Series[NQ4[t, x], {t, 0, 20}]], x], t] (* Robert Price, Jun 06 2012 *)
LinearRecurrence[{9, -30, 46, -33, 9}, {1, 9, 51, 235, 966}, 50] (* Vincenzo Librandi, Nov 25 2012 *)
PROG
(Magma) I:=[1, 9, 51, 235, 966]; [n le 5 select I[n] else 9*Self(n-1) - 30*Self(n-2)+ 46*Self(n-3) - 33*Self(n-4) + 9*Self(n-5): n in [1..30]]; // Vincenzo Librandi, Nov 25 2012
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert Price, Jun 06 2012
STATUS
approved