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 A132843 #15 Sep 08 2024 19:25:24 %S A132843 1,2,9,72,1296,52407,5240052,1314516033,853923545352,1457086698392796, %T A132843 6631460154689418828,81384300080656595328843, %U A132843 2719577128999047606509974434,249432083657086432899494832228657 %N A132843 a(n) = A005704( A037480(n) ) for n>0 with a(0)=1, where A005704 = number of partitions of 3n into powers of 3 and A037480(n) = n-th number having alternating base-3 digits 1, 2 (starting with '1'). %H A132843 Alois P. Heinz, <a href="/A132843/b132843.txt">Table of n, a(n) for n = 0..40</a> %F A132843 a(n) = A005704( (5*3^n + (-1)^n - 6)/8 ). %e A132843 Let b(n) = A005704(n) = number of partitions of 3n into powers of 3, %e A132843 then the initial terms of this sequence begin: %e A132843 b(0), b(1), b(5), b(16), b(50), b(151), b(455), b(1366),... %e A132843 APPLICATION: SPECIAL TERNARY TREE. %e A132843 a(n) = number of nodes in generation n of the following tree. %e A132843 Start at generation 0 with a single root node labeled [2]. %e A132843 From then on, each parent node [k] is attached k child nodes with %e A132843 labels congruent to 2(mod 3) for even n, or 3(mod 3) for odd n, %e A132843 within the range {1..3k}, for generation n >= 0. %e A132843 The initial generations 0..3 of the tree begin as follows; %e A132843 the path from the root node is given, followed by child nodes in []. %e A132843 GEN.0: [2]; %e A132843 GEN.1: 2->[3,6]; %e A132843 GEN.2: %e A132843 2-3->[2,5,8] %e A132843 2-6->[2,5,8,11,14,17]; %e A132843 GEN.3: %e A132843 2-3-2->[3,6] %e A132843 2-3-5->[3,6,9,12,15] %e A132843 2-3-8->[3,6,9,12,15,18,21,24] %e A132843 2-6-2->[3,6] %e A132843 2-6-5->[3,6,9,12,15] %e A132843 2-6-8->[3,6,9,12,15,18,21,24] %e A132843 2-6-11->[3,6,9,12,15,18,21,24,27,30,33] %e A132843 2-6-14->[3,6,9,12,15,18,21,24,27,30,33,36,39,42] %e A132843 2-6-17->[3,6,9,12,15,18,21,24,27,30,33,36,39,42,45,48,51] . %e A132843 Note: largest node label in generation n is A037480(n) + 1, %e A132843 and the sum of the labels in generation n equals a(n+1). %o A132843 (PARI) {A005704(n) = if(n<1, n==0, A005704(n\3) + A005704(n-1))} %o A132843 {a(n) = A005704( (5*3^n + (-1)^n - 6)/8 )} %Y A132843 Cf. A005704, A037480; variant: A132880. %K A132843 nonn,base %O A132843 0,2 %A A132843 _Paul D. Hanna_, Sep 27 2007