0% found this document useful (0 votes)
62 views35 pages

Operations Research

The document discusses linear programming, which is a mathematical technique used to allocate scarce resources. It defines linear programming and describes the components of a linear programming model, including the objective function and constraints. Some key aspects covered are: - The objective is to maximize or minimize some function subject to limitations on available resources. - Decision variables represent quantities being optimized. - Constraints define limitations on available resources and must be expressed as linear equations or inequalities. - Linear programming finds the optimal solution within the constraints to meet the objective.

Uploaded by

IGO SAUCE
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
62 views35 pages

Operations Research

The document discusses linear programming, which is a mathematical technique used to allocate scarce resources. It defines linear programming and describes the components of a linear programming model, including the objective function and constraints. Some key aspects covered are: - The objective is to maximize or minimize some function subject to limitations on available resources. - Decision variables represent quantities being optimized. - Constraints define limitations on available resources and must be expressed as linear equations or inequalities. - Linear programming finds the optimal solution within the constraints to meet the objective.

Uploaded by

IGO SAUCE
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 35

KWAME NKRUMAH UNIVERSITY OF SCIENCE AND TECHNOLOGY

LINEAR PROGRAMMING

Dr. Brght Emmanuel Owusu

February 8, 2023
0.1 DEFINITION
Linear programming is a mathematical technique concerned with the allocation of
scarce resources. It is a procedure to optimize the value of some objective( Profit or
Cost ) when the factors invloved( Labour or material ) are subjected to some limitations
or constraints.

0.1.1 LINEAR PROGRAMMING MODEL


In general, Linear programming models are stated as follows:

Maximize ( or Minimize )
n
X
cj ∗ xj
j =1

Subject to
m X
X n
a i j ∗ x j {≤, =, ≥}b i
i =1 j =1

x j ≥ 0 for i = 1, 2, ...m and j = 1, 2, ...n

Where:
• The i t h row may be an equation "=" , or an inequality " ≤ or ≥ "
• c j are known as Cost Coefficients

• x j are decision variables


• ai j are called structural coefficients
• b j are resource values( or stipulations because they define the constraint require-
ments )

0.1.2 CHARACTERISTICS OF A LINEAR PROGRAMING MODEL


Linear programming models consist of certain components or characteristics. The char-
acteristic model’s components include an objective function and constraints. These two
components are made of decision variables. In addition, these two components must
be linear functions.

0.1.3 LINEARITY REQUIREMENT


A major factor in linear programming is the requirement that all relationships be linear.
Obviously not all factors involve in business decisions are liner and indeed in some
situations non-linear relationships are typical and desirable.

1
0.1.4 DECISION VARIABLES ( X j )
In every organization, the management must decide on the quantity of a certain produc-
tion material to be purchased in order to minimize the cost of production or the quantity
of a certain good to produce in order to maximize profit. In linear programming mod-
els, the unknown quantities are assigned mathematical symbols, which are known as
variables. Thus, the decision variables are symbols that represent the quantities of a
certain good or a production material. For example, Ghana Brewery Ltd (GBL) may
desire to produce x 1 , x 2 and x 3 quantities of ABC mini bear, ABC larger bear, and club
shandy respectively. The values of x 1 , x 2 and x 3 as determined by the management
constitute their decision. For instance, x 1 = 20, x 2 = 15 and x 3 = 25 implies that GBL
will produce 20 bottles of ABC mini bear, 15 bottles of ABC larger bear and 25 bottles
of club shandy.

0.1.5 THE OBJECTiVE FUNCTION


Maximize (or Minimize)
n
X
cj ∗ xj
j =1

The first step in linear programming is to decide what result is required (i.e. the
objective). This may be to maximize or minimize a quantity, or some other appropriate
measure. Having decided on the objective, it 1s now necessary to state mathematically,
the elements involved in achieving this. This is called the objective function.

0.1.6 THE LIMITATIONS OR CONSTRAINTS


Circumstances always exist to govern the achievement of the objective. These factors
we known as limitations or constraints. The constraints in any given problem must be
clearly identified, quantified and expressed mathematically.

n
X
cj ∗ xj
j =1

Subject to
m X
X n
a i j ∗ x j {≤, =, ≥}b i
i =1 j =1

x j ≥ 0 for i = 1, 2, ...m and j = 1, 2, ...n

Therefore, this represents the restrictions placed on an organization by the scarcity


of resources for production. For example, there nay be only 38 hours of labour available
for the production of a product in a given period (say a week or a month).

2
0.2 FORMULATION OF LINEAR PROGRAMMING
MODELS
0.2.1 BASIC ASSUMPTIONS
Linear programming has a number of basic assumptions which form additional require-
ments to those mentioned above, and also enable us to formulate the linear program-
ming model correctly. Among these assumptions are:

• CONDITION OF CERTAINTY: we assume that conditions of certainty exist.


