Thursday, March 14 Introduction to Network Flows

Slides:



Advertisements
Similar presentations
Maximum flow Main goals of the lecture:
Advertisements

Cognitive Radio Communications and Networks: Principles and Practice By A. M. Wyglinski, M. Nekovee, Y. T. Hou (Elsevier, December 2009) 1 Chapter 12 Cross-Layer.
and 6.855J Cycle Canceling Algorithm. 2 A minimum cost flow problem , $4 20, $1 20, $2 25, $2 25, $5 20, $6 30, $
February 21, 2002 Simplex Method Continued
Thursday, April 11 Some more applications of integer
Introduction to Algorithms 6.046J/18.401J/SMA5503
Tuesday, May 7 Integer Programming Formulations Handouts: Lecture Notes.
Thursday, March 7 Duality 2 – The dual problem, in general – illustrating duality with 2-person 0-sum game theory Handouts: Lecture Notes.
Tuesday, March 5 Duality – The art of obtaining bounds – weak and strong duality Handouts: Lecture Notes.
1 LP, extended maxflow, TRW OR: How to understand Vladimirs most recent work Ramin Zabih Cornell University.
1 Outline relationship among topics secrets LP with upper bounds by Simplex method basic feasible solution (BFS) by Simplex method for bounded variables.
1 Column Generation. 2 Outline trim loss problem different formulations column generation the trim loss problem master problem and subproblem in column.
Randomized Algorithms Randomized Algorithms CS648 1.
Shadow Prices vs. Vickrey Prices in Multipath Routing Parthasarathy Ramanujam, Zongpeng Li and Lisa Higham University of Calgary Presented by Ajay Gopinathan.
COMP 482: Design and Analysis of Algorithms
Outline Minimum Spanning Tree Maximal Flow Algorithm LP formulation 1.
Routing and Congestion Problems in General Networks Presented by Jun Zou CAS 744.
1 Lecture 2 Shortest-Path Problems Assignment Problems Transportation Problems.
Introduction to Algorithms
The minimum cost flow problem
MS&E 211 Minimum Cost Flow LP Ashish Goel. Minimum Cost Flow (MCF) Need to ship some good from “supply” nodes to “demand” nodes over a network – Example:
MIT and James Orlin © Introduction to Networks Eulerian Tours Hamiltonian Tours The Shortest Path Problem Dijkstra’s Algorithm for Solving the Shortest.
Computational Methods for Management and Economics Carla Gomes Module 9a Network Models Terminology (Slides adapted from J.Orlin’s)
Network Optimization Models: Maximum Flow Problems In this handout: The problem statement Solving by linear programming Augmenting path algorithm.
Princeton University COS 423 Theory of Algorithms Spring 2002 Kevin Wayne Greed: Shortest Path s 3 t
1 Discrete Optimization. 2 The relationship between counting techniques/graph theory and discrete optimization Adding a goal (objective function) to a.
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.
Computational Methods for Management and Economics Carla Gomes Module 9d Network Models Maximum Flow Problem (Slides adapted from J.Orlin’s and Hillier’s)
1 Lecture 4 Maximal Flow Problems Set Covering Problems.
Graph Theory Chapter 6 from Johnsonbaugh Article(6.1, 6.2)
Table 1. Shipping costs, Supply, and Demand for Powerco Example
Maximum Flow Chapter 26.
Network Optimization Models
1 ESI 6417 Linear Programming and Network Optimization Fall 2003 Ravindra K. Ahuja 370 Weil Hall, Dept. of ISE
Introduction to Operations Research
Network Models Tran Van Hoai Faculty of Computer Science & Engineering HCMC University of Technology Tran Van Hoai.
Section 2.9 Maximum Flow Problems Minimum Cost Network Flows Shortest Path Problems.
Modeling and Evaluation with Graph Mohammad Khalily Dermany Islamic Azad University, Khomein branch.
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.
Chapter 1 Introduction Introduction  Networks: mathematical models of real systems like electrical and power/ telecom/ logistics/ highway/ rail/
. 1 Transportation and Assignment Problems. . 2 Applications Physical analog of nodes Physical analog of arcs Flow Communication systems phone exchanges,
EMIS 8373: Integer Programming “Easy” Integer Programming Problems: Network Flow Problems updated 11 February 2007.
Graphs Discrete Structure CS203. Adjacency Matrix We already saw a way of representing relations on a set with a Boolean matrix: R digraph(R) M R1234.
Lecture 5 – Integration of Network Flow Programming Models Topics Min-cost flow problem (general model) Mathematical formulation and problem characteristics.
Overview of Graph Theory. Some applications of Graph Theory Models for communications and electrical networks Models for computer architectures Network.
Chapter 8 Network Models to accompany Operations Research: Applications and Algorithms 4th edition by Wayne L. Winston Copyright (c) 2004 Brooks/Cole,
Shortest Path Algorithm 2 Prof. Sin-Min Lee Department of Computer Science.
CSCE 3110 Data Structures & Algorithm Analysis Graphs (I) Reading: Chap.9, Weiss.
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.
::Network Optimization:: Minimum Spanning Trees and Clustering Taufik Djatna, Dr.Eng. 1.
Maximum Flow Chapter 26.
Part 3 Linear Programming
St. Edward’s University
Network Optimization J.B. Orlin
Graph Theory and Optimization
The minimum cost flow problem
Lecture 5 – Integration of Network Flow Programming Models
Max Flow – Min Cut Problem
Lecture 5 – Integration of Network Flow Programming Models
1.206J/16.77J/ESD.215J Airline Schedule Planning
Part 3 Linear Programming
Introduction Basic formulations Applications
Chapter 5 Transportation, Assignment, and Transshipment Problems
Chapter 6 Network Flow Models.
Flow Feasibility Problems
A network problem is one that can be represented by...
Part 3 Linear Programming
INTRODUCTION TO NETWORK FLOWS
Network Optimization Models: Maximum Flow Problems
Lecture 12 Network Models.
Presentation transcript:

