Линейное программирование. Ч.1. Учебное пособие для бакалавриата
.pdf
5. Method of artificial variables
So,
X2max* =(10, 3, 8, 0, 10) .
And the optimal solution of the initial problem is
X =(1−t)X1 +tX2 =
(1−t)(4, 5, 0, 0, 16)+t(10, 3, 8, 0, 0)= =(4 +6t, 5−2t, 8t, 0, 16 −16t), t [0,1].
fmax = −27 .
Example. Find the solution of the linear programming problem
f = x1 +2x2 +9 →maxx1 +x2 −x3 =2,
x1 +4x2 +x4 =1,−x1 +x2 −x5 =3,
x ≥0.i
Solution.
We have the basis variable x4 in the second equation. Therefore, we need to add an artificial variable y1 and y2 in the first and third equations. We obtain
F = −y1 −y2 →maxx1 +x2 −x3 +y1 =2,
x1 +4x2 +x4 =1,
−x1 +x2 −x5 +y2 =3,
f −x1 −2x2 =9xi ≥0,yj ≥0.
We find from the main constraints
y1 =2−x1 −x2 +x3,y2 =3+x1 −x2 +x5.
— 51 —
5. Method of artificial variables
Using these expressions, we have
F= −y1 −y2 = −(2−x1 −x2 +x3 )−(3+x1 −x2 +x5 )= ,
=−5+2x2 −x3 −x5.
Or
F −2x2 +x3 +x5 = −5.
And get the following simplex table.
basis |
bi |
x1 |
x2 |
x3 x4 |
x5 |
y1 |
y2 |
|
y1 |
2 |
1 |
1 |
−1 0 0 |
1 |
0 |
||
x5 |
1 |
1 |
4 |
0 |
1 |
0 |
0 |
0 |
y2 |
3 |
−1 1 |
0 |
0 |
−1 |
0 1 |
||
f |
9 |
−1 −2 0 |
0 |
0 |
0 |
0 |
||
|
|
|
|
|
|
|
|
|
F |
−5 |
0 |
−2 1 |
0 |
1 |
0 |
0 |
|
|
|
|
|
|
|
|
|
|
We have only one negative estimation
γ2 = −2 <0 .
So, the second column is a pivot column. From this column we obtain
|
|
|
2 |
, |
1 |
, |
3 |
|
= |
1 |
. |
|
|
|
|
|
min |
1 |
4 |
1 |
|
4 |
|
|
|
||||
Thus, |
|
|
|
|
|
|
|
|
|
|
||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
a22 =4 |
|
|
|
|
|
|
|||||
is the pivot (x5 ↔ x2) . |
|
|
|
|
|
|
|
|
|
|
|
|||
After recalculation we have. |
|
|
|
|
|
|
||||||||
|
|
|
|
|
|
|
|
|
|
|
|
|
||
basis |
bi |
x1 |
|
x2 |
|
x3 |
|
|
x4 |
x5 |
y1 |
y2 |
||
y1 |
7/4 |
3/4 |
|
0 |
|
−1 |
−1/4 |
0 |
1 |
0 |
||||
x2 |
1/4 |
1/4 |
|
1 |
|
0 |
|
1/4 |
0 |
0 |
0 |
|||
y2 |
11/4 |
−5/4 |
|
0 |
|
0 |
|
−1/4 |
−1 |
0 |
1 |
|||
f |
19/2 |
−1/2 |
|
0 |
|
0 |
|
1/2 |
0 |
0 |
0 |
|||
|
|
|
|
|
|
|
|
|
|
|
|
|||
F |
−9/2 |
1/2 |
|
0 |
|
1 |
|
1/2 |
1 |
0 |
0 |
|||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
— 52 —
5. Method of artificial variables
In the table all evaluations are non-negative, so
Fmax = −9/2 <0 .
It shows us that the initial linear programming problem is infeasible.
Questions for self-control
1)For which linear programming problems do we use the method of artificial variables?
2)How we use the artificial variables?
3)What is the artificial objective function?
4)How to determine using the method of artificial
variables |
that |
the |
initial |
linear |
programming |
problem |
is feasible? |
|
|
|
|
|
|
5) How to determine using the method of artificial |
||||||
variables |
that |
the |
initial |
linear |
programming |
problem |
is infeasible?
Exercises for independent work
Find the solution of the linear programming problems by using the method of artificial variables.
f = −x1 −x2 −4x3 +5x4 →max
1)4x1 +x2 =4,
12x1 +3x2 −x3 +x4 =12,xi ≥0.
f =2x1 −x2 −2x3 +x4 +12 →max−x1 +4x2 +x3 =10,
2)7x1 +x3 +4x4 =42,x1 +3x2 −x5 =14,x ≥0.
i
— 53 —
5. Method of artificial variables
f = x1 −3x2 −5x3 −x4 +6 →max
3)x1 +x2 =1,
2x1 +11x2 +12x3 +3x4 =14,
xi ≥0.
f = x3 +x4 +x5 →max2x1 +3x2 −x3 =23,
4)x1 −2x2 −x4 =1,2x1 −x2 +x5 =1,x ≥0.
i
f = x2 +x3 +x5 −14 →max
2x +4x −x =9,
5)−3x1 +x2 +3x4 =3,x1 +5x2 +x3 +2x4 =4,x ≥0.
i 1 2 4
f = −6x1 +x3 +3 →max
3x −x −x =3,
6)5x2 +x3 +x4 =30,3x1 −x3 −x5 =6,x ≥0.
i 2 31
— 54 —
CONCLUSION
Linear programming as a science appeared in the first half of the twentieth century to solve applied problems of economics. Linear programming is still actively used to solve both theoretical and applied problems in various branches of science. Therefore, linear programming takes an important place in the knowledge system of a modern economist.
— 55 —
ANSWERS FOR QUESTIONS
AND EXERCISES
Section 2
Question
1). Linear programming is a branch of applied mathematics that deals with solving problems of maximization or minimization of a linear function subject to linear constraints (it means that constraints are linear equations or linear inequalities).
2) A linear programming problem is the following optimizing problem
f = c1x1 + +cmxm +c0 →max (min)
Subject to
a11x1 + +a1mxm ≤ b1,
,
an1x1 + +anmxm ≤ bn,
d11x1 + +d1mxm =q1,
,
dk1x1 + +dkmxm =qk, x1 ≥0, ,xm ≥0 .
— 56 —
Answers for questions and EXERCISES
3)
f = CT X +C0 →max (min)
AX ≤ B,
DX = Q,X ≥0.
4)The linear function f to be maximized or minimized is called the objective function.
5)A solution X* =(x1*,...,xn* )T of the linear program ming problem is called the optimal solution.
6)
AX ≤ B,
DX = Q.
7)x1 ≥0, ,xm ≥0 .
8)A vector X =(x1,...,xn )T satisfying the constraints of the linear programming problem is called a feasible solution.
9)The set of all feasible solutions is called the feasible
set.
10)A linear programming problem is said to be feasible if the feasible set is not empty.
11)A linear programming problem can have a unique solution, infinitely many solutions, or no solutions.
12)A set M is said to be convex if for any x,y M and any t [0;1] it follows that tx +(1−t)y M .
13)The feasible set of a linear programming problem is convex
14)
f = CT X +C0 →max
AX = B,
X ≥0.
— 57 —
Answers for questions and EXERCISES
15)Anylinearprogrammingproblemcanbetransformed to the canonicals form.
16)
f = CT X +C0 →max
AX ≤ B,
X ≥0.
17) If a linear programming problem written in the canonicals form system of basic constraints reduced to the unit basis, then the linear programming problem can be transformed to the standard form.
Exercises
1)
f= x1 −5x2 +2x3 →max
x1 −x2 +4x3 =7,
a)x1 −4x2 +y1 =2,
x1 +2x2 +3x3 −y2 =6,
x1 ≥0, x2 ≥0, x3 ≥ 0,y1 ≥ 0,y2 ≥ 0.
f= x1 +2x2 −x4 →min
x1 +2x2 −5x3 =3,
b)2x1 −2x2 +6x4 +y1 =1,x1 −x2 +2x3 −x4 +y2 =2,
x1 ≥0, x2 ≥0, x3 ≥ 0,x4 ≥ 0,y1 ≥ 0,y2 ≥ 0.
2)
f = −x1 +4x2 −4 →max
a)x1 −x2 ≤1,3x1 −2x2 ≤5,x1 ≥0, x2 ≥0.
— 58 —
Answers for questions and EXERCISES
f = x1 −3x2 +1 →min
b)x1 +2x2 ≤1,2x1 −x2 ≤5,x1 ≥0, x2 ≥0.
3) |
|
|
|
|
|
|
|
|
|
x1 |
|
|
|
|
|
|
||
f =(1 |
−1 |
|
|
2) x2 |
→min |
|
||||||||||||
|
|
|
|
|
|
|
|
|
|
x |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
|
|
|
|
|
|
|
|
|
|
1 −2 x |
|
|
|
3 |
|
|
|||||||||
1 |
|
|
|
|
||||||||||||||
|
|
−2 4 |
|
1 |
|
|
1 |
|
|
|
||||||||
1 |
x2 ≤ |
; |
|
|||||||||||||||
|
1 |
−5 2 |
x |
|
|
|
7 |
|
|
|
||||||||
|
|
|
|
|
|
|
|
|
|
|
3 |
|
|
|
|
|
|
|
|
|
|
|
0 |
|
|
|
|
|
|
|
|
|
|
||||
x1 |
|
|
|
|
|
|
|
|
|
|
|
|||||||
|
x |
|
≤ |
|
0 |
|
. |
|
|
|
|
|
|
|
|
|
||
|
|
|
|
|
|
|
|
|
|
|
|
|
||||||
|
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
||||
|
|
|
|
|
|
|
|
|
|
|
|
|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4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
||
— 59 —
Answers for questions and EXERCISES
Section 3
Question
1) We apply the geometrical method if the linear programming problems has 2 variables and is written in the standard form (all constraints are inequalities).
2)
a) Find the boundaries of the feasible region.
They are the straight lines defined by equations obtained by replacing the inequality sign with an equal sign in the system of constraints. You can build them by finding two points through which this line passes. These points can be obtained by substituting a fixed value of one of the variables into the equation and finding the corresponding value of the other variable.
b) Find the half-planes containing the feasible region. The straight lines of the boundaries divide the plane
into two half-planes. Substituting a test point (for example, a point O(0;0) ), we can determine which half-plane containing the feasible region. If, when substituting the test point into the inequality defining the half-plane of the constraint, we get the correct statement, then the feasible region belongs to the half-plane containing the test point. If, when substituting a test point into an inequality defining a half-plane of the constraint, we get an incorrect statement, then the feasible region belongs to a half-plane that does not contain a test point.
c) Find the intersection of all half-planes containing the feasible region.
3)The vector n =(n1,n2)T .
4)n1x1 +n2x2 = c where c is a constant.
— 60 —
