A078802 Triangular array T given by T(n,k) = number of 01-words of length n containing k 1's, no three of which are consecutive.
1, 1, 1, 1, 2, 1, 1, 3, 3, 0, 1, 4, 6, 2, 0, 1, 5, 10, 7, 1, 0, 1, 6, 15, 16, 6, 0, 0, 1, 7, 21, 30, 19, 3, 0, 0, 1, 8, 28, 50, 45, 16, 1, 0, 0, 1, 9, 36, 77, 90, 51, 10, 0, 0, 0, 1, 10, 45, 112, 161, 126, 45, 4, 0, 0, 0, 1, 11, 55, 156, 266, 266, 141, 30, 1, 0, 0, 0, 1, 12, 66, 210, 414
Offset: 0
Examples
T(4,3) = 2 counts 1+0+1+1 and 1+1+0+1. Top of triangle T: 1; 1, 1; 1, 2, 1; 1, 3, 3, 0; 1, 4, 6, 2, 0;
References
- Clark Kimberling, Binary words with restricted repetitions and associated compositions of integers, in Applications of Fibonacci Numbers, vol. 10, Proceedings of the Eleventh International Conference on Fibonacci Numbers and Their Applications, William Webb, editor, Congressus Numerantium, Winnipeg, Manitoba 194 (2009) 141-151.
Programs
-
Maple
seq(seq(sum(binomial(n+1-k,k-j)*binomial(k-j,j),j=0..ceil((k-1)/2)),k=0..n),n=0..20); # Dennis P. Walsh, Apr 04 2012
-
Mathematica
nn=15; a=1+y x+y^2 x^2;f[list_]:=Select[list,#>0&];Map[f,CoefficientList[Series[a/(1-x a),{x,0,nn}],{x,y}]]//Grid (* Geoffrey Critzer, Sep 15 2012 *)
Formula
T(n, k) = T(n-1, k) + T(n-2, k-1) + T(n-3, k-2) with initial values as in first 3 rows.
T(n,k) = Sum_{j=0..ceiling((k-1)/2)} C(n+1-k, k-j)*C(k-j, j). - Dennis P. Walsh, Apr 04 2012
G.f.: (1 + y*x + y^2*x^2)/(1 - (x*(1 + y*x + y^2*x^2))). - Geoffrey Critzer, Sep 15 2012
Comments