OFFSET
1,1
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
Vincenzo Librandi, Table of n, a(n) for n = 1..10000
EXAMPLE
The terms together with their corresponding rooted trees begin:
2: (o)
6: (o(o))
7: ((oo))
18: (o(o)(o))
20: (oo((o)))
21: ((o)(oo))
26: (o(o(o)))
34: (o((oo)))
37: ((oo(o)))
43: ((o(oo)))
54: (o(o)(o)(o))
60: (oo(o)((o)))
63: ((o)(o)(oo))
67: (((ooo)))
70: (o((o))(oo))
78: (o(o)(o(o)))
88: (ooo(((o))))
91: ((oo)(o(o)))
MATHEMATICA
MGTree[n_]:=If[n==1, {}, MGTree/@Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]];
Select[Range[337], Count[MGTree[#], {}, {0, Infinity}]==Count[MGTree[#], _[__], {0, Infinity}]&]
PROG
(Magma) PrimePi:=func< p |#PrimesUpTo(p)>; function C(n) if n eq 1 then return <1, 0>; end if; L:=0; I:=0; for t in Factorization(n) do for j in [1..t[2]]do c:=C(PrimePi(t[1]));
L+:=c[1]; I+:=c[2]; end for; end for; return <L, I+1>; end function; N:=150; seq:=[]; n:=1;
while #seq lt N do c:=C(n); if c[1] eq c[2] then Append(~seq, n); end if; n+:=1; end while;
seq; // Vincenzo Librandi, Mar 15 2026
KEYWORD
nonn
AUTHOR
Gus Wiseman, Nov 25 2022
STATUS
approved
