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-10 of 27 results. Next

A290689 Number of transitive rooted trees with n nodes.

Original entry on oeis.org

1, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 88, 143, 229, 370, 592, 955, 1527, 2457, 3929, 6304, 10081
Offset: 1

Views

Author

Gus Wiseman, Oct 19 2017

Keywords

Comments

A rooted tree is transitive if every proper terminal subtree is also a branch of the root. First differs from A206139 at a(13) = 143.
Regarding the notation, a rooted tree is a finite multiset of rooted trees. For example, the rooted tree (o(o)(oo)) is short for {{},{{}},{{},{}}}. Each "o" is a leaf. Each pair of parentheses corresponds to a non-leaf node (such as the root). Its contents "(...)" represent a branch. - Gus Wiseman, Nov 16 2024

Examples

			The a(7) = 8 7-node transitive rooted trees are: (o(oooo)), (oo(ooo)), (o(o)((o))), (o(o)(oo)), (ooo(oo)), (oo(o)(o)), (oooo(o)), (oooooo).
		

Crossrefs

The restriction to identity trees (A004111) is A279861, ranks A290760.
These trees are ranked by A290822.
The anti-transitive version is A306844, ranks A324758.
The totally transitive case is A318185 (by leaves A318187), ranks A318186.
A version for integer partitions is A324753, for subsets A324736.
The ordered version is A358453, ranks A358457, undirected A358454.