This implies that the constants in the objective function and the constraints known
with certainty that they will not change during the period of work.
• NON-NEGATIVITY: It is required that the decision variables be non-negative(thus
x j ≥ 0 for j = 1, 2, .., n). since no organization can produce a negative quantity of
any commodity or purchase any commodity for production at a negative price.
• PROPORTIONALITY: it must be assumed that proportionality exist in the ob-
jective function and constraints. That is if 5 units of a particular scarce resource
is used to produce 2 units a product, then producing 8 units of that product, 20
units of the resource must be used.

0.2.2 USEFUL STEPS IN MODELLING LINEAR PROGRAM-


MING PROBLEM
Formulating Word problems as linear programming problems requires considerable
practice. The following steps-by-step procedure is often useful:

STEP1: Read the problem carefully. If appropriate, organize the data into a table
as in the Solution to Examples 1.1 and 1.2 below.

STEP2: Determine the variables. These represent the unknown quantities who’s
values you want to find.

STEP3: formulate the objective function. This is what you want to optimize.

STEP4: Formulate the constraints. These are the expressions, which limit the
amount of resources you can use.

Example1.1:
A bicycle manufacturer owns a retail outlet and in addition sells some bikes large chain
store. One truck makes the deliveries from manufacturing ware-house to the retail out-
let and to the chain store distribution centre. It takes 2 hours to make a round trip to the
retail outlet and 4 hours to make a round trip to the distribution centre. The cost of a
round trip to the retail outlet is GHS50.00 and the cost of a round trip to the distribution

3
centre is GHS200.00.
The profit of each truckload sold through the retail outlet is GHS210.00 and the profit
GHS400.00 for the distribution centre. How many shipments per week should be
scheduled to each store in order to maximize profit if the manufacturer is limited to
no more than 40 hours of travel time per week and a cost of GHS1600:00?

SolutiontoExample1.1 :

Retail outlet Chain store Limiting value


Time for a round trip 2 4 40
Cost of round trip 50 200 1600
Profit 210 400

Table 1: Caption

Let x= the number of bikes delivered to the retail outlet, and


y= the number of bikes delivered to the chain store.
Also P= the profit which is the objective of the problem.
Therefore the model is:
Maximize P=210x + 400y
subject to: 2x + 4y ≤ 40
5Ox +200y ≤ 1600
x,y ≥ 20

Example 1.2 A Farmer can chose between three feeds for his lamas. The following
table gives the nutritional requirements and costs. The minimum daily requirements of
nutrients A, B and C are 72, 81 and 69 units, respectively. Determine the mixture of
feeds that will supply the minimum nutritional requirements at least cost.

Feed A(units/lb) B(units/lb) C(units/lb) Cost (GHS/lb)


Feed 1 5 8 3 0.10
Feed 2 2 4 4 0.07
Feed 3 6 5 3 0.60

Table 2:

Solution

4
Feed A B C Cost (GHS/lb)
1 5 8 3 0.10
2 2 4 4 0.07
3 6 5 3 0.60
Minimum requirements 72 81 69

Table 3:

Let x 1 = the amount of feed 1 required,

x 2 = the amount of feed 2 required,

x 3 = the amount of feed 3 required, and

C = the cost of the feeds which is the objective of this problem.

Therefore the model will be:

Minimize C = 0.10x 1 + 0.07x 2 + 0.06x 3

Subject to; 5x 1 + 2x 2 + 6x 3 ≥ 72
8x 1 + 4x 2 + 5x 3 ≥ 81
3x 1 + 4x 2 + 3x 3 ≥ 69

x i ≥ 0, for all 1 ≤ i ≤ 3

0.2.3 SOLUTIONS OF LINEAR PROGRAMMING MODEL


Mathematicians do not believe in "there are more questions than answers". Rather, to
every problem there is a solution.
Models seek to give ideas for the best decisions to be made by the management or
Organizations. So, how can this objective be achieved if there are no solutions to the
models? So, linear programming problems have solutions.
There are many methods of solving linear programming models. Among these are:

• The Geometric (Graphical ) Method (or Approach)


• the Simplex Algorithm (Method), accredited to George Bernard Dzantig
We shall discuss the two methods in our study.

0.3 THE GEOMETRIC APPROACH


This method of solving linear programming problems employs the idea of graphing
the constraints. We believe that is the reason why it is sometimes called The Graphical

5
Method of solving linear programming problems.
The equation of a line can be written in the form ax +by = c, where: a, b, and c repre-
sent constants and x and y represent variables.
A linear inequality in two variables x and y is an expression of the form:
ax + by < c, ax +by > c, ax + by ≤ c, or ax + by ≥ c.
The graph of an inequality is the set of all points (x, y) that satisfy the inequality.

Example1.3
The graph of x + 2y ≤ 6, consist of all the points on or below the line x + 2y = 6 as
shown in figure 1 Also the graph of x + 2y ≥ 6 consist of the points on or above the
line x + 2y = 6 as shown in figure

