def test_greedy_suboptimal_branching1b(): G = build_branching(greedy_subopt_branching_1b) assert_true(recognition.is_arborescence(G), True) assert_equal(branchings.branching_weight(G), 127)
def test_optimal_arborescence2(): G = build_branching(optimal_arborescence_2) assert_true(recognition.is_arborescence(G), True) assert_equal(branchings.branching_weight(G), 51)
def test_greedy_suboptimal_branching1b(): G = build_branching(greedy_subopt_branching_1b) assert recognition.is_arborescence(G), True assert branchings.branching_weight(G) == 127
def test_optimal_arborescence2(): G = build_branching(optimal_arborescence_2) assert recognition.is_arborescence(G), True assert branchings.branching_weight(G) == 51