Added get_tree_sum