OR-Tools  8.2
MinCostPerfectMatching

Detailed Description

Definition at line 50 of file perfect_matching.h.

Public Types

enum  Status { OPTIMAL = 0 , INFEASIBLE = 1 , INTEGER_OVERFLOW = 2 , COST_OVERFLOW = 3 }
 

Public Member Functions

 MinCostPerfectMatching ()
 
 MinCostPerfectMatching (int num_nodes)
 
void Reset (int num_nodes)
 
void AddEdgeWithCost (int tail, int head, int64 cost)
 
ABSL_MUST_USE_RESULT Status Solve ()
 
int64 OptimalCost () const
 
int Match (int node) const
 
const std::vector< int > & Matches () const
 

Member Enumeration Documentation

◆ Status

enum Status
Enumerator
OPTIMAL 
INFEASIBLE 
INTEGER_OVERFLOW 
COST_OVERFLOW 

Definition at line 81 of file perfect_matching.h.

Constructor & Destructor Documentation

◆ MinCostPerfectMatching() [1/2]

Definition at line 54 of file perfect_matching.h.

◆ MinCostPerfectMatching() [2/2]

MinCostPerfectMatching ( int  num_nodes)
inlineexplicit

Definition at line 55 of file perfect_matching.h.

Member Function Documentation

◆ AddEdgeWithCost()

void AddEdgeWithCost ( int  tail,
int  head,
int64  cost 
)

Definition at line 27 of file perfect_matching.cc.

◆ Match()

int Match ( int  node) const
inline

Definition at line 109 of file perfect_matching.h.

◆ Matches()

const std::vector< int > & Matches ( ) const
inline

Definition at line 113 of file perfect_matching.h.

◆ OptimalCost()

int64 OptimalCost ( ) const
inline

Definition at line 102 of file perfect_matching.h.

◆ Reset()

void Reset ( int  num_nodes)

Definition at line 21 of file perfect_matching.cc.

◆ Solve()

Definition at line 39 of file perfect_matching.cc.


The documentation for this class was generated from the following files: