Notation:

  • a directed network with nodes and arcs .
  • is the unit cost of arc . Default value is 0.
  • is the capacity of arc . We always assume that is positive. Default value is .
  • is the lower bound of flow of arc . We always assume that is non-negative. Default value is 0.
  • is the supply/demand at a node . Default value is 0.
    • If , then it is a supply node.
    • If , then it is a demand node.
    • If , then it is a transshipment node.

The goal of a network flow problem is to find the flow through every arc such that all bounds are satisfied and supply/demand is met at each node and the total cost is minimum.

We typically assume that the total supply is equal to the total demand, i.e.,

The min-cost flow problem can be viewed as the following LP:

The first constraint states that at every node , the outflow minus the inflow should equal the supply/demand. The second constraint ensures that the flow through each arc is between our lower bound and upper bounds.

Min-Cost Flow (MCF) Problem

Objective: Determine a least cost shipment of a commodity through a network in order to satisfy demands at certain nodes using supply at certain other nodes.

For example, consider the network

center

where a node is denoted . We want disperse goods from the supply nodes (1 and 5) to the demand nodes (2 and 6) with the lowest cost. In this example, the only parameters specified are the and the costs . The remaining parameters are assumed to be their default value.

The min-cost flow problem is the most general network flow problem.

Shortest Path Problem

Objective: Find a path of minimum cost from a source (or origin) node to a terminus (or destination) node in some network .

For example, in the network

center

The path of minimum cost from 1 to 6 is . In the graph above, the only parameters specified are the costs .

We can represent the shortest path problem as a min-cost flow problem. We set our source node to have a supply of 1 and the terminus node to have a demand of 1. The remaining nodes are transshipment nodes ( for all ). We set the lower bound for all . For the upper bounds, we use any positive value. The intuition is that we are sending exactly one unit of flow from to . Once the MCF problem has been solved, the -values that are 1 describe the shortest path.

Maximum Flow Problem

Objective: Find a feasible flow (i.e. a solution that honors the capacity limits on arcs) that sends the maximum amount of flow from a source node to a terminus node .

For example,

center

where arcs are labeled by . This is the maximum amount of flow from to for this network because we need that the outflow of is equal to the inflow of . This is indeed satisfied, since the outflow of 1 is and the inflow of 4 is . If we added an additional unit of flow along the arc, then the additional unit of flow would backup at node 2.

Note that nodes 2 and 3 have total inflow equal to total outflow. Hence, they are transshipment nodes.

The only parameters specified here are the arc capacities . All other parameters are their default values.

We can represent a max flow problem as a min-cost flow problem. We add an additional arc from the terminus to the source with a cost of -1 and a capacity of . All original arcs are given the default cost of 0.

center

Here the the arcs are labeled by . Since and we are trying to minimize cost, the MCF will send as much flow as possible through arc . The total amount sent is capped due to the capacities of the original network.

This example is also a min-cost circulation problem - there are no supply/demand nodes and the flow circulates through the network.

Transportation Problem

A special case of the MCF is the transportation problem, which occurs when the network is a bipartite graph, i.e.,

where is a set of supply nodes and is a set of demand nodes and each has and . We can intuitively think of it as sending goods from a set of warehouses to various stores to be sold.

center

A transportation problem is called balanced if

Assignment Problem

Objective: Given people and jobs and cost for assigning person to job . The goal is to assign each person to a job so that the total cost is minimized.

This is a special case of the transportation problem where , for each and for each .