15.053 Thursday, March 14 Introduction to Network Flows Handouts: Lecture Notes

Network Models Linear Programming models that exhibit a very special structure Can use this structure to dramatically reduce computational complexity First widespread application of LP to problems of industrial logistics 􀁺 Addresses huge number of diverse applications

Notation and Terminology Note: Network terminology is not (and never will be) standardized. The same concept may be denoted in many different ways. Called: • NETWORK • directed graph • digraph • graph Class Handouts (Ahuja, Magnanti, Orlin) Network G = (N,A) Node set N = {1,2,3,4} Arc Set {(1,2),(1,3),(3,2),(3,4),(2,4)} Also Seen Graph G = (V,E) Vertex set V = {1,2,3,4} Edge set: A={1-2,1-3,3-2,3-4,2-4}

Directed and Undirected Networks An Undirected Graph A Directed Graph • Networks are used to transport commodities • physical goods (products, liquids) • communication • electricity, etc. • The field of Network Optimization concerns optimization problems on networks

facilities, satellites An Overview of Some Applications of Network Optimization Physical analog of nodes Physical analog of arcs Applications Flow phone exchanges, computers, transmission facilities, satellites Communication systems Cables, fiber optic links, microwave relay links Voice messages, Data, Video transmissions Pumping stations Reservoirs, Lakes Water, Gas, Oil, Hydraulic fluids Hydraulic systems Pipelines Integrated computer circuits Gates, registers, processors Wires Electrical current Rods, Beams, Springs Mechanical systems Joints Heat, Energy Passengers, freight, vehicles, operators Intersections, Airports, Rail yards Highways, Airline routes Railbeds Transportation systems

Examples of terms. Path: Example: 5, 2, 3, 4. (or 5, c, 2, b, 3, e, 4) Note that directions are ignored. Directed Path . Example: 1, 2, 3, 4 (or 1, a, 2, b, 3, e) Directions are important. Two paths a-b-e (or 1-2-3-4) and a-c-d-e (or 1-2-5-3-4) Cycle or circuit (or loop) 1, 2, 3, 1. (or 1, a, 2, b, 3, e) Note that directions are ignored. Directed Cycle: (1, 2, 3, 4, 1) or 1, a, 2, b, 3, c, 4, d, 1 Directions are important. Cycles (loops): a-b-c-d (or 1-2-3-4-1) b-a-d-c (or 3-2-1-4-3) e-b-a (or 1-3-2-1) c-d-e (or 3-4-1-3)

More Definitions A network is connected if every node can be reached from every other node by following a sequence of arcs in which direction is ignored. A spanning tree is a connected subset of a network including all nodes, but containing no loops.

The Minimum Cost Flow Problem A network with costs, capacities, supplies, demands Network G = (N, A) – Node set N, arc set A; – Capacities uij on arc (i,j) – Cost cij on arc (i,j) – Supply/demand bi for node i. (Positive indicates supply) Minimize the cost of sending flow s.t. Flow out of i - Flow into i = bi Flow on arc (i,j) ≤ uij

The Minimum Cost Flow Problem Let xij be the flow on arc (i,j). Minimize the cost of sending flow s.t. Flow out of i - Flow into i = bi 0 ≤ xij ≤ uij Minimize s.t. for all i for all i-j

Example Formulation Min -3 x12 + 8 x13 + 7 x23 + 3 x24 + 2 x34 s.t x12 + x13 = 4 x23+ x24 - x12 = 3 x34 - x13 - x23 = -5 - x24 - x34 = -2 0 ≤ x12 ≤ 6 0 ≤ x13 ≤ 5 0 ≤ x23 ≤ 2 0 ≤ x24 ≤ 4 0 ≤ x34 ≤ 7

An Application of the Minimum Cost Flow Problem Warehouses Plants Supplies Customers Demands Ship from suppliers to customers, possibly through warehouses, at minimum cost to meet demands.

