"; } ?> None

TORSCHE Scheduling
Toolbox for Matlab

Name

mincostflow — finds the least cost flow in graph G.

Synopsis


   [G_FLOW, FMIN] = MINCOSTFLOW(G)
   [G_FLOW, FMIN] = MINCOSTFLOW(U,C,D,N)

Description

[G_FLOW, FMIN] = MINCOSTFLOW(G) finds the cheapest flow in graph G. Prices in graph G, lower and upper bounds of flows are specified in first, second and third user parameter on edges (UserParam). The function returns graph G_FLOW, i.e. graph G enlarged with fourth user parameter which contains amount of flow in every edge. FMIN contains total cost.

[G_FLOW, FMIN] = MINCOSTFLOW(U,C,D,N) finds the same, but everything without using graph, only matrixes. U is matrix of prices, C means lower bounds of flows, D upper bounds. The function returns G_FLOW, matrix of minimal flows.

See also

GRAPH/GRAPH, ILINPROG, EDGES2MATRIXPARAM, MATRIXPARAM2EDGES

Webmaster - Jan Dvořák (2004 - 2024)