Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
min_cost_matching_test.cc File Reference

Rigorous tests for Min_Cost_Matching.H. More...

#include <gtest/gtest.h>
#include <algorithm>
#include <bit>
#include <chrono>
#include <cstdint>
#include <functional>
#include <initializer_list>
#include <limits>
#include <ostream>
#include <random>
#include <stdexcept>
#include <tuple>
#include <utility>
#include <Blossom_Weighted.H>
#include <Min_Cost_Matching.H>
#include <tpl_agraph.H>
#include <tpl_array.H>
#include <tpl_dynMapTree.H>
#include <tpl_dynSetTree.H>
#include <tpl_graph.H>
#include <tpl_sgraph.H>
Include dependency graph for min_cost_matching_test.cc:

Go to the source code of this file.

Functions

 TEST (MinCostMatchingStandaloneTest, EmptyGraph)
 
 TEST (MinCostMatchingStandaloneTest, PositiveSingleEdgeIllustratesObjectiveModes)
 
 TEST (MinCostMatchingStandaloneTest, ParallelArcsUseCheapestArc)
 
 TEST (MinCostMatchingStandaloneTest, DigraphThrowsDomainError)
 
 TEST (MinCostMatchingStandaloneTest, LLONGMinCostThrowsOverflow)
 
 TEST (MinCostMatchingStandaloneTest, UnsignedCostAboveLongLongRangeThrowsOverflow)
 
 TEST (MinCostMatchingStandaloneTest, FreeAliasAndFunctorAgree)
 
 TEST (MinCostMatchingStandaloneTest, MatchesNegatedWeightedBlossomObjective)
 
 TEST (MinCostMatchingPerfectStandaloneTest, EmptyGraphIsPerfectlyMatchable)
 
 TEST (MinCostMatchingPerfectStandaloneTest, OddNodeCountIsInfeasible)
 
 TEST (MinCostMatchingPerfectStandaloneTest, EvenNodeCountCanStillBeInfeasible)
 
 TEST (MinCostMatchingPerfectStandaloneTest, DigraphThrowsDomainError)
 
 TEST (MinCostMatchingPerfectStandaloneTest, FeasiblePerfectMatchingMatchesExactOracle)
 
 TEST (MinCostMatchingPerfectStandaloneTest, AliasAndFunctorAgree)
 
 TEST (MinCostMatchingBackendsTest, DeterministicScenarioMatchesExactAcrossBackends)
 
 TEST (MinCostMatchingPerfectBackendsTest, RandomSmallGraphsMatchExactPerfectOracle)
 
 TEST (MinCostMatchingBackendsTest, RandomSmallGraphsMatchExactOptimum)
 
 TEST (MinCostMatchingBackendsTest, DISABLED_PerfRegressionLargeFixedSeed)
 

Detailed Description

Rigorous tests for Min_Cost_Matching.H.

Coverage:

  • Deterministic non-bipartite costed instances
  • Objective-mode behavior (pure minimum-cost vs max-cardinality + min-cost)
  • Parallel arcs, loops, and domain/overflow validations
  • Cross-backend consistency (List_Graph, List_SGraph, Array_Graph)
  • Random small-graph validation against exact exponential DP oracle

Definition in file min_cost_matching_test.cc.

Function Documentation

◆ TEST() [1/18]

TEST ( MinCostMatchingBackendsTest  ,
DeterministicScenarioMatchesExactAcrossBackends   
)

◆ TEST() [2/18]

TEST ( MinCostMatchingBackendsTest  ,
DISABLED_PerfRegressionLargeFixedSeed   
)

◆ TEST() [3/18]

TEST ( MinCostMatchingBackendsTest  ,
RandomSmallGraphsMatchExactOptimum   
)

Definition at line 801 of file min_cost_matching_test.cc.

References Aleph::divide_and_conquer_partition_dp(), and rng.

◆ TEST() [4/18]

TEST ( MinCostMatchingPerfectBackendsTest  ,
RandomSmallGraphsMatchExactPerfectOracle   
)

Definition at line 751 of file min_cost_matching_test.cc.

References Aleph::divide_and_conquer_partition_dp(), and rng.

◆ TEST() [5/18]

TEST ( MinCostMatchingPerfectStandaloneTest  ,
AliasAndFunctorAgree   
)

◆ TEST() [6/18]

TEST ( MinCostMatchingPerfectStandaloneTest  ,
DigraphThrowsDomainError   
)

◆ TEST() [7/18]

TEST ( MinCostMatchingPerfectStandaloneTest  ,
EmptyGraphIsPerfectlyMatchable   
)

◆ TEST() [8/18]

TEST ( MinCostMatchingPerfectStandaloneTest  ,
EvenNodeCountCanStillBeInfeasible   
)

◆ TEST() [9/18]

TEST ( MinCostMatchingPerfectStandaloneTest  ,
FeasiblePerfectMatchingMatchesExactOracle   
)

◆ TEST() [10/18]

TEST ( MinCostMatchingPerfectStandaloneTest  ,
OddNodeCountIsInfeasible   
)

◆ TEST() [11/18]

TEST ( MinCostMatchingStandaloneTest  ,
DigraphThrowsDomainError   
)

◆ TEST() [12/18]

TEST ( MinCostMatchingStandaloneTest  ,
EmptyGraph   
)

◆ TEST() [13/18]

TEST ( MinCostMatchingStandaloneTest  ,
FreeAliasAndFunctorAgree   
)

◆ TEST() [14/18]

TEST ( MinCostMatchingStandaloneTest  ,
LLONGMinCostThrowsOverflow   
)

◆ TEST() [15/18]

TEST ( MinCostMatchingStandaloneTest  ,
MatchesNegatedWeightedBlossomObjective   
)

◆ TEST() [16/18]

◆ TEST() [17/18]

TEST ( MinCostMatchingStandaloneTest  ,
PositiveSingleEdgeIllustratesObjectiveModes   
)

◆ TEST() [18/18]

TEST ( MinCostMatchingStandaloneTest  ,
UnsignedCostAboveLongLongRangeThrowsOverflow   
)