OFFSET
1,2
COMMENTS
The Matula-Goebel number of a rooted tree is the product of primes indexed by the Matula-Goebel numbers of the branches of its root, which gives a bijective correspondence between positive integers and unlabeled rooted trees.
LINKS
EXAMPLE
The terms together with their corresponding rooted trees begin:
1: o
4: (oo)
12: (oo(o))
14: (o(oo))
18: (o(o)(o))
19: ((ooo))
21: ((o)(oo))
27: ((o)(o)(o))
40: (ooo((o)))
52: (oo(o(o)))
60: (oo(o)((o)))
68: (oo((oo)))
70: (o((o))(oo))
74: (o(oo(o)))
78: (o(o)(o(o)))
86: (o(o(oo)))
89: ((ooo(o)))
90: (o(o)(o)((o)))
MATHEMATICA
MGTree[n_]:=If[n==1, {}, MGTree/@Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]];
Select[Range[100], Count[MGTree[#], {}, {0, Infinity}]==Depth[MGTree[#]]-1&]
CROSSREFS
A034781 counts trees by nodes and height.
KEYWORD
nonn
AUTHOR
Gus Wiseman, Nov 25 2022
STATUS
approved