A228360 Table read by antidiagonals: T(l,L) is the number of all possible covers of L-length line segment by l-length line segments with allowed gaps < l.
0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 2, 0, 0, 0, 1, 2, 1, 0, 0, 0, 1, 3, 2, 0, 0, 0, 0, 1, 4, 3, 1, 0, 0, 0, 0, 1, 5, 3, 2, 0, 0, 0, 0, 0, 1, 7, 4, 3, 1, 0, 0, 0, 0, 0, 1, 9, 6, 4, 2, 0, 0, 0, 0, 0, 0, 1, 12, 8, 4, 3, 1, 0, 0, 0, 0, 0, 0
Offset: 1
Examples
Table starts: 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ... 0, 0, 1, 2, 2, 3, 4, 5, 7, 9, 12, 16, 21, 28, 37, ... 0, 0, 0, 1, 2, 3, 3, 4, 6, 8, 10, 13, 18, 24, 31, ... 0, 0, 0, 0, 1, 2, 3, 4, 4, 5, 7, 10, 13, 16, 20, ... 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 5, 6, 8, 11, 15, ... 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 6, 7, 9, ... 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 7, ... 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, ... 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, ... 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, ... 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, ... 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, ... 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, ... 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, ... .....................................................
Programs
-
Mathematica
Gf[l_, z] := (1 - Sum[z^i, {i, l, 2 l - 1}])^-1*Sum[z^i, {i, 0, l - 1}]^2*z^l T[l_, L_] := CoefficientList[Series[Gf[l, z], {z, 0, 100}], z][[L + 1]] Table[T[n - b + 1, b - 1], {n, 1, 30}, {b, n, 1, -1}] // Flatten
Formula
For all l>=1:
G.f.: (1 - Sum[x^i, {i, l, 2 l - 1}])^-1*Sum[x^i, {i, 0, l - 1}]^2*x^l.
G.f. for l=1: x/(1-x).
G.f. for l=2: x^2*(1+x)^2/(1-x^2-x^3).
G.f. for l=3: x^3*(1 + x + x^2)^2/(1 - x^3 - x^4 - x^5).
For l>1, L>=0:
c[k, l, m] = Sum[(-1)^i binomial[k - 1 - i*l, m - 1] binomial[m, i], {i, 0, floor[(k - m)/l]}] // number of compositions of k into exactly m parts which do not exceed l.
a[L, l, m] = Sum[ binomial[m + 1, m + 1 - j]*c[L - l*m, l - 1, j], {j, 0, m + 1}] //the number of all possible covers of L-length line segment by m l-length line segments.
T[l, L] := Sum[a[L, l, j], {j, 1, ceiling[L/l]}].
Comments