1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

44
1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)
  • date post

    22-Dec-2015
  • Category

    Documents

  • view

    231
  • download

    8

Transcript of 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

Page 1: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

1

Lecture5

Linear Programming (6S)and

Transportation Problem (8S)

Page 2: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

2

George Dantzig – 1914 -2005 Concerned with optimal allocation of limited

resources such as Materials Budgets Labor Machine time

among competitive activities under a set of constraints

Linear ProgrammingLinear Programming

George Dantzig – 1914 -2005

Page 3: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

3

Product Mix Example (from session 1)Product Mix Example (from session 1)

Type 1 Type 2

Profit per unit $60 $50

Assembly time per unit

4 hrs 10 hrs

Inspection time per unit

2 hrs 1 hr

Storage space per unit

3 cubic ft 3 cubic ft

Resource Amount available

Assembly time 100 hours

Inspection time 22 hours

Storage space 39 cubic feet

Page 4: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

4

Maximize 60X1 + 50X2

Subject to

4X1 + 10X2 <= 100

2X1 + 1X2 <= 22

3X1 + 3X2 <= 39

X1, X2 >= 0

Linear Programming ExampleLinear Programming ExampleVariables

Objective function

Constraints

What is a Linear Program?

• A LP is an optimization model that has

• continuous variables

• a single linear objective function, and

• (almost always) several constraints (linear equalities or inequalities)

Non-negativity Constraints

Page 5: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

5

Decision variables unknowns, which is what model seeks to determine for example, amounts of either inputs or outputs

Objective Function goal, determines value of best (optimum) solution among all feasible (satisfy

constraints) values of the variables either maximization or minimization

Constraints restrictions, which limit variables of the model limitations that restrict the available alternatives

Parameters: numerical values (for example, RHS of constraints)

Feasible solution: is one particular set of values of the decision variables that satisfies the constraints Feasible solution space: the set of all feasible solutions

Optimal solution: is a feasible solution that maximizes or minimizes the objective function

There could be multiple optimal solutions

Linear Programming ModelLinear Programming Model

Page 6: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

6

Another Example of LP: Diet Another Example of LP: Diet ProblemProblem

Energy requirement : 2000 kcal Protein requirement : 55 g Calcium requirement : 800 mgFood Energy (kcal) Protein(g) Calcium(mg) Price per

serving($)

Oatmeal 110 4 2 3

Chicken 205 32 12 24

Eggs 160 13 54 13

Milk 160 8 285 9

Pie 420 4 22 24

Pork 260 14 80 13

Page 7: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

7

Example of LP : Diet ProblemExample of LP : Diet Problem

oatmeal: at most 4 servings/day chicken: at most 3 servings/day eggs: at most 2 servings/day milk: at most 8 servings/day pie: at most 2 servings/day pork: at most 2 servings/day

Design an optimal diet plan which minimizes the cost per

day

Page 8: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

8

Step 1: define decision variablesStep 1: define decision variables

x1 = # of oatmeal servings x2 = # of chicken servings x3 = # of eggs servings x4 = # of milk servings x5 = # of pie servings x6 = # of pork servings

Step 2: formulate objective function• In this case, minimize total cost

minimize z = 3x1 + 24x2 + 13x3 + 9x4 + 24x5 + 13x6

Page 9: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

9

Step 3: ConstraintsStep 3: Constraints

Meet energy requirement110x1 + 205x2 + 160x3 + 160x4 + 420x5 + 260x6 2000 Meet protein requirement4x1 + 32x2 + 13x3 + 8x4 + 4x5 + 14x6 55 Meet calcium requirement2x1 + 12x2 + 54x3 + 285x4 + 22x5 + 80x6 800 Restriction on number of servings0x14, 0x23, 0x32, 0x48, 0x52, 0x62

Page 10: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

10

So, how does a LP look like?So, how does a LP look like?

minimize 3x1 + 24x2 + 13x3 + 9x4 + 24x5 + 13x6

subject to110x1 + 205x2 + 160x3 + 160x4 + 420x5 + 260x6 2000

4x1 + 32x2 + 13x3 + 8x4 + 4x5 + 14x6 55