Figure 1: .

6
0.4 SOME IMPORTANT DEFINITIONS.
1. The graph of a system of inequalities is the set of all points that simultaneously
satisfy all of the inequalities.

2. Boundary lines of a constraint (inequality) ax + by = c or ax + by ≥ c the line


ax + by = c. therefore from Example 1.3, line x +2y = 6 is the boundary line of
x + 2y ≤ 6 and x + 2y ≥ 6.
3. Feasible Region is the area on the graph, which does not contravene any of the
constraints. Thus, the region where all the constraints overlap and therefore the
region where all solutions of the linear programming lie.
4. A Corner Point of a feasible region is a point that is in the feasible region and
is the intersection of two or more boundary lines. Thus, a corner point can be
obtained by solving two or more equations of boundary lines simultaneously to
know the values of the decision variables at their point of intersection.

5. Feasible Point is any point that can be found in the feasible region.
6. Polyhedron is a region bounded by lines or more generally (hyper) planes.So
in general, the feasible region is always a polyhedron.
Also the feasible region is convex.

7. A Convex is any point on a straight line, which is joining two points within a
region, and (the point) is also in the region.

7
Figure 2: .

Example1.4
Graphically display the feasible region for the following constraints:

5x + 2y ≤ 15
2x + 3y ≤ 12
x+y≤2

x,y ≥ 0

This example actually seeks to illustrate the above definitions.

Solution

Let 5x + 2y = 15
when x = 0, then 2y = 15
=⇒ y = 15/2

8
Also when y = 0, then 5x = 15
=⇒ x = 3.
Hence (0, 15/2) and (3, 0) are points on the boundary line 5x + 2y = 15.

Let 2x + 3y = 12
When x = 0, then 3y = 12
=⇒ y = 4

Also, when y = 0, then 2x = 12


=⇒ x = 6
Hence (0, 4) and (6, 0) are points on the boundary line 2x + 3y = 12

Again, let x + y = 2
Then (0, 2) and (2, 0) are the points on the boundary line x + y = 2

Figure 3: .

From figure 3, the point A is the point on lines 5x + 2y = 15 and 2x + 3y = 12,


Therefore, solving this two equations simultaneously,

9
5x + 2y = 15 (1)
2x + 3y = 12 (2)
10x + 4y = 30 (3)
10x + 15y = 60 (4)

Note equations (3) and (4) were derived by multiplying equations 2*(1) and 5*(2) re-
spectively

equations (4)-(3) =⇒ 11y = 30


=⇒ y = 30/11

Also, 5x + 2y = 15
5x + 2(30/11) = 15
=⇒ x = 21/11
Therefore A = (21/11, 30/11)
So, (0, 4), (0, 2). (2, 0). (3, 0), and (21/11, 30/11) are corner points of the feasible
region D. D is a polyhedron and convex.
x = 0, y = 0, 5x+2y = 15, 2x + 3y = 12, and x +y = 2 are boundary lines.

0.4.1 OPTIMAL SOLUTION


This is the best solution out of the possible solutions. Thus if the problem is a maxi-
mization (or minimisation) problem, then the optimal solution is the value of the objec-
tive function which is largest (or smallest) among all the possible values of the objective
function.

The optimal solution is determined graphically by evaluating the objective function


at each corner points and choosing the optimal value. Examples 2.5 and 2.6 illustrate
how to determine the optimal solution graphically.

Example1.5

Maximise Z = 120x + 100y


Subject to

x+y ≤4
5x + 3y ≤ 15
x, y ≥ 0

10
Solution
Let x + y = 4
when x= 0, then y = 4
i.e.(0, 14)

Also when y = 0, then x = 4


i.e. (4, 0)
Hence (0, 4) and (4, 0) are points on the boundary line x + y = 4

Let 5x + 3y = 15
When x = 0, then 3y = 15
=⇒ y = 5 i.e. (0, 5)

Also when y = 0, then 5x = 15


=⇒ x = 3 i.e.(3, 0)
Hence (0, 5) and (3, 0) are points on the boundary line 5x + 3y = 15

Also solving x + y = 4 and 5x + 3y = 15 simultaneously yields the point (3/2, 5/2)


The corner points are (0, 0), (3, 0).(3/2, 5/2) and (0, 4)

The solutions are:

At (0, 0), Z = 120(0) + 100(0) = 0


At (3,0), Z = 120(3) + 100(0) = 360
At (3/2, 5/2), Z= 120(3/2) + 100(5/2) = 430
At (0, 4), Z = 120(0) + 100(4) = 400.

Therefore the optimal solution is Z = 430 at the corner point x = 3/2 and y = 5/2

Example2.6
Minimize C= 12x + 8y
subject to:

x + y ≥ 100
2x + y ≥ 160
x + 2y ≥ 125

