Explorations in Artificial Intelligence - PowerPoint PPT Presentation

1 / 85
About This Presentation
Title:

Explorations in Artificial Intelligence

Description:

Title: Structure, Duality, and Randomization - Common Themes in AI and OR Author: Carla P. Gomes Last modified by: gomes Created Date: 6/5/1997 6:05:21 PM – PowerPoint PPT presentation

Number of Views:95
Avg rating:3.0/5.0
Slides: 86
Provided by: CarlaP9
Category:

less

Transcript and Presenter's Notes

Title: Explorations in Artificial Intelligence


1
Explorations in Artificial Intelligence
  • Prof. Carla P. Gomes
  • gomes_at_cs.cornell.edu
  • Module 5
  • Intro to Linear Programming

2
Constraint Programming
  • 1- Problem Formulation
  • A problem is a finite set of constraints
    involving a finite set of variables.
  • Constraint Satisfaction Problems (CSP) ?
    feasibility problem only and --- SAT is a
    particular case of CSP
  • Constraint Optimization Problems (COP) if in
    addition the solution is required to maximize an
    objective function
  • 2- Problem Solution
  • Domain specific methods
  • General Solution Methods

3
Mathematical Program
  • Optimization problem in which the objective and
    constraints are given as mathematical functions
    and functional relationships.
  • Optimize Z f(x1, x2, , xn)
  • Subject to
  • g1(x1, x2, , xn) , , b1

g2(x1, x2, , xn) , , b2

gm(x1, x2, , xn) , , bm
Linear Programming problem ? special type of a
mathematical programming problem (all functions
are linear)
4
Linear Programming (LP)
  • One of the most important scientific advances of
    the 20th century
  • A variety of applications
  •    Financial planning, Marketing, E-business,
    Telecommunications, Manufacturing, Transportation
    Planning, System Design, Health Care
  • Remarkably efficient solution procedures to solve
    LP models simplex method and interior point
    methods ---
  • Very fast LP solvers (CPLEX from 1981-2001
    2,000,000X faster!)

5
Linear Programming
  • Significance.
  • Powerful tool for optimal allocation of scarce
    resources, among a number of competing
    activities.
  • Powerful model generalizes many classic problems
  • shortest path, max flow, multicommodity flow,
    MST, matching, 2-person zero sum games
  • Ranked among most important scientific advances
    of 20th century.
  • accounts for a major proportion of all scientific
    computation
  • Helps find "good" solutions to NP-hard
    optimization problems.
  • optimal solutions (branch-and-cut)
  • provably good solutions (randomized rounding)

