OR-Tools  9.6
SimpleMaxFlow

Detailed Description

Definition at line 152 of file max_flow.h.

Public Types

enum  Status { OPTIMAL , POSSIBLE_OVERFLOW , BAD_INPUT , BAD_RESULT }
 

Public Member Functions

 SimpleMaxFlow ()
 
ArcIndex AddArcWithCapacity (NodeIndex tail, NodeIndex head, FlowQuantity capacity)
 
NodeIndex NumNodes () const
 
ArcIndex NumArcs () const
 
NodeIndex Tail (ArcIndex arc) const
 
NodeIndex Head (ArcIndex arc) const
 
FlowQuantity Capacity (ArcIndex arc) const
 
Status Solve (NodeIndex source, NodeIndex sink)
 
FlowQuantity OptimalFlow () const
 
FlowQuantity Flow (ArcIndex arc) const
 
void GetSourceSideMinCut (std::vector< NodeIndex > *result)
 
void GetSinkSideMinCut (std::vector< NodeIndex > *result)
 
void SetArcCapacity (ArcIndex arc, FlowQuantity capacity)
 
FlowModelProto CreateFlowModelProto (NodeIndex source, NodeIndex sink) const
 

Member Enumeration Documentation

◆ Status

enum Status
Enumerator
OPTIMAL 
POSSIBLE_OVERFLOW 
BAD_INPUT 
BAD_RESULT 

Definition at line 180 of file max_flow.h.

Constructor & Destructor Documentation

◆ SimpleMaxFlow()

Definition at line 29 of file max_flow.cc.

Member Function Documentation

◆ AddArcWithCapacity()

ArcIndex AddArcWithCapacity ( NodeIndex  tail,
NodeIndex  head,
FlowQuantity  capacity 
)

Definition at line 31 of file max_flow.cc.

◆ Capacity()

FlowQuantity Capacity ( ArcIndex  arc) const

Definition at line 50 of file max_flow.cc.

◆ CreateFlowModelProto()

FlowModelProto CreateFlowModelProto ( NodeIndex  source,
NodeIndex  sink 
) const

Definition at line 123 of file max_flow.cc.

◆ Flow()

FlowQuantity Flow ( ArcIndex  arc) const

Definition at line 111 of file max_flow.cc.

◆ GetSinkSideMinCut()

void GetSinkSideMinCut ( std::vector< NodeIndex > *  result)

Definition at line 118 of file max_flow.cc.

◆ GetSourceSideMinCut()

void GetSourceSideMinCut ( std::vector< NodeIndex > *  result)

Definition at line 113 of file max_flow.cc.

◆ Head()

NodeIndex Head ( ArcIndex  arc) const

Definition at line 48 of file max_flow.cc.

◆ NumArcs()

ArcIndex NumArcs ( ) const

Definition at line 44 of file max_flow.cc.

◆ NumNodes()

NodeIndex NumNodes ( ) const

Definition at line 42 of file max_flow.cc.

◆ OptimalFlow()

FlowQuantity OptimalFlow ( ) const

Definition at line 109 of file max_flow.cc.

◆ SetArcCapacity()

void SetArcCapacity ( ArcIndex  arc,
FlowQuantity  capacity 
)

Definition at line 54 of file max_flow.cc.

◆ Solve()

SimpleMaxFlow::Status Solve ( NodeIndex  source,
NodeIndex  sink 
)

Definition at line 58 of file max_flow.cc.

◆ Tail()

NodeIndex Tail ( ArcIndex  arc) const

Definition at line 46 of file max_flow.cc.


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