A092923 Number of permutations containing exactly one occurrence of the pattern #, with # one of {1-23, 3-21, 12-3, 32-1}.
1, 7, 39, 211, 1168, 6728, 40561, 256297, 1696707, 11752973, 85047284, 641782220, 5041634549, 41160207335, 348664792199, 3059885806071, 27781291314396, 260599397789924, 2522492941426381, 25166308238897929, 258507111338795491, 2731176458973448817
Offset: 3
Keywords
Links
- Alois P. Heinz, Table of n, a(n) for n = 3..500
- A. Claesson and T. Mansour, Counting patterns of type (1,2) or (2,1), arXiv:math/0110036 [math.CO], 2001.
Crossrefs
Column k=1 of A260665.
Programs
-
Mathematica
a[n_ /; n<3] = 0; a[n_] := a[n] = 2 a[n-1] + Sum[Binomial[n-2, k] (a[k+1] + BellB[k+1]), {k, 0, n-3}]; Table[a[n], {n, 3, 24}] (* Jean-François Alcover, Aug 19 2018 *)
-
PARI
a(n)=if(n<1,0,2*a(n-1)+sum(k=0,n-3,binomial(n-2,k)*(a(k+1)+polcoeff(serlaplace(exp(exp(x)-1)),k+1))))
Formula
G.f.: Sum_{n>=1} (x/(1-n*x)) * Sum_{k>=0} k*x^(k+n)/Product_{l=1..k+n} (1-l*x).
Recurrence: a(n) = 2a(n-1) + Sum_{k=0..n-3} C(n-2, k)*(a(k+1) + B(k+1)), with B(n) the Bell numbers A000110(n).