A206494 Number of ways to take apart the rooted tree corresponding to the Matula-Goebel number n by sequentially removing terminal edges.
1, 1, 1, 2, 1, 3, 2, 6, 6, 4, 1, 12, 3, 8, 10, 24, 2, 30, 6, 20, 20, 5, 6, 60, 20, 15, 90, 40, 4, 60, 1, 120, 15, 10, 40, 180, 12, 30, 45, 120, 3, 120, 8, 30, 210, 36, 10, 360, 80, 140, 30, 90, 24, 630, 35, 240, 90, 24, 2, 420, 30, 6, 420, 720, 105, 105, 6, 60, 126, 280, 20, 1260
Offset: 1
Keywords
Examples
a(7)=2 because the rooted tree with Matula-Goebel number 7 is Y; denoting the edges in preorder by 1,2,3, it can be taken apart either in the order 231 or 321. a(11) = 1 because the rooted tree with Matula-Goebel number 11 is the path tree with 5 vertices; any path tree can be taken apart in only one way.
References
- D. E. Knuth, The Art of Computer Programming, Vol.3, 2nd edition, Addison-Wesley, Reading, MA, 1998.
Links
- Kevin Ryde, Table of n, a(n) for n = 1..10000
- Emeric Deutsch, Tree statistics from Matula numbers, arXiv:1111.4288 [math.CO], 2011.
- J. Fulman, Mixing time for a random walk on rooted trees, The Electronic J. of Combinatorics, 16, 2009, R139.
- 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.
- Kevin Ryde, PARI/GP Code
- B. E. Sagan and Y.-N. Yeh, Probabilistic algorithms for trees, The Fibonacci Quarterly, 27, 1989, 201-208. [_Emeric Deutsch_, Apr 28 2015]
- Index entries for sequences related to Matula-Goebel numbers
Programs
-
Maple
with(numtheory): E := 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 0 elif bigomega(n) = 1 then 1+E(pi(n)) else E(r(n))+E(s(n)) end if end proc: 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 a(pi(n)) else a(r(n))*a(s(n))*binomial(E(r(n))+E(s(n)), E(r(n))) end if end proc: seq(a(n), n = 1 .. 72);
-
Mathematica
r[n_] := FactorInteger[n][[1, 1]]; s[n_] := n/r[n]; e[n_] := e[n] = Which[n == 1, 0, PrimeOmega[n] == 1, 1+e[PrimePi[n]], True, e[r[n]] + e[s[n]]]; a[n_] := a[n] = Which[n == 1, 1, PrimeOmega[n] == 1, a[PrimePi[n]], True, a[r[n]]*a[s[n]]*Binomial[e[r[n]] + e[s[n]], e[r[n]]] ]; Table[a[n], {n, 1, 72}] (* Jean-François Alcover, Aug 06 2024, after Maple program, replacing E(n) with e[n] *)
-
PARI
\\ See links.
Formula
a(prime(m)) = a(m); a(r*s) = a(r)*a(s)*binomial(E(r*s),E(r)), where E(k) is the number of edges of the rooted tree with Matula-Goebel number k. The Maple program is based on these recurrence relations.
Comments