Algorithms And Data Structures Codexery

Minimum-cost flow problem

Optimization problem to send flow at minimum cost.

Minimum-cost flow problem

The minimum-cost flow problem (MCFP) is an optimization and decision problem to find the cheapest possible way of sending a certain amount of flow through a flow network. A typical application involves finding the best delivery route from a factory to a warehouse where the road network has some capacity and cost associated. The problem is one of the most fundamental among all flow and circulation problems because most other such problems can be cast as a minimum cost flow problem and it can be solved efficiently using the network simplex algorithm.

field
Optimization and decision problem
known_for
Finding cheapest possible flow through a network
related_problems
Shortest path problem, maximum flow problem, assignment problem, minimum cost circulation problem
key_algorithms
Cycle canceling, cut canceling, minimum mean cycle canceling, successive shortest path, capacity scaling, cost scaling, network simplex algorithm, out-of-kilter algorithm

Lore & Background

The minimum-cost flow problem is defined on a directed graph G = (V, E) with a source vertex s and a sink vertex t. Each edge (u, v) has capacity c(u, v) > 0, flow f(u, v), and cost a(u, v). The cost of sending flow along an edge is f(u, v) · a(u, v). The problem requires an amount of flow d to be sent from source s to sink t, minimizing the total cost over all edges. Most minimum-cost flow algorithms support edges with negative costs. A variation of this problem is to find a flow which is maximum but has the lowest cost among the maximum flow solutions, called a minimum-cost maximum-flow problem. The related minimum cost circulation problem has no source and sink, instead having costs and lower and upper bounds on each edge. Any minimum-cost flow instance can be converted into a minimum cost circulation instance by adding an extra edge from sink t to source s with capacity and lower bound both equal to d. Several well-known problems are special cases of the minimum cost flow problem, including the shortest path problem, the maximum flow problem, and the assignment problem. The problem can be solved by linear programming, and many combinatorial algorithms exist, such as cycle canceling, cut canceling, minimum mean cycle canceling, successive shortest path, capacity scaling, cost scaling, network simplex algorithm, and the out-of-kilter algorithm by D. R. Fulkerson.

Reader's Guide

The minimum-cost flow problem holds a central place in network flow theory because it generalizes many other fundamental problems, including the shortest path problem, maximum flow problem, and assignment problem. Its ability to model real-world scenarios such as delivery route optimization with capacity and cost constraints makes it practically important. The problem can be solved efficiently using the network simplex algorithm, a specialized version of the linear programming simplex method. A deterministic almost-linear time algorithm is known to solve the problem on directed graphs with m edges and polynomially bounded demands, costs, and capacities, running in time m^{1+o(1)}. The cycle canceling algorithms, which iteratively improve flow by pushing flow around negative-cost cycles, include the minimum mean cycle canceling method that can find such cycles in polynomial time using binary search with the Bellman-Ford algorithm. The problem's versatility and efficient solvability have made it a cornerstone of operations research and computer science.

Did You Know?

Frequently Asked Questions

Who is Minimum-cost flow problem?

MCFP is an optimization and decision problem that figures out the least expensive way to push a specified amount of flow through a network of edges, each carrying its own capacity limit and per-unit cost. Think of it as the penny-pinching logistics planner of the entire flow-problem family.

What are Minimum-cost flow problem's powers/role?

Its signature ability is identifying the cheapest delivery routes in networks where every edge has both a capacity and a cost, making it the go-to model for factory-to-warehouse shipping and similar routing tasks. It can also be reshaped to handle circulation variants and a wide range of other flow scenarios.

How does Minimum-cost flow problem's story end?

The 'finale' is reached by running a solver such as the network simplex method, successive shortest path, or cost-scaling routines, which iteratively re-route flow until no cheaper adjustment remains. At that point the minimum total cost is locked in and the problem is solved.

Why is Minimum-cost flow problem important?

It sits at the foundation of the entire flow-and-circulation problem family because nearly every other classic flow problem—shortest path, maximum flow, assignment—can be reformulated as a special case of MCFP. Its efficient solvability, especially via the network simplex algorithm, makes it a workhorse in operations research and combinatorial optimization.

Who are Minimum-cost flow problem's closest allies?

Its regular supporting cast includes the shortest path problem, maximum flow problem, assignment problem, and minimum-cost circulation problem, all of which are essentially special cases or close relatives that MCFP subsumes. The out-of-kilter algorithm and various cycle-canceling techniques round out the ensemble of tools used alongside it.

More in Algorithms And Data Structures 25-38

Elsewhere in the Algorithms And Data Structures universe

Spotted an error? Know more?

This is a living reference — every entry is fact-audited, and reader corrections feed straight into our audit queue. Suggest an edit · See this site's audit record

Comments

Loading…
Open in the interactive codex →