63
NETWORK OPTIMIZATION MODELS MODELS

NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

  • Upload
    dophuc

  • View
    235

  • Download
    2

Embed Size (px)

Citation preview

Page 1: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

NETWORK OPTIMIZATION MODELSMODELS

Page 2: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Network models

Network representation is widely used in:Production, distribution, project planning, facilities location, resource management, financial planning, etc.

Transportation, electrical and communication networks pervade our daily lives.Algorithms and software are being used to solve huge g g gnetwork problems on a routine basis.Many network problems are special cases of linear Many network problems are special cases of linear programming problems.

João Miguel da Costa Sousa / Alexandra Moutinho 138

Page 3: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Prototype exampleyp p

Seervada Park has a limited amount of sightseeing g gand backpack hiking. 

O: entrance of the park.pT: station with scenic wonder.

João Miguel da Costa Sousa / Alexandra Moutinho 139

Page 4: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Park problemsp

Determine route from park entrance to station Twith smallest total distance for the operation of trams.Telephone lines must be installed under the roads to establish communication among all the stations. This should be accomplished with a minimum total number of miles of lines.R t  th   i  t i   f t  t   i i th   b   f Route the various trips of trams to maximize the number of trips per day without violating the limits of any road.

João Miguel da Costa Sousa / Alexandra Moutinho 140

Page 5: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Typical networksyp

Nodes  Arcs  Flow

Intersections Roads VehiclesIntersections Roads Vehicles

Airports Air lanes Aircraft

Switching points Wires, channels Messages

Pumping stations Pipes Fluidsp g p

Work centers Material‐handling sources Jobs

João Miguel da Costa Sousa / Alexandra Moutinho 141

Page 6: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Terminology of networksgy

Network is a set of points (nodes or vertices) and a set of lines (arcs or links or edges or branches) connecting certain pairs of the nodes.

Example: road system of Seervada Park has 7 nodes and 12 arcs.

Flow in only one direction is a directed arc.Flow allowed in either direction: undirected arc or link.Network with only directed arcs is a directed network.network.

João Miguel da Costa Sousa / Alexandra Moutinho 142

Page 7: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Terminology of networksgy

Network with only undirected arcs is an undirected network.A path between two nodes is a sequence of distinct arcs connecting these nodes.gA directed path from node i to node j is a sequence of connecting arcs whose direction is toward node j.co ect g a cs ose d ect o s to a d ode jAn undirected path from node i to node j is a sequence of connecting arcs whose direction (if any) sequence of connecting arcs whose direction (if any) can be either toward or away from node j.

João Miguel da Costa Sousa / Alexandra Moutinho 143

Page 8: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Terminology of networksgy

A path that begins and ends at the same node is a cycle.Two nodes are connected if the network contains at least one undirected path between them.A connected network is a network where every pair of nodes is connected.o odes s co ectedA tree is a connected network (for some subset of the n nodes of the original network) that contains no n nodes of the original network) that contains no undirected cycles. 

João Miguel da Costa Sousa / Alexandra Moutinho 144

Page 9: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Terminology of networksgy

A spanning tree is a connected network for all n nodes A spanning tree is a connected network for all n nodes of the original network that contains no undirected cycles. A spanning tree has exactly n – 1 arcs.cycles. A spanning tree has exactly n 1 arcs.The maximum amount of flow that can be carried on a directed arc is the arc capacitya directed arc is the arc capacity.Supply node: the flow out of the node exceeds the fl  i t th   d  Th    i    d d  dflow into the node. The reverse in a demand node.Transshipment node: node that satisfies conservation of flow, i.e., flow in equals flow out.

João Miguel da Costa Sousa / Alexandra Moutinho 145

Page 10: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Growing a tree one arc at a timeg

a) Nodes without arcsb) Tree with one arcc) Tree with two arcsd) Tree with three arcse) A spanning tree

João Miguel da Costa Sousa / Alexandra Moutinho 146

Page 11: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Examplep

Distribution Unlimited Co. produces the same new product at  diff  f i  P d    b   hi d     two different factories. Products must be shipped to two 

warehouses (a distribution center is available).F1 W1F1 W1

DCExample of a 

DCp

directed network

F2

João Miguel da Costa Sousa / Alexandra Moutinho 147

