A343006 Internal path length of the rooted tree with Matula-Goebel number n.
0, 0, 1, 0, 3, 1, 1, 0, 2, 3, 6, 1, 3, 1, 4, 0, 3, 2, 1, 3, 2, 6, 5, 1, 6, 3, 3, 1, 6, 4, 10, 0, 7, 3, 4, 2, 3, 1, 4, 3, 6, 2, 3, 6, 5, 5, 8, 1, 2, 6, 4, 3, 1, 3, 9, 1, 2, 6, 6, 4, 5, 10, 3, 0, 6, 7, 3, 3, 6, 4, 6, 2, 5, 3, 7, 1, 7, 4, 10, 3, 4, 6, 9, 2, 6, 3, 7, 6, 3, 5, 4, 5, 11, 8, 4, 1, 11, 2, 8, 6
Offset: 1
Keywords
Examples
a(7) = 1 because the rooted tree with Matula-Goebel number 7 is the rooted tree Y (0+1). a(2^m) = 0 because the rooted tree with Matula-Goebel number 2^m is a star with m edges and therefore has only one internal node: its root. a(3^m) = m because the rooted tree with Matula-Goebel number 3^m is a star with m branches of length 2, so the internal nodes are the root and the m nodes attached to it.
Links
- E. 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.
- D. Matula, A natural rooted tree enumeration by prime factorization, SIAM Rev. 10 (1968) 273.
- Index entries for sequences related to Matula-Goebel numbers
Programs
-
PARI
InIpl(n)={ if(n==1, return([0,0]), my(f=factor(n)~, v=Mat(vector(#f,k,InIpl(primepi(f[1,k]))~)) ); return( [ 1+sum(k=1,#f,v[1,k]*f[2,k]) , sum(k=1,#f,(v[1,k]+v[2,k])*f[2,k]) ] ) ) }; A343006(n) = InIpl(n)[2];
Comments