Google OR-Tools v9.15
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
operations_research::MinCostPerfectMatching Class Reference

Detailed Description

Definition at line 50 of file perfect_matching.h.

#include <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_t cost)
ABSL_MUST_USE_RESULT Status Solve ()
int64_t OptimalCost () const
int Match (int node) const
const std::vector< int > & Matches () const

Member Enumeration Documentation

◆ Status

Enumerator
OPTIMAL 
INFEASIBLE 
INTEGER_OVERFLOW 
COST_OVERFLOW 

Definition at line 81 of file perfect_matching.h.

Constructor & Destructor Documentation

◆ MinCostPerfectMatching() [1/2]

operations_research::MinCostPerfectMatching::MinCostPerfectMatching ( )
inline

Definition at line 54 of file perfect_matching.h.

◆ MinCostPerfectMatching() [2/2]

operations_research::MinCostPerfectMatching::MinCostPerfectMatching ( int num_nodes)
inlineexplicit

Definition at line 55 of file perfect_matching.h.

Member Function Documentation

◆ AddEdgeWithCost()

void operations_research::MinCostPerfectMatching::AddEdgeWithCost ( int tail,
int head,
int64_t cost )

Definition at line 40 of file perfect_matching.cc.

◆ Match()

int operations_research::MinCostPerfectMatching::Match ( int node) const
inline

Definition at line 109 of file perfect_matching.h.

◆ Matches()

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

Definition at line 113 of file perfect_matching.h.

◆ OptimalCost()

int64_t operations_research::MinCostPerfectMatching::OptimalCost ( ) const
inline

Definition at line 102 of file perfect_matching.h.

◆ Reset()

void operations_research::MinCostPerfectMatching::Reset ( int num_nodes)

Definition at line 34 of file perfect_matching.cc.

◆ Solve()

MinCostPerfectMatching::Status operations_research::MinCostPerfectMatching::Solve ( )

Definition at line 52 of file perfect_matching.cc.


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