cp's OEIS Frontend

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.

Showing 1-3 of 3 results.

A176503 Leading column of triangle in A176463.

Original entry on oeis.org

1, 1, 1, 2, 4, 8, 15, 29, 57, 112, 220, 432, 848, 1666, 3273, 6430, 12632, 24816, 48754, 95783, 188177, 369696, 726312, 1426930, 2803381, 5507590, 10820345, 21257915, 41763825, 82050242, 161197933, 316693445, 622183778, 1222357651, 2401474098, 4717995460
Offset: 1

Views

Author

N. J. A. Sloane, Dec 07 2010

Keywords

Comments

a(n+1) is the number of compositions n=p(1)+p(2)+...+p(m) with p(1)=1 and p(k) <= 4*p(k+1), see example. [Joerg Arndt, Dec 18 2012]

Examples

			From _Joerg Arndt_, Dec 18 2012: (Start)
There are a(6+1)=15 compositions 6=p(1)+p(2)+...+p(m) with p(1)=1 and p(k) <= 4*p(k+1):
[ 1]  [ 1 1 1 1 1 1 ]
[ 2]  [ 1 1 1 1 2 ]
[ 3]  [ 1 1 1 2 1 ]
[ 4]  [ 1 1 1 3 ]
[ 5]  [ 1 1 2 1 1 ]
[ 6]  [ 1 1 2 2 ]
[ 7]  [ 1 1 3 1 ]
[ 8]  [ 1 1 4 ]
[ 9]  [ 1 2 1 1 1 ]
[10]  [ 1 2 1 2 ]
[11]  [ 1 2 2 1 ]
[12]  [ 1 2 3 ]
[13]  [ 1 3 1 1 ]
[14]  [ 1 3 2 ]
[15]  [ 1 4 1 ]
(End)
		

Crossrefs

Programs

  • Mathematica
    b[n_, r_, k_] := b[n, r, k] = If[n < r, 0, If[r == 0, If[n == 0, 1, 0], Sum[b[n-j, k*(r-j), k], {j, 0, Min[n, r]}]]];
    a[n_] := b[3n-2, 1, 4];
    Array[a, 40] (* Jean-François Alcover, Jul 21 2018, after Alois P. Heinz *)
  • PARI
    /* g.f. as given in the Elsholtz/Heuberger/Prodinger reference */
    N=66;  q='q+O('q^N);
    t=4;  /* t-ary: t=2 for A002572, t=3 for A176485, t=4 for A176503  */
    L=2 + 2*ceil( log(N) / log(t) );
    f(k) = (1-t^k)/(1-t);
    la(j) = prod(i=1, j, q^f(i) / ( 1 - q^f(i) ) );
    nm=sum(j=0, L, (-1)^j * q^f(j) * la(j) );
    dn=sum(j=0, L, (-1)^j * la(j) );
    gf = nm / dn;
    Vec( gf )
    /* Joerg Arndt, Dec 27 2012 */

Formula

a(n) = A294775(n-1,3). - Alois P. Heinz, Nov 08 2017

Extensions

Added terms beyond a(13)=848, Joerg Arndt, Dec 18 2012

A176431 Irregular triangle read by rows: T(n,k) = number of Huffman-equivalence classes of binary trees with n leaves and 2k leaves on the bottom level (n>=2, k>=1).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 3, 2, 5, 3, 1, 9, 5, 1, 1, 16, 9, 2, 1, 28, 16, 4, 2, 50, 28, 7, 4, 89, 50, 12, 7, 1, 159, 89, 22, 12, 2, 1, 285, 159, 39, 22, 3, 2, 510, 285, 70, 39, 22, 3, 1
Offset: 2

Views

Author

N. J. A. Sloane, Dec 07 2010

Keywords

Examples

			Triangle begins:
1
1
1 1
2 1
3 2
5 3 1
9 5 1 1
16 9 2 1
28 16 4 2
50 28 7 4
89 50 12 7 1
159 89 22 12 2 1
285 159 39 22 3 2
510 285 70 39 22 3 1
		

References

  • J. Paschke et al., Computing and estimating the number of n-ary Huffman sequences of a specified length, Discrete Math., 311 (2011), 1-7.

Crossrefs

Cf. A176452, A176463. First three columns are A002572 (twice), A002573.

A176452 Irregular triangle read by rows: T(n,k) = number of Huffman-equivalence classes of ternary trees with 2n+1 leaves and 3k leaves on the bottom level (n>=1, k>=1).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 2, 1, 7, 4, 2, 13, 7, 4, 1, 25, 13, 7, 2, 1, 48, 25, 13, 3, 2, 1, 92, 48, 25, 6, 3, 2, 176, 92, 48, 12, 6, 3, 1, 338, 176, 92, 23, 12, 6, 1
Offset: 1

Views

Author

N. J. A. Sloane, Dec 07 2010

Keywords

Examples

			Triangle begins:
1
1
1 1
2 1 1
4 2 1
7 4 2
13 7 4 1
25 13 7 2 1
48 25 13 3 2 1
92 48 25 6 3 2
176 92 48 12 6 3 1
338 176 92 23 12 6 1
		

References

  • J. Paschke et al., Computing and estimating the number of n-ary Huffman sequences of a specified length, Discrete Math., 311 (2011), 1-7.

Crossrefs

Cf. A176431. A176463. Leading column is A176485.
Showing 1-3 of 3 results.