|
Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
|
Maximum flows, cuts, decompositions, minimum costs, assignments and the applications of the networks on every small network, against the oracles. More...
#include <algorithm>#include <array>#include <cmath>#include <cstdio>#include <limits>#include <map>#include <memory>#include <new>#include <numeric>#include <random>#include <set>#include <stdexcept>#include <string>#include <type_traits>#include <utility>#include <vector>#include <gmpxx.h>#include <gtest/gtest.h>#include "allocation_failure.H"#include <tpl_net.H>#include <tpl_maxflow.H>#include <tpl_netcost.H>#include <tpl_mincost.H>#include <tpl_netcapgraph.H>#include <tpl_net_sup_dem.H>#include <net_apps.H>#include <Hungarian.H>#include <Johnson.H>#include "graph_harness.H"#include "graph_oracles.H"Go to the source code of this file.
Classes | |
| class | ExhaustiveMaxFlow< Net > |
| class | ExhaustiveMaxFlowCapacities< Net > |
| class | ExhaustiveMinCost< Net > |
| class | ExhaustiveAssignment< C > |
| class | ExhaustiveNodeCapacities< Net > |
| class | ExhaustiveFlowMemory |
Concepts | |
| concept | @923::Cost_Network |
Typedefs | |
| using | Flow_Nets = ::testing::Types< Net_Graph< Net_Node< int >, Net_Arc< int, int > >, Net_Graph< Net_Node< int >, Net_Arc< int, double > >, Net_Cost_Graph< Net_Cost_Node< int >, Net_Cost_Arc< Empty_Class, long > > > |
| The networks of integers, of floating flows and of costs. | |
| using | Capacity_Nets = ::testing::Types< Net_Graph< Net_Node< int >, Net_Arc< int, int > >, Net_Graph< Net_Node< int >, Net_Arc< int, double > > > |
| The networks of integers and of floating flows. | |
| using | Cost_Nets = ::testing::Types< Net_Cost_Graph< Net_Cost_Node< int >, Net_Cost_Arc< Empty_Class, long > >, Net_Cost_Graph< Net_Cost_Node< int >, Net_Cost_Arc< Empty_Class, double > > > |
| The networks with costs, of integers and of floating flows. | |
| using | Cost_Types = ::testing::Types< int, long, double > |
| The types of the costs: integers and floating. | |
| using | Node_Cap_Nets = ::testing::Types< Net_Cap_Graph< Net_Cap_Node< int, long >, Net_Arc< int, long > >, Net_Cap_Graph< Net_Cap_Node< int, double >, Net_Arc< int, double > > > |
Functions | |
| TYPED_TEST_SUITE (ExhaustiveMaxFlow, Flow_Nets) | |
| TYPED_TEST (ExhaustiveMaxFlow, AugmentingPathsMatchTheOracle) | |
| TYPED_TEST (ExhaustiveMaxFlow, PreflowsMatchTheOracle) | |
| TYPED_TEST (ExhaustiveMaxFlow, RandomPreflowMatchesTheOracle) | |
| TYPED_TEST (ExhaustiveMaxFlow, DinicScalingAndHlppMatchTheOracle) | |
| TYPED_TEST_SUITE (ExhaustiveMaxFlowCapacities, Capacity_Nets) | |
| TYPED_TEST (ExhaustiveMaxFlowCapacities, AugmentingPathsTakeEveryCapacity) | |
| TYPED_TEST (ExhaustiveMaxFlowCapacities, PreflowsTakeEveryCapacity) | |
| TYPED_TEST (ExhaustiveMaxFlowCapacities, RandomPreflowTakesEveryCapacity) | |
| TYPED_TEST (ExhaustiveMaxFlowCapacities, DinicScalingAndHlppTakeEveryCapacity) | |
| TYPED_TEST (ExhaustiveMaxFlow, MaxFlowsFromAFlowAlreadyThere) | |
| TYPED_TEST (ExhaustiveMaxFlow, SecondRunsKeepTheMaximum) | |
| TYPED_TEST (ExhaustiveMaxFlow, MinCutsMatchTheOracle) | |
| TYPED_TEST (ExhaustiveMaxFlow, DecompositionsRebuildFlowsWithCycles) | |
| TYPED_TEST (ExhaustiveMaxFlow, DecompositionsRebuildTheMaximumFlow) | |
| TYPED_TEST (ExhaustiveMaxFlow, AugmentingPathSearchesMatchTheOracle) | |
| TYPED_TEST (ExhaustiveMaxFlow, SuperSourcesAndSinksMatchTheOracle) | |
| TYPED_TEST_SUITE (ExhaustiveMinCost, Cost_Nets) | |
| TYPED_TEST (ExhaustiveMinCost, CycleCancelingMatchesTheOracle) | |
| TYPED_TEST (ExhaustiveMinCost, SimplexAndShortestPathsMatchTheOracle) | |
| TYPED_TEST (ExhaustiveMinCost, CheapestMaxFlowsTakeEveryCost) | |
| TYPED_TEST (ExhaustiveMinCost, CheapestMaxFlowsTakeNegativeCosts) | |
| TYPED_TEST (ExhaustiveMinCost, CheapestMaxFlowsOnRandomNetworks) | |
| TYPED_TEST (ExhaustiveMinCost, CheapestMaxFlowsFromAFlowAlreadyThere) | |
| TEST (ExhaustiveFloatingFlow, TenthsStayNearTheExactMaximum) | |
| TEST (ExhaustiveFloatingFlow, CutsDecompositionsAndStatisticsOfTenths) | |
| TEST (ExhaustiveFloatingFlow, RealsStayNearTheExactMaximum) | |
| TEST (ExhaustiveFloatingFlow, TenthsOnRandomNetworksStayNearTheExactMaximum) | |
| TEST (ExhaustiveFloatingFlow, CheapestMaxFlowsOfTenths) | |
| TEST (ExhaustiveFloatingFlow, PathsCarryTheLeastCapacityExactly) | |
| TEST (ExhaustiveFloatingFlow, SmallFlowsBesideLargeCapacitiesStay) | |
| TYPED_TEST_SUITE (ExhaustiveAssignment, Cost_Types) | |
| TYPED_TEST (ExhaustiveAssignment, HungarianMatchesTheOracle) | |
| TYPED_TEST (ExhaustiveAssignment, AssignmentByFlowMatchesTheOracle) | |
| TEST (ExhaustiveAssignmentLimits, HungarianWithCostsNearTheLimits) | |
| TYPED_TEST (ExhaustiveAssignment, TransportationMatchesTheOracle) | |
| TEST (ExhaustiveAssignmentLimits, TransportationOfTenths) | |
| TYPED_TEST (ExhaustiveMinCost, TransshipmentMatchesTheOracle) | |
| TEST (ExhaustiveNetApps, CirculationsMatchTheOracle) | |
| TEST (ExhaustiveNetApps, ProjectSelectionsMatchTheOracle) | |
| TEST (ExhaustiveNetApps, BaseballEliminationsMatchTheOracle) | |
| TEST (ExhaustiveNetApps, SegmentationsMatchTheOracle) | |
| TEST (ExhaustiveNetApps, SurveysMatchTheOracle) | |
| TYPED_TEST_SUITE (ExhaustiveNodeCapacities, Node_Cap_Nets) | |
| TYPED_TEST (ExhaustiveNodeCapacities, AuxiliaryNetworksMatchTheOracle) | |
| TEST (ExhaustiveSupplyDemand, TheAuxiliaryNetworkMatchesTheOracle) | |
| TEST (ExhaustiveNetworkCopies, CopiesKeepTheNetwork) | |
| TEST_F (ExhaustiveFlowMemory, SuperNodesWhenMemoryRunsOut) | |
| TEST_F (ExhaustiveFlowMemory, SuppliesWhenMemoryRunsOut) | |
| TEST_F (ExhaustiveFlowMemory, CopiesWhenMemoryRunsOut) | |
| TEST_F (ExhaustiveFlowMemory, NodeCapacitiesWhenMemoryRunsOut) | |
| TEST_F (ExhaustiveFlowMemory, CheapestFlowsWhenMemoryRunsOut) | |
| TEST (ExhaustiveJohnson, IntegerDistancesThatFitDoNotOverflow) | |
| TYPED_TEST (ExhaustiveMaxFlow, MembersKeepTheirContracts) | |
| TYPED_TEST (ExhaustiveMinCost, ResidualNetworksMirrorTheFlow) | |
Maximum flows, cuts, decompositions, minimum costs, assignments and the applications of the networks on every small network, against the oracles.
Each test runs one family of algorithms over every digraph of a domain of graph_harness.H (up to 4 nodes and 3 arcs for the maximum flows; one more of each with ALEPH_GRAPH_HARNESS=heavy), with loops, parallel and antiparallel arcs and the arcs in two orders (in one for the floating flows, which are exact there and run as the integers do), with the source and the sink taken over every pair of nodes, and compares each answer with an oracle of this file, which uses the standard library only, and GMP for the exact rationals. A network has the sources and the sinks that its arcs give, so the tests make the source the only one with arcs of capacity 0 to the others, and the sink likewise; if the source has arcs in or the sink arcs out, the flow goes from a node added before the source to one added after the sink. Every flow that an algorithm leaves is checked: within the capacities, conserved, and of the value that it returns.
The families: the maximum flows (augmenting paths, preflows, Dinic, the scaling and HLPP), from zero, from a flow already there and on a second run, with every class of capacities and on random networks; the minimum cuts, the decompositions and the statistics; the augmenting paths and semi-paths; the super sources and sinks; the floating flows of tenths, of real numbers and of capacities far apart, against exact rationals; the cheapest maximum flows (cycle canceling, network simplex and successive shortest paths), the transshipment, the transportation and the assignments, by flow and by Hungarian; the applications of net_apps.H; the capacities of the nodes; the supplies and demands; the copies of the networks; the networks when memory runs out; and Johnson with integer weights next to the limits.
The capacities, and the costs, are in units of the type of the flow: 1 for the integers and 1/4 for the floating types, so that a floating flow is exact; the spec that a failure prints has them in w.
Definition in file graph_exhaustive_flow_test.cc.
| using Capacity_Nets = ::testing::Types<Net_Graph<Net_Node<int>, Net_Arc<int, int> >, Net_Graph<Net_Node<int>, Net_Arc<int, double> >> |
The networks of integers and of floating flows.
Definition at line 878 of file graph_exhaustive_flow_test.cc.
| using Cost_Nets = ::testing::Types<Net_Cost_Graph<Net_Cost_Node<int>, Net_Cost_Arc<Empty_Class, long> >, Net_Cost_Graph<Net_Cost_Node<int>, Net_Cost_Arc<Empty_Class, double> >> |
The networks with costs, of integers and of floating flows.
Definition at line 2243 of file graph_exhaustive_flow_test.cc.
| using Cost_Types = ::testing::Types<int, long, double> |
The types of the costs: integers and floating.
Definition at line 3125 of file graph_exhaustive_flow_test.cc.
| using Flow_Nets = ::testing::Types<Net_Graph<Net_Node<int>, Net_Arc<int, int> >, Net_Graph<Net_Node<int>, Net_Arc<int, double> >, Net_Cost_Graph<Net_Cost_Node<int>, Net_Cost_Arc<Empty_Class, long> >> |
The networks of integers, of floating flows and of costs.
Definition at line 768 of file graph_exhaustive_flow_test.cc.
| using Node_Cap_Nets = ::testing::Types<Net_Cap_Graph<Net_Cap_Node<int, long>, Net_Arc<int, long> >, Net_Cap_Graph<Net_Cap_Node<int, double>, Net_Arc<int, double> >> |
Definition at line 4105 of file graph_exhaustive_flow_test.cc.
| TEST | ( | ExhaustiveAssignmentLimits | , |
| HungarianWithCostsNearTheLimits | |||
| ) |
Definition at line 3238 of file graph_exhaustive_flow_test.cc.
References Aleph::DynMatrix< T >::allocate(), check(), graph_harness::Check::expect(), graph_harness::Check::fail(), Aleph::hungarian_assignment(), r, row, and graph_harness::Check::run().
| TEST | ( | ExhaustiveAssignmentLimits | , |
| TransportationOfTenths | |||
| ) |
Definition at line 3418 of file graph_exhaustive_flow_test.cc.
References check(), graph_harness::Check::fail(), LL, m, r, graph_harness::Check::run(), and Aleph::solve_transportation().
| TEST | ( | ExhaustiveFloatingFlow | , |
| CheapestMaxFlowsOfTenths | |||
| ) |
Definition at line 2792 of file graph_exhaustive_flow_test.cc.
References graph_harness::Spec::arcs, graph_harness::heavy(), k, graph_harness::Spec::n, graph_harness::random_spec(), graph_harness::random_weights(), rng, seed, w, and graph_harness::Spec::w.
| TEST | ( | ExhaustiveFloatingFlow | , |
| CutsDecompositionsAndStatisticsOfTenths | |||
| ) |
Definition at line 2513 of file graph_exhaustive_flow_test.cc.
References Aleph::compute_flow_statistics(), Aleph::decompose_flow(), graph_harness::Check::fail(), graph_harness::Check::run(), and Aleph::FlowStatistics< Flow_Type >::total_flow.
| TEST | ( | ExhaustiveFloatingFlow | , |
| PathsCarryTheLeastCapacityExactly | |||
| ) |
Definition at line 2839 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, check(), k, and graph_harness::Spec::n.
| TEST | ( | ExhaustiveFloatingFlow | , |
| RealsStayNearTheExactMaximum | |||
| ) |
Definition at line 2597 of file graph_exhaustive_flow_test.cc.
References graph_harness::Spec::arcs, graph_harness::heavy(), k, graph_harness::Spec::n, Aleph::none(), graph_harness::random_spec(), rng, and seed.
| TEST | ( | ExhaustiveFloatingFlow | , |
| SmallFlowsBesideLargeCapacitiesStay | |||
| ) |
Definition at line 2897 of file graph_exhaustive_flow_test.cc.
References graph_harness::Spec::arcs, chain(), graph_harness::for_each_spec(), graph_harness::heavy(), k, graph_harness::Spec::n, graph_harness::random_spec(), rng, and seed.
| TEST | ( | ExhaustiveFloatingFlow | , |
| TenthsOnRandomNetworksStayNearTheExactMaximum | |||
| ) |
Definition at line 2664 of file graph_exhaustive_flow_test.cc.
References graph_harness::Spec::arcs, k, graph_harness::Spec::n, w, and graph_harness::Spec::w.
| TEST | ( | ExhaustiveFloatingFlow | , |
| TenthsStayNearTheExactMaximum | |||
| ) |
Definition at line 2486 of file graph_exhaustive_flow_test.cc.
References check().
| TEST | ( | ExhaustiveJohnson | , |
| IntegerDistancesThatFitDoNotOverflow | |||
| ) |
Definition at line 5167 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, graph_harness::domain(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::for_each_spec(), h, graph_oracles::Inf, Aleph::List_Graph< _Graph_Node, _Graph_Arc >::insert_arc(), Aleph::List_Graph< _Graph_Node, _Graph_Arc >::insert_node(), graph_harness::Spec::n, nodes, graph_harness::Check::run(), graph_oracles::shortest_distances(), and graph_harness::Spec::w.
| TEST | ( | ExhaustiveNetApps | , |
| BaseballEliminationsMatchTheOracle | |||
| ) |
Definition at line 3807 of file graph_exhaustive_flow_test.cc.
References check(), Aleph::check_baseball_elimination(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::heavy(), k, r, rng, graph_harness::Check::run(), seed, and w.
| TEST | ( | ExhaustiveNetApps | , |
| CirculationsMatchTheOracle | |||
| ) |
Definition at line 3596 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, check(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::for_each_spec(), Aleph::low(), graph_harness::Spec::n, graph_harness::Spec::num_arcs(), out, r, graph_harness::Check::run(), Aleph::solve_circulation(), and graph_harness::Spec::w.
| TEST | ( | ExhaustiveNetApps | , |
| ProjectSelectionsMatchTheOracle | |||
| ) |
Definition at line 3674 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, check(), graph_harness::domain(), graph_harness::for_each_spec(), graph_harness::heavy(), k, graph_harness::Spec::n, r, graph_harness::random_spec(), graph_harness::random_weights(), rng, seed, and Aleph::solve_project_selection().
| TEST | ( | ExhaustiveNetApps | , |
| SegmentationsMatchTheOracle | |||
| ) |
Definition at line 3885 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), cols, LL, m, r, rows, and Aleph::segment_image().
| TEST | ( | ExhaustiveNetApps | , |
| SurveysMatchTheOracle | |||
| ) |
Definition at line 3986 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), Aleph::design_survey(), graph_harness::Check::fail(), k, r, and graph_harness::Check::run().
| TEST | ( | ExhaustiveNetworkCopies | , |
| CopiesKeepTheNetwork | |||
| ) |
Definition at line 4493 of file graph_exhaustive_flow_test.cc.
References r.
| TEST | ( | ExhaustiveSupplyDemand | , |
| TheAuxiliaryNetworkMatchesTheOracle | |||
| ) |
Definition at line 4223 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, Aleph::edmonds_karp_maximum_flow(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::for_each_spec(), Aleph::Array_Graph< __Graph_Node, __Graph_Arc >::Node_Arc_Iterator::has_curr(), Aleph::Dlink::is_empty(), graph_harness::Spec::n, graph_harness::Spec::num_arcs(), graph_harness::Check::run(), Aleph::DynDlist< T >::size(), w, and graph_harness::Spec::w.
| TEST_F | ( | ExhaustiveFlowMemory | , |
| CheapestFlowsWhenMemoryRunsOut | |||
| ) |
Definition at line 5073 of file graph_exhaustive_flow_test.cc.
References Aleph::and, arcs, graph_harness::Check::fail(), k, graph_harness::Spec::n, Aleph::Filter_Iterator< Container, It, Show_Item >::next_ne(), nodes, graph_harness::Spec::num_arcs(), graph_harness::Check::run(), Aleph::solve_transshipment(), Aleph::successive_shortest_paths(), and graph_harness::Spec::w.
| TEST_F | ( | ExhaustiveFlowMemory | , |
| CopiesWhenMemoryRunsOut | |||
| ) |
Definition at line 4882 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, Aleph::copy_graph(), graph_harness::domain(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::for_each_spec(), Aleph::inter_copy_graph(), k, graph_harness::Spec::n, Aleph::none(), and graph_harness::Check::run().
| TEST_F | ( | ExhaustiveFlowMemory | , |
| NodeCapacitiesWhenMemoryRunsOut | |||
| ) |
Definition at line 4969 of file graph_exhaustive_flow_test.cc.
References Aleph::and, graph_harness::Spec::arcs, assign(), graph_harness::domain(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::for_each_spec(), k, graph_harness::Spec::n, graph_harness::Check::run(), and y.
| TEST_F | ( | ExhaustiveFlowMemory | , |
| SuperNodesWhenMemoryRunsOut | |||
| ) |
Definition at line 4681 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), graph_harness::domain(), graph_harness::Check::fail(), graph_harness::for_each_spec(), k, nodes, and graph_harness::Check::run().
| TEST_F | ( | ExhaustiveFlowMemory | , |
| SuppliesWhenMemoryRunsOut | |||
| ) |
Definition at line 4764 of file graph_exhaustive_flow_test.cc.
References Aleph::and, Aleph::copy_graph(), GraphCommon< GT, Node, Arc >::get_num_nodes(), Aleph::Net_Graph< NodeT, ArcT >::insert_arc(), Aleph::Net_Graph< NodeT, ArcT >::insert_node(), k, and y.
| TYPED_TEST | ( | ExhaustiveAssignment | , |
| AssignmentByFlowMatchesTheOracle | |||
| ) |
Definition at line 3196 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), r, and Aleph::solve_assignment().
| TYPED_TEST | ( | ExhaustiveAssignment | , |
| HungarianMatchesTheOracle | |||
| ) |
Definition at line 3129 of file graph_exhaustive_flow_test.cc.
References Aleph::DynMatrix< T >::allocate(), Aleph::and, OhashCommon< HashTbl, Key >::empty(), graph_harness::Check::expect(), graph_harness::Check::fail(), h, Aleph::hungarian_assignment(), Aleph::hungarian_max_assignment(), m, r, graph_harness::Check::run(), and Aleph::size().
| TYPED_TEST | ( | ExhaustiveAssignment | , |
| TransportationMatchesTheOracle | |||
| ) |
Definition at line 3357 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), col, m, r, row, and Aleph::solve_transportation().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| AugmentingPathSearchesMatchTheOracle | |||
| ) |
Definition at line 1584 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), Aleph::decrease_flow(), graph_harness::Check::fail(), Aleph::find_aumenting_path_bfs(), Aleph::find_aumenting_path_dfs(), Aleph::find_aumenting_semi_path_bfs(), Aleph::find_aumenting_semi_path_dfs(), Aleph::Find_Aumenting_Path< Net, Q >::find_dec_path(), Aleph::find_decrementing_path_bfs(), Aleph::find_decrementing_path_dfs(), Aleph::Path< GT >::Iterator::has_current_arc(), Aleph::increase_flow(), Aleph::HTList::is_empty(), Aleph::Path< GT >::is_empty(), LL, graph_harness::Check::run(), Aleph::Find_Aumenting_Path< Net, Q >::semi_path(), and value.
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| AugmentingPathsMatchTheOracle | |||
| ) |
Definition at line 854 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| DecompositionsRebuildFlowsWithCycles | |||
| ) |
Definition at line 1426 of file graph_exhaustive_flow_test.cc.
References check(), Aleph::decompose_flow(), graph_harness::Check::expect(), and graph_harness::Check::run().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| DecompositionsRebuildTheMaximumFlow | |||
| ) |
Definition at line 1447 of file graph_exhaustive_flow_test.cc.
References Aleph::compute_flow_statistics(), Aleph::decompose_flow(), Aleph::edmonds_karp_maximum_flow(), graph_harness::Check::fail(), and graph_harness::Check::run().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| DinicScalingAndHlppMatchTheOracle | |||
| ) |
Definition at line 869 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| MaxFlowsFromAFlowAlreadyThere | |||
| ) |
Definition at line 1046 of file graph_exhaustive_flow_test.cc.
References Aleph::and, and check().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| MembersKeepTheirContracts | |||
| ) |
Definition at line 5289 of file graph_exhaustive_flow_test.cc.
References Aleph::and, arcs, graph_harness::Check::fail(), Aleph::DynList< T >::get_first(), LocateFunctions< Container, Type >::get_it(), l, graph_harness::Spec::n, out, r, and graph_harness::Check::run().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| MinCutsMatchTheOracle | |||
| ) |
Definition at line 1235 of file graph_exhaustive_flow_test.cc.
References Aleph::and, and check().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| PreflowsMatchTheOracle | |||
| ) |
Definition at line 859 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| RandomPreflowMatchesTheOracle | |||
| ) |
Definition at line 864 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| SecondRunsKeepTheMaximum | |||
| ) |
Definition at line 1084 of file graph_exhaustive_flow_test.cc.
References Aleph::and, and check().
| TYPED_TEST | ( | ExhaustiveMaxFlow | , |
| SuperSourcesAndSinksMatchTheOracle | |||
| ) |
Definition at line 1781 of file graph_exhaustive_flow_test.cc.
References Aleph::and, Aleph::edmonds_karp_maximum_flow(), graph_harness::Check::expect(), graph_harness::Check::fail(), graph_harness::Spec::n, graph_harness::Spec::num_arcs(), and graph_harness::Check::run().
| TYPED_TEST | ( | ExhaustiveMaxFlowCapacities | , |
| AugmentingPathsTakeEveryCapacity | |||
| ) |
Definition at line 884 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlowCapacities | , |
| DinicScalingAndHlppTakeEveryCapacity | |||
| ) |
Definition at line 899 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlowCapacities | , |
| PreflowsTakeEveryCapacity | |||
| ) |
Definition at line 889 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMaxFlowCapacities | , |
| RandomPreflowTakesEveryCapacity | |||
| ) |
Definition at line 894 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| CheapestMaxFlowsFromAFlowAlreadyThere | |||
| ) |
Definition at line 2335 of file graph_exhaustive_flow_test.cc.
References Aleph::and, check(), and graph_harness::Spec::w.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| CheapestMaxFlowsOnRandomNetworks | |||
| ) |
Definition at line 2315 of file graph_exhaustive_flow_test.cc.
References graph_harness::heavy(), k, graph_harness::random_spec(), graph_harness::random_weights(), rng, seed, and graph_harness::Spec::w.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| CheapestMaxFlowsTakeEveryCost | |||
| ) |
Definition at line 2275 of file graph_exhaustive_flow_test.cc.
References graph_harness::Spec::arcs, graph_harness::for_each_spec(), and graph_harness::Spec::w.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| CheapestMaxFlowsTakeNegativeCosts | |||
| ) |
Definition at line 2294 of file graph_exhaustive_flow_test.cc.
References graph_harness::Spec::arcs, graph_harness::for_each_spec(), and graph_harness::Spec::w.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| CycleCancelingMatchesTheOracle | |||
| ) |
Definition at line 2249 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| ResidualNetworksMirrorTheFlow | |||
| ) |
Definition at line 5435 of file graph_exhaustive_flow_test.cc.
References Aleph::and, Aleph::build_residual_net(), Aleph::check_residual_net(), graph_harness::Check::expect(), graph_harness::Check::fail(), Aleph::DynMapTree< Key, Data, Tree, Compare >::find(), GraphCommon< GT, Node, Arc >::get_num_arcs(), NODE_COOKIE, Aleph::preflow_create_residual_net(), r, graph_harness::Check::run(), Aleph::DynSetTree< Key, Tree, Compare >::size(), Aleph::update_flow(), and graph_harness::Spec::w.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| SimplexAndShortestPathsMatchTheOracle | |||
| ) |
Definition at line 2261 of file graph_exhaustive_flow_test.cc.
| TYPED_TEST | ( | ExhaustiveMinCost | , |
| TransshipmentMatchesTheOracle | |||
| ) |
Definition at line 3487 of file graph_exhaustive_flow_test.cc.
References Aleph::and, arcs, graph_harness::Spec::arcs, check(), graph_harness::Check::fail(), graph_harness::for_each_spec(), LL, graph_harness::Spec::n, nodes, r, graph_harness::Check::run(), Aleph::solve_transshipment(), and graph_harness::Spec::w.
| TYPED_TEST | ( | ExhaustiveNodeCapacities | , |
| AuxiliaryNetworksMatchTheOracle | |||
| ) |
Definition at line 4111 of file graph_exhaustive_flow_test.cc.
References Aleph::and, ARC_COOKIE, graph_harness::Spec::arcs, Aleph::dinic_maximum_flow(), Aleph::edmonds_karp_maximum_flow(), graph_harness::Check::fail(), graph_harness::for_each_spec(), graph_harness::Spec::n, graph_harness::Check::run(), value, and graph_harness::Spec::w.
| TYPED_TEST_SUITE | ( | ExhaustiveAssignment | , |
| Cost_Types | |||
| ) |
| TYPED_TEST_SUITE | ( | ExhaustiveMaxFlow | , |
| Flow_Nets | |||
| ) |
| TYPED_TEST_SUITE | ( | ExhaustiveMaxFlowCapacities | , |
| Capacity_Nets | |||
| ) |
| TYPED_TEST_SUITE | ( | ExhaustiveMinCost | , |
| Cost_Nets | |||
| ) |
| TYPED_TEST_SUITE | ( | ExhaustiveNodeCapacities | , |
| Node_Cap_Nets | |||
| ) |