F2 W2

Page 12: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Linear Programmingmodelg g

1 2 1 1 1 2Minimize  2 4 9 3F F F DC F W F DCZ x x x x− − − −= + + +

2 1 2 2 13 2DC W W W W Wx x x− − −+ + +

50x x x+ + =subject to:1 2 1 1 1

1 2 2

50400

F F F DC F W

F F F DC

x x xx x

x x x

− − −

− −

+ + =− + =

+

subject to:

1 2 2

1 1 1 2 2 1

03060

F DC F DC DC W

F W W W W W

x x xx x x

− − −

− − −

− − + =− + − = −

2 1 2 2 1 60DC W W W W Wx x x− − −− − + = −

1 2 10F Fx − ≤

2 800,

DC W

i

xx i

− ≤≥ ∀

João Miguel da Costa Sousa / Alexandra Moutinho 148

Page 13: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Shortest‐path problemp p

Consider an undirected and connected network with Consider an undirected and connected network with the special nodes called origin and destination.

h l k d d h d dEach link (undirected arc) has an associated distance.Objective: find the shortest path from the origin to the destination.Algorithm: starting from the origin, successively g g g , yidentify the shortest path to each of the nodes in the ascending order of their distances from the origin.g gThe problem is solved when the destination is reachedreached.

João Miguel da Costa Sousa / Alexandra Moutinho 149

Page 14: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Algorithm for shortest‐path problemg p p

Objective of nth iteration  find the nth nearest node to Objective of nth iteration: find the nth nearest node to the origin (n = 1, 2, …) until the nth nearest node is reachedreached.Input for the nth iteration: n – 1 nearest nodes to the 

l d h h h d dorigin, including their shortest path and distance to the origin (these are the solved nodes).Candidates for the nth nearest node: each solved that is directly connected to unsolved nodes provides onecandidate – the unsolved node with the shortestconnecting link.

João Miguel da Costa Sousa / Alexandra Moutinho 150

Page 15: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Algorithm for shortest‐path problemg p p

Calculation of the nth nearest node: for each solved node and its candidate, add the distance between them to the distance of the shortest path from the origin to this solved node.The candidate with the smallest total distance is the nth nearest node, and its shortest path is the one generating this distance.

João Miguel da Costa Sousa / Alexandra Moutinho 151

Page 16: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Example: Seervada parkp p

Solved nodes  Closest  Total  nth n

Solved nodes directly connected to unsolved nodes

Closest connected 

unsolved node

Total distance involved

nth nearest node

Minimum distance

Last connection

1 O A 2 A 2 OA1 O A 2 A 2 OA

2,3O C 4 C 4 OC

A B 2 + 2 = 4 B 4 AB

4

A D 2 + 7 = 9

B E 4 + 3 = 7 E 7 BE

C E 4 + 4 = 8C E 4 + 4   8

João Miguel da Costa Sousa / Alexandra Moutinho 152

Page 17: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Example: Seervada parkp p

Solved nodes  Closest  Total  nth 

n

Solved nodes directly connected to unsolved nodes

Closest connected 

unsolved node

Total distance involved

nth nearest node

Minimum distance

Last connection

1 O A 2 A 2 OA1 O A 2 A 2 OA

2,3 O C 4 C 4 OC

A B 2 + 2 = 4 B 4 AB

A D 2 + 7 = 9

4 B E 4 + 3 = 7 E 7 BE

C E 4 + 4 = 8C E 4 + 4 = 8

A D 2 + 7 = 9

5 B D 4 + 4 = 8 D 8 BD

E D 7 + 1 = 8 D 8 ED

6 D T 8 + 5 = 13 T 13 DT

E T 7 + 7 = 14E T 7 + 7   14

João Miguel da Costa Sousa / Alexandra Moutinho 153

Page 18: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Using simplex to solve the problemg p p

João Miguel da Costa Sousa / Alexandra Moutinho 154

Page 19: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Using simplex to solve the problemg p p

João Miguel da Costa Sousa / Alexandra Moutinho 155

Page 20: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Applications of shortest‐pathpp p

Main applications:1. Minimize the total distance traveled.2. Minimize the total cost of a sequence of activities.3 Minimize the total time of a sequence of activities3. Minimize the total time of a sequence of activities.4. Combination of the previous three.

