Presentation is loading. Please wait.

Presentation is loading. Please wait.

Network Models (2) Tran Van Hoai Faculty of Computer Science & Engineering HCMC University of Technology 2010-20111Tran Van Hoai.

Similar presentations


Presentation on theme: "Network Models (2) Tran Van Hoai Faculty of Computer Science & Engineering HCMC University of Technology 2010-20111Tran Van Hoai."— Presentation transcript:

1 Network Models (2) Tran Van Hoai Faculty of Computer Science & Engineering HCMC University of Technology 2010-20111Tran Van Hoai

2 Products transported from Assembly line to Inspection are for Quality Control Ballston Electric Assembly line - Inspection 2010-20112Tran Van Hoai Which assembly line should be assigned to which inspection area (to minimize a given objective)?

3 Time to transport a unit of product from assembly line to inspection Inspection Area ABCDE Assembly Line 1 1046 12 2 1177914 3 13881415 4 1416 17 5 1911172019 2010-2011Tran Van Hoai3 Time difference mainly comes from the distance difference among pair

4 MIN10X 11 + 4X 12 + … + 20X 54 + 19X 55 S.T. X 11 +X 12 +X 13 +X 14 +X 15 =1(Assemble line 1 is assigned) X 21 +X 22 +X 23 +X 24 +X 25 =1(Assemble line 2 is assigned) X 31 +X 32 +X 33 +X 34 +X 35 =1(Assemble line 3 is assigned) X 41 +X 42 +X 43 +X 44 +X 45 =1(Assemble line 4 is assigned) X 51 +X 52 +X 53 +X 54 +X 55 =1(Assemble line 5 is assigned) X 11 +X 21 +X 31 +X 41 +X 51 =1(Inspection area 1 is assigned) X 12 +X 22 +X 32 +X 42 +X 52 =1(Inspection area 2 is assigned) X 13 +X 23 +X 33 +X 43 +X 53 =1(Inspection area 3 is assigned) X 14 +X 24 +X 34 +X 44 +X 54 =1(Inspection area 4 is assigned) X 15 +X 25 +X 35 +X 45 +X 55 =1(Inspection area 5 is assigned) All X ij ’s ≥ 0 Define a set of decision variables X ij, which mean 1if Line i is assigned to Inspection j X ij = 0otherwise Define a set of decision variables X ij, which mean 1if Line i is assigned to Inspection j X ij = 0otherwise Formulation 2010-2011Tran Van Hoai4

5 Assignment networks Definition Can be solved by – Enumeration – LP – Transportation model – Dynamic programming – Branch-and-bound – Hungarian algorithm 2010-2011Tran Van Hoai5 - m workers are to be assigned to m jobs - Unit cost C ij for worker i performing job j Goal: to minimize total cost of assignment - m workers are to be assigned to m jobs - Unit cost C ij for worker i performing job j Goal: to minimize total cost of assignment

6 Advanced issues (1) Number of workers ≥ number of jobs – Worker constraint changed from “=” to “≤” A worker can perform ≥ 1 jobs Minimization changed to maximization Additional constraints – Line 1 cannot be assigned to Inspection B X 12 =0 – If Line 1 is assigned to Inspection B, then Line 2 must be assigned to Inspection D 2010-2011Tran Van Hoai6

7 Advanced issues (2) Additional constraints – If Line 1 is assigned to Inspection B, then Line 2 must be assigned to Inspection D X 12 ≤ X 24 – At least one in Lines {1,3,4} is assigned to Inspection E X 15 +X 35 +X 45 =1 2010-2011Tran Van Hoai7

8 Generalized assignment model 2010-2011Tran Van Hoai8

9 Marriage service 2010-2011Tran Van Hoai9 ASSIGNMENT Each man only assigned to one woman Pair assignment requires a operational cost Each man only assigned to one woman Pair assignment requires a operational cost GOAL: to find a match having minimum total cost

10 Shortest path problem 2010-2011Tran Van Hoai10 1 2 3 4 5 6 8 7 100 151 42 67 150 75 22 89 52 25 71 11 - n nodes, a starting node (source), an ending node (destination) - Arcs connecting adjacent nodes with non- negative distances d ij GOAL: to find a shortest path from source to destination - n nodes, a starting node (source), an ending node (destination) - Arcs connecting adjacent nodes with non- negative distances d ij GOAL: to find a shortest path from source to destination

11 Solution methods Dijkstra – Only works for non-negative arc weight Bellman-Ford – To find shortest path from a source to all other nodes – Works with non-negative arc weight (provided that there is no negative weighted cycle) Floyd–Warshall – To find shortest path between all node pairs 2010-2011Tran Van Hoai11 Not easy to include additional constraints (for non-IT users) Not easy to include additional constraints (for non-IT users)

12 LP-based approach 2010-2011Tran Van Hoai12 Define a set of decision variables X ij, which mean 1if arc ij is utilized X ij = 0otherwise Define a set of decision variables X ij, which mean 1if arc ij is utilized X ij = 0otherwise MIN∑d ij X ij S.T. = 1(for source) - = 0 (for intermediate nodes) - = -1(for destination) X ij = 0 or 1

13 MIN100X 12 + 151X 13 + … + 52X 78 S.T.X 12 +X 13 =1 -X 12 +X 25 +X 26 =0 -X 13 +X 34 +X 35 =0 -X 34 +X 45 +X 47 =0 -X 25 -X 35 -X 45 +X 57 =0 -X 26 +X 67 +X 68 =0 -X 47 -X 57 -X 67 +X 78 =0 -X 68 -X 78 = X ij = 0 or 1 2010-2011Tran Van Hoai13

