login
A116815
Number of permutations of length n which avoid the patterns 1234, 1432, 3241.
0
1, 2, 6, 21, 70, 199, 502, 1232, 2962, 6970, 16138, 36982, 84083, 189918, 426722, 954884, 2129756, 4737382, 10514539, 23294911, 51533491, 113864171, 251330512, 554292891, 1221605912, 2690738608, 5923829534, 13036444247, 28679413033
OFFSET
1,2
FORMULA
G.f.: x (2x^10 +4x^9 +9x^8 +9x^7 +4x^6 -18x^5 -15x^4 -5x^3 -x^2+x-1)/((x-1) (x^3+x^2+x-1) (x^5+3x^4+2x^3+x^2+x-1))
MAPLE
cn := [-1, 2, 0, -1, -7, -19, -19, 6, 12, 10, 4, 2] ;
p := add(cn[i]*x^(i-1), i=1..nops(cn)) ;
q := (x-1)*(x^5+3*x^4+2*x^3+x^2+x-1)*(x^3+x^2+x-1) ;
taylor(p/q, x=0, 40) ;
gfun[seriestolist](%) ; # R. J. Mathar, Nov 07 2017
MATHEMATICA
Join[{1, 2}, LinearRecurrence[{3, -1, 0, -2, -4, -1, 2, 3, 1}, {6, 21, 70, 199, 502, 1232, 2962, 6970, 16138}, 30]] (* Harvey P. Dale, Nov 18 2014 *)
CROSSREFS
Sequence in context: A116756 A116813 A116765 * A116804 A116832 A116811
KEYWORD
nonn,easy
AUTHOR
Lara Pudwell, Feb 26 2006
STATUS
approved