2x1 + 12x2 + 54x3 + 285x4 + 22x5 + 80x6 800

0x14

0x23

0x32

0x48

0x52

0x62

Page 11: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

11

Optimal Solution – Diet ProblemOptimal Solution – Diet ProblemUsing LINDO 6.1Using LINDO 6.1

Cost of diet = $96.50 per day

Food # of servings

Oatmeal 4

Chicken 0

Eggs 0

Milk 6.5

Pie 0

Pork 2

Page 12: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

12

Optimal Solution – Diet ProblemOptimal Solution – Diet ProblemUsing Management ScientistUsing Management Scientist

Cost of diet = $96.50 per day

Food # of servings

Oatmeal 4

Chicken 0

Eggs 0

Milk 6.5

Pie 0

Pork 2

Page 13: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

13

Guidelines for Model FormulationGuidelines for Model Formulation

Understand the problem thoroughly. Describe the objective. Describe each constraint. Define the decision variables. Write the objective in terms of the decision

variables. Write the constraints in terms of the decision

variables Do not forget non-negativity constraints

Page 14: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

14

A Transportation TableA Transportation Table

Warehouse

4 7 7 1100

12 3 8 8200

8 10 16 5150

450

45080 90 120 160

1 2 3 4

1

2

3

Factory Factory 1can supply 100units per period

Demand

Warehouse B’s demand is 90 units per period Total demand

per period

Total supplycapacity perperiod

Page 15: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

15

LP Formulation of Transportation ProblemLP Formulation of Transportation Problem

minimize 4x11+7x12+7x13+x14+12x21+3x22+8x23+8x24+8x31+10x32+16x33+5x34

Subject to x11+x12+x13+x14=100 x21+x22+x23+x24=200 x31+x32+x33+x34=150 x11+x21+x31=80 x12+x22+x32=90 x13+x23+x33=120 x14+x24+x34=160 xij>=0, i=1,2,3; j=1,2,3,4

Supply constraint for factories

Demand constraint of warehouses

Minimize total cost of transportation

Page 16: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

16

Solution in Management ScientistSolution in Management Scientist

Total transportation cost = 4(80) + 7(0) + 7(10)+ 1(10) + 12(0) + 3(90) + 8(110) + 8(0) + 8(0) +10(0) + 16(0) +5 (150) = $2300

Page 17: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

17

Solution using LINDOSolution using LINDO

Notice multiple optimal solutions!

Page 18: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

18

Product Mix ProblemProduct Mix Problem• Floataway Tours has $420,000 that can be used to

purchase new rental boats for hire during the summer. • The boats can be purchased from two different

manufacturers.• Floataway Tours would like to purchase at least 50 boats.• They would also like to purchase the same number from

Sleekboat as from Racer to maintain goodwill. • At the same time, Floataway Tours wishes to have a total

seating capacity of at least 200.

• Formulate this problem as a linear program

Page 19: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

19

Maximum Expected Daily

Boat Builder Cost Seating Profit

Speedhawk Sleekboat $6000 3 $ 70

Silverbird Sleekboat $7000 5 $ 80

Catman Racer $5000 2 $ 50

Classy Racer $9000 6 $110

Product Mix ProblemProduct Mix Problem

Page 20: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

20

Define the decision variables

x1 = number of Speedhawks ordered

x2 = number of Silverbirds ordered

x3 = number of Catmans ordered

x4 = number of Classys ordered Define the objective function Maximize total expected daily profit: Max: (Expected daily profit per unit) x (Number of units)

Max: 70x1 + 80x2 + 50x3 + 110x4

Product Mix ProblemProduct Mix Problem

Page 21: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

21

Define the constraints(1) Spend no more than $420,000:

6000x1 + 7000x2 + 5000x3 + 9000x4 < 420,000 (2) Purchase at least 50 boats: x1 + x2 + x3 + x4 > 50 (3) Number of boats from Sleekboat equals number

of boats from Racer: x1 + x2 = x3 + x4 or x1 + x2 - x3 - x4 = 0

(4) Capacity at least 200: 3x1 + 5x2 + 2x3 + 6x4 > 200

Nonnegativity of variables: xj > 0, for j = 1,2,3,4

