[go: up one dir, main page]

login
Number of rooted bicolored trees on n nodes such that black nodes are not adjacent to each other.
5

%I #9 Jan 09 2021 22:13:01

%S 2,3,9,28,97,346,1302,5014,19830,79813,326344,1350918,5652334,

%T 23861787,101519790,434827232,1873491739,8114411769,35309142309,

%U 154288183928,676730773252,2978405318453,13149337960554,58218455727085,258435947527696,1149982662789042

%N Number of rooted bicolored trees on n nodes such that black nodes are not adjacent to each other.

%H Andrew Howroyd, <a href="/A339831/b339831.txt">Table of n, a(n) for n = 1..500</a>

%e a(1) = 2: B, W.

%e a(2) = 3: B(W), W(B), W(W).

%e a(3) = 9: B(WW), W(BB), W(BW), W(WW), B(W(B)), B(W(W)), W(B(W)), W(W(B)), W(W(W)).

%o (PARI) EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}

%o seq(n)={my(u=v=[]); for(n=1, n, my(t=concat([1], EulerT(v))); v=concat([1], EulerT(u + v)); u=t); u + v}

%Y Cf. A038055 (rooted bicolored trees), A339830 (unrooted case), A339835, A339838.

%K nonn

%O 1,1

%A _Andrew Howroyd_, Dec 19 2020