fWhat happens if the network is directed?How to optimize from the source to all other nodes?How to find the shortest path from every node to every other node?y

João Miguel da Costa Sousa / Alexandra Moutinho 156

Page 21: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Minimum spanning tree problemp g p

Also for undirected and connected networks. A positive length (distance, cost, time, etc.) is p gassociated with each link.Both the shortest‐path problem and the minimum Both the shortest path problem and the minimum spanning tree problem choose a set of links that satisfy a certain property.sat s y a ce ta p ope tyObjective: find the shortest total length that provide a path between each pair of nodespath between each pair of nodes.

João Miguel da Costa Sousa / Alexandra Moutinho 157

Page 22: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Minimum spanning tree problemp g p

Definition:1. Nodes of the network are given, as well as potential g p

links and positive length for each if it is inserted in the network.

2. Design network inserting links in order to have a path between each pair of nodes.pat bet ee eac pa o odes

3. These links must minimize the total length of the links inserted into the networklinks inserted into the network.

João Miguel da Costa Sousa / Alexandra Moutinho 158

Page 23: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Propertiesp

A network with nnodes requires n – 1 links to provide a path between each pair of nodes.The n – 1 links form a spanning tree.Which are spanning p gtrees?

João Miguel da Costa Sousa / Alexandra Moutinho 159

Page 24: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Applicationspp

Design of telecommunication networks: fiber‐optic, computer, leased‐line telephone cable television, etc.Design of a lightly used transportation network to minimize the total cost of providing the links.gDesign of a network of high‐voltage electrical power transmission lines.t a s ss o esDesign of a network of wiring on electrical equipment to minimize the total length of wireto minimize the total length of wire.Design of a network of pipelines to connect locations.

João Miguel da Costa Sousa / Alexandra Moutinho 160

Page 25: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Algorithm for minimum spanning treeg p g

Can be solved in a straightforward way using a Can be solved in a straightforward way using a greedy algorithm.S l     d   bi il   d   i     h  1. Select any node arbitrarily, and connect it to the nearest distinct node.

2. Identify the unconnected node that is closest to a connected node, and connect the two nodes. Repeat this step until all nodes have been connected.Tie breaking: can be done arbitrarily. It can indicate that more than one optimal solution exist.p

João Miguel da Costa Sousa / Alexandra Moutinho 161

Page 26: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Application to Seervada parkpp p

T l l h  f  h  li k    KTotal length of the links: 14 Km.Verify that the choice of the initial node does not affect the final solution!the final solution!

João Miguel da Costa Sousa / Alexandra Moutinho 162

Page 27: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Maximum flow problemsp

Third problem in Seervada Park: route the tram trips p pfrom the park entrance O to the scenic wonder T maximizing the number of trips per day.g p p yOutgoing trips allowed per day:

João Miguel da Costa Sousa / Alexandra Moutinho 163

Page 28: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Feasible solution

One solution (not optimal):( p )5 trams using the route O → B→ E→ T1 tram using O → B→ C→ E→ Tg1 tram using O → B→ C→ E→ D → T

João Miguel da Costa Sousa / Alexandra Moutinho 164

Page 29: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Definition of maximum flow problemp

All flow through a directed and connected network from the source to the sink.All remaining nodes are transshipment nodes.Flow through an arc is only allowed in the direction Flow through an arc is only allowed in the direction indicated by the arrowhead. Maximum amount of flow is given by the capacity of that node.o s g e by t e capac ty o t at odeObjective: maximize the total amount of flow from the source to the sinkthe source to the sink.

João Miguel da Costa Sousa / Alexandra Moutinho 165

Page 30: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Applications pp

M i i   h  fl   h h    ’  di ib i  Maximize the flow through a company’s distribution network from its factories to its costumers.Maximize the flow through a company’s supply network from its vendors (suppliers) to its factories.Maximize the flow of oil through a system of pipelines.Maximize the flow of water through a system g yaqueducts.Maximize the flow of vehicles through a transportation g pnetwork.

João Miguel da Costa Sousa / Alexandra Moutinho 166

Page 31: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Some applicationspp

For some applications, the flow may be originated at more than one node, and may also terminate at more than one node.

More than one source: include a dummy sourcewith capacity equal to the maximum flow.More than one sink: include a dummy sinkwith capacity 