Product Mix ProblemProduct Mix Problem

Page 22: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

22

Max 70x1 + 80x2 + 50x3 + 110x4

s.t.

6000x1 + 7000x2 + 5000x3 + 9000x4 < 420,000

x1 + x2 + x3 + x4 > 50

x1 + x2 - x3 - x4 = 0

3x1 + 5x2 + 2x3 + 6x4 > 200

x1, x2, x3, x4 > 0

Product Mix Problem - Complete FormulationProduct Mix Problem - Complete Formulation

Daily profit = $5040

Boat # purchased

Speedhawk 28

Silverbird 0

Catman 0

Classy 28

Page 23: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

23

Marketing Application: Media SelectionMarketing Application: Media Selection

Advertising budget for first month = $30000 At least 10 TV commercials must be used At least 50000 customers must be reached Spend no more than $18000 on TV adverts Determine optimal media selection plan

Advertising Media # of potential customers reached

Cost ($) per advertisement

Max times available per month

Exposure Quality Units

Day TV 1000 1500 15 65

Evening TV 2000 3000 10 90

Daily newspaper 1500 400 25 40

Sunday newspaper 2500 1000 4 60

Radio 300 100 30 20

Page 24: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

24

Media Selection FormulationMedia Selection Formulation Step 1: Define decision variables

DTV = # of day time TV adverts ETV = # of evening TV adverts DN = # of daily newspaper adverts SN = # of Sunday newspaper adverts R = # of radio adverts

Step 2: Write the objective in terms of the decision variables Maximize 65DTV+90ETV+40DN+60SN+20R

Step 3: Write the constraints in terms of the decision variables

DTV <= 15

ETV <= 10

DN <= 25

SN <= 4

R <= 30

1500DTV + 3000ETV + 400DN + 1000SN + 100R <= 30000

DTV + ETV >= 10

1500DTV + 3000ETV <= 18000

1000DTV + 2000ETV + 1500DN + 2500SN + 300R >= 50000

BudgetBudget

Customers Customers reachedreached

TV TV ConstraintConstraint

ss

Availability of Availability of MediaMedia

DTV, ETV, DN, SN, R >= 0DTV, ETV, DN, SN, R >= 0

Exposure = 2370 units

Variable Value

DTV 10

ETV 0

DN 25

SN 2

R 30

Page 25: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

25

Applications of LPApplications of LP

Product mix planning Distribution networks Truck routing Staff scheduling Financial portfolios Capacity planning Media selection: marketing

Page 26: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

26

Possible Outcomes of a LPPossible Outcomes of a LP

A LP is either Infeasible – there exists no solution which satisfies

all constraints and optimizes the objective function or, Unbounded – increase/decrease objective

function as much as you like without violating any constraint

or, Has an Optimal Solution Optimal values of decision variables Optimal objective function value

Page 27: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

27

Infeasible LP – An ExampleInfeasible LP – An Example minimize

4x11+7x12+7x13+x14+12x21+3x22+8x23+8x24+8x31+10x32+16x33+5x34

Subject to x11+x12+x13+x14=100 x21+x22+x23+x24=200 x31+x32+x33+x34=150

x11+x21+x31=80 x12+x22+x32=90 x13+x23+x33=120 x14+x24+x34=170

xij>=0, i=1,2,3; j=1,2,3,4

Total demand exceeds total supply

Page 28: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

28

Unbounded LP – An ExampleUnbounded LP – An Example

maximize 2x1 + x2

subject to

-x1 + x2 1

x1 - 2x2 2

x1 , x2 0

x2 can be increased indefinitely without violating any constraint

=> Objective function value can be increased indefinitely

Page 29: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

29

Multiple Optima – An ExampleMultiple Optima – An Example

maximize x1 + 0.5 x2

subject to

2x1 + x2 4

x1 + 2x2 3

x1 , x2 0• x1= 2, x2= 0, objective function = 2

• x1= 5/3, x2= 2/3, objective function = 2

Page 30: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

30

Operations SchedulingChapter 16

Page 31: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

31

Establishing the timing of the use of equipment, facilities and human activities in an organization

Effective scheduling can yield

Cost savings

Increases in productivity