Solution: Let x + y = 100


when x = 0, then y = 100
i.e. (0, 100)

Also when y = 0, then x = 100

11
i.e. ( 100, 0)

Hence (0, 100) and (100, 0) are points on the boundary line x + y= 100.

Let 2x + y = 160
When x = 0, then y = 160
i.e. (0, 160)
Also when y = 0, then 2x = 160
=⇒ x = 80, i.e. (80, 0)

Hence (0, 160) and (80, 0) are points on the boundary line 2x + y = 160

Again, let x + 2y = 125


when x = 0 then 2y = 125
=⇒ y = 125/2

also when y = 0 then x = 125


i.e. (125, 0)
Then (0,125/2) and (125, 0) are the points on the boundary line x + 2y= 125

Also solving x + y = 100 and x + 2y = 125 Simultaneously yields x = 75 and y =


25.
i.e. (75, 25)

again solving x + y = 100 and 2x + y = 160 simultaneously yields x = 60 and y =


40.

From figure 2.5, the solutions at the comer points are:

at (0, 160) ; C = 12(0) + 8(160) = 1280


at (60, 40) ; C = 12(60) + 8(40)= 1040
at (75, 25) ; C = 12(75) + 8(25) = 1100
at (125, 0) ; C = 12(125) + 80(0) = 1500

Therefore the optimal solution is C = 1,040 which occurred at x = 60 and y = 40.

12
Figure 4: .

13
Figure 5: .

0.4.2 PECULIARITIES OF THE GEOMETRIC APPROACH


1. Both maximization and minimization problems can be solved by the Geometric
Approach.

2. Both the greater-than-or equal-to (≥) and less- than-or-equal-to (≤) constraints
can be handled without any difficulties.
3. The graphical method can deal with any number of constraints. But as the con-
straints are shown as lines on the same graph, it will be very difficult to read the
graph if the lines on the graph are many. So as the constraints increase, accuracy
decreases.

4. The Geometric Approach cannot handle (or be used to solve) problems involving
more than two decision variables.

0.4.3 SPECIAL CASES OF THE GEOMETRIC APPROACH OF


SOLVING LINEAR PROGRAMMING MODELS.
• REDUNDANCY Whenever there are two constraints, which are actually the same,
it is said that redundancy exists or there is a redundant constraint.

14
For example,

6x + 2y ≤ 80
12x + 4y ≤ 160

In a more general sense, a redundant constraint does not affect the feasible solu-
tion.
Suppose, a linear programming model has the following constraint:

x 1 + x 2 ≥ 100
0.3x 1 + 0.1x 2 ≥ 15
0.1x 1 + 0.05x 2 ≥ 8
0.2x 1 + 0.4x 2 ≥ 25

the second constraint is redundant. If redundancy is detected, strike out the re-
dundant constraint and proceed as usual. Even if it is not detected, there will be
no harm done to the solution.

• UNBOUNDEDNESS There is no limit to the profit that can be made, if the feasi-
ble region of a profit maximization problem is open-ended. To solve the problem
of u:
(i) the fact that the feasible region is unbounded should be stated.
(ii) the model builder should find the constraint which was overlooked, which
would have capped off the feasible region. With this overlooked constraint
added, the analysis continues as usual, since the feasible region will no longer be
open-ended
• INCONSISTENCY suppose a linear programming model has among its con-
straints, the following:
x + y ≥ 10 and x + y ≤ 5.
it should be apparent that there cannot exist any two numbers x and y which can
satisfy the above conditions simultaneously. To solve this problem, care should
be taken to see if there are unintended constraints which could be eliminated. if
all the constraints are intended, then the model builder must decide which con-
straint to eliminate or relax.
• ALTERNATE OPTIMAL SOLUTIONS The solution is not unique, thus, the prob-
lem has more than one solution that optimizes the objective function. Thus, there
are at least two comer points that give the same optimal value. Actually, all are
optimal solutions. So, one of them should be taken and the other relaxed.
For example,
Maximize P = x 1 + x 2

15
subject to:

x 1 + 2x 2 ≤ 24
x 1 + x 2 ≤ 14
5x 1 + 3x 2 ≤ 60
x1 , x2 ≤ 0

The corner points are (0, 0), (12, 0), (9, 5). (4, 10), and (0, 12)
therefore P is given as:
at (0, 0), Z = 0 +0 = 0
at ( 12, 0), Z= 12 + 0 = 12
at (9 ,5), Z = 9 + 5 = 14
at (4, 10), Z = 4 + 10 = 14
at (0, 12), Z = 0 + 12 = 12

Therefore the alternate optimal solutions are:


Z = 14, X 1 = 9, X 2 = 5 and
Z = 14, x 1 = 4, x 2 = 10.

0.4.4 THE SIMPLEX ALGORITHM


