login
A394137
G.f. A(x) satisfies (1-x)*A(x)^3+(3x-2)*A(x)^2+(1-x)*A(x)+x^2-x=0.
2
0, 1, 2, 6, 21, 81, 334, 1444, 6463, 29695, 139255, 663817, 3207057, 15668163, 77274843, 384221651, 1923893753, 9692937761, 49101121091, 249935367839, 1277744991383, 6557730926365, 33775001481244, 174514216113442, 904355547895403, 4699102486549625
OFFSET
0,3
COMMENTS
Number of n-vertex planar rooted trees with vertices colored red, blue, and green with blue root where red vertices can only be followed by blue vertices, blue vertices can be followed by red or green vertices, and green vertices can only be followed by red vertices.
LINKS
S. Dimitrov, N. Fox, K. Hadaway, A. Tharp, and S. Wagner, Counting Colored Trees, arXiv:2602.16055 [math.CO], 2026.
FORMULA
a(n) ~ 11^(1/4) * 2^(n - 5/2) * 3^(2*n - 7/4) / (sqrt(Pi) * n^(3/2) * (9 - sqrt(33))^(n - 3/2)). - Vaclav Kotesovec, Jun 04 2026
PROG
(Python)
def A394137(n):
A = [[0, 1, 0], [1, 0, 1], [1, 0, 0]]
if n == 0:
return 0
m = len(A)
output = [[1] for i in range(m)]
for l in range(2, n + 1):
for i in range(m):
term = 0
for k in range(1, l):
for j in range(m):
term += A[i][j] * output[i][k - 1] * output[j][l - k - 1]
output[i].append(term)
return output[1][n - 1]
CROSSREFS
Cf. A394136.
Sequence in context: A279565 A150214 A150215 * A328434 A150216 A150217
KEYWORD
nonn
AUTHOR
Nathan Fox, Mar 11 2026
STATUS
approved