OFFSET
2,5
COMMENTS
LINKS
M. Bousquet-Mélou and A. Rechnitzer, The site-perimeter of bargraphs, Adv. in Appl. Math. 31 (2003), 86-112.
Emeric Deutsch, S. Elizalde, Statistics on bargraphs viewed as cornerless Motzkin paths, arXiv preprint arXiv:1609.00088 [math.CO], 2016.
FORMULA
G.f.: G = G(t,z) satisfies aG^2 + bG + c = 0, where a = z(1-t^2*z-t^2*z^3+t^4*z^3), b = -t(1-3z+z^2+tz^2-t^2*z^2-z^3+2t^2*z^3+tz^4-2t^3*z^4+t^2*z^4), c = t^2*z^2*(t+z-2tz-tz^2+t^2*z^2).
EXAMPLE
Row 4 is 3,1,0,1 because the 5 (=A082582(4)) bargraphs of semiperimeter 4 correspond to the compositions [1,1,1],[1,2],[2,1],[2,2],[3] and the corresponding drawings show that the lengths of the longest initial sequence of the form UHUH... are 2,4,1,1,1, respectively.
Triangle starts
0,1;
1,1;
3,1,0,1;
8,2,1,2;
22,5,4,3,0,1;
MAPLE
a := z*(1-t^2*z-t^2*z^3+t^4*z^3): b := -t*(1-3*z+z^2+t*z^2-t^2*z^2-z^3+2*t^2*z^3+t*z^4-2*t^3*z^4+t^2*z^4): c := t^2*z^2*(t+z-2*t*z-t*z^2+t^2*z^2): eq := a*G^2+b*G+c = 0: G := RootOf(eq, G): Gser := simplify(series(G, z = 0, 21)): for n from 2 to 18 do P[n] := sort(expand(coeff(Gser, z, n))) end do: for n from 2 to 18 do seq(coeff(P[n], t, j), j = 1 .. 2*floor((1/2)*n)) end do; # yields sequence in triangular form
MATHEMATICA
nmax = 12;
a = z (1 - t^2 z - t^2 z^3 + t^4 z^3);
b = -t (1 - 3z + z^2 + t z^2 - t^2 z^2 - z^3 + 2t^2 z^3 + t z^4 - 2t^3 z^4 + t^2 z^4);
c = t^2 z^2 (t + z - 2t z - t z^2 + t^2 z^2);
G = 0; Do[G = Series[(-c - a G^2)/b, {z, 0, nmax}, {t, 0, nmax}] // Normal, {nmax}];
cc = CoefficientList[G, z];
row[n_] := CoefficientList[cc[[n+1]], t] // Rest;
Table[row[n], {n, 2, nmax}] // Flatten (* Jean-François Alcover, Jul 25 2018 *)
CROSSREFS
KEYWORD
nonn,tabf
AUTHOR
Emeric Deutsch, Sergi Elizalde, Aug 26 2016
STATUS
approved