Você está na página 1de 9

Optimization Methods: Integer Programming - Examples

Module 7 Lecture Notes 3 Integer Programming - Examples Introduction In the previous two lectures, we have discussed about the procedures for solving integer linear programming and also mixed integer linear programming. In this lecture we will be discussing a few examples based on the methods already discussed. Example of Cutting plane method for ILP: These steps are explained using the example previously discussed. Maximize subject to Z = 3x1 + x 2 2 x1 x 2 6 3x1 + 9 x 2 45 x1 , x 2 0 x1 and x2 are integers The standard form for the problem can be written as Maximize subject to Z = 3x1 + x2 2 x1 x2 + y1 = 6 3x1 + 9 x2 + y2 = 45 x1 , x2 , y1 , y2 0

x1, x2 , y1 and y2 are integers


Step 1: Solve the problem as an ordinary LP problem neglecting the integer requirements. Table 1 Z Iteration Basis Variables

br x1 x2
-1 -1 9

y1
0 1 0

y2
0 0 1 0 6 45

br crs
-3 15

1 0 0

-3 2 3

y1 y2

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples Table 2 Variables Iteration Basis Z

br x1 x2
5 2 1 2

y1
3 2 1 2
3 2

y2
0 9

br crs
--

x1

-24 7

y2

21 2

36

Table 3 Variables Iteration Basis Z

br x1 x2
0

y1
8 7 6 14 1 7

y2
5 21 1 21 2 21 123 7 33 7 24 7

br crs
--

x1 x2

--

--

Optimum value of Z is are x1 =

123 as shown above. Corresponding values of basic variables 7

33 24 = 4 5 , x2 = = 3 3 and those of non-basic variables are all zero 7 7 7 7

(i.e., y1 = y 2 = 0 ). The values are not integers. Step 2: Introduce Gomory constraints. Gomory constraint is developed for x1 which is having high fractional value. From the row corresponding to x1 in the last table, we can write, x1 = 33 6 y1 1 y2 7 14 21

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples

Here b1 = 33 , bi = 4, i = 5 , c11 = 6 , c11 = 0, 11 = 6 , c12 = 1 , c12 = 0 and 12 = 1 . 7 7 14 14 21 21 From Eqn. Gomory constraint can be expressed as s1 11 y1 12 y 2 = 1 i.e., s1 6 14 y1 1 21 y2 = 1 21

By inserting a new row with the coefficients of this constraint to the last table, we get Table 4 Variables Iteration Basis Z

br y2
5 21 1 21 2 21 1 21

x1
Z 1 0 0 0 0 1 0 0

x2
0 0 1 0

y1
8 7 6 14 1 7 6 14

s1
0 0 0 1
123 7 33 7 24 7 5 7

x1 x2 s1

Step 3: Solve using dual simplex method Table 5 Variables Iteration Basis Z

br y2
5 21 1 21 2 21 1 21

x1
Z 1 0 0 0 0 1 0 0 --

x2
0 0 1 0 --

y1
8 7 6 14 1 7 6 14 8 3

s1
0 0 0 1 -123 7 33 7 24 7 5 7

x1 x2 s1
Ratio

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples Table 6 Variables Iteration Basis Z

br y2
1 9

x1
Z 1 0 0 0 0 1 0 0

x2
0 0 1 0

y1
0 0 0 1

s1
8 3 47 3

x1
4

0
1 9 1 9

1
1 3 7 3

4
11 3 5 3

x2 y1

Optimum value of Z from the present tableau is of basic variables are x1 = 4 , x 2 =

47 as shown above. Corresponding values 3

11 7 , y1 = and those of nonbasic variables are all zero 3 3

(i.e., y 2 = s1 = 0 ). Here also the values of x 2 and y1 are not integers.

Step 4: Generation of new Gomory constraint for x 2 From the row corresponding to x 2 in the last table, we can write, x 2 = 11 1 y 2 + 1 s1 3 9 3 Therefore Gomory constraint can be written as s2 1 y2 + 1 s1 = 2 9 3 3

Step 5: Adding this constraint to the previous table and solving using dual simplex method

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples Table 7 Variables Iteration Basis Z

br s1
8 3

x1
Z 1 0 0 0 0 0 1 0 0 0 --

x2
0 0 1 0 0 --

y1
0 0 0 1 0 --

y2
1 9

s2
0 0 0 0
1 3 47 3

x1 x2 y1

0
1 9 1 9 1 9

1
1 3 7 3

4
11 3 5 3 2 3

s2
Ratio

