Upload
shannon-glenn
View
229
Download
0
Tags:
Embed Size (px)
Citation preview
1
Optimización Combinatoria: Una Introducción
Dr. Juan Frausto Solís
Tecnológico de Monterrey
Campus Cuernavaca
2
CONTENTS
Course Data Subjects The rules of the game Introduction to LP:
Linear Programming to Optimization Theory
Modeling Problems
Some Complexity Remarks
3
Course´s Data
Dr. Juan Frausto Solís [email protected] [email protected] http://campus.cva.itesm.mx/jfrausto/ Address:
• Reforma 182-A Col Lomas de Cuernavaca
• Temixco Morelos, 62589 Mexico
4
Course´s Data
Dairigido a:• Estudiantes de doctorado• Estudiantes de Maestrìa con
posibilidad de hacer investigaciòn independiente
Propósito del curso:• Una introducción a los
métodos de Optimización Combinatoria. Habilidades para investigación original en el área.
5
Temas
1. Introducción 2. Linear Programming (LP). Método simplex General 3. Variantes del Método Simplex. RSM; Dual 4. Degeneración 5. Interior-Point Methods (IPM) 6. Evolutive Programming. Simplex Genetic, Simplex
Annealing 7. Simplex Cosine 8. Optimización Combinatoria en Algoritmos de Redes:
SVM; NN 9. Problemas duros Clásicos: SAT, Graph Coloring,.. 10. Problemas duros no clásicos: GRASPING, Futbol
Robótico, Inversión Bursatil,..
6
Bibliography
G.B. Dantzig, Linear Programming, Springer David G: Luemberger, Programación Lineal y No
Lineal, Addison Wesley Iberoamerica Jorge Nocedal, Operations Research, Springer A. D. Belegundu, Optimization Concepts and
Applications in Engineering, Prentice Hall Hamdy Taha, Operations Research, An
Introduction. Prentice Hall Autores: Golberg, Gary Johnson, Papadimitrou,..
7
Rules of the GameConcept
Work Hard
Work Hard
Work Hard
Work Hard
8
Optimización Combinatoria
9
Many Extensions collectively knownAs Mathematical Programming: Non LP,Int Prog, Stocastic Prog, Comb Opt,Network Flow Maximization
1947: G.W. Dantzig propose LP to setgeneral objectives and arrive at a detailedschedule to meet these goals.
10
OPTIMIZATION AREAOPTIMIZATION AREA
optimize z = f(x)Subject to x
Constraint
Unconstraint
LinearNo Linear
ContinuosInteger
One variableMulti-variable
MultiobjectiveOne-objective
Tipo deProblemaType ofProblem
x
xz
z y
11
What Mathematical Programming is?
Math Prog = Optimization Theory
12
Math Prog Vs LP
Math Prog: Branch of Math dealing withtechniques for Maximizing or Minimizing anObjective function, subject to linear, no linear,and integer constraints.
LP: Spetial case of MP concerned withMaximizing or Minimizing a linear Objectivefunction in many variables and subject toLinear equality and inequality constraints
13
Why the Programming word is into LP?
For many applications, the solutionCan be interpreted as a program,Namely, a statement of the timeAnd quantity of actions toPerformed by the system so that itMay move from its given statusTowards some defined objective
14
Size of LP Problems
Small Problems: constraints 1000
Medium Problems: 1000 constraints 2000
Large Problems: 2000 constraints 10000
Very Large Problems: constraints 10,000
15
Some Simple Examples
16
A product Mix Problem
17
The case of DES-K, a founiture company
DES-k manufactures four models of desks. Each one is first constructed in the carpentry shop and is next sent to the finishing Shop, where it is varnished, waxed, and polished. The number of man-hours of labor required in each shop and the number of hours available in each shop are known.The raw materials and supplies are available in adequate supply and all desks produced can be sold.The DES-k wants to know the optimal product mix,that is, the quantities to make of each type of deskthat will maximize profit.
18
Resource Allocation Model in a Manufacturing Company
Many activities compete for resources, such as machine capacity at a plant. The available quantities of some resources may be insufficient to accomodate all the demands placed on them.Moreover, some activities may consume severalresources in producing desired outputs. LP models allow resources to be allocated across the entire sytem being analized to determine how scarce resources can be optimal used.
19
Ajax Computer Co. Has a Resource Allocation Problem
Ajax sells three types of computers with the followingNet Profit for each sold computer:
Personal Computer Alpha: $350NoteBook Computer Beta: $470Workstation Gamma : $610
Net profit equals the sales price of each computer minusthe direct costs of´purchasing components, producingComputer cases, and assembling and testing theComputer. We assume that all production during the week will be sold immediatly.
20
Ajax test capacity
This week, 120 hours are available onThe A-Line Test equipment Where assembled´s and ´s are tested, and 48 hours are availableOn the C-Line test equipment where ´s assembledAre tested. The testing of each computer takes1 hour.
21
Ajax Production constraint for this week: Labor availability
Production is constrained on the availabilityof 2000 labor hours for product assembly. Each requires 10 labor hours,each requires 15 labor hours andEach requires 20 labor hours.Other activities are involved, but are not veryimportant.
We want to allocate these resourcesto maximize net profits for the week.
22
Building an LP Model
23
Before you can put a problem into a computer and efficiently find a solution, you must first abstract it, which means you have to build a mathematical model.
Formulating Linear Programs
24
Formulating Linear Problem
The process of building a math model is so important than solving it, because this process provides insight about how the system works.
The model also helps organize essential information about it.
25
It is easy to formulate a Problem?
To formulate a problem of the real word could be most difficult than to solve it!!
This is because of the richness, variety, and ambiguity than exists in the real world or
Because of our ambiguos understanding of the real world.
26
How to get a Model: The row (material balance) Approach
27
Step 0
Understanding the Problem
28
Step 1: Define the Decision Variables
X= Number of ´s to be assembled tested and sold during the week
X = Number of ´s to be assembled tested and sold during the week
X= Number of ´s to be assembled tested and sold during the week
29
Step 2.What is the Objective Defining the Objective Function
Objective: To Maximize the Net Profit
Net Profit= 350 X+ 470X + 610X
Max Z = 350 X+ 470X + 610X
30
Step 3: Constraints
A Line Test Capacity:
X+ X 120
C line Test Capacity
X 48
Labor availability
10 X+ 15X + 20 X 2000
31
Step 4: No Negativity variables
X 0 X 0 X 0
32
Final Step: Joining Everything
Max Z = 350 X+ 470X + 610X
Subjecto to: X+ X 120 A-Line test Capacity X 48 C-Line Test Capacity10 X+ 15X + 20 X 2000 Labor availability
X 0; X 0 ; X 0
33
Model Structure
Max Z = 350 X+ 470X + 610X
Subjecto to: X+ X 120 X 48 10 X+ 15X + 20 X 2000
X 0; X 0 ; X 0
Right Hand Sides
Non NegativeVariables
34
Structure Model: Activities
Max Z = 350 X+ 470X + 610X
Subjecto to: X+ X 120 X 4810 X+ 15X + 20 X 2000
X 0; X 0 ; X 0
Asociated with eachDecision variableIs an activityDescribing the rateAt which theDecision variableConsumesResources.
1 010
X Activity
35
How to get a Model?
Row approach
Material Balance Approach
Column Approach
Recipe/Activity Approach
36
DES-K With Data
DES-K manufactures four models of desks. Each desk is first constructed in the carpentry shop and then is sent to the finiship shop, where it is varnished, washed and polished. The number of man hours of labor requerid on each shop is:
Desk1 (hrs)
Desk2 (hrs)
Desk3 (hrs)
Desk4 (hrs)
Available
Carpentry Shop
Finishing Shop
4
1
9
1
7
3
10
40
6,000
4,000
37
DES-K With Data
Because of limitations in capacity of the plant,no more than 6,000 man hours can be expected in the carpentry shop and 4000 in the finishing shop in the next six months. The profit (revenue minus costs) from the sale of each item is:
Desk1 Desk2 Desk3 Desk4
Profit $12 $20 $18 $40
38
DES-K With Data
Determine the optimal production mix assuming that the raw material and supplies are available in adequate supply amd all desks produced will be sold.
That is, determine the quantities to make each type of product which maximize profit
39
A System: It is decomposable into a number of elementary functions: the activities.
Column (Recipe/Activity)Approach
40
Column (Recipe/Activity)Approach
Activitymen,material,equipment
Final orIntermediateproductsitems
Activity: Like a recipe in a cookbook. Activity level: Quantity of each activity
41
Column (recipe/Activity)Approach
42
STEPs on Column (recipe/Activity)Approach
43
Step 1: Define the activity Set
Decompose the entire system into all of its elementary functions, the activities or processes and
Choose a unit for each type of activity or process in terms of which its quantity or level can be measured.
44
STEP 1: Define The activity Set.Exemple: DES-K
Activity: • Manufacturing a desk
Activity Level: Number of desks manufactured = Decision Variable.
Manufacturing Desk1: X1 Manufacturing Desk2: X2 Manufacturing Desk3: X3 Manufacturing Desk4: X4
45
Step 2: Define the set itemsExemple: DES-K
1. Object Classes: Desks 2. Items:
• Capacity carpentry shop (in man hours)• Capacity finishing shop (in man hours)• Costs (measured in dollars)
46
Step 3: Define The Input-Output Coefficients aij
Determine the quantity of each item i consumed or produced by the operation of each activity j at its unit level.
Ex: aij= amount of time in shop i required to manufacture one desk j
47
STEP 3: Input-Output Coefficient
Manufacturing1 unit of Desk 1
4 hours of carpentrycapacity
1 hour of finishingcapacity
$12
48
STEP 3: Input-Output Coefficients
Activities
Items Desk1 desk2 Desk3 Desk 4
1. Carpentry Capacity (hrs)
4 9 7 10
2. Finishing capacity (hrs)
1 1 3 40
3. Costs (profit)
$
12 20 18 40
49
Step 4. Specify the Exogenous Flows bi
Specify:• Exogenous amounts of each item being supplied (required) to the system
Capacity in the carpentry and finishing are inputs to each activities:
6000 maximun (carpentry) 4000 maximun(finishing shop)
50
Step 5. Balance Equations1. Assign unknown activity levels x1,x2,x3,...,
2. For each item write the material balance
Activities
Items Desk1 desk2 Desk3 Desk 4
1. Carpentry Capacity (hrs) 4 9 7 10
2. Finishing capacity (hrs) 1 1 3 40
3. Costs (profit) $ 12 20 18 40
4x1+9x2+7x3+10x4 6000x1+ x2 +3x3+40x4 4000
f.O: Z= 12x1+20x2+18x3+40x4
51
JOINING EVERYTHING
Max Z= 12x1+20x2+18x3+40x4
4x1+9x2+7x3+10x4 6000x1+ x2 +3x3+40x4 4000
s.t.
X1,X2,X3,X40
52
Some Complexity Remarques
53
Complexity of Problems/Algorithms
Resources invested to Solve a Problem
Computational View:Time, Space
Temporal, Spatial Complexity
54
Problem:
A set of questions about a subject Instance (of a Problem). A particular
question about a problem.
Subjectx s.t
55
Exemple
Problem: Min Z= F(X) s.t X
Instance of a Problem:Min Z = 3 X1+ 4 X2s.t 3 X1 +4 X2 12X1,X2 0
56
Complexity of ALgorithms
Time/Memory invested for an algorithm for solving a problem
57
Temporal Complexity of Algorithms
Input size
Execution time
exponential
polinomial
58
Deterministic (Non Deterministic) Algorithm
(Not) All its instructons are deterministic
Ex. Classicals Simplex, Montecarlo Gauss Jordan
59
Polinomial/No-Polinomial Problem
Polinominal They are at least one deterministic algorithm able to solve all their instances in a polinomial time
Non Polinomial Problem.• Thery are not any deterministic
algorithm able to solve all their instances in a polinomial time.
• They are at least one non-deterministic algorithm able to solve all their instances in a polinomial time.
60
Good News,l Bad News
Linear Programming is a Polinomial Problem
Linear Programming is used in many other Optimization Problems
Simplex is the most effective Algorithm for many practical problems
Simplex is exponential
61
NPH = optimization + X
62
Linear Programming AlgorithmsMenu
DETERMINÍSTICOS
NO DETERMINÍSTICOS
• Simplex Genetic•Simplex Annealing
• Simplex, •Revised•LU SImplex• Interior Point •Simplex Cosine
63
Computational Methods for Optimization: An Introduction
Dr. Juan Frausto Solís
Tecnológico de Monterrey
Campus Cuernavaca