yöneylem

24
Operations Research Solving IPs

Upload: hilalaldemir

Post on 13-Jan-2016

215 views

Category:

Documents


0 download

DESCRIPTION

yöneylem arastırasına giriş_tamsayılı programlama (integer programming)

TRANSCRIPT

Page 1: yöneylem

Operations Research

Solving IPs

Page 2: yöneylem

There are two common approaches:

The technique based on dividing the problem into a number of

smaller problems in a tree search method called branch and

bound.

The method based on cutting planes (adding constraints to

force integrality).

Actually, all these approaches involve solving a series of LP

Page 3: yöneylem

Categorization (w.r.t. Purpose)

General purpose methods will solve any IP but potentially

computationally ineffective (will only solve relatively small

problems);

Special purpose methods are designed for one particular

type of IP problem but potentially computationally more

effective.

Page 4: yöneylem

Categorization (w.r.t. Algorithm) Optimal algorithms mathematically guarantee to find the

optimal solution

Heuristic algorithms are used to solve a problem by trial and error when an optimal algorithm approach is impractical. They hopefully find a good feasible solution that, in objective function terms, is close to the optimal solution.

Because the size of problem that we want to solve is beyond the computational limit of known optimal algorithms within the computer time we have available.

We could solve optimally but feel that this is not worth the effort (time, money, etc) we would expend in finding the optimal solution.

In fact it is often the case that a well-designed heuristic algorithm can give good quality (near-optimal) results.

Page 5: yöneylem

Solution Algorithms Categories

General Purpose, Optimal

Branch and bound, cutting plane

General Purpose, Heuristic

Running a general purpose optimal algorithm and terminating

after a specified time

Special Purpose, Optimal

Tree search approaches based upon generating bounds via dual

ascent, lagrangean relaxation

Special Purpose, Heuristic

Bound based heuristics, tabu search, simulated annealing,

population heuristics (e.g. genetic algorithms), interchange

Page 6: yöneylem

Solving IP

The Branch-and-Bound Method

B&B for Solving Pure IP Problems

B&B for Solving Mixed IP Problems

B&B for Solving Binary IP Problems

B&B for Solving Knapsack Problems

B&B for Solving Combinatorial Optimization Problems

Cutting Planes

Page 7: yöneylem

B&B for Solving Pure IP Problems

The Telfa Corporation manufactures tables and chairs. A

table requires 1 hour of labor and 9 square board feet of

wood, and a chair requires 1 hour of labor and 5 square

board feet of wood. Currently, 6 hours of labor and 45

square board feet of wood are available. Each table

contributes $8 to profit, and each chair contributes $5 to

profit. Formulate and solve an IP to maximize Telfa’s

profit.

Page 8: yöneylem

Solution

x1 number of tables manufactured

x2 number of chairs manufactured

max z = 8x1 + 5x2

s.t. x1 + x2 ≤ 6 (Labor constraint)

9x1 + 5x2 ≤ 45 (Wood constraint)

x1, x2 ≥ 0; x1, x2 integer

Page 9: yöneylem

The branch-and-bound method begins by solving the LP

relaxation of the IP. If all the decision variables assume

integer values in the optimal solution to the LP relaxation,

then the optimal solution to the LP relaxation will be the

optimal solution to the IP. We call the LP relaxation

subproblem 1

the optimal solution to the LP relaxation is z=165/4, x1=

15/4, x2 = 9/4

(optimal z-value for IP) (optimal z-value for LP

relaxation)

Upper bound for Telfa’s profit= 165/4

Page 10: yöneylem

Our next step is to partition the feasible region for the

LP relaxation in an attempt to find out more about the

location of the IP’s optimal solution. We arbitrarily choose

a variable that is fractional in the optimal solution to the

LP relaxation—say, x1.

Now observe that every point in the feasible region for

the IP must have either x1 ≤ 3 or x1 ≥ 4.

we “branch” on the variable x1 and create the following

two additional subproblems:

Subproblem 2 Subproblem 1 + Constraint x1 ≥ 4.

Subproblem 3 Subproblem 1 + Constraint x1 ≤ 3 .

Page 11: yöneylem

We now choose any subproblem that has not yet been

solved as an LP.

We arbitrarily choose to solve subproblem 2.

the optimal solution to subproblem 2 is z = 41, x1 = 4, x2

= 9/5

Page 12: yöneylem

The optimal solution to subproblem 2 did not yield an all-

integer solution, so we choose to use subproblem 2 to

create two new subproblems. Because x2 is the only

fractional variable in the optimal solution to subproblem

2, we branch on x2. We partition the feasible region for

subproblem 2 into those points having x2 ≥ 2 and x2 ≤ 1.

This creates the following two subproblems:

Subproblem 4 Subproblem 1+ Constraints x1 = 4 and

x2 ≥ 2 = subproblem 2 + Constraint x2 ≥ 2.

Subproblem 5 Subproblem 1 + Constraints x1= 4 and

x2 ≤ 1= subproblem 2 + Constraint x2 ≤ 1.

Page 13: yöneylem

subproblem 4 is infeasible we place an X by subproblem

4.

Page 14: yöneylem

the optimal solution to subproblem 5 is z = 365/9, x1 =

40/9, x2 =1.

we choose to partition subproblem 5’s

feasible region by branching on the fractional-valued

variable x1

Subproblem 6 Subproblem 5 + Constraint x1 ≥ 5.

Subproblem 7 Subproblem 5 + Constraint x1 ≤ 4.

Page 15: yöneylem
Page 16: yöneylem
Page 17: yöneylem
Page 18: yöneylem
Page 19: yöneylem

B&B for Solving Mixed IP Problems

max z = 2x1 + x2

s.t. 5x1 + 2x2 ≤ 8

x1 + x2 ≤ 3

x1, x2 ≥ 0; x1 integer

The optimal solution of the

LP relaxation is z =11/3, x1 = 2/3, x2 = 7/3

x2 is allowed to be fractional, we do not branch on x2

Page 20: yöneylem
Page 21: yöneylem

Knapsack Problems

Any IP, that has only one constraint is referred to as a

knapsack problem.

Page 22: yöneylem

B&B for Solving Knapsack Problems

max z = 8x1 + 11x2 + 6x3 + 4x4

s.t. 5x1 + 7x2 + 4x3 + 3x4 ≤ 14

xj = 0 or 1 (j = 1,2,3,4)

Page 23: yöneylem

We compute the ratios:

r1 = 8 / 5 = 1.6

r2 = 11 / 7 = 1.57

r3 = 6 / 4 = 1.5

r4 = 4 / 3 = 1.33

Page 24: yöneylem