0 --

--

--

Table 8 Variables Iteration Basis Z

br s1
8 3

x1
Z 1 0 0 0 1 0

x2
0 0 1

y1
0 0 0

y2
0 0 0

s2
1 3

15 4 3

x1
5

1
1 3 7 3

0
1 3 1 3

x2 y1 s2

0 0

0 0

0 0

1 0

0 1

1 6

-3

The solution from this tableau is x1 = 4, x2 = 3, y1 = 1, s 2 = 6, y 2 = s1 = 0 and the value of Z = 15. These are satisfying the integer requirement and hence the desired solution.

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples Example of Cutting plane method for MILP Consider the example previously discussed with integer constraint only on x 2 . The standard form for the problem is Maximize subject to Z = 3x1 + x2 2 x1 x2 + y1 = 6 3x1 + 9 x2 + y2 = 45 x1 , x2 , y1 , y2 0

x2 should be an integer
Step 1: Solve the problem as an ordinary LP problem. The final tableau is showing the optimal solutions are shown below. Table 9 Variables Iteration Basis Z

br x1 x2
0

y1
8 7 6 14 1 7

y2
5 21 1 21 2 21 123 7 33 7 24 7

br crs
--

x1 x2

--

--

Optimum value of Z is
x2 =

33 123 and corresponding values of basic variables are x1 = = 45 , 7 7 7

24 = 3 3 and those of non-basic variables are all zero (i.e., y1 = y 2 = 0 ). This is not 7 7

satisfying the constraint of x2 to be an integer. Step 2: Generate Gomory constraint. Gomory constraint is developed for x2 .From the row corresponding to x2 in the last table, we can write, x 2 = 24 + 1 y 2 2 y1 7 7 21

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples Here b2 = 24 , c 21 = 1 , c 22 = 2 . 7 7 21 Since b2 = b2 + 2 as per Eqn(), the value of b2 = 3 and 2 = 3 . 7
+ + + c21 + c22 Similarly c21 = c21 and c 22 = c22 .

Therefore,
+ c21 = 0, c21 =1 + c22 =2

since c21 is negative

21

, c22 = 0 since c22 is positive

Thus Gomory constraint can be written as


si
m + cij yj

j =1

cij y j = i 1 j =1

i.e., s2 2

21

y2 3

28

y1 = 3

Insert this constraint as the last row of the final tableau. Table 10 Variables Iteration Basis Z

br y2
5 21 1 21 2 21 2 21

x1
Z 1 0

x2
0

y1
8 7 6 14 1 7 3 28

s2
0
123 7 33 7 24 7 3 7

x1 x2 s2

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples Step 3: Solve using dual simplex method Table 11 Variables Iteration Basis Z

br y2
5 21 1 21 2 21 2 21

x1
Z 1 0 0 0 0 1 0 0 --

x2
0 0 1 0 --

y1
8 7 6 14 1 7 3 28

s2
0 0 0 1 -123 7 33 7 24 7 3 7

x1
4

x2

s2
Ratio

32 3

2.5

Table 12 Variables Iteration Basis Z

br y2
0 0 0 1

x1
Z 1 0 0 0 0 1 0 0

x2
0 0 1 0

y1
7 8 3 8 1 4

s2
1 1 1
21 2 33 2 9 2

x1
4

x2 y2

3
9 2

9 8

Optimum value of Z from the present tableau is

33 as shown above. Corresponding values 2

of basic variables are x1 = 4.5 , x2 = 3 , y 2 = 4.5 and those of non-basic variables are all zero (i.e., y1 = s 2 = 0 ). This solution is satisfying all the constraints.

D Nagesh Kumar, IISc, Bangalore

M7L3

Optimization Methods: Integer Programming - Examples References/ Further Reading:

1. Hillier F.S. and G.J. Lieberman, Operations Research, CBS Publishers & Distributors, New Delhi, 1987. 2. Kasana H.S., and Kumar K.D., Introductory Operations Research Theory and Applications, Springer Pvt. Ltd, New Delhi, 2003. 3. Rao, S.S., Engineering Optimization Theory and Practice, New Age Intl. Pvt. Ltd., New Delhi, 1996. 4. Ravindran A., D.T. Phillips and J.J. Solberg, Operations Research Principles and Practice, John Wiley & Sons, New York, 2001. 5. Taha H.A., Operations Research An Introduction, Prentice-Hall of India Pvt. Ltd., New Delhi, 2005.

D Nagesh Kumar, IISc, Bangalore

M7L3

Você também pode gostar