Total variation on a tree
Dynamic Programming and Graph Algorithms in Computer Vision