Scheduling Scheduling

Page 32: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

32

High-Volume SystemsHigh-Volume Systems

Flow system: High-volume system with Standardized equipment and activities

Flow-shop scheduling: Scheduling for high-volume flow system

Work Center #1 Work Center #2 Output

Page 33: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

33

High-Volume Success FactorsHigh-Volume Success Factors

Process and product design

Preventive maintenance

Rapid repair when breakdown occurs

Optimal product mixes

Minimization of quality problems

Reliability and timing of supplies

Page 34: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

34

Scheduling Low-Volume SystemsScheduling Low-Volume Systems

Loading - assignment of jobs to process centers

Sequencing - determining the order in which jobs will be processed

Job-shop scheduling Scheduling for low-volume

systems with many variations in requirements

Page 35: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

35

Gantt Load ChartGantt Load Chart

Gantt chart - used as a visual aid for loading and scheduling

WorkCenter

Mon. Tues. Wed. Thurs. Fri.

1 Job 3 Job 42 Job 3 Job 73 Job 1 Job 6 Job 74 Job 10

Figure 16.2

Page 36: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

36

More Gantt ChartsMore Gantt Charts

Page 37: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

37

Assignment ProblemAssignment Problem Objective: Assign n jobs/workers to n machines

such that the total cost of assignment is minimized Special case of transportation problem

When # of rows = # of columns in the transportation tableau

All supply and demands =1 Plenty of practical applications

Job shops Hospitals Airlines, etc.

Page 38: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

38

Cost Table for Assignment ProblemCost Table for Assignment Problem

1 2 3 4

1 $1 $4 $6 $3

2 $9 $7 $10 $9

3 $4 $5 $11 $7

4 $8 $7 $8 $5

Pilot (i)

Aircraft (j)

All assignment costs in thousands of $

Page 39: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

39

Management Scientist SolutionManagement Scientist Solution

Pilot Assigned to aircraft #

Cost (`000 $)

1 1 1

2 3 10

3 2 5

4 4 5

Page 40: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

40

Formulation of Assignment ProblemFormulation of Assignment Problem minimize x11+4x12+6x13+3x14 + 9x21+7x22+10x23+9x24 +

4x31+5x32+11x33+7x34 + 8x41+7x42+8x43+5x44

subject to x11+x12+x13+x14=1 x21+x22+x23+x24=1 x31+x32+x33+x34=1 x41+x42+x43+x44=1

x11+x21+x31+x41=1 x12+x22+x32+x42=1 x13+x23+x33+x43=1 x14+x24+x34+x44=1

xij = 1, if pilot i is assigned to aircraft j, i=1,2,3,4; j=1,2,3,4 0 otherwise

Pilot Assigned to aircraft #

Cost (`000 $)

1 1 1

2 3 10

3 2 5

4 4 5Optimal Solution:

x11=1; x23=1; x32=1; x44=1; rest=0

Cost of assignment = 1+10+5+5=$21 (`000)

Page 41: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

41

SequencingSequencing Sequencing: Determine the order in which jobs at a

work center will be processed. Workstation: An area where one person works,

usually with special equipment, on a specialized job. Priority rules: Simple heuristics used to select the

order in which jobs will be processed.

FCFS - first come, first served

SPT - shortest processing time

Minimizes mean flow time

EDD - earliest due date

In-class example

Page 42: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

42

Performance MeasuresPerformance Measures Job flow time

Length of time a job is at a particular workstation

Includes actual processing time, waiting time, transportation time etc.

Lateness = flow time – due date

Tardiness = max {lateness, 0}

Makespan

Total time needed to complete a group of jobs

Length of time between start of first job and completion of last job

Page 43: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

43

Scheduling DifficultiesScheduling Difficulties

Variability in Setup times Processing times Interruptions Changes in the set of jobs

No method for identifying optimal schedule Scheduling is not an exact science Ongoing task for a manager

Page 44: 1 Lecture 5 Linear Programming (6S) and Transportation Problem (8S)

44

Minimizing Scheduling DifficultiesMinimizing Scheduling Difficulties

Set realistic due dates

Focus on bottleneck operations

Consider lot splitting of large jobs