While visually appealing, the geometric approach discussed in the previous section is
of limited use; since most practical (real life) problems have more than two variables.
The Simplex Algorithm (method) which systematically finds solutions to equivalent
systems of linear equations provides a remarkably efficient names for obtaining opti-
mal solutions.

DEFINITIONS

(i). A system of linear equations with ’m’ equations and ’n’ variables:

a 11 x 1 + a 12 x 2 + a 13 x 3 ... + a 1n x n = b 1
a 21 x 1 + a 22 x 2 + a 23 x 3 ... + a 2n x n = b 2
a 31 x 1 + a 32 x 2 + a 33 x 3 ... + a 3n x n = b 3
.
.
.
a m1 x 1 + a m2 x 2 + a m3 x 3 ... + a mn x n = b m

Thus:
m X
X n
ai j ∗ x j = b j
i =1 j =1

16
is in canonical form (or is a canonical system of linear equations) if:

(a). m ≤ n

(b). there are "m" distinguished variables, called Basic Variables, such that each basic
variable x i has coefficient one (1) in exactly one equation and coefficients zero (0) in
the other equations and such that each equation contains exactly one basic variable.
The other variables are called non − basic variables,

(ii) SLACK VARIABLES:


these are variables, which are added to a less-than, or equal-to (≤) inequality to take up
any slack between the left and the right hand Sides of the inequality in order to convert
the inequality to equality (equation).

For example:

x + 2y + z ≤10
becomes; x + 2y + z + s = 10
where; ’s’ is a slack variable.

(iii).SURPLUS VARIABLES:
these are variables which are subtracted from a greater-than or equal-to (≥) inequality
to take up any surplus between the right and the left hand sides of the inequality in
order to convert the inequality to equality (or equation).

For example:

x + 2y + z ≥ 10
becomes, x + 2y + z + s = 10
where, ’s’ is a surplus variables.

(iv). ARTIPICIAL VARIABLBS:


those are variables, which have been introduced into an equation in order to ensure that
a basic feasible solution is obtained.Actually, these variables have value zero and so
must be removed from the final solution.

For example:

x + 2y +z = 10
can be written as, x + 2y + z + a = 10
where, variable ’a’ is an artificial variable.

(v) An LP Model is said to be in Standard form if it is in the form:

17
Maximize
n
X
cj ∗ xj
j =1

Subject to,
m X
X n
a i j ∗ x j {≤, =, ≥}b i
i =1 j =1

for every bi ≥ 0, 1 ≤ i ≤ m and x j ≥ 0, 1 ≤ i ≤ n

(vi). THE SIMPLEX TABLEAU:


this is a table for keeping track of the computations of the optimal solution at each
iteration of the simplex method. Consider Table 2.3.

(vii). ITERATION:
this is a process (or an algorithm or method) which repeat itself over and over again
until a certain stopping criterion is met (satisfied).

(viii). THE INITIAL SIMPLEX TABLEAU:


this is the simplex tableau filled with the canonical system of equations, which has been
obtained from the standard form of the LP Model. Consider Table 2.2

Where:

1. C j the row of the objective function of the coefficients decision variables.


2. b j is the right hand side (RHS) values of the constraints.

3. A mat r i x is the "m x n" matrix formed by the coefficients of the variables in the
constraint equation.
4. C B objective function coefficient for each of the basic variables
5. Z j is the row of the decrease in the value of the objective function that will result
if one of the Variables corresponding to the j t h column of the A mat r i x is brought
into the basis.
6. C j - Z j is the row of the net change in the value of the objective function if one
unit of the variable corresponding to the j t h column of the A mat r i x is brought
into the solution. It is called the NET EVALUATION ROW
INSERT TABLE 2.2

Table 2.2 is called the initial simplex tableau. This tableau has been filled with the

18
..

Figure 6:

canonical system of equations.


Where, the variables in the column labelled BASIS are called basic variables. All other
variables in the canonical system are non-basic variables.

(ix). BASIC VARIABLE:


a variable is said to be a basic variable if it occurs once and only once in the whole
system of equations.
And so in the simplex tableau, a variable is said to be a basic variable if it has a coeffi-
cient of one (1) in a row and a coefficient of zero (0) in all other rows.
That is why s 1 , s 2 , s 3 . . . s m are basic variables in the tableau in table 2.2.

Any variable, which is not a basic variable, is said to be a non-basic variable. A


non-basic variable can be made a basic variable through a process known as ROW
OPERATION.
While a variable enters the basis, a variable must leave the basis. Thus; if you have
four basic variables and three non-basic variables, after a row operation, there will still
be four basic and three non-basic variables. Just that if s i , was a basic variable, it may
leave the basis for x j , to enter the basis.

(x) BASIC SOLUTION:


this is a solution which contains at most ’m’ variables that are different from zero and
in which all other variables (n - m) are equal to zero.
Thus; this is a solution obtained from the canonical system of equations or the simplex
tableau when all the non-basic variables are set to zero.

