Our method involves finding the optimal tree decomposition of a graph, which is in general an NP-complete problem.
the relation to tree decomposition allows us to exploit existing algorithms for this problem, such as the linear time algorithm of Bodlaender (1996) for graphs of bounded treewidth.