pub struct StMincut {
pub value: f64,
pub cut: Vec<u32>,
pub partition: Vec<u32>,
pub partition2: Vec<u32>,
}Expand description
Output of st_mincut: scalar value, cut edge ids, and the
source-side / sink-side vertex partitions.
Mirrors the four output parameters of igraph_st_mincut in
references/igraph/src/flow/flow.c:1140 (value, cut,
partition, partition2) — bundled into one return type for
ergonomic Rust call sites.
Fields§
§value: f64Capacity of the minimum source → target cut. Equals the
scalar value returned by st_mincut_value /
max_flow_value within 1e-12.
cut: Vec<u32>Edge ids (in graph’s ecount-order) whose removal disconnects
source from target. Sum of capacities equals value.
partition: Vec<u32>Source-side partition S (vertices reachable from source in
the residual network after saturation). Always contains
source. Sorted ascending.
partition2: Vec<u32>Sink-side partition V \ S. Always contains target (unless
target is itself unreachable from source even before any
flow is pushed, in which case the empty cut suffices). Sorted
ascending.