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.
%I A246187 #13 Nov 07 2015 03:23:40 %S A246187 1,0,1,0,2,1,0,0,5,1,0,0,4,9,1,0,0,0,17,14,1,0,0,0,8,46,20,1,0,0,0,0, %T A246187 49,100,27,1,0,0,0,0,16,180,190,35,1,0,0,0,0,0,129,510,329,44,1,0,0,0, %U A246187 0,0,32,603,1225,532,54,1,0,0,0,0,0,0,321,2121,2618,816,65,1,0,0,0,0,0,0,64,1827,6202,5124,1200,77,1 %N A246187 Triangle read by rows: T(n,k) is the number of weighted lattice paths in F[n] having length k (length = number of steps). The members of F[n] are paths of weight n that start at (0,0), do not go below the horizontal axis, and whose steps are of the following four kinds: an (1,0)-step with weight 1, an (1,0)-step with weight 2, a (1,1)-step with weight 2, and a (1,-1)-step with weight 1. The weight of a path is the sum of the weights of its steps. %C A246187 The paths need not end on the horizontal axis. %C A246187 Number of entries in row n is n+1. %C A246187 Sum of entries in row n is A182905(n). %C A246187 Sum of entries in column k is A001700(k). %H A246187 Alois P. Heinz, <a href="/A246187/b246187.txt">Rows n = 0..140, flattened</a> %H A246187 M. Bona and A. Knopfmacher, <a href="http://dx.doi.org/10.1007/s00026-010-0060-7">On the probability that certain compositions have the same number of parts</a>, Ann. Comb., 14 (2010), 291-306. %F A246187 G.f.: G(t,z) = g/(1-t*z^2*g), where g=g(t,z) satisfies g = 1 + t*z*g + t*z^2*g +t^2*z^3*g^2. %F A246187 The g.f. G(t,z) satisfies t*z^2*(1 - 2*t*z - 2*t*z^2) + (1 - t*z - 3*t*z^2)*G - 1 = 0. %e A246187 Row 2 is 0,2,1; indeed, the weight-2 paths are hh, H, and U (where h=(1,0) of weight 1, H=(1,0) of weight 2, and U=(1,1)) and their lengths are 2,1,and 1, respectively. %e A246187 Triangle starts: %e A246187 1; %e A246187 0,1; %e A246187 0,2,1; %e A246187 0,0,5,1; %e A246187 0,0,4,9,1; %p A246187 eq := t*z^2*(1-2*t*z-2*t*z^2)*G^2+(1-t*z-3*t*z^2)*G-1 = 0: GG := RootOf(eq, G): Gser := simplify(series(GG, z = 0, 20)): for n from 0 to 18 do P[n] := sort(expand(coeff(Gser, z, n))) end do; for n from 0 to 18 do seq(coeff(P[n], t, j), j = 0 .. n) end do; # yields sequence in triangular form %p A246187 # second Maple program: %p A246187 b:= proc(n, y) option remember; `if`(y<0, 0, %p A246187 `if`(n=0, 1, expand(x*(b(n-1, y) +b(n-1, y-1)+ %p A246187 `if`(n>1, b(n-2, y) +b(n-2, y+1), 0))))) %p A246187 end: %p A246187 T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n, 0)): %p A246187 seq(T(n), n=0..14); # _Alois P. Heinz_, Aug 29 2014 %t A246187 b[n_, y_] := b[n, y] = If[y<0, 0, If[n==0, 1, Expand[x*(b[n-1, y] + b[n-1, y-1] + If[n>1, b[n-2, y] + b[n-2, y+1], 0])]]]; T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, n}]][b[n, 0]]; Table[T[n], {n, 0, 14}] // Flatten (* _Jean-François Alcover_, Nov 07 2015, after _Alois P. Heinz_ *) %Y A246187 Cf. A182905, A001700. %K A246187 nonn,tabl %O A246187 0,5 %A A246187 _Emeric Deutsch_, Aug 29 2014