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-6 of 6 results.

A300352 Number of strict trees of weight n with distinct leaves.

Original entry on oeis.org

1, 1, 2, 2, 3, 6, 8, 11, 17, 40, 48, 76, 109, 159, 400, 470, 745, 1057, 1576, 2103, 5267, 6022, 9746, 13390, 20099, 26542, 39396, 82074, 101387, 152291, 215676, 308937, 423587, 596511, 799022, 1623311, 1960223, 2947722, 4048704, 5845982, 7794809, 11028888
Offset: 1

Views

Author

Gus Wiseman, Mar 03 2018

Keywords

Comments

A strict tree of weight n > 0 is either a single node of weight n, or a sequence of two or more strict trees with strictly decreasing weights summing to n.

Examples

			The a(8) = 11 strict trees with distinct leaves: 8, (71), ((52)1), ((43)1), (62), ((51)2), (53), ((41)3), (5(21)), (521), (431).
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=
    Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    str[q_]:=str[q]=If[Length[q]===1,1,Total[Times@@@Map[str,Select[sps[q],And[Length[#]>1,UnsameQ@@Total/@#]&],{2}]]];
    Table[Total[str/@Select[IntegerPartitions[n],UnsameQ@@#&]],{n,1,20}]

Formula

a(n) = Sum_{i=1..A000009(n)} A294018(A246867(n,i)).

A300354 Number of enriched p-trees of weight n with distinct leaves.

Original entry on oeis.org

1, 1, 1, 2, 2, 3, 8, 8, 13, 17, 54, 56, 98, 125, 195, 500, 606, 921, 1317, 1912, 2635, 6667, 7704, 12142, 16958, 24891, 33388, 47792, 106494, 126475, 195475, 268736, 393179, 523775, 750251, 979518, 2090669, 2457315, 3759380, 5066524, 7420874, 9726501, 13935546
Offset: 0

Views

Author

Gus Wiseman, Mar 03 2018

Keywords

Comments

An enriched p-tree of weight n > 0 is either a single node of weight n, or a sequence of two or more enriched p-trees with weakly decreasing weights summing to n.

Examples

			The a(6) = 8 enriched p-trees with distinct leaves: 6, (42), (51), ((31)2), ((32)1), (3(21)), ((21)3), (321).
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    ept[q_]:=ept[q]=If[Length[q]===1,1,Total[Times@@@Map[ept,Join@@Function[sptn,Join@@@Tuples[Permutations/@GatherBy[sptn,Total]]]/@Select[sps[q],Length[#]>1&],{2}]]];
    Table[Total[ept/@Select[IntegerPartitions[n],UnsameQ@@#&]],{n,1,30}]

Formula

a(n) = Sum_{i=1..A000009(n)} A299203(A246867(n,i)).

A300355 Number of enriched p-trees of weight n with odd leaves.

Original entry on oeis.org

1, 1, 1, 3, 6, 16, 47, 132, 410, 1254, 4052, 12818, 42783, 139082, 469924, 1563606, 5353966, 18065348, 62491018, 213391790, 743836996, 2565135934, 8994087070, 31251762932, 110245063771, 385443583008, 1365151504722, 4800376128986, 17070221456536, 60289267885410
Offset: 0

Views

Author

Gus Wiseman, Mar 03 2018

Keywords

Comments

An enriched p-tree of weight n > 0 is either a single node of weight n, or a sequence of two or more enriched p-trees with weakly decreasing weights summing to n.

Examples

			The a(5) = 16 enriched p-trees of weight with odd leaves:
5,
((31)1), ((((11)1)1)1), (((111)1)1), (((11)(11))1), (((11)11)1), ((1111)1),
(3(11)), (((11)1)(11)), ((111)(11)),
(311), (((11)1)11), ((111)11),
((11)(11)1),
((11)111),
(11111).
		

Crossrefs

Programs

  • Mathematica
    c[n_]:=c[n]=If[EvenQ[n],0,1]+Sum[Times@@c/@y,{y,Select[IntegerPartitions[n],Length[#]>1&]}];
    Table[c[n],{n,30}]
  • PARI
    seq(n)={my(v=vector(n)); for(n=1, n, v[n] = n%2 + polcoef(1/prod(k=1, n-1, 1 - v[k]*x^k + O(x*x^n)), n)); concat([1], v)} \\ Andrew Howroyd, Aug 26 2018

Formula

O.g.f: (1 + x/(1-x^2) + Prod_{i>0} 1/(1 - a(i)x^i))/2.
a(n) = Sum_{i=1..A000009(n)} A299203(A300351(n,i)).

A300440 Number of odd strict trees of weight n (all outdegrees are odd).

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 2, 3, 5, 7, 11, 18, 27, 45, 75, 125, 207, 353, 591, 1013, 1731, 2984, 5122, 8905, 15369, 26839, 46732, 81850, 142932, 251693, 441062, 778730, 1370591, 2425823, 4281620, 7601359, 13447298, 23919512, 42444497, 75632126, 134454505, 240100289
Offset: 1

Views

Author

Gus Wiseman, Mar 05 2018

Keywords

Comments

An odd strict tree of weight n is either a single node of weight n, or a finite odd-length sequence of at least 3 odd strict trees with strictly decreasing weights summing to n.

Examples

			The a(10) = 7 odd strict trees: 10, (721), (631), (541), (532), ((421)21), ((321)31).
		

Crossrefs

Programs

  • Mathematica
    g[n_]:=g[n]=1+Sum[Times@@g/@y,{y,Select[IntegerPartitions[n],Length[#]>1&&OddQ[Length[#]]&&UnsameQ@@#&]}];
    Array[g,20]
  • PARI
    seq(n)={my(v=vector(n)); for(n=1, n, v[n] = 1 + polcoef(prod(k=1, n-1, 1 + v[k]*x^k + O(x*x^n)) - prod(k=1, n-1, 1 - v[k]*x^k + O(x*x^n)), n)/2); v} \\ Andrew Howroyd, Aug 25 2018

A300652 Number of enriched p-trees of weight 2n + 1 in which all outdegrees and all leaves are odd.

Original entry on oeis.org

1, 2, 4, 12, 40, 136, 496, 1952, 7488, 30368, 123456, 512384, 2129664, 9068672, 38391552, 165642752, 713405952, 3109135872, 13528865792, 59591322624, 261549260800, 1159547047936, 5131968999424, 22883893137408, 101851069587456, 456703499042816, 2042949493276672
Offset: 0

Views

Author

Gus Wiseman, Mar 10 2018

Keywords

Comments

An enriched p-tree of weight n > 0 is either a single node of weight n, or a finite sequence of at least two enriched p-trees whose weights are weakly decreasing and sum to n.

Examples

			The a(3) = 12 trees:
7,
(511), (331),
((111)31), (3(111)1), ((311)11), (31111),
((111)(111)1), (((111)11)11), ((11111)11), ((111)1111), (1111111).
		

Crossrefs

Programs

  • Mathematica
    r[n_]:=r[n]=If[OddQ[n],1,0]+Sum[Times@@r/@y,{y,Select[IntegerPartitions[n],Length[#]>1&&OddQ[Length[#]]&]}];
    Table[r[n],{n,1,40,2}]
  • PARI
    seq(n)={my(v=vector(n)); for(n=1, n, v[n] = 1 + polcoef(1/prod(k=1, n-1, 1 - v[k]*x^(2*k-1) + O(x^(2*n))) - 1/prod(k=1, n-1, 1 + v[k]*x^(2*k-1) + O(x^(2*n))), 2*n-1)/2); v} \\ Andrew Howroyd, Aug 26 2018

Formula

a(n) = (1 - (-1)^n)/2 + Sum_y Product_{i in y} a(i) where the sum is over all non-singleton integer partitions of n with an odd number of parts.

A300797 Number of strict trees of weight 2n + 1 in which all outdegrees and all leaves are odd.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 4, 6, 11, 17, 34, 59, 118, 213, 424, 799, 1606, 3072, 6216, 12172, 24650, 48710, 99333, 198237, 405526, 815267, 1673127, 3387165, 6974702, 14179418, 29285048, 59841630, 123848399, 253927322, 526936694, 1084022437, 2253778793, 4649778115
Offset: 0

Views

Author

Gus Wiseman, Mar 13 2018

Keywords

Comments

A strict tree of weight n > 0 is either a single node of weight n, or a sequence of two or more strict trees with strictly decreasing weights summing to n.

Examples

			The a(7) = 6 strict trees: 15, (11 3 1), (9 5 1), (7 5 3), ((7 3 1) 3 1), ((5 3 1) 5 1).
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=a[n]=If[OddQ[n],1,0]+Sum[Times@@a/@ptn,{ptn,Select[IntegerPartitions[n],Length[#]>1&&OddQ[Length[#]]&&UnsameQ@@#&]}];
    Table[a[n],{n,1,60,2}]
  • PARI
    seq(n)={my(v=vector(n)); for(n=1, n, v[n] = 1 + polcoef(prod(k=1, n-1, 1 + v[k]*x^(2*k-1) + O(x^(2*n))) - prod(k=1, n-1, 1 - v[k]*x^(2*k-1) + O(x^(2*n))), 2*n-1)/2); v} \\ Andrew Howroyd, Aug 26 2018

Extensions

a(30)-a(37) from Alois P. Heinz, Mar 13 2018
Showing 1-6 of 6 results.