l t  th   i  flequal to the maximum flow.

Maximum flow problem is a linear programming bl b l d b h l h dproblem; it can be solved by the simplex method.

However, augmented path algorithm is more efficient.

João Miguel da Costa Sousa / Alexandra Moutinho 167

Page 32: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Augmented path algorithmg p g

Every arc is changed from a directed to an undirected arc:

O B7 O B7 0

Residual network shows the residual capacities for assigning additional flows:

O B2 5

assigning additional flows:

O B

João Miguel da Costa Sousa / Alexandra Moutinho 168

Page 33: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Servada Park residual network

Augmenting path is a directed path from the source g g p pto the sink in the residual network, such that every arc on this path has strictly positive residual capacity.p y p p y

João Miguel da Costa Sousa / Alexandra Moutinho 169

Page 34: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Iteration of augmented path algorithmg p g

1. Identify an augmenting path (directed path from source to sink with positive residual capacity).

2. Identify residual capacity c* (minimum of residual y p y (capacities of the arcs on path). Increase flow by c*.

3 Decrease by c* the residual capacity of each arc on 3. Decrease by c the residual capacity of each arc on this augmented path. Increase by c* the residual capacity of each arc in the opposite direction  Return capacity of each arc in the opposite direction. Return to Step 1.Several augmenting paths can be chosen  Its choice Several augmenting paths can be chosen. Its choice is important for the efficiency of large‐scale networksnetworks.

João Miguel da Costa Sousa / Alexandra Moutinho 170

Page 35: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Application to Seervada Parkpp

Iteration 1: one of several augmenting paths is O → B → E →T residual capacity is min{7, 5, 6} = 5.

52

55 55

5

0

51

João Miguel da Costa Sousa / Alexandra Moutinho 171

Page 36: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Iteration 2

Iteration 2: assign a flow of 3 to the augmenting path               Iteration 2: assign a flow of 3 to the augmenting path               O → A → D → T

30

8 28

5 5

2 3 36

52

55 5

5

05

5

0

51

51

João Miguel da Costa Sousa / Alexandra Moutinho 172

Page 37: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Iterations 3 and 43 4

f fIteration 3: assign flow of 1 to augmenting path O→A→B→D→TIteration 4: assign flow of 2 to augmenting path O→B→D→T

4 00

11 011

7 51 3 6

3

01

31

5

0

1

João Miguel da Costa Sousa / Alexandra Moutinho 173

Page 38: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Iterations 5 and 65

f fIteration 5: assign flow of 1 to augmenting path O→C→E→D→TIteration 6: assign flow of 1 to augmenting path O→C→E→T

4 00

13 013

7 61 3 7

2

01

31

5

02

0

1

0222

0

João Miguel da Costa Sousa / Alexandra Moutinho 174

Page 39: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Iteration 77

f fIteration 7: assign flow of 1 to augmenting path                          O → C → E → B → D → T

4 00

14 014

76

1 3 81

01

40

4

11

0

1

0331

João Miguel da Costa Sousa / Alexandra Moutinho 175

Page 40: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Optimal solutionp

After iteration 7 there are no more augmenting paths. Optimal flow pattern is:

The flow assignment of 1 for O → C → E → B → D → T cancels 1 unit of flow assigned at iteration 1 (O → B → E → T) and replaces it by assignments of 1 unit to both O → B → D → T 

d O  C  E  Tand O → C → E → T.João Miguel da Costa Sousa / Alexandra Moutinho 176

Page 41: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Finding an augmenting pathg g g p

This can be difficult, especially for large networks.This can be difficult, especially for large networks.Procedure:

Find all nodes that can be reached from the source along a Find all nodes that can be reached from the source along a single arc with strictly positive residual capacity.For each reached node  find all new nodes from this node For each reached node, find all new nodes from this node that can be reached along an arc with strictly positive residual capacity.p yRepeat this successively with the new nodes as they are reached.Identification of a tree of all nodes reached from the source along a path with strictly positive residual flow capacity.

João Miguel da Costa Sousa / Alexandra Moutinho 177

Page 42: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Example in Seervada Parkp

Residual network after Iteration 6 is given, as well as the possible augmenting path.

João Miguel da Costa Sousa / Alexandra Moutinho 178

Page 43: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

How to recognize the optimal?g p

Using the maximum‐flow min‐cut theoremUsing the maximum‐flow min‐cut theorem.Cut: any set of directed arcs containing at least one  f    di t d  th f  th    t  th  arc from every directed path from the source to the 

sink.Cut value: sum of the arc capacities of the arcs (in the specified direction) of the cut.Maximum‐flow min‐cut theorem: for any network with a single source and sink, the maximum feasible flow from the source to the sink equals the minimum cut value for all cuts of the network.

João Miguel da Costa Sousa / Alexandra Moutinho 179

Page 44: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Maximum‐flow min‐cut theorem

F is the amount of flow from the source to the sink for F is the amount of flow from the source to the sink for any feasible flow pattern.Example  value of cut is 3 + 4 + 1 + 6   14  This is the Example: value of cut is 3 + 4 + 1 + 6 = 14. This is the maximum value of F, so this is the minimum cut.

João Miguel da Costa Sousa / Alexandra Moutinho 180

Page 45: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Using simplex to solve the problemg p p

João Miguel da Costa Sousa / Alexandra Moutinho 181

Page 46: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Using simplex to solve the problemg p p

João Miguel da Costa Sousa / Alexandra Moutinho 182

Page 47: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Minimum cost flow problemp

It contains a large number of applications and it can be solved extremely efficiently.y y

Like the maximum flow problem, it considers flow through a network with limited arc capacities.Like the shortest‐path problem, it considers a cost (or distance) for flow through an arc.Like the transportation problem or assignment problem, it can consider multiple sources (supply nodes) and multiple d ti ti  (d d  d ) f  th  fl   i   ith destinations (demand nodes) for the flow, again with associated costs.

João Miguel da Costa Sousa / Alexandra Moutinho 183

Page 48: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Minimum cost flow problemp

The four previous problems are all special cases of the minimum cost flow problem.This problem can be formulated as a linear programming problem, solved using a streamlined g g gversion of the simplex method:

The network simplex method.

João Miguel da Costa Sousa / Alexandra Moutinho 184

Page 49: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Definition of minimum cost flow problemp

1. The network is a directed and connected network.2. At least one of the nodes is a supply node.3. At least one of the other nodes is a demand node.34. All the remaining nodes are transshipment nodes.5. Flow through an arc is in the direction of the arrow. Maximum 5 g

amount of flow given by the capacity of the arc.6. Network has enough arcs with sufficient capacity such that all 

flow generated at supply nodes reaches the demand nodes.7. Cost of flow through each arc is proportional to the amount of 

th t flthat flow.Objective: minimize (maximize) the total cost (profit) of sending the available supply through the network to satisfy the demandthe available supply through the network to satisfy the demand.

João Miguel da Costa Sousa / Alexandra Moutinho 185

Page 50: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Applicationspp

Kind of application Supply nodes Transshipment nodes Demand nodes

Operation of a distributed network

Sources of goods Intermediate storage facilities

Customers

Solid waste  Sources of solid  Processing facilities Landfill locationsSolid waste management

Sources of solid waste

Processing facilities Landfill locations

Operation of a supply network

Vendors  Intermediate warehouses Processing facilitiesnetwork facilities

Coordinating product mixes at plants

Plants  Production of a specific product

Market for a specific product

Cash flow management

Sources of cash at a specific time

Short‐term investment options

Needs for cash at a specific time

João Miguel da Costa Sousa / Alexandra Moutinho 186

Page 51: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Formulation of the model

Consider directed network where n nodes include  l     l   d   d   d d  dat least one supply node and one demand node.

Decision variables:xij = flow through arc i→ j

Given information:cij = cost per unit flow through arc i→ juij = arc capacity for arc i→ jb fl d dbi = net flow generated at node i

Value of bi depends on nature of node i:bi > 0 if node i is a supply nodebi < 0 if node i is a demand nodeb   if  d  i i    t hi t  dbi = 0 if node i is a transshipment node

João Miguel da Costa Sousa / Alexandra Moutinho 187

Page 52: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Formulation of the model

Minimize ,n n

ij ijZ c x=∑∑Node 

1 1j j

i j= =∑∑

subject ton n

constraints= =

− =∑ ∑1 1

, for each node  ,n n

ij ji ij j

x x b i

≤ ≤ →and 0 , for each arc ij ijx u i j

João Miguel da Costa Sousa / Alexandra Moutinho 188

Page 53: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Minimum cost flow problemp

Feasible solutions property: necessary condition for Feasible solutions property: necessary condition for a minimum cost flow problem to have any feasible solutions: n

∑solutions:

1

0ii

b=

=∑If this condition does not hold, a dummy supply node or a dummy demand node is needed (as in the transportation problem).Integer solutions property:when every bi and uijjhave integer values, all basic variables in every basic feasible (BF) solution also have integer values.

João Miguel da Costa Sousa / Alexandra Moutinho 189

Page 54: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Examplep

Distribution network for the Distribution Unlimited Co.Distribution network for the Distribution Unlimited Co.

João Miguel da Costa Sousa / Alexandra Moutinho 190

Page 55: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Examplep

Linear programming problem:Linear programming problem:

Minimize 2 4 9 3 3 2 ,AB AC AD BC CE DE EDZ x x x x x x x= + + + + + +

+ + =subject to

50AB AC ADx x x

− + =+ =

5

40

0

AB AC AD

AB BCx x

x x x− − + =− + − = −

0

30

6

AC BC CE

AD DE ED

x x x

x x x

− − + = −60CE DE EDx x x

≤ ≤ ≥and 10, 80, all  0.AB CE ijx x x j

João Miguel da Costa Sousa / Alexandra Moutinho 191

Page 56: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Using simplex to solve the problemg p p

João Miguel da Costa Sousa / Alexandra Moutinho 192

Page 57: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Using simplex to solve the problemg p p

João Miguel da Costa Sousa / Alexandra Moutinho 193

Page 58: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Special casesp

Transportation problem. A supply node is provided for each source and a demand node for each destination. No transshipment nodes are included. Also, uij =∞.Assignment problem. As in the transportation g p pproblem and 

Number of supply nodes equal to number of demand nodes.pp y qbi = 1 for supply nodes and bi = –1 for demand nodes.

Transshipment problem A minimum cost flow Transshipment problem. A minimum cost flow problem with unlimited arc capacities: uij = ∞ (like previous example if uAB and uCE were ∞)previous example if uAB and uCE were ∞).

