cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A334154 a(n) is the number of length n decorated permutations avoiding the pattern 012.

This page as a plain text file.
%I A334154 #22 May 18 2020 07:00:58
%S A334154 1,2,5,15,54,236,1254,7986,59584,509304,4897272,52237448,611460432,
%T A334154 7787383488,107155194928,1583776282704,25019083516416,420609003810944,
%U A334154 7496930998018176,141203784944996736,2802115237399913728,58432523737192745472,1277372108617847278848
%N A334154 a(n) is the number of length n decorated permutations avoiding the pattern 012.
%C A334154 A decorated permutation of length n is a word w=w_1...w_n on the letters {0,...,n} such that the restriction of w to its nonzero entries is an ordinary permutation in one-line notation. Then w avoids the pattern 012 if there is no subword w_{i_1}w_{i_2}w_{i_3} with i_1 < i_2 < i_3 such that w_{i_1} = 0 and 0 < w_{i_2} < w_{i_3}.
%F A334154 a(n) = n! + Sum_{j=1..n} Sum_{l=1..n-j+1} binomial(n-l,j-1)*binomial(n-j,l-1)*(l-1)!.
%e A334154 For n=3, there are 16 decorated permutations of length 3 (000, 001, 010, 100, 012, 102, 120, 021, 201, 210, 123, 132, 213, 231, 312, and 321). All of these avoid 012 except 012 itself. Therefore, a(3) = 15.
%e A334154 For n=5, 02031 is a decorated permutation that does not avoid 012 because it contains the subword 023.
%o A334154 (PARI) a(n) = n! + sum(j=1, n, sum(l=1, n-j+1, binomial(n-l,j-1)*binomial(n-j,l-1)*(l-1)!)); \\ _Michel Marcus_, May 11 2020
%Y A334154 Cf. A334155, A334156.
%K A334154 nonn
%O A334154 0,2
%A A334154 _Jordan Weaver_, Apr 16 2020