A184160 Number of root subtrees in the rooted tree with Matula-Goebel number n.
1, 2, 3, 4, 4, 6, 5, 8, 9, 8, 5, 12, 7, 10, 12, 16, 6, 18, 9, 16, 15, 10, 10, 24, 16, 14, 27, 20, 9, 24, 6, 32, 15, 12, 20, 36, 13, 18, 21, 32, 8, 30, 11, 20, 36, 20, 13, 48, 25, 32, 18, 28, 17, 54, 20, 40, 27, 18, 7, 48, 19, 12, 45, 64, 28, 30, 10, 24, 30, 40, 17, 72, 16, 26, 48, 36, 25, 42, 11, 64, 81, 16, 11, 60, 24
Offset: 1
Examples
a(2^m) = 2^m because the rooted tree with Matula-Goebel number 2^m is a star with m edges (each edge can be included or not in the subtree).
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..10000
- É. Czabarka, L. Székely, and S. Wagner, The inverse problem for certain tree parameters, Discrete Appl. Math., 157, 2009, 3314-3319.
- Emeric Deutsch, Tree statistics from Matula numbers, arXiv preprint arXiv:1111.4288 [math.CO], 2011.
- 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 Rev. 10 (1968) 273.
- Index entries for sequences related to Matula-Goebel numbers
Crossrefs
Cf. A184161.
Programs
-
Maple
with(numtheory): a := 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 1+a(pi(n)) else a(r(n))*a(s(n)) end if end proc: seq(a(n), n = 1 .. 85);
-
Mathematica
a[1] = 1; a[p_?PrimeQ] := a[p] = 1+a[PrimePi[p]]; a[n_] := a[n] = With[{f = FactorInteger[n]}, Times @@ ((a /@ f[[All, 1]])^f[[All, 2]])]; Array[a, 100] (* Jean-François Alcover, May 03 2017 *)
-
PARI
a(n)={my(f=factor(n)); prod(i=1, #f~, my([p,e]=f[i,]); (1 + a(primepi(p)))^e)} \\ Andrew Howroyd, Aug 01 2018
Formula
a(1)=1; if n=prime(t), then a(n)=1+a(t); if n=r*s (r,s,>=2), then a(n)=a(r)a(s). The Maple program is based on this recursive formula.
Completely multiplicative with a(prime(t)) = 1 + a(t). - Andrew Howroyd, Aug 01 2018
Comments