19
(xi) BASIC FEASIBLE SOLUTION:
a basic solution is said to be feasible if none of the constraints are violated (especially
the non - negativity requirement of the constraints)

20
0.5 OPTIMIZING THE BASIC FEASIBLE SOLUTION
This is the process by which a basic feasible solution which in not optimal is made to
become optimal solution. A non-optimal solution is made optimal by elementary row
operations
These two rules govern the row operation:

Rule l: ENTERING BASIC VARIABLE RULE FOR TABLEAU


The entering basic variable as the name implies in the non-basic variable which enters
the basis.
This is the variable which is heading the column in the tableau that contains the most
positive (or negative) value in the C j - Z j row for a maximization (or minimization)
model. Ties are broken arbitrarily.
The column of the entering variable is called the PIVOT COLUMN.

Rule 2: DEPARTING BASIC VARIABLE RULE FOR TABLEAU


The departing basic variable is the basic variable which leaves the basis and becomes
a non-basic variable.
To determine the departing basic variables, locate the pivot column first. If the pivot
column is the j t h column, form the ratios b j /ai j . Ties may be broken arbitrary. The
departing basic variable is the variable corresponding to the smallest positive value of
these ratios. The row associated with the departing basic variable called the PIVOT
ROW.

0.5.1 PIVOTING
The idea of pivoting is simply applyıng an elementary row operation to a matrix. This
is done by;

• selecting the pivot element (entry) multiplying the pivot row with the reciprocal
of the pivot element to convert the pivot element to unity (thus the value one).
THE PIVOT ELEMENT (ENTRY) is the ai j element, which is common to the
pivot row and the pivot column.

• The all other entries in the column of the A mat r i x should be made to go to zero
through elementary row operations.

21
0.6 TERMINATION RULE
After the pivoting has been done, then iteration has been completed for the simplex
method. So a new tableau will be set with the new ai j , b j , C j , basis, Z j , and C j - Z j ,
this new tableau is known as the current simplex tableau. It gives a new basis feasible
solution which may be an optimal solution.
Pivoting is stopped when the optimal solution is reached. One knows that the op-
timum is reached when all the entries in the net evaluation row are non-positive or
non-negative for maximization or minimization models respectively.

Example 1.7
Use the simplex method to solve the model in example 1.6

Solution
Maximize Z = 120x + 100y
Subject to
x+y ≤4
5x + 3y ≤ 15
x, y ≥ 0
This model is in the standard form. Adding slacks s 1 to constraint 1 and s 2 to constraint
2, we form the canonical system of equations.

Maximize Z = 120x + 100y


Subject to
x + y + s1 ≤ 4
5x + 3y + s 2 ≤ 15
x, y, s 1 , s 2 ≥ 0
Setting up the initial simplex tableau, we have:

BASIS x y s1 s2 solution ratio


CB j 120 100 0 0
s1 0 1 1 1 0 4
s2 0 5 3 0 1 15
Zj 0 0 0 0 0
Cj − Zj 120 100 0 0
Table 4:

From this table, the basic feasible solution is Z = 0, s 1 = 4,s 2 = 15, x = y = 0.


This is not the optimum solution since C j − Z j , has entries, Which are positive.

22
The entering basic variable is x since the most positive value in the C j − Z j row is 120
and it corresponds to the column headed (labelled) x. The departing basic variable is s 2
since from the ratios bi /ai j = 15/5 = 3 and 4/1 = 4 gives 3 as the smallest non-negative
ratio and that corresponds to the s 2 row. Hence, the pivot element is 5.

BASIS ↓x y s1 s2 solution ratio


CB j 120 100 0 0 (b j /ai j )
s1 0 1 1 1 0 4 4/1 = 4
← s2 0 5 3 0 1 15 15/5 = 3
Zj 0 0 0 0 0
Cj − Zj 120 100 0 0
Table 5:

Multiplying row 2 (R 2 ) of the A matrix by 1/5, we get;

1 3/5 0 1/5 3 −→(R2 )


Now carrying Out an elementary row operation. (Row 1 minus the new row 2 )

i.e. R 1 - R 2new = 2/5 1 -1/5 1 −→(R1 )

Therefore the current simplex tableau is

BASIS x ↓y s1 s2 solution ratio


CB j 120 100 0 0 (b j /ai j )
←− s 1 0 0 2/5 1 -1/5 1 1/(2/5)
x 120 1 3/5 0 1/5 3 3/(3/5)
Zj 120 72 0 24 360
Cj − Zj 0 28 0 -24
Table 6:

The solution from this tableau is Z = 360, x = 3, s 1 = 1, s 2 = y =0. However, this is


still not the optimal solution since the C - Z row contains a positive entry thus 28.
Therefore, we continue the research for optimal solution. The entry basic variable is y
and the departing basic variable is s 1 since 1/(2/5) = 5/2 and 3/(3/5) = 5
2/5 is therefore the pivot entry.

