Sunco Oil


    {  Exmpl8.3-3_SunCoOil.mpl  }

    {  Winston, Operations Research, Applications and Algorithms, 4th ed.  }

    {  Chapter 8.3,  Example 3, Maximum Flow,  Size: 5x7,  Page 420 }


TITLE
    SunCoOil;

INDEX
    node  := 0..4;
    node2 :=  node;

DATA
    Capacity[node,node2] := [0,1,2,
                             0,2,3,
                             1,2,3,
                             1,3,4,
                             3,4,1,
                             2,4,2,
                             4,0,9];

VARIABLE
    Flow[node,node2] WHERE (Capacity > 0);

MODEL

    MAX TotalFlow = SUM(node,node2=4: Flow);

SUBJECT TO

    FlowBalance[node]:

        SUM(node2: Flow) = SUM(node2: Flow[node:=node2,node2:=node]);

BOUNDS
    Flow <= Capacity;
END


Back To Top | Maximal Home Page | List of Models | Previous Page | Next Page