Useful Facts About The Minimum Cost Flow Problem Suppose the following properties of the constraint matrix, A (ignoring simple upper and lower variable bounds, such as x ≤ 7) hold: (1) all entries of A are 0 or 1 or -1 (2) there is at most one 1 in any column and at most one -1. Then this is a minimum cost flow problem.

Useful Facts (cont’d) Theorem. If one carries out the simplex algorithm on the minimum cost flow problem with integer valued capacities and RHS, then at every iteration of the simplex algorithm, each coefficient in the tableau (except for costs and RHS) is either 0 or -1 or 1. Corollary. The optimal LP solution is integer valued.

The Minimum Cost Flow Problem A network with costs, capacities, supplies, demands Network G = (N, A) – Node set N, arc set A; – Capacities uij on arc (i,j) – Cost cij on arc (i,j) – Supply/demand bi for node i. (Positive indicates supply) Minimize the cost of sending flow s.t. Flow out of i - Flow into i = bi Flow on arc (i,j) ≤ uij

The Transportation Problem Suppose that one wants to ship from warehouses to retailers In this example: 3 warehouses 4 retailers ai is the supply at warehouse i. bj is the demand at retailer j. cij is the cost of shipping from i to j. There are no capacities on the arcs. Let xij be the amount of flow shipped from warehouse i to retailer j. How do we formulate an LP?

The Transportation Problem is a Min Cost Flow Problem Minimize the cost of sending flow s.t. Flow out of i - Flow into i = bi 0 ≤ xij ≤ uij Flow out occurs at the supply nodes. Flow in occurs at demand Capacities are infinite: uij= ∞

The Transportation Problem In general the LP formulation is given as Minimize All arcs are from a node in S to a node in D, and uncapacitated. S: Supply nodes D: Demand nodes

Useful Facts About Transportation Problem Suppose that (1) the constraint matrix can be partitioned into A1x = b1 and A2x = b2. (2) all entries of A1 and A2 are 0 or 1 (3) there is at most one 1 in any column of A1 or A2 Then this is a transportation problem. Theorem. If one carries out the simplex algorithm on the transportation problem, then at every iteration of the simplex algorithm, each coefficient in the tableau (except for costs and RHS) is either 0 or -1 or 1. The costs and RHS are both integer valued. Corollary. The optimal solution to the LP is integer valued.

The Assignment Problem Suppose that one wants to assign tasks to persons Tasks Persons In this example: 4 tasks 3 persons No two tasks to the same person Each person gets a task cij is the “cost” of assigning task i to person j. Let xij = 1 if task i is assigned to j. Let xij = 0 otherwise. How do we formulate an LP?

The Assignment Problem In general the LP formulation is given as Minimize Each supply is 1 Each demand is 1

More on the Assignment Problem Tasks Persons The assignment problem is a special case of the transportation problem. The simplex algorithm can solve the LP relaxation, and it will give integer answers, that is, it will solve the assignment problem.

An Application of the Assignment Problem Suppose that there are moving targets in space. You can identify each target as a pixel on a radar screen. Given two successive pictures, identify how the targets have moved.

Maximize the flow leaving s The Maximum Flow Problem Network G = (N, A). – Source s and sink t – Capacities uij on arc (i,j) – Variable: Flow xij on arc (i,j) Graph with capacities Maximize the flow leaving s s.t. Flow out of i - Flow into i = 0 for i ≠ s, t 0 ≤ xij ≤ uij

The Max Flow Problem In general the LP formulation is given as Minimize otherwise This is not formulated as a special case of a minimum cost flow formulation. Can we reformulate it in this way?

More on the maximum flow problem Is the current flow optimal? An s-t cut is a separation of the nodes into two parts S and T, with s in S and t in T. The capacity of the cut is the sum of the capacities from S to T. The max flow from s to t is at most the capacity of any s-t cut Graph with capacities and flows (underlined)

The Shortest Path Problem What is the shortest path from an origin or source node (often denoted as s) to a destination or sink node, (often denoted as t)? What is the shortest path from node 1 to node 6? Assumptions for now: 1. There is a path from node s to all other nodes. 2. All arc lengths are non-negative

Direct Applications What is the path with the shortest driving time from 77 Massachusetts Avenue to Boston City Hall? What is the path from Building 7 to Building E40 that minimizes the time spent outside? 􀁺What is the communication path from i to j that is the fastest (taking into account congestion at nodes)?

Formulation as a linear program In general the LP formulation is given as Minimize otherwise

The Shortest Path Problem 􀁺 Fact: The Shortest path problem is a special case of the minimum cost flow problem Lots of interesting applications (coming up) Very fast algorithm (coming up) Connection to dynamic programming (several lectures from now)

Conclusions. Advantages of the transportation problem and the minimum cost flow problem – Integer solutions – Very fast solution methods – Extremely common in modeling Today we saw the following: – The minimum cost flow problem – The transportation problem – The assignment problem – The maximum flow problem – The shortest path problem