João Miguel da Costa Sousa / Alexandra Moutinho 194

Page 59: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Special casesp

Shortest‐path problemA supply node with the supply of 1 is provided for the origin.A demand node with the demand of 1 is provided for the d ti ti  destination. Rest of nodes are transshipment nodes.E h  di d li k i   l d b     i   f di d   i  Each undirected link is replaced by a pair of directed arcs in opposite directions (cij = cji), except arcs into supply node or out of demand nodeout of demand node.No arc capacities are imposed: uij = ∞.

João Miguel da Costa Sousa / Alexandra Moutinho 195

Page 60: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Example of shortest‐path problemp p p

João Miguel da Costa Sousa / Alexandra Moutinho 196

Page 61: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Special casesp

Maximum flow problem. Network already provided with one supply node (source) and one demand node (sink). Adjustments needed:

Set cij = 0 for all existing arcs (absence of costs).Select F, a safe upper bound on the maximum feasible flow through the network, and assign it as supply and demand.Add an arc from the supply node to the demand node and assign it an arbitrarily large unit cost, cij = M, as well as unlimited capacity  u  ∞  unlimited capacity, uij = ∞. 

João Miguel da Costa Sousa / Alexandra Moutinho 197

Page 62: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Example of maximum flow problemp p

João Miguel da Costa Sousa / Alexandra Moutinho 198

Page 63: NETWORK OPTIMIZATION MODELS - ULisboa OD...NETWORK OPTIMIZATION MODELS. Network models Network representation is widely used in: Production, distribution, project planning, facilities

Final comments

Except for transshipment problem  each of these Except for transshipment problem, each of these special cases was seen in this or the previous lesson (Chap 8 and 9)(Chap.8 and 9).For these, we already saw special‐purpose l halgorithms.

When a computer code is not readily available for the special‐purpose algorithm, it is reasonable to use the network simplex method, a highly streamlined version of the simplex method for solving minimum cost flow problems.

João Miguel da Costa Sousa 199