23
2/5*R 1 −→ R 1new

-3/5*R 1 + R 2 −→ R 2new

BASIS x y s1 s2 solution ratio


CB j 120 100 0 0 (b j /ai j )
y 100 0 1 2/5 -1/2 5/2 5/2
x 120 1 0 -3/2 1/2 3/2 5
Zj 120 100 70 10 430
Cj − Zj 0 0 -70 -10
Table 7:

This is the final simplest tableau for the model since all the entries in the C J − Z j
row are non-positive values. The optimum solution for the model is Z = 430, x = 3/2
and y = 5/2, s 1 = s 2 = 0.

example 2.8

Maximize Z = 32x 1 + 18x 2 + 19x 3


Subject to

2x 1 + x 2 + x 3 ≤ 12
8x 1 + 10x 2 + x 3 ≤ 90
4x 1 + 4x 2 + 3x 3 ≤ 30
x1 , x2 , x3 ≤ 0

Solution

From the cononical system of equations, we get:

Maximize 32x1 + 18x2 + 19x3 =.Z

Subject to 2x1 + x2 + x3 + s1 = 12
8x1 + 10x2 + x3 + s2 =90
4x1 + 4x2 + 3x3 + s3 = 30

x1 , x 2 , x 3 , s 1 , s 2 , s 3 ≥ 0

24
25
0.7 NONSTANDARD FORM OF LP MODELS
From the definition of standard form LP model, it implies that minimization problems
are not in the standard form and if the model contains a "≥" grater than or equal to or
(and) "=" equal to constraints, then that model is not in the standard form.
Any model that is not in the standard form is said to a nonstandard form LP model.

Example 2.9

1. Maximize Z = x 1 − 2x 2
subject to
2x 1 + 5x 2 ≤ 60
x 1 + x 2 ≥ 10
x1 , x2 ≥ 0

2. Maximize Z = x 1 − 2x 2
subject to
2x 1 + 5x 2 ≤ 60
x 1 + x 2 ≥ 10
x1 , x2 ≥ 0

3. Minimize C = 2x 1 − 4x 2
subject to
2x 1 + 3x 2 ≤ 5
x1 − x2 ≤ 4
x1 , x2 ≥ 0

4. Maximize C = −2x 1 + x 2 − 3x 3
subject to
2x 1 + 2x 2 + 3x 3 ≤ 10
2x 1 − x 2 + 3x 3 ≤ 9
x 1 + 3x 2 + 2x 3 ≥ 4
2x 1 − x 2 + 3x 3 ≥ 5
x i ≥ 0; 1 ≤ i ≤ 3

5. Minimize P = 20x 1 + 34x 2 + 36x 3


subject to
5x 1 − 2x 2 + 3x 3 ≥ 8
x 1 − x 2 + 2x 3 = 5
x 1 + 3x 2 + 2x 3 ≤ 12
x i ≥ 0; 1 ≤ i ≤ 3

26
It can be seen from the above example model 1 is in the standard and hence its solution
follows the same partern of the models solved above. However, models 2 to 5 are in
the nonstandard form.
Nonstandard form models can also be solved through so many ways. Two os these
ways(methods) shall be discussed in this study.

0.7.1 THE MODIFIED SIMPLEX METHOD (MSM)


FOR NONSTANDARD MODELS

This model modifies the nonstandard model.


Now to obtain a standard model.

A. For minimization model, multiply the objective function by negative one (-1) and
then maximize the new objective function. Thus from model 3 in Example 29; maxi-
mize C = 2x 1 − 4x 2 must be modified by multiplying through by -1.
Hence the modified model becomes, Z = −2x 1 + 4x 2 where Z = -C.
In this case, after the optimum solution had been obtained, the optimum value to the
original model (Minimization) is the negative of the optimum value obtained from the
modified objective function ( Maximization). Thus after the optimum solution had
been obtained, the value of Z should be negated to give the value of C. That is C= -Z.

B. For a greater than or equal to (≥) constraints, multiply through the constraint by
negative one (-1) to obtain a less than or equal to (≤) constraint. In this, the bi will
become negative values hence the basic solutions will not be a feasible solution. Thus,
the non-negative constraints will be violated. So we will use row operations to remove
these negative entries.

The pivot rules for the MSM are:


(i) Determine a pivot row. This is the row with the most negative entry in the bcol umn

Ties are broken arbitrarily.

(ii) Determine the pivot column. This is the column corresponding to the smallest
non- negative ratio of entries in the bcol umn to tho entries in that row. That means,
form the ratio with the negative entries in the A mat r i x that are in the pivot row.

(iii) Pivot on the pivot entry, which is the entry common to both the pivot row and
column.

(iv) Repeat steps i, ii and iii until there are no negative entries in the bcol umn

Solving the non-standar d models of example 2.9 with the MSM.

