This site is supported by donations to The OEIS Foundation.

Thanks to everyone who made a donation during our annual appeal!
To see the list of donors, or make a donation, see the OEIS Foundation home page.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A196055 The terminal Wiener index of the rooted tree with Matula-Goebel number n. 0
 0, 1, 2, 2, 3, 3, 6, 6, 4, 4, 4, 8, 8, 8, 5, 12, 8, 10, 12, 10, 10, 5, 10, 15, 6, 10, 12, 16, 10, 12, 5, 20, 6, 10, 12, 18, 15, 15, 12, 18, 10, 19, 16, 12, 14, 12, 12, 24, 20, 14, 12, 19, 20, 21, 7, 26, 18, 12, 10, 21, 18, 6, 22, 30, 14, 14, 15, 20, 14, 22, 18, 28, 19, 18, 16, 26, 14, 22, 12, 28, 24, 12, 12, 30, 14, 19, 14, 21, 24, 24 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,3 COMMENTS The terminal Wiener index of a connected graph is the sum of the distances between all pairs of nodes of degree 1. The Matula-Goebel number of a rooted tree can be defined in the following recursive manner: to the one-vertex tree there corresponds the number 1; to a tree T with root degree 1 there corresponds the t-th prime number, where t is the Matula-Goebel number of the tree obtained from T by deleting the edge emanating from the root; to a tree T with root degree m>=2 there corresponds the product of the Matula-Goebel numbers of the m branches of T. REFERENCES F. Goebel, On a 1-1-correspondence between rooted trees and natural numbers, J. Combin. Theory, B 29 (1980), 141-143. I. Gutman, B. Furtula and M. Petrovic, Terminal Wiener index, J. Math. Chem., 46. 2009, 522-531. 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 Review, 10, 1968, 273. LINKS E. Deutsch, Tree statistics from Matula numbers, arXiv preprint arXiv:1111.4288, 2011 FORMULA Let LV(m) and EPL(m) denote the number of leaves and the external path length, respectively, of the rooted tree with Matula number m (see A109129 and A196048, where LV(m) and EPL(m) are obtained recursively). a(1)=0; if n=p(t) (=the t-th prime) and t is prime, then a(n)=a(t)+LV(t); if n=p(t) (=the t-th prime) and t is not prime, then a(n)=a(t)+LV(t)+EPL(t). Now assume that n is not prime; it can be written n=rs, where r is prime and s>=2. If s is prime, then a(n)=a(r)-EPL(r)+a(s)-EPL(s)+EPL(r)*LV(s) + EPL(s)*LV(r); if s is not prime, then a(n)=a(r)-EPL(r)+a(s)+EPL(r)*LV(s) + EPL(s)*LV(r); The Maple program is based on this recursive formula. EXAMPLE a(7)=6 because the rooted tree with Matula-Goebel number 7 is the rooted tree Y (2+2+2=6). if m>2 then a(2^m) = m(m-1) because the rooted tree with Matula-Goebel number 2^m is a star with m edges and the vertices of each of the binom(m,2) pairs of nodes of degree 1 are at distance 2. MAPLE with(numtheory): TW := proc (n) local r, s, LV, EPL, Tw: r := proc (n) options operator, arrow: op(1, factorset(n)) end proc: s := proc (n) options operator, arrow: n/r(n) end proc: LV := proc (n) if n = 1 then 0 elif n = 2 then 1 elif bigomega(n) = 1 then LV(pi(n)) else LV(r(n))+LV(s(n)) end if end proc: EPL := proc (n) if n = 1 then 0 elif n = 2 then 1 elif bigomega(n) = 1 then EPL(pi(n))+LV(pi(n)) else EPL(r(n))+EPL(s(n)) end if end proc: Tw := proc (n) if n = 1 then 0 elif bigomega(n) = 1 then Tw(pi(n)) else Tw(r(n))+Tw(s(n))+EPL(r(n))*LV(s(n))+EPL(s(n))*LV(r(n)) end if end proc: if n = 1 then 0 elif bigomega(n) = 1 and bigomega(pi(n)) = 1 then TW(pi(n))+LV(pi(n)) elif bigomega(n) = 1 then TW(pi(n))+EPL(n) else Tw(r(n))+Tw(s(n))+EPL(r(n))*LV(s(n))+EPL(s(n))*LV(r(n)) end if end proc; seq(TW(n), n = 1 .. 90); CROSSREFS Cf. A109129, A196048, A196051. Sequence in context: A175175 A116417 A271410 * A145787 A096111 A101081 Adjacent sequences:  A196052 A196053 A196054 * A196056 A196057 A196058 KEYWORD nonn AUTHOR Emeric Deutsch, Sep 29 2011 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified January 18 16:40 EST 2019. Contains 319271 sequences. (Running on oeis4.)