14 Shortest path 2010-2011Tran Van Hoai14 1 2 3 4 5 6 8 7 100 151 42 67 150 75 22 89 52 25 71 9

15 Additional constraints Not go through node 5 X 25 = X 35 = X 45 = X 57 = 0 Don’t have to remove node 5 Node 4 must be on the path X 45 +X 47 = 1 2010-2011Tran Van Hoai15 1 2 3 4 5 6 8 7 100 151 42 67 150 75 22 89 52 25 71 9 1 2 3 4 5 6 8 7 100 151 42 67 150 75 22 89 52 25 71 9

16 Additional constraints If node 7 on path, then node 3 must on path X 35 + X 34 – X 78 ≥ 0 … 2010-2011Tran Van Hoai16 1 2 3 4 5 6 8 7 100 151 42 67 150 75 22 89 52 25 71 9

17 Maximal flow model 2010-2011Tran Van Hoai17 - one source node, generating flows - one terminal node, depositing flows - flow in = flow out on intermediate nodes - capacity C ij on arc from i to j GOAL: to find maximum flow out of source to terminal, without exceeding arc capacities - one source node, generating flows - one terminal node, depositing flows - flow in = flow out on intermediate nodes - capacity C ij on arc from i to j GOAL: to find maximum flow out of source to terminal, without exceeding arc capacities

18 Maximal flow problem 2010-2011Tran Van Hoai18 1 2 3 4 5 6 8 7 10 15 5 6 12 7 2 8 5 4 7 3

19 LP-based approach X ij : flow from node i to node j (if arc ij exists) 2010-2011Tran Van Hoai19

20 MAXX 12 + X 13 S.T.-X 12 +X 25 +X 26 =0 -X 13 +X 34 +X 35 =0 -X 34 +X 45 +X 47 =0 -X 25 -X 35 -X 45 +X 57 =0 -X 26 +X 67 +X 68 =0 -X 47 -X 57 -X 67 +X 78 =0 X ij = 0 or 1 X 12 ≤1, X 13 ≤2, X 25 ≤3, X 26 ≤4, X 34 ≤5, X 35 ≤6, X 45 ≤7, X 47 ≤8,X 57 ≤9,X 67 ≤10,X 68 ≤11,X 78 ≤12 2010-2011Tran Van Hoai20

21 Maximal flow problem 2010-2011Tran Van Hoai21 1 2 3 4 5 6 8 7 10 15 5 6 12 7 2 8 5 4 7 3 7 5 7 5 5 7 5

22 Cuts in maximal flow problem 2010-2011Tran Van Hoai22 1 2 3 4 5 6 8 7 10 15 5 6 12 7 2 8 5 4 7 3 7 5 7 5 5 7 5 CUT (all flow from 1 → 8 must cross CUT) Maximal flow (12) ≤ C 25 + C 26 + C 35 + C 45 + C 47 (34) Sum of arc capacities on the cut provides upper bound for maximal flow

23 Max flow/Min cut theorem 1.The value of max flow = the sum of capacities of min cut 2.The flow of all arcs on min cut will be at their upper bound 2010-2011Tran Van Hoai23

24 Traveling salesman network NP-Hard (cannot be solved in polynomial time) Connectivity network model 2010-2011Tran Van Hoai24 - m nodes - unit cost C ij utilizing arc from i to j GOAL: to find a minimum cost tour (cycle) visiting all nodes (not twice) - m nodes - unit cost C ij utilizing arc from i to j GOAL: to find a minimum cost tour (cycle) visiting all nodes (not twice)

25 Solution methods Enumerating all possible tour (cycle) (m-1)! tours for m nodes in symmetric TSP LP-based approach 2010-2011Tran Van Hoai25 Define a set of decision variables X ij, which mean 1if arc ij is utilized X ij = 0otherwise Define a set of decision variables X ij, which mean 1if arc ij is utilized X ij = 0otherwise

26 Federal Emergency Managament Agency 2010-2011Tran Van Hoai26 1 2 3 4 H 30 50 35 45 65 80 40 50 25 40

27 Assignment constraints Sum of arcs used out of each node is 1 X 11 + X 12 + X 13 + X 14 + X 15 = 1 Sum of arcs used into each node is 1 X 11 + X 21 + X 31 + X 41 + X 51 = 1 2010-2011Tran Van Hoai27 1 2 3 4 H 30 50 35 45 65 80 40 50 25 40 INVALID SOLUTION Need constraints to remove subtours

28 Subtour constraints One-node subtour constraints X 11, X 22, X 33, X 44, X 55 ≤ 0 Two-node subtour constraints X 12 + X 21 ≤ 1, … Three-node subtour constraints X 12 + X 23 + X 31 ≤ 2, … Four-node subtour constraints X 12 + X 23 + X 34 + X 41 ≤ 3, … 2010-2011Tran Van Hoai28

29 Vehicle routing problem Generalized TSP 2010-2011Tran Van Hoai29

30 Minimum spanning tree network Read textbook 2010-2011Tran Van Hoai30


Download ppt "Network Models (2) Tran Van Hoai Faculty of Computer Science & Engineering HCMC University of Technology 2010-20111Tran Van Hoai."

Similar presentations


Ads by Google