Lecture 5 – Integration of Network Flow Programming Models

Slides:



Advertisements
Similar presentations
Thursday, March 14 Introduction to Network Flows
Advertisements

Outline LP formulation of minimal cost flow problem
1 Lecture 2 Shortest-Path Problems Assignment Problems Transportation Problems.
Network Flows. 2 Ardavan Asef-Vaziri June-2013Transportation Problem and Related Topics Table of Contents Chapter 6 (Network Optimization Problems) Minimum-Cost.
Transportation Problem (TP) and Assignment Problem (AP)
1 1 Slides by John Loucks St. Edward’s University Modifications by A. Asef-Vaziri.
1 1 Slide © 2011 Cengage Learning. All Rights Reserved. May not be scanned, copied or duplicated, or posted to a publicly accessible website, in whole.
1Transportation ModelsLesson 4 LECTURE FOUR Transportation Models.
Management Science 461 Lecture 6 – Network Flow Problems October 21, 2008.
Basic Feasible Solutions: Recap MS&E 211. WILL FOLLOW A CELEBRATED INTELLECTUAL TEACHING TRADITION.
1 1 Slide © 2006 Thomson South-Western. All Rights Reserved. Slides prepared by JOHN LOUCKS St. Edward’s University.
Network Optimization Models: Maximum Flow Problems In this handout: The problem statement Solving by linear programming Augmenting path algorithm.
Example 15.4 Distributing Tomato Products at the RedBrand Company
Max-flow/min-cut theorem Theorem: For each network with one source and one sink, the maximum flow from the source to the destination is equal to the minimal.
Lecture 4 – Network Flow Programming
Lecture 3 Transshipment Problems Minimum Cost Flow Problems
1 1 Slide © 2011 Cengage Learning. All Rights Reserved. May not be scanned, copied or duplicated, or posted to a publicly accessible website, in whole.
ENGM 732 Network Flow Programming Network Flow Models.
Network Optimization Problem
Modeling and Evaluation with Graph Mohammad Khalily Dermany Islamic Azad University, Khomein branch.
1 1 Slide © 2008 Thomson South-Western. All Rights Reserved Slides by JOHN LOUCKS St. Edward’s University.
1 Minimum Cost Flows Goal: Minimize costs to meet all demands in a network subject to capacities (combines elements of both shortest path and max flow.
Minimum Cost Flows. 2 The Minimum Cost Flow Problem u ij = capacity of arc (i,j). c ij = unit cost of shipping flow from node i to node j on (i,j). x.
EMIS 8373: Integer Programming “Easy” Integer Programming Problems: Network Flow Problems updated 11 February 2007.
Network Optimization Problems
Route Planning Texas Transfer Corp (TTC) Case 1. Linear programming Example: Woodcarving, Inc. Manufactures two types of wooden toys  Soldiers sell for.
1 1 Slide © 2009 South-Western, a part of Cengage Learning Slides by John Loucks St. Edward’s University.
1 Network Models Transportation Problem (TP) Distributing any commodity from any group of supply centers, called sources, to any group of receiving.
EMIS 8374 Network Flow Models updated 29 January 2008.
Network Optimization Network optimization models: Special cases of linear programming models Important to identify problems that can be modeled as networks.
Lecture 5 – Integration of Network Flow Programming Models Topics Min-cost flow problem (general model) Mathematical formulation and problem characteristics.
1 1 Slide © 2008 Thomson South-Western. All Rights Reserved Slides by JOHN LOUCKS St. Edward’s University.
8/14/04J. Bard and J. W. Barnes Operations Research Models and Methods Copyright All rights reserved Lecture 5 – Integration of Network Flow Programming.
Network Flow Problems Example of Network Flow problems:
Chapter 8 Network Models to accompany Operations Research: Applications and Algorithms 4th edition by Wayne L. Winston Copyright (c) 2004 Brooks/Cole,
8/14/04 J. Bard and J. W. Barnes Operations Research Models and Methods Copyright All rights reserved Lecture 6 – Integer Programming Models Topics.
Lecture 6 – Integer Programming Models Topics General model Logic constraint Defining decision variables Continuous vs. integral solution Applications:
1 Chapter 2 Notation and Definitions Data Structures Transformations.
1 1 Slide © 2008 Thomson South-Western. All Rights Reserved © 2011 Cengage Learning. All Rights Reserved. May not be scanned, copied or duplicated, or.
Lecture 4 – Network Flow Programming Topics Terminology and Notation Network diagrams Generic problems (TP, AP, SPP, STP, MF) LP formulations Finding solutions.
Tuesday, March 19 The Network Simplex Method for Solving the Minimum Cost Flow Problem Handouts: Lecture Notes Warning: there is a lot to the network.
St. Edward’s University
Network Optimization J.B. Orlin
ENGM 535 Optimization Networks
Lecture 5 – Integration of Network Flow Programming Models
The Network Simplex Method
Assignment Problem A balanced transportation problem in which
Transportation, Assignment and Network Models
Optimization II.
Chapter 7 Transportation, Assignment & Transshipment Problems
Introduction Basic formulations Applications
Transportation Problems
Network Models Robert Zimmer Room 6, 25 St James.
Chapter 5 Transportation, Assignment, and Transshipment Problems
Chapter 5 Network Modeling.
Chapter 6 Network Flow Models.
Slides by John Loucks St. Edward’s University.
Flow Feasibility Problems
A network problem is one that can be represented by...
Minimum Cost Network Flow Problems
The Network Simplex Method
Lecture 6 – Integer Programming Models
Introduction to Minimum Cost Flows
Network Optimization Models: Maximum Flow Problems
The network simplex method
Network Flow Problems – Maximal Flow Problems
Maximum Flow Problems in 2005.
EMIS The Maximum Flow Problem: Flows and Cuts Updated 6 March 2008
Lecture 12 Network Models.
Presentation transcript:

Lecture 5 – Integration of Network Flow Programming Models Topics Min-cost flow problem (general model) Mathematical formulation and problem characteristics Pure vs. generalized networks 8/14/04 J. Bard and J. W. Barnes Operations Research Models and Methods Copyright 2004 - All rights reserved

Example: Distribution problem Min-Cost Flow Problem Example: Distribution problem Warehouses store a particular commodity in Phoenix, Austin and Gainesville. Customers - Chicago, LA, Dallas, Atlanta, & New York Supply [ si ] at each warehouse i Demand [ dj ] of each customer j Shipping links depicted by arcs, flow on each arc is limited to 200 units. Dallas and Atlanta - transshipment hubs Per unit transportation cost (cij ) for each arc Problem: Determine optimal shipping plan that minimizes transportation costs

Distribution Problem 2 6 1 3 4 5 8 7 [supply / demand] arc lower bounds = 0 (shipping cost) arc upper bounds = 200 [700] [–200] (6) CHIC 2 NY 6 [–250] PHOE 1 (4) (7) (6) (4) (3) (3) (5) (5) (2) [–200] LA 3 DAL 4 ATL 5 [–150] (7) (2) [–300] (4) (2) (7) (6) (5) GAINS 8 [200] AUS 7 [200]

Notation for Min-Cost Flow Problem In general: [supply/demand] on nodes (shipping cost per unit) on arcs In example: all arcs have an upper bound of 200 nodes labeled with a number 1,...,8 Must indicate notation that is included in model: (cij) for costs (uij) for capacities/simple upper bounds (gij) for gains All 3 could be included: (cij, uij, gij)

Spreadsheet Input Data arc name origin node termination node lower bound upper bound cost gain xij i j lij uij cij gij i j external flow si or -di The origin node is the arc’s tail The termination node is called the head Supplies are positive and demands are negative

Data Entry Using Math Programming/Network Add-in. And here is the solution ...

Solution to Distribution Problem [supply / demand] (flow) [-200] [-250] (200) [700] CHIC NY PHOE (50) (100) (200) (200) [-150] LA ATL (200) [-300] DAL (50) [-200] (200) [200] GAINS AUS [200]

Sensitivity Report for Max Flow Problem

Characteristics of Network Flow Problems · Conservation of flow at nodes. At each node flow in = flow out. At supply nodes there is an external inflow (positive) At demand nodes there is an external outflow (negative). · Flows on arcs must obey the arc’s bounds. lower bound & upper bound (capacity) · Each arc has a per unit cost & the goal is to minimize total cost.

Distribution Network  Notation [external flow] (cost) lower = 0, upper = 200 [-200] [-250] (6) 2 6 [700] 1 (4) (6) (7) (4) (5) (3) (3) (7) (2) (5) [-200] 4 [-150] 3 5 [-300] (2) (4) (6) (7) (2) (5) 8 [200] 7 [200]  Notation

LP for Distribution Problem Pure network  flow at each node is conserved  flow across an arc is conserved  no gains or losses can occur on arcs Min 6x + 3x + 3x + ¼ 7x + + 4x + 7x 12 13 14 16 85 86 s.t. -x - x - x = - 200 Flow balance constraints for each of the 8 nodes sit. - x + x - x = - 12 200 21 42 41 52 51 x + x + x x = 700 x + x + + x + x = 700 12 21 13 23 14 24 15 26 -x + x - x = - 200 - x + x - x = - 43 73 200 13 23 43 63 + x + x + x + x - -x x - x - x = - 300 x + 42 x + 43 x + x + x + x + x + x = - 300 41 41 43 46 45 47 46 54 24 54 74 84 64 84 . . . x + x + x = 200 84 85 86 0 £ xij £ 200, for all (i,j ) combinations which are arcs

(or in the other order if i > j) Decision variables are the flow variables xij i j By examining the flow balance constraints we see that xij appears in exactly two of them: xij . . . +1 node i (or in the other order if i > j) . . . - 1 node j . . .

Observations from LP Model If we add the constraints we obtain zero on the left-hand side so the right-hand side must also be zero for feasibility. In particular, this means sum of supplies = sum of demands. Mathematically, we have one redundant constraint. Must be careful in interpreting shadow prices on the flow balance constraints. Cannot change only a supply or demand and have model make sense.

Pure Minimum Cost Flow Problem G = (N, A)  network with node set N and arc set A Indices i, j Î N denote nodes and (i, j) Î A denote arcs Originating set of arcs for node i (tails are i) is the forward star of i FS(i) = { (i,j ) : (i,j ) Î A } Terminating set of arcs for node i is the reverse star of i RS(i) = { (j,i ) : (j,i ) Î A }.

å xij – å xji = bi In our example: FS(1) = { (1,2), (1,3), (1,4), (1, 5) } RS(1) = Ø FS(4) = { (4,2), (4,3), (4,5), (4,6) } RS(4) = { (1,4), (5, 4), (7,4), (8,4) } å xij – å xji = bi (i,j )ÎFS(i ) where bi is positive for supply and negative for demand at node i. (j,i )ÎRS(i ) Flow Balance equation:

Pure Min-Cost Flow Problem Indices/sets i, j Î N nodes arcs forward star of i reverse star of i (i, j ) Î A FS(i ) RS(i ) Data cij unit cost of flow on (i,j ) lower bound on flow (i,j ) upper bound on flow (i,j ) external flow at node i lij uij bi

å cijxij å xij - å xji = bi, " i Î N Decision Variables xij = flow on arc (i,j ) Formulation Min å cijxij (i,j)ÎA s.t. å xij - å xji = bi, " i Î N (i,j )ÎFS(i ) (j,i )ÎRS(i ) lij £ xij £ uij, " (i,j ) Î A

Generalized Minimum Cost Network Flow Model Only one modification to “pure” formulation  a possible gain on each arc, denoted by gij If gij = 0.95 then 100 units of flow leaves node i and 95 units arrive at node j

Generalized Formulation å cijxij Min (i,j )ÎA s.t. å xij - å gjixji = bi, " i Î N (i,j )ÎFS(i ) (j,i )ÎRS(i ) lij £ xij £ uij, " (i,j )ÎA Note that if gij =1 " (i,j ) Î A, then we obtain the “pure” model

Gains and Losses Might experience 5% spoilage of a perishable good during transportation on a particular arc. gij = 0.95 for the associated arc (i,j). In production of manufacturing formulations we might incur losses due to production defects. In financial examples we can have gains due to currency exchange or gains due to returns on investments. US $ Swiss francs Year 1 Year 2 currency exchange 15% return on investment Gain = 1.78 Gain = 1.15

Pure Network Problems vs. General Network Problems If bi, lij and uij are integer-valued then all extreme points of the feasible region for a pure network flow problem give integer values for xij. FACT (Same cannot be said for generalized network models.) This integer property means that if we use the simplex method to solve a pure network flow problem then we are guaranteed that xij will be integer at optimality.

This is critical when we formulate the assignment, shortest path problems, and other network problems. Special cases of the pure min-cost flow model: Transportation problem Assignment problem Shortest path problem Maximum flow problem

Checking for Arbitrage Opportunities US $ Yen(100) CHF D-Mark Brit £ 1 US $ 1 1.05 1.45 1.72 .68 2 Yen(100) .95 1 1.41 1.64 .64 3 CHF .69 .71 1 1.14 .48 4 D-Mark .58 .61 0.88 1 .39 5 Brit £ 1.50 1.56 2.08 2.08 1 The table is to be read as follows: The 1.45 in row 1 column 3 means that $1 US will purchase 1.45 Swiss Francs (CHF). In addition, there is a 1% fee that is charged on each exchange.

Arbitrage Network: Generalized Min-Cost Flow Problem Arc costs: cij = $ equivalent (first column of table) For example: c14 = 1, c35 = 0.69 [-1] US $ 1 Yen 2 5 Brit £ 4 3 D-Mark CHF Each arc has a gain of gij. For example, g12 = (1.05)(0.99) g51 = (1.50)(0.99)

Solution to Arbitrage Network US $ Arc gains in optimal cycle: 1 0.674 g54 = 2.535 g43 = 0.871 g35 = 0.475 Brit £ 5 30.473 13.801 CHF 3 Total cycle gain: = 1.0488 = 4.88% 4 34.986 D-Mark Note (£  $): g51 = 1.485 Start with 13.801 £  34.986 D-Mark  30.473 CHF  14.475 £ Remove 0.674 £  $1 leaving 13.801 £