login
Triangular array read by rows, arising from enumeration of binary words containing n 0's and k 1's that avoid the pattern 0100010.
2

%I #16 Oct 06 2024 10:29:06

%S 1,2,1,6,3,1,20,10,4,1,70,35,15,5,1,248,126,56,21,6,1,894,457,210,84,

%T 28,7,1,3264,1674,786,330,120,36,8,1,12036,6183,2947,1280,495,165,45,

%U 9,1,44722,22997,11080,4933,1994,715,220,55,10,1

%N Triangular array read by rows, arising from enumeration of binary words containing n 0's and k 1's that avoid the pattern 0100010.

%C This is a Riordan array.

%H Alois P. Heinz, <a href="/A246971/b246971.txt">Rows n = 0..200, flattened</a> (first 16 rows from Chai Wah Wu)

%H D. Baccherini, D. Merlini, R. Sprugnoli, <a href="http://dx.doi.org/10.1016/j.disc.2006.07.023">Binary words excluding a pattern and proper Riordan arrays</a>, Discrete Math. 307 (2007), no. 9-10, 1021--1037. MR2292531 (2008a:05003).

%e Array begins:

%e 1;

%e 2, 1;

%e 6, 3, 1;

%e 20, 10, 4, 1;

%e 70, 35, 15, 5, 1;

%e 248, 126, 56, 21, 6, 1;

%e 894, 457, 210, 84, 28, 7, 1;

%e 3264, 1674, 786, 330, 120, 36, 8, 1;

%e ...

%o (Python)

%o from itertools import combinations

%o A246971_list = []

%o for n in range(10):

%o for k in range(n, -1, -1):

%o c, d0 = 0, ['0']*(n+k)

%o for x in combinations(range(n+k), n):

%o d = list(d0)

%o for i in x:

%o d[i] = '1'

%o if not '0100010' in ''.join(d):

%o c += 1

%o A246971_list.append(c) # _Chai Wah Wu_, Sep 12 2014

%Y Cf. A239103.

%K nonn,tabl

%O 0,2

%A _N. J. A. Sloane_, Sep 11 2014

%E More terms from _Chai Wah Wu_, Sep 12 2014