5

There is a scene in Goodwill Hunting where professor challenges students with task of finding all homeomorphically irreducible trees of degree $10$. This is discussed in many places, such as here and is by itself a relatively easy to solve puzzle.

The most tricky part in that task, at least for me, is to decide if I have already found every such tree or something is missing. So here comes the question: how to calculate, how much homeomorphically irreducible trees of degree $N$ there are?

I've tried to find if such problem is already solved, but I was finding only various variants of Goodwill Hunting discussions. Is there a formula or algorithm for it? How to cope with that task?

Cettt
  • 2,494
  • 1
    What do you mean by the "degree" of a tree? If you mean the maximum degree, there are infinitely many homeomorphically irreducible trees of maximum degree $3.$ – bof Feb 10 '17 at 20:52
  • Polya enumeration theorem is pretty useful for counting all non isomorphic graphs with n vertex. https://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theoremhttps://en.wikipedia.org/wiki/P%C3%B3lya_enumeration_theorem demonstrates n=3 and n=4 – Mars Sep 06 '21 at 18:13
  • @bof: here it means the number of vertices. – Qiaochu Yuan Sep 20 '23 at 00:38

2 Answers2

0

Yes there is, but I must admit that I don't fully understand it (http://oeis.org/A000014), as I am not a Mathematician. I found the number of trees for n=11 to be 14, and I discovered a way to grind through determining all trees using a method invented by me in under 4 minutes specifically for the task, but these mathematicians already came up with the formula. I found the site with the formula from http://mathworld.wolfram.com/Series-ReducedTree.html

The method I used was fun in and of itself. I listed the trees for n=11 as follows:
1(10)
2(2,7); 2(3,6); 2(4,5)
3(2,1,5); 3(2,2,4); 3(2,3,3); 3(2,4,2); 3(3,1,4); 3(3,2,3)
4(2,1,1,3); 4(2,2,1,2)
H(0)3(2,2,3)
H(1)3(2,2,2)

Where H(1)3(2,2,2)=

 >+<
  ^

H(1) means a hub from which only 1 branch is a direct end a hub is a node from which >2 branches are not direct ends

Using this method I was able to easily deduce that there were 14 trees for n=11, and induce that there must be a formula.

Seth
  • 1
0

There is actually an easier way to do this; if we use notation such as {2,1,1,2,5} means: ">-<" with one of the nodes on the right side linked to five more nodes, we can list these as; {1, 10} {2, 1, 1, 7} {2, 1, 1, 2, 5} {2, 1, 1, 2, 2, 3} {2, 1, 1, 2, 3, 2} {2, 1, 1, 3, 4} {2, 1, 1, 3, 2, 2} {2, 1, 1, 4, 3} {3, 1, 1, 6} {3, 1, 1, 2, 4} {3, 1, 1, 2, 2, 2} {3, 1, 1, 3, 3} {3, 1, 1, 4, 2} {4, 1, 1, 5}

All possible trees except one have a {1, 1} group, meaning a [(1, 1),(1, 1)] tree with other trees substituted in for the two nodes. Also, I'm sure someone could write an algorithm for my method (if nobody has already discovered it.)