6
Linear Programming (LP)
  • Linear all the functions are linear (f and g
    functions are linear. Ex f (x1, x2, , xn) c1x1
    c2 x2 cn xn
  • Programming does not refer to computer
    programming but rather planning - planning of
    activities to obtain an optimal result i.e., it
    reaches the specified goal best (according to the
    mathematical model) among all feasible
    alternatives.

7
Prototype Example Wyndor Glass (Hillier and
Liebermnan)
8
Wyndor Glass Co. Product Mix Problem
  • Wyndor Co. has developed the following new
    products
  • An 8-foot glass door with aluminum framing.
  • A 4-foot by 6-foot double-hung, wood-framed
    window.
  • The company has three plants
  • Plant 1 produces aluminum frames and hardware.
  • Plant 2 produces wood frames.
  • Plant 3 produces glass and assembles the windows
    and doors.

9
(No Transcript)
10
Wyndor Glass Co. Product Mix Problem
  • Questions
  • Should they go ahead with launching these two new
    products?
  • If so, what should be the product mix?

How to formulate this problem as an Linear
Programming problem?
11
Steps in setting up a LP
  • Determine and label the decision variables.
  • Determine the objective and use the decision
    variables to write an expression for the
    objective function.
  • Determine the constraints - feasible region.
  • Determine the explicit constraints and write a
    functional expression for each of them.
  • Determine the implicit constraints (e.g.,
    nonnegativity constraints).

12
Algebraic Model for Wyndor Glass Co.
Let D the number of doors to produce W the
number of windows to produce Maximize P 3 D
5 W subject to D 4 2W 12 3D 2W
 18 and D  0, W  0.
13
Finding the Optimal Solution
Our objective function is maximize 3D5W
The vector representing the gradient of the
objective function is
The line through the origin that contains this
vector is
Maximize P 3 D 5 W subject to D 4 2W
12 3D 2W  18 and D  0, W  0.
isoprofit line
14
LP Geometry
  • Geometry.
  • Forms an n-dimensionalpolyhedron.
  • Convex if y and z are feasible solutions, then
    so is ½y ½z.
  • Extreme point feasible solution x that can't be
    written as ½y ½z for any two distinct feasible
    solutions y and z.

15
LP Geometry
  • Extreme Point Theorem. If there exists an
    optimal solution to standard form LP (P), then
    there exists one that is an extreme point.
  • Only need to consider finitely many possible
    solutions.
  • Greed. Local optima areglobal optima.

16
Graphical Method
  • Draw the constraint boundary line for each
    constraint. Use the origin (or any point not on
    the line) to determine which side of the line is
    permitted by the constraint.
  • Find the feasible region by determining where all
    constraints are satisfied simultaneously.
  • Determine the slope of one objective function
    line (perpendicular to its gradient vector). All
    other objective function lines will have the same
    slope.
  • Move a straight edge with this slope through the
    feasible region in the direction of improving
    values of the objective function (direction of
    the gradient). Stop at the last instant that the
    straight edge still passes through a point in the
    feasible region. This line given by the straight
    edge is the optimal objective function line.
  • A feasible point on the optimal objective
    function line is an optimal solution.

17
Terminology and Notation
  • Resources m (plants)
  • Activities n (2 products)
  • Wyndor Glass problem? optimal product mix ---
    allocation of resources to activities i.e.,
    choose the levels of the activities that achieve
    best overall measure of performance
  •  

18
Terminology and notation (cont.)
  • Z value of the overall measure of performance
    value of the objective function,
  • xj level of activity j (for j 1, 2, , n) ?
    decision variables
  • cj increase in Z for each unit increase in the
    level of activity j coefficient of objective
    function associated with activity j
  • bi amount of resource i that is available (for
    i1,2,, m). Right-hand-side of constraint
    associated with resource i.
  • aij amount of resource i consumed by each unit
    of activity j.  Technological coefficient.
  • (The values of cj, bi, and aij are the input
    constants for the model ? the parameters of the
    model. )

19
Standard form of the LP model
  •  
  • xi gt 0 , (i 1,2,,n)
  • Other forms
  • Minimize Z (instead of maximizing Z)
  •    Some functional constraints have signs gt
    (rather than lt)
  •    Some functional constraints are equalities
  •    Some variables have unrestricted sign, i.e.,
    they are not subject to the non-negativity
    constraints

20
Terminology of solutions in LP model
  • Solution not necessarily the final answer to
    the problem!!!  
  • Feasible solution solution that satisfies all
    the constraints
  • Infeasible solution solution for which at least
    one of the constraints is violated
  • Feasible region set of all points that
    satisfies all the constraints (possible to have a
    problem without any feasible solutions)
  • Binding constraint the left-hand side and the
    right-hand side of the constraint are equal,
    I.e., constraint is satisfied in equality.
    Otherwise the constraint is nonbinding.
  • Optimal solution feasible solution that has the
    best value of the objective function.
  • Largest value ? maximization problems
  • Smallest value ? minimization problems
  • Multiple optimal solutions
  • No optimal solutions
  • Unbounded Z

21
Corner Point Solutions
  • Corner-point feasible solution special
    solution that plays a key role when the simplex
    method searches for an optimal solution.
    Relationship between optimal solutions and CPF
    solutions
  • Any LP with feasible solutions and bounded
    feasible region ?
  •  
  • (1)  the problem must possess CPF solutions and
    at least one optimal solution
  • (2)  the best CPF solution must be an optimal
    solution
  • If the problem has exactly one optimal solution
    it must be a CFP solution
  • If the problem has multiple optimal solutions, at
    least two must be CPF solutions

22
Wyndor Glass
Let D the number of doors to produce W the
number of windows to produce Maximize P 3 D
5 W
1
Z30
2
Z36
Edge of Feasible region
3
Z27
Z0
0
CPF
23
No Feasible Solutions Why?
Maximize P 3 D 5 W subject to D 4 2W
12 3D 2W  18 3 D 5 W? 50 and D  0, W  0.
Previous Feasible Region
24
Multiple Optimal Solutions. Why?
Maximize P 3 D 2 W subject to D 4 2W
12 3D 2W  18 and D  0, W  0.
Every point on this line is An optimal solution
with P18
25
Unbounded Objective Function. Why?
(4, ) P
Maximize P 3 D 2 W subject to D
4 and D  0, W  0.
(4,8) P28
(4,4) P20
(4,2) P16
26
Sensitivity Analysis




















Our objective function is maximize 3x1c2x2



Production rate
W
for windows
8
P 3600 300D 500W
Optimal solution c2gt2
How does the optimal solution change as c2
changes?
x(2, 6)
P 3000 300D 500W
6
Feasible
Multiple Optimal solution c22 P18 x (2,6)
x(4,3) And any convex combination
4
region
P 1500 300D 500W
Optimal solution 0 ltc2lt2 x(4,3)
2
Multiple Optimal solution c20 P12 x(4,3) and
(4,0) and any Convex combination
2
0
4
6
8
D
10
Production rate for doors
Optimal solution c2lt0 x(4,0)
27
LP Assumptions
 
 
PProportionality The contribution of each
activity to the value of the objective function Z
is proportional to the level of the activity xj
as represented by the cjxj term The
contribution of each activity to the left-hand
side of each functional constraint is
proportional to the level of the activity xj as
represented by the term aij. This assumption
implies that all the x terms of the linear
equations cannot have exponents greater than
1. Note if there is a term that is a product of
different variables, even though the
proportionality assumption is satisfied, the
additivity assumption is violated.  
     
 
28
LP Assumptions
  • Additivity
  • The contribution of all variables to the
    objective function and to the left-hand side of
    the functional constraints has to be additive,
    i.e., it has to be the sum of the individual
    contributions of the respective activities
    therefore cross-products of variables are ruled
    out.

29
LP Assumptions
  • Certainty
  • The parameters of the model, (coefficients of
    the objective function and of the functional
    constraints, and the right-hand sides of the
    functional constraints) are assumed to be known
    constants.
  • Rarely the case sometimes we use
    approximations ? important to perform sensitivity
    analysis to identify sensitive parameters (the
    parameters that cannot be changed without
    changing the value of the objective function).
  • What to do when certainty assumption violated
  • treat parameters as random variables

30
LP Assumptions
  • Divisibility
  •  
  • Decision variables in an LP model are allowed to
    have any values, including noninteger values,
    that satisfy the functional and nonnegativity
    constraints. i.e., activities can be run at
    fractional levels.
  • What to do when divisibility assumption violated
  • realm of integer programming!!!

31
Examples of Different Categories of LP problems
  • Resource-Allocation Problems
  • Cost-benefit-trade-off problems
  • Distribution-Network Problems

32
Algebraic Model for Wyndor Glass Co.
Let D the number of doors to produce W the
number of windows to produce Maximize P 3 D
5 W subject to D 4 2W 12 3D 2W
 18 and D  0, W  0.
33
Examples of Different Categories of LP problems
  • Resource-Allocation Problems

34
Resource Allocation Problem Wyndor Glass
  • Resources m (plants)
  • Activities n (2 products)
  • Wyndor Glass problem? optimal product mix ---
    allocation of resources to activities i.e.,
    choose the levels of the activities that achieve
    best overall measure of performance with
    available resources
  •  

35
Finding the Optimal Solution
Our objective function is maximize 3D5W
The vector representing the gradient of the
objective function is
The line through the origin that contains this
vector is
Maximize P 3 D 5 W subject to D 4 2W
12 3D 2W  18 and D  0, W  0.
isoprofit line
36
Cost-benefit-trade-off problems
37
Cost-benefit-trade-off problems
  • The mix of levels of various activities is
  • chosen to achieve minimum acceptable levels
  • for various benefits at a minimum cost.

38
The Profit Gambit Co. (Hillier Hillier)
  • Management has decided to undertake a major
    advertising campaign that will focus on the
    following three key products
  • A spray prewash stain remover.
  • A liquid laundry detergent.
  • A powder laundry detergent.
  • The campaign will use both television and print
    media
  • The general goal is to increase sales of these
    products.
  • Management has set the following goals for the
    campaign
  • Sales of the stain remover should increase by at
    least 3.
  • Sales of the liquid detergent should increase by
    at least 18.
  • Sales of the powder detergent should increase by
    at least 4.
  • Question how much should they advertise in each
    medium to meet the sales goals at a minimum total
    cost?

39
  • Activity 1 advertise on television
  • Activity 2 advertise in the print media
  • Benefit 1 increases sales of stain remover
  • Benefit 2 increases sales of liquid detergent
  • Benefit 3 increases sales of powder detergent

40
Profit Gambit Co. Data
41
Algebraic Model for Profit Gambit
Let TV the number of units of advertising on
television PM the number of units of
advertising in the print media Minimize Cost
TV 2PM (in millions of dollars) subject to PM
3 3TV 2PM  18 TV 4PM  4 and TV  0,
PM  0.
42
Algebraic Model for Profit Gambit
Let TV the number of units of advertising on
television PM the number of units of
advertising in the print media Minimize Cost
TV 2PM (in millions of dollars) subject
to Stain remover increased sales PM
3 Liquid detergent increased sales 3TV 2PM
 18 Powder detergent increased sales TV 4PM
 4 and TV  0, PM  0.
43
Applying the Graphical Method
44
The Optimal Solution
45
Summary of the Graphical Method
  • Draw the constraint boundary line for each
    constraint. Use the origin (or any point not on
    the line) to determine which side of the line is
    permitted by the constraint.
  • Find the feasible region by determining where all
    constraints are satisfied simultaneously.
  • Determine the slope of one objective function
    line. All other objective function lines will
    have the same slope.
  • Move a straight edge with this slope through the
    feasible region in the direction of improving
    values of the objective function. Stop at the
    last instant that the straight edge still passes
    through a point in the feasible region. This line
    given by the straight edge is the optimal
    objective function line.
  • A feasible point on the optimal objective
    function line is an optimal solution.

46
Union Airways Personnel Scheduling
  • Union Airways is adding more flights to and from
    its hub airport and so needs to hire additional
    customer service agents.
  • The five authorized eight-hour shifts are
  • Shift 1 600 AM to 200 PM
  • Shift 2 800 AM to 400 PM
  • Shift 3 Noon to 800 PM
  • Shift 4 400 PM to midnight
  • Shift 5 1000 PM to 600 AM
  • Question How many agents should be assigned to
    each shift, so that the cost is minimized?

47

Time Periods Covered by Shift Time Periods Covered by Shift Time Periods Covered by Shift Time Periods Covered by Shift Time Periods Covered by Shift
Time Period 1 2 3 4 5 MinimumNumber ofAgents Needed
6 AM to 8 AM v 48
8 AM to 10 AM v v 79
10 AM to noon v v 65
Noon to 2 PM v v v 87
2 PM to 4 PM v v 64
4 PM to 6 PM v v 73
6 PM to 8 PM v v 82
8 PM to 10 PM v 43
10 PM to midnight v v 52
Midnight to 6 AM v 15
Daily cost per agent 170 160 175 180 195
48
LP Formulation
Let Si Number working shift i (for i 1 to
5),Minimize Cost 170S1 160S2 175S3
180S4 195S5subject to S1 48 S1 S2
79 S1 S2 65 S1 S2 S3 87 S2 S3
64 S3 S4 73 S3 S4 82 S4 43 S4
S5 52 S5 15and Si 0 (for i 1 to 5)
49
LP Formulation
Let Si Number working shift i (for i 1 to
5),Minimize Cost 170S1 160S2 175S3
180S4 195S5subject to Total agents
6AM8AM S1 48 Total agents 8AM10AM S1 S2
79 Total agents 10AM12PM S1 S2 65 Total
agents 12PM2PM S1 S2 S3 87 Total agents
2PM4PM S2 S3 64 Total agents 4PM6PM S3
S4 73 Total agents 6PM8PM S3 S4
82 Total agents 8PM10PM S4 43 Total agents
10PM12AM S4 S5 52 Total agents
12AM6AM S5 15and Si 0 (for i 1 to 5)
50
Work-scheduling problem
51
A Work-Scheduling Problem
  • A post office requires different numbers of
    full-time
  • employees on different days of the week. Union
    rules
  • state that each full-time employee must work five
  • consecutive days and then receive two days off.
    For
  • example, an employee who works on Monday to
  • Friday must be off on Saturday and Sunday. The
  • post office wants to meet its daily requirements
    using only
  • full-time employees, and minimizing number of
    employees.

52
Overview
  • Work-scheduling problem
  • The model
  • Practical enhancements or modifications
  • Two non-linear objectives that can be made linear
  • A non-linear constraint that can be made linear

These slides are adapted from James Orlins
53
Scheduling Postal Workers
  • Each postal worker works for 5 consecutive days,
    followed by 2 days off, repeated weekly.

Minimize the number of postal workers (for the
time being, we will permit fractional workers on
each day.)
54
Whats wrong with this formulation?
  • Decision variables
  • Let x1 be the number of workers who work on
    Monday
  • Let x2 be the number of workers who work on
    Tuesday
  • Let x3, x4, , x7 be defined similarly.

55
Answer
  • Objective function is not number of full-time
    post office employees ? each employee is counted
    five times
  • The variables x1, x2, x3, etc are interrelated
    but that is not captured in our formulation (for
    example some people who are working on Monday are
    also working on Tuesday)

56
LP Formulation
  • Select the decision variables
  • Let x1 be the number of workers who start working
    on Monday, and work till Friday
  • Let x2 be the number of workers who start on
    Tuesday
  • Let x3, x4, , x7 be defined similarly.
  • Note 1 number of full-time employees is
  • x1 x2 x3 x4 x5 x6 x7
  • Note 2 Who is working on Monday? Everybody
    except those who start working on Tuesday and
    Wednesday (on Monday they have a day off)
  • (similarly reasoning can be applied for the
    other days)

57
The linear program
Minimize
z x1 x2 x3 x4 x5 x6 x7
x1 x4 x5 x6 x7 ? 17
subject to
x1 x2 x5 x6 x7 ? 13
x1 x2 x3 x6 x7 ? 15
x1 x2 x3 x4 x7 ? 19
x1 x2 x3 x4 x5 ? 14
x2 x3 x4 x5 x6 ? 16
x3 x4 x5 x6 x7 ? 11
xj ? 0 for j 1 to 7
58
Some Enhancements of the Model
  • Suppose that there is a pay differential. The
    cost of workers who start work on day j is cj
    per worker and we want to minimize the cost.

Minimize
z c1 x1 c2 x2 c3 x3 c7 x7
59
Some Enhancements of the Model
  • Suppose that one can hire part time workers (one
    day at a time), and that the cost of a part time
    worker on day j is PTj.
  • Let yj number of part time workers on day j

60
What is the Revised Linear Program?
Minimize
z x1 x2 x3 x4 x5 x6 x7
61
Minimize
z x1 x2 x3 x4 x5 x6 x7
PT1 y1 PT2 y2 PT7 y7
x1 x4 x5 x6 x7 y1 ?
17
subject to
x1 x2 x5 x6 x7 y2 ?
13
x1 x2 x3 x6 x7 y3 ?
15
x1 x2 x3 x4 x7 y4 ?
19
x1 x2 x3 x4 x5 y5 ?
14
x2 x3 x4 x5 x6 y6 ?
16
x3 x4 x5 x6 x7 y7 ?
11
xj ? 0 , yj ? 0 for j 1 to 7
62
Another Enhancement
  • Suppose that the number of workers required on
    day j is dj. Let yj be the number of workers on
    day j.
  • What is the minimum cost schedule, where the
    cost of having too many workers on day j is
    -fj(yj dj), which is a non-linear function?
  • NOTE this will lead to a non-linear program, not
    a linear program.
  • We will let sj yj dj be the excess number of
    workers on day j.

63
What is the Revised Linear Program?
z x1 x2 x3 x4 x5 x6 x7
Minimize
64
Minimize
z f1(s1) f2(s2) f3(s3) f4(s4) f5(s5)
f6(s6) f7(s7)
x1 x4 x5 x6 x7 - s1 17
subject to
x1 x2 x5 x6 x7 - s2
13
x1 x2 x3 x6 x7 - s3
15
x1 x2 x3 x4 x7 - s4
19
x1 x2 x3 x4 x5 - s5 14
x2 x3 x4 x5 x6 - s6 16
x3 x4 x5 x6 x7 - s7
11
xj ? 0 , sj ? 0 for j 1 to 7
65
A non-linear objective that often can be made
linear.
Suppose that one wants to minimize the maximum of
the slacks, that is minimize z max (s1, s2,
, s7). This is a non-linear objective. But we
can transform it, so the problem becomes an LP?
66
minimize z max (s1, s2, , s7).
x1 x4 x5 x6 x7 - s1 17
subject to
x1 x2 x5 x6 x7 - s2
13
x1 x2 x3 x6 x7 - s3
15
x1 x2 x3 x4 x7 - s4
19
x1 x2 x3 x4 x5 - s5 14
x2 x3 x4 x5 x6 - s6 16
x3 x4 x5 x6 x7 - s7
11
xj ? 0 , sj ? 0 for j 1 to 7
67
Minimize z
z ? sj for j 1 to 7.
x1 x4 x5 x6 x7 - s1 17
subject to
x1 x2 x5 x6 x7 - s2
13
x1 x2 x3 x6 x7 - s3
15
x1 x2 x3 x4 x7 - s4
19
x1 x2 x3 x4 x5 - s5 14
x2 x3 x4 x5 x6 - s6 16
x3 x4 x5 x6 x7 - s7
11
xj ? 0 , sj ? 0 for j 1 to 7
The new constraint ensures that z ? max (s1, ,
s7)
The objective ensures that z sj for some j.
68
Another non-linear objective that often can be
made linear.
Suppose that the goal is to have dj workers on
day j. Let yj be the number of workers on day
j. Suppose that the objective is minimize Si
yj dj This is a non-linear objective. But
we can transform it, so the problem becomes an LP.
69
Minimize Sj zj
zj ? dj - yj for j 1 to 7.
zj ? yj - dj for j 1 to 7.
x1 x4 x5 x6 x7 y1
subject to
x1 x2 x5 x6 x7 y2
x1 x2 x3 x6 x7 y3
x1 x2 x3 x4 x7 y4
x1 x2 x3 x4 x5 - y5
x2 x3 x4 x5 x6 y6
x3 x4 x5 x6 x7 y7
xj ? 0 , yj ? 0 for j 1 to 7
The new constraints ensure that zj ? yj dj
for each j.
The objective ensures that zj yj dj for
each j.
70
A ratio constraint
Suppose that we need to ensure that at least 30
of the workers have Sunday off.
How do we model this?
(x1 x2 )/(x1 x2 x3 x4 x5 x6 x7) ?
.3
(x1 x2 ) ? .3 x1 .3 x2 .3 x3 .3 x4 .3
x5 .3 x6 .3 x7
-.7 x1 - .7 x2 .3 x3 .3 x4 .3 x5 .3 x6
.3 x7 lt 0
71
Other enhancements
  • Require that each shift has an integral number of
    workers
  • integer program
  • Consider longer term scheduling
  • model 6 weeks at a time
  • Consider shorter term scheduling
  • model lunch breaks
  • Model individual workers
  • permit worker preferences

72
Distribution Network Problems
73
The Big M Distribution-Network Problem
  • The Big M Company produces a variety of heavy
    duty machinery at two factories. One of its
    products is a large machine, lathes (model L).
  • Orders have been received from three customers
    for the machine, lathes (model L).

74
Some Data
Shipping Cost for Each Lathe Shipping Cost for Each Lathe Shipping Cost for Each Lathe
To Customer 1 Customer 2 Customer 3
From Output
Factory 1 700 900 800 12 model L
Factory 2 800 900 700 15 model L
Order Size 10 lathes Model L 8 lathes Model L 9 lathes Model l
75
The Distribution Network
10 Model L needed
12 Model L produced
8 Model L needed
15 Model L produced
9 Model L needed
Question How many machines (model L) should be
shipped from each factory to each customer so
that sipping costs are minimized?
76
  • Activities shipping lanes (not the level of
    production which has already been defined)
  • Level of each activity number of machines of
    model L shipped through the corresponding
    shipping lane.
  • Best mix of shipping amounts
  • Resources ? requirements from factories and
    customers. Example
  • Requirement 1 Factory 1 must ship 12 machines
    model L
  • Requirement 2 Factory 2 must ship 15 machines
    model L
  • Requirement 3 Customer 1 must receive 10
    machines model L Requirement 4 Customer 2 must
    receive 8 machines model L Requirement 5
    Customer 3 must receive 9 machines model L

77
Algebraic Formulation
Let Sij Number of lathes to ship from i to j (i
F1, F2 j C1, C2, C3).Minimize Cost
700SF1-C1 900SF1-C2 800SF1-C3
800SF2-C1 900SF2-C2 700SF2-C3 subject
to SF1-C1 SF1-C2 SF1-C3 gt 12 SF2-C1
SF2-C2 SF2-C3 gt 15 SF1-C1 SF2-C1 lt
10 SF1-C2 SF2-C2lt lt 8 SF1-C3 SF2-C3 lt
9and Sij 0 (i F1, F2 j C1, C2, C3).
78
Algebraic Formulation
Let Sij Number of lathes to ship from i to j (i
F1, F2 j C1, C2, C3).Minimize Cost
700SF1-C1 900SF1-C2 800SF1-C3
800SF2-C1 900SF2-C2 700SF2-C3 subject
to Factory 1 SF1-C1 SF1-C2 SF1-C3
12 Factory 2 SF2-C1 SF2-C2 SF2-C3
15 Customer 1 SF1-C1 SF2-C1 10 Customer
2 SF1-C2 SF2-C2 8 Customer 3 SF1-C3
SF2-C3 9and Sij 0 (i F1, F2 j C1, C2,
C3).
79
Summary of Main Categories of LP problems
  • Resource-Allocation Problems
  • Cost-benefit-trade-off problems
  • Distribution-Network Problems

80
Types of Functional Constraints
Type Form Typical Interpretation Main Usage
Resource constraint LHS RHS For some resource, Amount used Amount available Resource-allocation problems and mixed problems
Benefit constraint LHS RHS For some benefit, Level achieved Minimum Acceptable Cost-benefit-trade-off problems and mixed problems
Fixed-requirement constraint LHS RHS For some quantity, Amount provided Required amount Distribution-network problems and mixed problems
LHS Left-hand side RHS Right-hand side (a constant). LHS Left-hand side RHS Right-hand side (a constant). LHS Left-hand side RHS Right-hand side (a constant). LHS Left-hand side RHS Right-hand side (a constant).
81
Mixed LP problems
82
Save-It Company Waste Reclamation
  • The Save-It Company operates a reclamation center
    that collects four types of solid waste materials
    and then treats them so that they can be
    amalgamated into a salable product.
  • Three different grades of product can be made A,
    B, and C (depending on the mix of materials
    used).
  • Question What quantity of each of the three
    grades of product should be produced from what
    quantity of each of the four materials?

83
Product Data for the Save-It Company
Grade Specification Amalgamation Cost per Pound Selling Price per Pound
A Material 1 Not more than 30 of totalMaterial 2 Not less than 40 of totalMaterial 3 Not more than 50 of totalMaterial 4 Exactly 20 of total 3.00 8.50
B Material 1 Not more than 50 of totalMaterial 2 Not less than 10 of the totalMaterial 4 Exactly 10 of the total 2.50 7.00

C Material 1 Not more than 70 of the total 2.00 5.50
84
Material Data for the Save-It Company
Material Pounds/WeekAvailable Treatment Costper Pound Additional Restrictions
1 3,000 3.00 1. For each material, at least half of the pounds/week available should be collected and treated.2. 30,000 per week should be used to treat these materials.
2 2,000 6.00 1. For each material, at least half of the pounds/week available should be collected and treated.2. 30,000 per week should be used to treat these materials.
3 4,000 4.00 1. For each material, at least half of the pounds/week available should be collected and treated.2. 30,000 per week should be used to treat these materials.
4 1,000 5.00 1. For each material, at least half of the pounds/week available should be collected and treated.2. 30,000 per week should be used to treat these materials.
85
Algebraic Formulation
Let xij Pounds of material j allocated to
product i per week (i A, B, C j 1, 2, 3,
4). Maximize Profit 5.5(xA1 xA2 xA3 xA4)
4.5(xB1 xB2 xB3 xB4) 3.5(xC1 xC2
xC3 xC4)subject to xA1 0.3 (xA1 xA2 xA3
xA4) xA2 0.4 (xA1 xA2 xA3 xA4) xA3
0.5 (xA1 xA2 xA3 xA4) xA4 0.2 (xA1
xA2 xA3 xA4) xB1 0.5 (xB1 xB2 xB3
xB4) xB2 0.1 (xB1 xB2 xB3 xB4) xB4
0.1 (xB1 xB2 xB3 xB4) xC1 0.7 (xC1
xC2 xC3 xC4) xA1 xB1 xC1 3,000 xA2
xB2 xC2 2,000 xA3 xB3 xC3
 4,000 xA4 xB4 xC4 1,000 xA1 xB1
xC1 1,500 xA2 xB2 xC2 1,000 xA3 xB3
xC3 2,000 xA4 xB4 xC4 500 3(xA1
xB1 xC1) 6(xA2 xB2 xC2) 4(xA3 xB3
xC3) 5(xA4 xB4 xC4) 30,000and xij 0 (i
A, B, C j 1, 2, 3, 4).
86
Algebraic Formulation
Let xij Pounds of material j allocated to
product i per week (i A, B, C j 1, 2, 3,
4). Maximize Profit 5.5(xA1 xA2 xA3 xA4)
4.5(xB1 xB2 xB3 xB4) 3.5(xC1 xC2
xC3 xC4)subject to Mixture Specifications xA1
0.3 (xA1 xA2 xA3 xA4) xA2 0.4 (xA1
xA2 xA3 xA4) xA3 0.5 (xA1 xA2 xA3
xA4) xA4 0.2 (xA1 xA2 xA3 xA4) xB1
0.5 (xB1 xB2 xB3 xB4) xB2 0.1 (xB1
xB2 xB3 xB4) xB4 0.1 (xB1 xB2 xB3
xB4) xC1 0.7 (xC1 xC2 xC3 xC4)
Availability of Materials xA1 xB1 xC1
3,000 xA2 xB2 xC2 2,000 xA3 xB3 xC3
 4,000 xA4 xB4 xC4 1,000 Restrictions
on amount treated xA1 xB1 xC1 1,500 xA2
xB2 xC2 1,000 xA3 xB3 xC3
2,000 xA4 xB4 xC4 500 Restriction on
treatment cost 3(xA1 xB1 xC1) 6(xA2 xB2
xC2) 4(xA3 xB3 xC3) 5(xA4 xB4
xC4) 30,000and xij 0 (i A, B, C j 1,
2, 3, 4).
87
Spreadsheet Formulation
Write a Comment
User Comments (0)
About PowerShow.com