Suppose I have 3 kinds of restrictions to computing a spanning tree:
Are there any good algorithms to solve this that aren't gonna drive me insane? I'm gonna have to run this with rather large inpputs (1000+ nodes), so its complexity can't be too high either.
The degree-constrained spanning tree problem is NP-complete. See http://en.wikipedia.org/wiki/Degree-constrained_spanning_tree . So, no good (i.e., polynomial) algorithms. There are approximation algorithms, though.
A Google search seems to indicate that the bounded diameter spanning tree problem is equally hard.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With