2. Given maximize Z = x 1 − 2x 2

27
subject to

2x 1 + 5x 2 ≤ 60
x 1 + x 2 ≥ 10
x1 , x2 ≥ 0

The modified model is:


Maximize Z = x 1 − 2x 2
subject to

2x 1 + 5x 2 ≤ 60
−x 1 − x 2 ≤ −10
x1 , x2 ≥ 0

This the standard form.

solution

28
3. Given
MinimizeC = 2x 1 − 4x 2
subject to

2x 1 + 3x 2 ≤ 5
x1 − x2 ≤ 4
x1 , x2 ≥ 0

The modified model is


Maximize D = −2x 1 + 4x 2
subject to

2x 1 + 3x 2 ≤ 5
x1 − x2 ≤ 4
x1 , x2 ≥ 0

Where D = -C.

Solution

29
Hence x 2 = 5/3, x 1 = 0, D = 20/3, but D = -C, this implies that C = -20/3
Therefore, the solution to the original problem(model) is x 2 = 5/3, x 1 = 0, D = -20/3

C. Two numbers "a" and "b" satisfy a ≤ b and a ≥ b if and only if "a = b".
Therefore for an "equal to" constraint, replace it with two inequality constraints.
thus for the constraint, 2x 1 − 3x 2 + x 3 = 8,
it should be replaced by 2x 1 − 3x 2 + x 3 ≤ 8 and 2x 1 − 3x 2 + x 3 ≥ 8
then the ≥constraint shall be treated as in B.

solution for models in example 2.9


Given
Minimize P = 20x 1 + 34x 2 + 36x 3
subject to

5x 1 − 2x 2 + 3x 3 ≥ 8
x 1 − x 2 + 2x 3 = 5
x 1 + 3x 2 + 2x 3 ≤ 12
x i ≥ 0; 1 ≤ i ≤ 3

The modified model is


Minimize P = 20x 1 + 34x 2 + 36x 3

30
subject to

−5x 1 + 2x 2 − 3x 3 ≤ −8
x 1 − x 2 + 2x 3 ≤ 5
−x 1 + x 2 − 2x 3 ≤ −5
x 1 + 3x 2 + 2x 3 ≤ 12
x i ≥ 0; 1 ≤ i ≤ 3

Solution

31
This is the final tableau and the solution to the original model is x 1 = 11/12, x 2 =
65/12, x 3 = 19/12, P = 747/2.

32
0.8 THE BIG-M METHOD
This is another method for solving Linear Programming problems in non-standard
form. This method introduces three kinds of non-negative variables: slack, Surplus
and artificial variables. The introduction of these variables coverts the non-standard LP
problems into a canonical system of linear equations to which the simplex method can
be applied.

Specifically:

(i) to each "≤" constraint, add a non - negative slack variable.

(ii) to each "≥" constraint, first subtract a non- negative slack variable (or add a surplus
variable) then add an artificial variable.

(iii) to each "=" constraint, add an artificial variable

The artificial variables which have been added to both the ≥ and = constraints actually
have nothing to do with the problem but only to give an initial basic feasible solution
since the artificial variable was added to start the simplex tableau, it has to be out of
the solution out of the solutions before the solution gets to the optimum.
To do this, we assign a very large cost(M) to the artificial variable in the objective func-
tion If the model is a Maximization model, then negative of the large cost is assigned
to each of the artificial variables. However, if the model is a Minimization model, then
positive large cost is assigned to the artificial variables.

0.8.1 STEPS FOR SOLVING A MINIMIZATION MODEL WITH


THE BIG-M METHOD
Step 1. After assigning the positive M to each artificial variable in the objective func-
tion, set up the initial simplex tableau.

Step 2. Select the pivot variable. The objective function is being minimized. There-
fore, it makes sense to select, as the pivot variable, the variable that causes the largest
reduction in the objective function. Thus, the variable associated with the most nega-
tive value in the C j − Z J , row.

Step 3. Select the pivot row. The pivot row is selected in precisely the same man-
ner as before. Thus, the smallest ratio (b j /ai j ).

33
Step 4. Pivot on the pivot-entry and perform row operations to generate new basis.

Step 5. Repeat steps 2,3 and 4 until optimality is reached. The optimal solution is
reached, when every entry in the net evaluation row is non - negative (this is directly
the opposite of the maximization optimality test).

Also the objective function of a minimization model can be multiplied by negative


one (-1) to render the model a maximization model.

Example 2.10

1. solve question 5 of example 2.9 with the BIG-M Method


2. Minimize P = 20x 1 + 34x 2 + 36x 3
subject to

5x 1 − 2x 2 + 3x 3 ≥ 8
x 1 − x 2 + 2x 3 = 5
2x 1 + x 2 + x 3 ≤ 12
x i ≥ 0; 1 ≤ i ≤ 3

Assigning the large cost M, we have:

34

You might also like