Programs

  • Mathematica
    nn=18;
    rtall[n_]:=If[n===1,{{}},Module[{cas},Union[Sort/@Join@@(Tuples[rtall/@#]&/@IntegerPartitions[n-1])]]];
    Table[Length[Select[rtall[n],Complement[Union@@#,#]==={}&]],{n,nn}]

Extensions

a(20) from Robert Price, Sep 13 2018
a(21)-a(22) from Robert P. P. McKone, Dec 16 2023

A290822 Transitive numbers: Matula-Goebel numbers of transitive rooted trees.

Original entry on oeis.org

1, 2, 4, 6, 8, 12, 14, 16, 18, 24, 28, 30, 32, 36, 38, 42, 48, 54, 56, 60, 64, 72, 76, 78, 84, 90, 96, 98, 106, 108, 112, 114, 120, 126, 128, 138, 144, 150, 152, 156, 162, 168, 180, 192, 196, 210, 212, 216, 222, 224, 228, 234, 238, 240, 252, 256, 262, 266, 270
Offset: 1

Views

Author

Gus Wiseman, Oct 19 2017

Keywords

Comments

A number x is transitive if whenever prime(y) divides x and prime(z) divides y, we have prime(z) divides x.

Examples

			The sequence of transitive rooted trees begins:
1  o
2  (o)
4  (oo)
6  (o(o))
8  (ooo)
12 (oo(o))
14 (o(oo))
16 (oooo)
18 (o(o)(o))
24 (ooo(o))
28 (oo(oo))
30 (o(o)((o)))
32 (ooooo)
36 (oo(o)(o))
38 (o(ooo))
42 (o(o)(oo))
48 (oooo(o))
54 (o(o)(o)(o))
56 (ooo(oo))
60 (oo(o)((o)))
64 (oooooo)
72 (ooo(o)(o))
76 (oo(ooo))
78 (o(o)(o(o)))
84 (oo(o)(oo))
90 (o(o)(o)((o)))
96 (ooooo(o))
98 (o(oo)(oo))
		

Crossrefs

Programs

  • Mathematica
    primeMS[n_]:=If[n===1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    subprimes[n_]:=If[n===1,{},Union@@Cases[FactorInteger[n],{p_,_}:>FactorInteger[PrimePi[p]][[All,1]]]];
    Select[Range[270],Divisible[#,Times@@subprimes[#]]&]

A306844 Number of anti-transitive rooted trees with n nodes.

Original entry on oeis.org

1, 1, 2, 3, 7, 14, 36, 83, 212, 532, 1379, 3577, 9444, 25019, 66943, 179994, 487031, 1323706, 3614622, 9907911
Offset: 1

Views

Author

Gus Wiseman, Mar 13 2019

Keywords

Comments

A rooted tree is anti-transitive if the subbranches are disjoint from the branches, i.e., no branch of a branch is a branch.

Examples

			The a(1) = 1 through a(6) = 14 anti-transitive rooted trees:
  o  (o)  (oo)   (ooo)    (oooo)     (ooooo)
          ((o))  ((oo))   ((ooo))    ((oooo))
                 (((o)))  (((oo)))   (((ooo)))
                          ((o)(o))   ((o)(oo))
                          ((o(o)))   ((o(oo)))
                          (o((o)))   ((oo(o)))
                          ((((o))))  (o((oo)))
                                     (oo((o)))
                                     ((((oo))))
                                     (((o)(o)))
                                     (((o(o))))
                                     ((o((o))))
                                     (o(((o))))
                                     (((((o)))))
		

Crossrefs

Programs

  • Mathematica
    rtall[n_]:=Union[Sort/@Join@@(Tuples[rtall/@#]&/@IntegerPartitions[n-1])];
    Table[Length[Select[rtall[n],Intersection[Union@@#,#]=={}&]],{n,10}]

Extensions

a(16)-a(20) from Jinyuan Wang, Jun 20 2020

A303431 Aperiodic tree numbers. Matula-Goebel numbers of aperiodic rooted trees.

Original entry on oeis.org

1, 2, 3, 5, 6, 10, 11, 12, 13, 15, 18, 20, 22, 24, 26, 29, 30, 31, 33, 37, 39, 40, 41, 44, 45, 47, 48, 50, 52, 54, 55, 58, 60, 61, 62, 65, 66, 71, 72, 74, 75, 78, 79, 80, 82, 87, 88, 89, 90, 93, 94, 96, 99, 101, 104, 108, 109, 110, 111, 113, 116, 117, 120, 122
Offset: 1

Views

Author

Gus Wiseman, Apr 23 2018

Keywords

Comments

A positive integer is an aperiodic tree number iff either it is equal to 1 or it belongs to A007916 (numbers that are not perfect powers, or numbers whose prime multiplicities are relatively prime) and all of its prime indices are also aperiodic tree numbers, where a prime index of n is a number m such that prime(m) divides n.

Examples

			Sequence of aperiodic rooted trees begins:
01 o
02 (o)
03 ((o))
05 (((o)))
06 (o(o))
10 (o((o)))
11 ((((o))))
12 (oo(o))
13 ((o(o)))
15 ((o)((o)))
18 (o(o)(o))
20 (oo((o)))
22 (o(((o))))
24 (ooo(o))
26 (o(o(o)))
29 ((o((o))))
30 (o(o)((o)))
31 (((((o)))))
33 ((o)(((o))))
		

Crossrefs

Programs

  • Mathematica
    zapQ[1]:=True;zapQ[n_]:=And[GCD@@FactorInteger[n][[All,2]]===1,And@@zapQ/@PrimePi/@FactorInteger[n][[All,1]]];
    Select[Range[100],zapQ]

A318185 Number of totally transitive rooted trees with n nodes.

Original entry on oeis.org

1, 1, 1, 2, 3, 5, 7, 12, 17, 28, 41, 65, 96, 150, 221, 342, 506, 771, 1142, 1731, 2561, 3855, 5702, 8538, 12620, 18817, 27774, 41276, 60850, 90139
Offset: 1

Views

Author

Gus Wiseman, Aug 20 2018

Keywords

Comments

A rooted tree is totally transitive if every branch of the root is totally transitive and every branch of a branch of the root is also a branch of the root. Unlike transitive rooted trees (A290689), every terminal subtree of a totally transitive rooted tree is itself totally transitive.

Examples

			The a(8) = 12 totally transitive rooted trees:
  (o(o)(o(o)))
  (o(o)(o)(o))
  (o(o)(ooo))
  (o(oo)(oo))
  (oo(o)(oo))
  (ooo(o)(o))
  (o(ooooo))
  (oo(oooo))
  (ooo(ooo))
  (oooo(oo))
  (ooooo(o))
  (ooooooo)
The a(9) = 17 totally transitive rooted trees:
  (o(o)(oo(o)))
  (oo(o)(o(o)))
  (o(o)(o)(oo))
  (oo(o)(o)(o))
  (o(o)(oooo))
  (o(oo)(ooo))
  (oo(o)(ooo))
  (oo(oo)(oo))
  (ooo(o)(oo))
  (oooo(o)(o))
  (o(oooooo))
  (oo(ooooo))
  (ooo(oooo))
  (oooo(ooo))
  (ooooo(oo))
  (oooooo(o))
  (oooooooo)
		

Crossrefs

Programs

  • Mathematica
    totra[n_]:=totra[n]=If[n==1,{{}},Join@@Table[Select[Union[Sort/@Tuples[totra/@c]],Complement[Union@@#,#]=={}&],{c,IntegerPartitions[n-1]}]];
    Table[Length[totra[n]],{n,20}]

A324753 Number of integer partitions of n containing all prime indices of their parts.

Original entry on oeis.org

1, 1, 1, 2, 2, 4, 5, 7, 8, 14, 16, 23, 29, 40, 49, 66, 81, 109, 133, 172, 211, 274, 332, 419, 511, 640, 775, 965, 1165, 1434, 1730, 2109, 2530, 3083, 3683, 4447, 5308, 6375, 7573, 9062, 10730, 12786, 15104, 17909, 21095, 24937, 29284, 34488, 40421, 47450
Offset: 0

Views

Author

Gus Wiseman, Mar 16 2019

Keywords

Comments

These could be described as transitive integer partitions.
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The a(1) = 1 through a(8) = 8 integer partitions:
  (1)  (11)  (21)   (211)   (41)     (321)     (421)      (3221)
             (111)  (1111)  (221)    (411)     (2221)     (4211)
                            (2111)   (2211)    (3211)     (22211)
                            (11111)  (21111)   (4111)     (32111)
                                     (111111)  (22111)    (41111)
                                               (211111)   (221111)
                                               (1111111)  (2111111)
                                                          (11111111)
		

Crossrefs

The subset version is A324736. The strict case is A324748. The Heinz number version is A290822. An infinite version is A324698.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],SubsetQ[#,PrimePi/@First/@Join@@FactorInteger/@DeleteCases[#,1]]&]],{n,0,30}]

A301345 Regular triangle where T(n,k) is the number of transitive rooted trees with n nodes and k leaves.

Original entry on oeis.org

1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 2, 1, 0, 0, 0, 1, 3, 1, 0, 0, 0, 1, 2, 4, 1, 0, 0, 0, 0, 3, 4, 5, 1, 0, 0, 0, 0, 2, 6, 6, 6, 1, 0, 0, 0, 0, 1, 6, 10, 9, 7, 1, 0, 0, 0, 0, 1, 5, 12, 16, 12, 8, 1, 0, 0, 0, 0, 0, 4, 13, 22, 23, 16, 9, 1, 0, 0, 0, 0, 0, 3, 14, 27, 36, 32, 20, 10, 1, 0, 0, 0, 0, 0, 2, 11
Offset: 1

Views

Author

Gus Wiseman, Mar 19 2018

Keywords

Examples

			Triangle begins:
1
1   0
0   1   0
0   1   1   0
0   0   2   1   0
0   0   1   3   1   0
0   0   1   2   4   1   0
0   0   0   3   4   5   1   0
0   0   0   2   6   6   6   1   0
0   0   0   1   6  10   9   7   1   0
0   0   0   1   5  12  16  12   8   1   0
The T(9,5) = 6 transitive rooted trees: (o(o)(oo(o))), (o((oo))(oo)), (oo(o)(o(o))), (o(o)(o)(oo)), (ooo(o)((o))), (oo(o)(o)(o)).
		

Crossrefs

Programs

  • Mathematica
    rut[n_]:=rut[n]=If[n===1,{{}},Join@@Function[c,Union[Sort/@Tuples[rut/@c]]]/@IntegerPartitions[n-1]];
    trat[n_]:=Select[rut[n],Complement[Union@@#,#]==={}&];
    Table[Length[Select[trat[n],Count[#,{},{-2}]===k&]],{n,15},{k,n}]

A324748 Number of strict integer partitions of n containing all prime indices of the parts.

Original entry on oeis.org

1, 1, 0, 1, 0, 1, 1, 1, 0, 2, 1, 2, 3, 2, 2, 4, 3, 4, 3, 5, 6, 9, 8, 7, 8, 11, 12, 13, 15, 17, 22, 22, 20, 28, 31, 32, 36, 41, 43, 53, 53, 59, 70, 76, 77, 89, 99, 108, 124, 135, 139, 160, 172, 188, 209, 229, 243, 274, 298, 315, 353, 391, 417, 457, 496, 538, 588
Offset: 0

Views

Author

Gus Wiseman, Mar 15 2019

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The first 15 terms count the following integer partitions.
   1: (1)
   3: (2,1)
   5: (4,1)
   6: (3,2,1)
   7: (4,2,1)
   9: (8,1)
   9: (6,2,1)
  10: (4,3,2,1)
  11: (8,2,1)
  11: (5,3,2,1)
  12: (9,2,1)
  12: (7,4,1)
  12: (6,3,2,1)
  13: (8,4,1)
  13: (6,4,2,1)
  14: (8,3,2,1)
  14: (7,4,2,1)
  15: (12,2,1)
  15: (9,3,2,1)
  15: (8,4,2,1)
  15: (5,4,3,2,1)
An example for n = 6 is (20,18,11,5,3,2,1), with prime indices:
  20: {1,1,3}
  18: {1,2,2}
  11: {5}
   5: {3}
   3: {2}
   2: {1}
   1: {}
All of these prime indices {1,2,3,5} belong to the partition, as required.
		

Crossrefs

The subset version is A324736. The non-strict version is A324753. The Heinz number version is A290822. An infinite version is A324698.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],UnsameQ@@#&&SubsetQ[#,PrimePi/@First/@Join@@FactorInteger/@DeleteCases[#,1]]&]],{n,0,30}]

A184155 The Matula-Goebel number of rooted trees having all leaves at the same level.

Original entry on oeis.org

1, 2, 3, 4, 5, 7, 8, 9, 11, 16, 17, 19, 21, 23, 25, 27, 31, 32, 49, 53, 57, 59, 63, 64, 67, 73, 81, 83, 85, 97, 103, 115, 121, 125, 127, 128, 131, 133, 147, 159, 171, 189, 227, 241, 243, 256, 269, 277, 289, 307, 311, 331, 335, 343, 361, 365, 367, 371, 391, 393, 399, 419, 425, 431, 439, 441, 477
Offset: 1

Views

Author

Emeric Deutsch, Oct 07 2011

Keywords

Comments

The Matula-Goebel number of a rooted tree can be defined in the following recursive manner: to the one-vertex tree there corresponds the number 1; to a tree T with root degree 1 there corresponds the t-th prime number, where t is the Matula-Goebel number of the tree obtained from T by deleting the edge emanating from the root; to a tree T with root degree m>=2 there corresponds the product of the Matula-Goebel numbers of the m branches of T.
The sequence is infinite.

Examples

			7 is in the sequence because the rooted tree with Matula-Goebel number 7 is the rooted tree Y, having all leaves at level 2.
2^m is in the sequence for each positive integer m because the rooted tree with Matula-Goebel number 2^m is a star with m edges.
From _Gus Wiseman_, Mar 30 2018: (Start)
Sequence of trees begins:
01 o
02 (o)
03 ((o))
04 (oo)
05 (((o)))
07 ((oo))
08 (ooo)
09 ((o)(o))
11 ((((o))))
16 (oooo)
17 (((oo)))
19 ((ooo))
21 ((o)(oo))
23 (((o)(o)))
25 (((o))((o)))
27 ((o)(o)(o))
31 (((((o)))))
(End)
		

References

  • F. Goebel, On a 1-1-correspondence between rooted trees and natural numbers, J. Combin. Theory, B 29 (1980), 141-143.
  • I. Gutman and A. Ivic, On Matula numbers, Discrete Math., 150, 1996, 131-142.
  • I. Gutman and Yeong-Nan Yeh, Deducing properties of trees from their Matula numbers, Publ. Inst. Math., 53 (67), 1993, 17-22.
  • D. W. Matula, A natural rooted tree enumeration by prime factorization, SIAM Review, 10, 1968, 273.

Crossrefs

Programs

  • Maple
    with(numtheory): P := proc (n) local r, s: r := proc (n) options operator, arrow: op(1, factorset(n)) end proc: s := proc (n) options operator, arrow: n/r(n) end proc: if n = 1 then 1 elif bigomega(n) = 1 then sort(expand(x*P(pi(n)))) else sort(P(r(n))+P(s(n))) end if end proc: A := {}: for n to 500 do if degree(numer(subs(x = 1/x, P(n)))) = 0 then A := `union`(A, {n}) else  end if end do: A;
  • Mathematica
    primeMS[n_]:=If[n===1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    dep[n_]:=If[n===1,0,1+Max@@dep/@primeMS[n]];
    rnkQ[n_]:=And[SameQ@@dep/@primeMS[n],And@@rnkQ/@primeMS[n]];
    Select[Range[2000],rnkQ] (* Gus Wiseman, Mar 30 2018 *)

Formula

In A184154 one constructs for each n the generating polynomial P(n,x) of the leaves of the rooted tree with Matula-Goebel number n, according to their levels. The Maple program finds those n (between 1 and 500) for which P(n,x) is a monomial.

A298120 Matula-Goebel numbers of rooted trees in which all positive outdegrees are odd.

Original entry on oeis.org

1, 2, 3, 5, 8, 11, 12, 18, 19, 20, 27, 30, 31, 32, 37, 44, 45, 48, 50, 61, 66, 67, 71, 72, 75, 76, 80, 99, 103, 108, 110, 113, 114, 120, 124, 125, 127, 128, 131, 148, 157, 162, 165, 171, 176, 180, 186, 190, 192, 193, 197, 200, 222, 223, 229, 242, 243, 244, 264
Offset: 1

Views

Author

Gus Wiseman, Jan 12 2018

Keywords

Examples

			Sequence of trees begins:
1  o
2  (o)
3  ((o))
5  (((o)))
8  (ooo)
11 ((((o))))
12 (oo(o))
18 (o(o)(o))
19 ((ooo))
20 (oo((o)))
27 ((o)(o)(o))
30 (o(o)((o)))
31 (((((o)))))
32 (ooooo)
37 ((oo(o)))
44 (oo(((o))))
45 ((o)(o)((o)))
48 (oooo(o))
50 (o((o))((o)))
		

Crossrefs

Programs

  • Mathematica
    primeMS[n_]:=If[n===1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    otQ[n_]:=Or[n===1,With[{m=primeMS[n]},OddQ@Length@m&&And@@otQ/@m]];
    Select[Range[1000],otQ]
Showing 1-10 of 27 results. Next