login
Triangle read by rows: T(n,k) is the number of full binary trees with n leaves, each internal node having the heights of its two subtrees weakly increasing left to right, and with k internal nodes having two subtrees of equal height.
1

%I #11 Apr 03 2023 21:47:36

%S 1,0,1,0,1,0,0,1,0,1,0,1,1,1,0,0,1,2,2,1,0,0,1,4,3,2,2,0,0,1,6,7,6,3,

%T 0,1,0,1,9,13,14,9,3,1,0,0,1,12,27,27,22,14,3,1,0,0,1,16,47,59,54,32,

%U 16,7,0,0,0,1,20,81,117,125,91,44,20,8,1,0

%N Triangle read by rows: T(n,k) is the number of full binary trees with n leaves, each internal node having the heights of its two subtrees weakly increasing left to right, and with k internal nodes having two subtrees of equal height.

%H Andrew Howroyd, <a href="/A360985/b360985.txt">Table of n, a(n) for n = 1..1275</a> (rows 1..50).

%F T(n,2) = A002620(n-3) for all n>=3.

%F T(n,n-1) = 1 if n is a power of 2, and T(n,n) = 0 otherwise.

%F T(n,n-2) != 0 if and only if n-1 has exactly one maximal group of consecutive zeros in its binary representation, and in this case T(n,n-2) = 2^(a-1) where a is the number of 1s at the beginning of the binary representation of n-1.

%F Sum_{k=0..n-1} T(n,k)*2^(n-k-1) = A000108(n-1).

%e The table for T(n,k) begins:

%e n\k 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

%e 1 1

%e 2 0 1

%e 3 0 1 0

%e 4 0 1 0 1

%e 5 0 1 1 1 0

%e 6 0 1 2 2 1 0

%e 7 0 1 4 3 2 2 0

%e 8 0 1 6 7 6 3 0 1

%e 9 0 1 9 13 14 9 3 1 0

%e 10 0 1 12 27 27 22 14 3 1 0

%e 11 0 1 16 47 59 54 32 16 7 0 0

%e 12 0 1 20 81 117 125 91 44 20 8 1 0

%e 13 0 1 25 128 233 272 228 143 61 23 8 2 0

%e 14 0 1 30 197 439 573 555 389 206 90 21 10 2 0

%e 15 0 1 36 287 801 1178 1275 1014 621 303 109 32 4 4 0

%e 16 0 1 42 410 1383 2367 2841 2522 1727 962 421 138 36 7 0 1

%o (PARI) T(n)={my(p=x+O(x*x^n), q=p); for(n=2, n, p=y*p^2 + p*(q-p); q+=p); my(v=Vec(q)); vector(#v, n, Vecrev(v[n], n))}

%o { my(A=T(12)); for(n=1, #A, print(A[n])) } \\ _Andrew Howroyd_, Mar 24 2023

%Y Row sums give A045761.

%Y Column k=2 is A002620.

%Y Cf. A000108, A335833.

%K nonn,tabl

%O 1,18

%A _Ludovic Schwob_, Feb 27 2023