A minimum-cost flow minimizes a linear edge cost subject to vertex flow balances and edge capacity intervals. Subtracting every lower capacity from its edge flow converts all lower bounds to zero while shifting the balance vector and objective by constants.
A maximum-value feasible network flow chosen to have the least total cost among all maximum-value flows. It combines a maximum-flow objective with a minimum-cost flow objective.
Consider nonnegative route variables with constraints , , , , and a linear reward . It is a minimum-cost flow problem: use arcs of capacity and cost , of capacity and cost zero, of capacity and cost , of unlimited capacity and cost , of unlimited capacity and cost , and of capacity and cost zero. Close the network by an unlimited zero-cost arc . The four forward path flows are exactly , so conservation gives the resource constraints. This reduction does not assert that general multi-commodity flow is ordinary minimum-cost flow.
A feasible flow satisfies every flow balance and every capacity interval of a network problem. Feasibility is distinct from optimality: capacitated flow optimality conditions additionally certify that no allowed balanced flow displacement reduces the cost. With only one independent graph cycle, every balanced flow is determined by a single cycle parameter, and its feasible set is the intersection of the induced parameter intervals.
For positive capacities and a feasible flow, optimality is equivalent to network dual potentials for which the network reduced cost is nonnegative at a lower bound, zero in the interior, and nonpositive at an upper bound. These signs make every feasible displacement nonnegative in total cost. They are also equivalent to absence of negative-cost cycles in the residual network. A zero-capacity edge is fixed and imposes no reduced-cost sign condition.
A flow balance prescribes net outgoing minus incoming flow at a vertex. Positive is supply and negative is demand; zero is ordinary flow conservation. Summing all balances requires total supply to equal total demand. In a directed graph, these equations are represented by the oriented incidence matrix.
An uncapacitated minimum-cost flow has nonnegative edge flows without finite upper capacities. The flow balances prescribe net supply at each vertex. For the oriented incidence matrix convention with tail and head , vertex network dual potentials have network reduced costs . Nonnegative network reduced costs and complementary slackness certify a feasible optimum. A feasible negative-cost directed cycle makes the problem unbounded below.
A vertex potential in the dual of an uncapacitated minimum-cost flow yields the edge inequalities . Its objective is . Adding a common constant leaves all network reduced costs and the objective unchanged when total net supply is zero. Potentials tight on a spanning tree are fixed up to this common constant.
In a directed network with no negative-cost directed cycle, add a source having zero-cost arcs to all vertices and compute shortest-path distances . The inequalities make dual feasible for uncapacitated minimum-cost flow. Shortest-path tree arcs are tight. An arbitrary spanning tree also fixes tight candidate potentials up to a constant, but it does not guarantee the non-tree inequalities; these must be checked.
With the tail-positive incidence convention, a network edge's reduced cost is . For uncapacitated minimum-cost flow, dual feasibility requires and complementary slackness requires . A negative non-tree reduced cost identifies an improving graph cycle pivot in the network simplex algorithm. This sign convention differs from the row-column potentials of a transportation problem.
The network simplex algorithm specializes the simplex algorithm to network flows. A basis is represented by a spanning tree with nonbasic flows at their bounds; potentials give reduced costs, and entering arcs produce cycle pivots. Degeneracy in linear programming is particularly common in assignment instances.
For a connected capacitated minimum-cost flow network, a spanning tree supplies basic flow variables. Every non-tree edge is fixed at its lower or upper bound. Flow balance determines the tree flows; these must also obey capacity constraints. An entering edge creates one cycle, and adjusting flow on that cycle preserves balance until a bound is hit and an edge leaves the tree.