0% found this document useful (0 votes)
13 views59 pages

Decision Maths 1 Chapter 7 Simplex Algorithm Updated May 22B

The document provides an overview of the Simplex Algorithm, a method used in linear programming to find optimal solutions to problems defined by systems of linear inequalities. It includes examples of formulating linear programming problems, defining decision variables, objectives, and constraints, as well as the process of transforming inequalities into equations using slack variables. The document emphasizes the importance of the Simplex method in handling complex problems with multiple variables and outlines the steps to determine optimal solutions through vertex analysis.

Uploaded by

1340500277
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)
13 views59 pages

Decision Maths 1 Chapter 7 Simplex Algorithm Updated May 22B

The document provides an overview of the Simplex Algorithm, a method used in linear programming to find optimal solutions to problems defined by systems of linear inequalities. It includes examples of formulating linear programming problems, defining decision variables, objectives, and constraints, as well as the process of transforming inequalities into equations using slack variables. The document emphasizes the importance of the Simplex method in handling complex problems with multiple variables and outlines the steps to determine optimal solutions through vertex analysis.

Uploaded by

1340500277
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/ 59

Decision 1:: The Simplex

Algorithm
Produced by Hannah Watson
[email protected]
& [email protected]

Last modified: 16th May 2022


Decision 1 Overview

1:: Algorithms 2:: Graphs and networks


Sorting and bin What is a graph and how they 3:: Algorithms on graphs
packing. represent things. What algorithms do I need to
be able to apply?
4:: Route inspection
5:: The Travelling Salesman
Find the shortest route 6:: Linear Programming
Find the shortest route
which travels along all How to find an optimal
which visits all places.
roads solution graphically

7:: The simplex algorithm


8:: Critical path analysis
How to find an optimal
solution algebraically. How to plan a project.
Formulating linear programming problems
You need to be able to formulate real life problems as linear programming problems. In
the previous chapter you did this with two-variable situations.

In this chapter you will consider more complicated linear programming problems.
source
To formulate a linear programming problem:

• Define your decision variables


• Write down the objective
• Write down the constraints

The simplex method


involves defining the Don’t be lulled into a false sense of
system of linear security – the Simplex Algorithm isn’t so
inequalities as before, named because of the lack of complexity,
then ‘moving’ along each it is named after a geometric
line, vising vertices trying construction known as a simplex, which
to improve your is a triangle generalised into n-
objective function on dimensions.
each trip. https://en.wikipedia.org/wiki/Simplex_algorithm
Example – text book
A grower specialising in cut flowers is considering cultivating four varieties of the new
‘Sunlip’ flowers, A, B, C and D. He estimates the time, in hours per hectare, taken for each
of the four stages – sowing, thinning, picking and packing for each variety, which is shown
in the table. For this crop he can devote up to 70 hours to sowing, 360 to thinning, 500 to
picking and 550 to packing.
He estimates the total profit, in £/hectare as 67, 63, 71 and 75 respectively.
He has 20 hectares to use and wishes to maximise profit.
Formulate this as a linear programming problem, define your variables, state your
objective and write the constraints as inequalities.
Let 𝑥𝐴 , 𝑥𝐵 , 𝑥𝐶 , 𝑥𝐷 , be the number of
hectares of 𝐴, 𝐵, 𝐶, 𝐷 planted.
Time/ Total time
A B C D
hectare available Maximise
Sowing 3 4 3 5 70 𝑃 = 67𝑥𝐴 + 63𝑥𝐵 + 71𝑥𝐶 + 75𝑥𝐷
Subject to:
Thinning 18 17 19 16 360
3𝑥𝐴 + 4𝑥𝐵 + 3𝑥𝐶 + 5𝑥𝐷 ≤ 70
Picking 20 25 26 22 500 18𝑥𝐴 + 17𝑥𝐵 + 19𝑥𝐶 + 16𝑥𝐷 ≤ 360
20𝑥𝐴 + 25𝑥𝐵 + 26𝑥𝐶 + 22𝑥𝐷 ≤ 550
Packing 24 27 28 23 550
24𝑥𝐴 + 27𝑥𝐵 + 28𝑥𝐶 + 23𝑥𝐷 ≤ 550
Profit 67 63 71 75 𝑥𝐴 + 𝑥𝐵 + 𝑥𝐶 + 𝑥𝐷 ≤ 20
𝑥𝐴 , 𝑥𝐵 , 𝑥𝐶 , 𝑥𝐷 ≥ 0
Further Example
To supplement his diet, Andy wishes to take some Vitatab, Weldo, Xtramin and Yestivit, the
contents of vitamins A, B, C and iron, in mg/tablet are shown in the table.
A B C Iron Andy wishes to take at least 80, 30, 60 and 14 mg of
A, B, C and iron per day respectively.
Vitatab 10 10 20 4
He wants at least 25% of the tablets to be Vitatab and
Weldo 15 20 10 5 to take at least twice as many Weldo and Yestivit.
Xtramin 25 15 15 3 The tablets cost 4, 6, 12, and 7 pence each.
He wishes to minimise the cost. Formulate this as a linear
Yestivit 20 15 20 2 programming problem, define your variables, state your objective and write the
constraints as simplified inequalities with integer coefficients.

Let 𝑥1 , 𝑥2 , 𝑥3 , 𝑥4 be the number of Vitatab, Weldo, Xtramin and Yestivit tablets taken each day.

Minimise: 𝐶 = 4𝑥1 + 6𝑥2 + 12𝑥3 + 7𝑥4 Note: mark schemes are very fussy about how you
define your constraints!
Subject to:
10𝑥1 + 15𝑥2 + 25𝑥3 + 20𝑥4 ≥ 80 𝑥1 ≥ 0.25 𝑥1 + 𝑥2 + 𝑥3 + 𝑥4
10𝑥1 + 20𝑥2 + 15𝑥3 + 15𝑥4 ≥ 30 ⇒ 3𝑥1 − 𝑥2 − 𝑥3 − 𝑥4 ≥ 0
20𝑥1 + 10𝑥2 + 15𝑥3 + 20𝑥4 ≥ 60
4𝑥1 + 5𝑥2 + 3𝑥3 + 2𝑥4 ≥ 14 𝑥2 ≥ 2𝑥4 ⇒ 𝑥2 − 2𝑥4 ≥ 0

𝑥1 , 𝑥2 , 𝑥3 , 𝑥4 ≥ 0
Formulating linear programming problems
To implement The Simplex Algorithm inequalities have to be transformed into equations
using slack variables (so called because they represent the amount of slack between an
actual quantity and the maximum possible value of that quantity.

Example
Rewrite the inequalities from slide 4 as equations using slack variables, 𝑟, 𝑠, 𝑡, 𝑢, 𝑣,

3𝑥𝐴 + 4𝑥𝐵 + 3𝑥𝐶 + 5𝑥𝐷 ≤ 70 3𝑥𝐴 + 4𝑥𝐵 + 3𝑥𝐶 + 5𝑥𝐷 + 𝑟 = 70


18𝑥𝐴 + 17𝑥𝐵 + 19𝑥𝐶 + 16𝑥𝐷 ≤ 360 18𝑥𝐴 + 17𝑥𝐵 + 19𝑥𝐶 + 16𝑥𝐷 + 𝑠 = 360
20𝑥𝐴 + 25𝑥𝐵 + 26𝑥𝐶 + 22𝑥𝐷 ≤ 550 20𝑥𝐴 + 25𝑥𝐵 + 26𝑥𝐶 + 22𝑥𝐷 + 𝑡 = 550
24𝑥𝐴 + 27𝑥𝐵 + 28𝑥𝐶 + 23𝑥𝐷 ≤ 550 24𝑥𝐴 + 27𝑥𝐵 + 28𝑥𝐶 + 23𝑥𝐷 + 𝑢 = 550
𝑥𝐴 + 𝑥𝐵 + 𝑥𝐶 + 𝑥𝐷 ≤ 20 𝑥𝐴 + 𝑥𝐵 + 𝑥𝐶 + 𝑥𝐷 + 𝑣 = 20
𝑥𝐴 , 𝑥𝐵 , 𝑥𝐶 , 𝑥𝐷 ≥0 𝑥𝐴 , 𝑥𝐵 , 𝑥𝐶 , 𝑥𝐷 , 𝑟, 𝑠, 𝑡, 𝑢, 𝑣 ≥ 0

Note – it is a condition of The


Simplex Algorithm that the
slack variables must be non-
negative.
Exercise 7A
Pearson Decision 1, Page 174
The simplex method
In the previous chapter you found optimal solutions by considering the vertices of the
feasible region. With two-variable problems the feasible region can be represented as an
area on a graph. With three variables, you would need to represent the feasible region as
a 3D polyhedron. As the number of variables increase, it becomes impossible to visualise
graphically, the simplex method can be applied with n-variables.

The simplex algorithm starts at one vertex, and moves between vertices in sequence,
increasing the objective function and one of the variables each time, until it reaches an
optimal solution.

The simplex method allows you to:


• Determine if a particular vertex, on the edge of the feasible region, is optimal
• Decide which adjacent vertex you should move to in order to increase the value of the
objective function

Slack variables are essential when using the simplex algorithm


Example – the lines representing slack variables = 0
Consider the following linear programming problem:
Maximise: 𝑃 = 3𝑥 + 2𝑦
Subject to: 5𝑥 + 7𝑦 + 𝑟 = 70
10𝑥 + 3𝑦 + 𝑠 = 60
𝑥, 𝑦, 𝑟, 𝑠 ≥ 0
https://www.desmos.com/calculator/ppqb2fqgqi

Notice how the line 10𝑥 + 3𝑦 = 60


Is also the line for 𝑟 = 0,
equivalently the line 5𝑥 + 7𝑦 = 70 is also the
line 𝑠 = 0.

𝑥&𝑟 = 0

𝑠&𝑟 =0

𝑠&𝑦 =0 Notice at each vertex two of the four


𝑥&𝑦 = 0 variables/slack variables are zero.
Example Back to slide 17

How to use the algebraic simplex algorithm. So we hit 𝑦 = 0, 𝑠 = 0 first.

Maximise 𝑃 = 3𝑥 + 2𝑦 Find out if we have hit the optimum point.


subject to, 5𝑥 + 7𝑦 + 𝑟 = 70
10𝑥 + 3𝑦 + 𝑠 = 60 3 𝑠
𝑥, 𝑦, 𝑟, 𝑠 ≥ 0 2 ÷ 10 = 𝑥 + 𝑦+ =6 5
10 10

Initially, Use 5 to eliminate 𝑥 from 1 &(3)


5𝑥 + 7𝑦 + 𝑟 = 70 (1)
10𝑥 + 3𝑦 + 𝑠 = 60 2 11 1
1 −5 5 = 𝑦 + 𝑟 − 𝑠 = 40 4
𝑃 − 3𝑥 − 2𝑦 =0 (3) 2 2
Start at (0,0), where 𝑥, 𝑦 = 0 3 1
𝑥 + 𝑦 + 𝑠=6 5
Test the objective function 10 10
𝑃 = 3𝑥 + 2𝑦 ⇒ 𝑃 = 0, this is not optimal 11 3
3 +3 5 =𝑃 − 𝑦 + 𝑠 = 18 (6)
10 10
We see from our objective that increasing 𝑥 or 𝑦 will Look at (6), at 𝑦 = 𝑠 = 0, 𝑃 = 18 so our current
increase 𝑃, we will increase 𝑥 (moving along the 𝑥-axis), profit is 18.
as this will give a greater increase in 𝑃. 11 3
𝑃 = 18 + 𝑦− 𝑠
10 10
Move along until you hit 𝑟 = 0 or 𝑠 = 0 Increasing 𝑦 will increase 𝑃, increasing 𝑠, will
decrease 𝑃.
1 ⇒ 5𝑥 + 7 × 0 + 0 = 70 ⇒ 𝑥 = 14
2 ⇒ 10𝑥 + 3 × 0 + 0 = 60 ⇒ 𝑥 = 6 So keep s = 0 and increase 𝑦 (travel along 𝑠 = 0)
Example
Moving along 𝑠 = 0, we will either get to 1 1
𝑠 = 𝑟 = 0 or 𝑥 = 𝑠 = 0 next, so try these in 𝑃 = 26 − 𝑟 − 𝑠
5 5
4 & (5) to see which gives the lower 𝑦-value.
11 1 3
4 ⇒ 𝑦 + 0 − × 0 = 40 ⇒ 𝑦 = 7 At this vertex 𝑟 = 𝑠 = 0, so 𝑃 = 26
2 2 11
3 1
5 ⇒0 + 𝑦 + × 0 = 6 ⇒ 𝑦 = 20 We can see that if we increase 𝑟 or 𝑠 we
10 10
We can see that we get to 𝑠 = 𝑟 = 0 first. will reduce profit, so we have reached
the optimal solution.
3
At the vertex 𝑠 = 𝑟 = 0, 𝑦 = 7 11, we could use
these values to calculate 𝑃, but we need 𝑃 in terms 𝑃 = 26 when
42 80
of 𝑟 & 𝑠 so see what the effect of increasing these 𝑥 = 11 , 𝑦 = 11 , 𝑟 = 0, 𝑠 = 0
variables would be. So, eliminate 𝑦 from 5 & 6

11 2 1 80
4 ÷ = 𝑦+ 𝑟− 𝑠= 7
2 11 11 11
3 3 7 42
5 − 7 = 𝑥 − 𝑟+ 𝑠= 8
10 55 55 11
11 1 1
6 + 7 = 𝑃 + 𝑟 + 𝑠 = 26 (9)
10 5 5
Example with three (non-slack) variables.
Maximise, 𝑃 = 10𝑥 + 12𝑦 + 8𝑧 5
So we reach (0, 2 , 0), 𝑟 = 0 first.
subject to 2𝑥 + 2𝑦 ≤ 5
5𝑥 + 3𝑦 + 4𝑧 ≤ 15 Eliminate 𝑦 to see if increasing 𝑥, 𝑧, 𝑟 would
𝑥, 𝑦, 𝑧 ≥ 0
increase 𝑃.
Introduce slack variables 𝑟 & 𝑠 and form 1 5
equations: 1 ÷2= 𝑥+𝑦+ 𝑟 = 4
2 2
2𝑥 + 2𝑦 +𝑟 =5 1 3 15
2 −3 4 = 2𝑥 + 4𝑧 − 𝑟 + 𝑠 = 5
5𝑥 + 3𝑦 + 4𝑧 + 𝑠 = 15 2 2 2
𝑃 − 10𝑥 − 12𝑦 − 8𝑧 =0 3 3 + 12 4 = 𝑃 + 2𝑥 − 8𝑧 + 6𝑟 = 30 (6)

𝑃 = 30 − 2𝑥 + 8𝑧 − 6𝑟
𝑃 = 10𝑥 + 12𝑦 + 8𝑧
We can increase 𝑃 by increasing 𝑧.
We can see that increasing either 𝑥 or 𝑦 or
𝑧 would increase 𝑃, choose to increase 𝑦 as
Note (4) has no 𝑧 term so won’t give a value
this will give the greatest increase in 𝑃.
for 𝑧.
Increase 𝑦 will get us to either
From (5) when 𝑥 = 𝑟 = 𝑠 = 0
𝑥 = 𝑧 = 𝑟 = 0 𝑜𝑟 𝑥 = 𝑧 = 𝑠 = 0
15 15
5 4𝑧 = ⇒𝑧=
2 8
1 ⇒ 0 + 2𝑦 + 0 = 5 ⇒ 𝑦 =
2
2 ⇒ 0 + 3𝑦 + 0 + 0 = 15 ⇒ 𝑦 = 5
Example with 3 (non-slack) variables
1 3 1 15
5 ÷4= 𝑥+𝑧− 𝑟+ 𝑠 = 7
2 8 4 8

Eliminate 𝑧 from (4) and (6)

1 5
4 = 𝑥+𝑦 + 𝑟 = 4
2 2
1 3 1 15
7 = 𝑥 +𝑧− 𝑟+ 𝑠 = 7
2 8 4 8
6 + 8 7 = 𝑃 + 6𝑥 + 3𝑟 + 2𝑠 = 45 (8)

𝑃 = 45 − 6𝑥 − 3𝑟 − 2𝑠

We can see that increasing 𝑥, 𝑟, 𝑠 will decrease profit so I’m not sure this graph adds
we have found the optimal solution. much, but I include it to
illustrate the point that what
𝑃 = 45 when we have done in 3D is the
5 15 same process we went through
𝑥 = 0, 𝑦 = ,𝑧 = , 𝑟 = 0, 𝑠 = 0 in 2D.
2 8
The fact that 𝑟 = 𝑠 = 0 tells us that the https://www.geogebra.org/3d/
first and 2nd constraint are at capacity. s4aaucpb
Tableau
You can greatly simplify the method outlined in the examples by using a table called a
simplex tableau.

In your exam you might need to use a simplex tableau to solve linear programming
problems with a maximum of four variables and four constraints (in addition to any non-
negativity constraints). Problems could require you either maximise or minimise an
objective function.

• Any variables in a simplex tableau, that are not basic variables, have the value 0.

• The basic feasible solutions is where all the constraints are satisfied, but applying the
simplex method will lead to an improved solution.

• The simplex method always starts from a basic feasible solution, at the origin, and then
progresses with each iteration to an adjacent point within the feasible region unit the
optimal solution is found.
Example – Maximising
Solve the following linear programming problem (seen previously) using
simplex tableaux.
Maximise: 𝑃 = 3𝑥 + 2𝑦
Subject to: 5𝑥 + 7𝑦 + 𝑟 = 70
10 + 3𝑦 + 𝑠 = 60
𝑥, 𝑦, 𝑟, 𝑠 ≥ 0

Our initial tableau is Basic 𝑥 𝑦 𝑟 𝑠 Value


Variable

𝑟 5 7 1 0 70
𝑠 10 3 0 1 60
𝑃 -3 -2 0 0 0

The ‘basic variable’ column indicates the variables that are not currently at zero. Initially
you start at the vertex (0, 0).

Any variables in a simplex tableau, that are not basic variables have the value 0.
Example cont.
Taking (0, 0) as the start,
Basic 𝑥 𝑦 𝑟 𝑠 Value
𝑥 = 𝑦 = 0, so reading across the
Variable
rows gives us
𝑟 = 70, 𝑠 = 60 and 𝑃 = 0. 𝑟 5 7 1 0 70
This is called the basic feasible 𝑠 10 3 0 1 60
solution – all the constraints are
𝑃 -3 -2 0 0 0
satisfied by applying the simplex
method will lead to an improved
solution.
Scan the objective (bottom) row for the most negative number (unless the exam question
asks you to select a different column). This gives the pivot column as the x column.

For each of the other rows, calculate the θ values where


𝜃 = (the term in the value column) ÷ (the term in the pivot column)
Basic 𝑥 𝑦 𝑟 𝑠 Value 𝜃 values
Variable Slide 11 for
𝑟 5 7 1 0 70 70 ÷ 5 = 14 a recap of
how we did
𝑠 10 3 0 1 60 60 ÷ 10 = 6 this
previously.
𝑃 -3 -2 0 0 0
Slide 11.
Example cont.
Basic 𝑥 𝑦 𝑟 𝑠 Value 𝜃 values Selecting the row
Variable
containing the smallest
𝑟 5 7 1 0 70 70 ÷ 5 = 14 positive 𝜃 value (known
as the pivot row).
𝑠 10 3 0 1 60 60 ÷ 10 = 6
Divide this row by the
𝑃 -3 -2 0 0 0 pivot value, to create the
pivot row.
Basic 𝑥 𝑦 𝑟 𝑠 Value Row operations If you select a negative or
Variable zero 𝜃 value, you get no
more marks for the
𝑟 5 7 1 0 70 question .

𝒙 1 3 0 1 6 R2 ÷ 10 Relabel basic variable.


10 10
𝑃 -3 -2 0 0 0 You can label the Row
Operations based on the
original value, so this
Basic 𝑥 𝑦 𝑟 𝑠 Value Row operations 5
could be 𝑅1 − 𝑅2
Variable 10

𝑟 0 11 1 1 40 R1 -5R2
-2
2
3 1
Use this pivot row to
𝒙 1 0 6
10 10 eliminate 𝑥 from each of
𝑃 0 11
- 10 0 3 18 R3+3R2 the other rows.
10
Example cont.
Basic 𝑥 𝑦 𝑟 𝑠 Value
Repeat the process. Variable
First look for most 𝑟 0 11 1 1 40
-
negative entry in 3
2 2
1
objective, giving pivot 𝒙 1 0 6
10 10
𝑃 0 11 0 3 18
column. -
10 10

Basic 𝑥 𝑦 𝑟 𝑠 Value 𝜃 values


Second calculate the Variable
new 𝜃 values. 𝑟 0 11 1 1 40 11 80
- 40 ÷ d =
2 2 2 11
𝒙 1 3 0 1 6 3
10
6÷ d = 20
10 10

𝑃 0 11 0 3 18
-
10 10

Basic 𝑥 𝑦 𝑟 𝑠 Value 𝜃 values


Third select smallest,
Variable
positive 𝜃 values, this 𝑟 0 11 1 1 40 11 80
- 40 ÷ d =
becomes the next pivot 2 2 2 11
𝒙 1 3 0 1 6 3
row. 10
6÷ d = 20
10 10

𝑃 0 11 0 3 18
-
10 10
Example cont.
Basic 𝑥 𝑦 𝑟 𝑠 Value Row operations
Fourth divide the row Variable
by the pivot. Remember 2 1 80 11
𝑦 0 1 - R1 d
÷
to change the basic 11 11 11 2
variable. 𝑥 1 3 0 1 6
10 10

𝑃 0 11 0 3 18
-
10 10
Finally, eliminate the Basic 𝑥 𝑦 𝑟 𝑠 Value Row operations
pivot term from the Variable
other two rows, using 𝑦 0 1 2 1 80
11
- 11
11
the pivot row to do so. 𝑥 1 0 3 7 42 3
− R2 -d R1
Here, eliminate 𝑦 from 55 55 11 10

the two 𝑥 and 1 1 11


𝑃 0 0 26 R3 +d R1
𝑃 columns. 5 5 10

All numbers in the 𝑃 = 26


objective row are non- 42
𝑥 =
negative so we have 11
reached the optimal 80 d
𝑦 =
solution. 11
𝑟 = 0
𝑠 = 0
Tableau
Using a simplex tableau to solve a maximising linear programming problem, where the
constraints are given as inequalities.
1. Draw the tableaux. (You need a basic variable column on the left, one column for each
variable, including the slack, and a value column. You need one row for each
constraint and the bottom row for the objective function.
2. Create the initial tableau. (Enter the coefficient of the variable in the appropriate
column and row)
3. Look along the objective row for the most negative entry: this indicates the pivot
column.
4. Calculate the 𝜃 values, for each of the constraint rows, where
𝜃 = (the term in the value column) ÷ (the term in the pivot column)
5. Select the row with the smallest, positive 𝜃 value to become the pivot row*
6. The element in the pivot row and pivot column is the pivot
7. Divide the row found in step 5 by the pivot and change the basic variable at the start
of the row to the variable at the top of the pivot column. This is now the pivot row.
8. Use the pivot row to eliminate the pivot’s variable from the other rows. This means
that the pivot column now contains one 1 and zeros.
9. Repeat steps 3-8 until there are no more negative number sin the objective row.
10. The tableau is now optimal and the non-zero values can be read off using the basic
variable column and value column.
* If all 𝜃 values are negative or zero, this relates geometrically to an unbounded region so no optimal solution can be found – this came up in
the Mock Set 1 Question 9 from Edexcel.
Example - Minimising
The steps for solving a minimising linear programming problem are identical to those
given on the previous slide, apart from:
• First, define a new objective function that is the negative of the original objective
function
• After you have maximised this new objective function, write your solution as the
negative of this value, which will minimise the original objective function.
Minimise 𝑃 = 3𝑥 − 𝑦 As we are minimising….
Subject to: 𝑃 = 3𝑥 − 𝑦
2𝑥 + 𝑦 ≤ 12 Define 𝑄 = −𝑃 = −3𝑥 + 𝑦
𝑥 + 4𝑦 ≤ 8
𝑥 ≥ 0, 𝑦 ≥ 0
Then our initial tableau is

Our equations are… Basic 𝑥 𝑦 𝑟 𝑠 Value


Variable
2𝑥 + 𝑦 + 𝑟 = 12
𝑟 2 1 1 0 12
𝑥 + 4𝑦 + 𝑠 = 8
𝑄 + 3𝑥 − 𝑦 = 0 𝑠 1 4 0 1 8
𝑄 3 -1 0 0 0
Example cont.
Taking (0, 0) as the Basic 𝑥 𝑦 𝑟 𝑠 Value 𝜃 values
start, 𝑥 = 𝑦 = 0, so Variable
reading across the rows
gives us 𝑟 2 1 1 0 12 12 ÷ 1 =
𝑟 = 12,
12
𝑠 = 8&𝑄 = 0
𝑠 1 4 0 1 8 8 ÷ 4 =2

𝑄 3 -1 0 0 0

The smallest positive Basic 𝑥 𝑦 𝑟 𝑠 Value 𝜃 values


𝜃 value is 2 in row 2, so
Variable
this becomes the pivot
row.
𝑟 2 1 1 0 12 12 ÷ 1 =
12
𝑠 1 4 0 1 8 8 ÷ 4 =2
The value in the pivot
column and pivot row is 𝑄 3 -1 0 0 0
4 which becomes the
pivot.
Example cont.
Basic 𝑥 𝑦 𝑟 𝑠 Value Row
Variable operations

𝑟 2 1 1 0 12

𝑦 1 1 0 1 2 R2 ÷ 4
4 4
𝑄 3 -1 0 0 0

Basic 𝑥 𝑦 𝑟 𝑠 Value Row


Variable operations

𝑟 7 0 1 1 10 R1 – R2

4 4
𝑦 1 1 0 1 2
4 4
𝑄 13 0 0 1 2 R3 + R2
4 4
There are no negative values in the objective row, so the solution is optimal.
Maximum value of 𝑄 = 2, when 𝑥 = 0 𝑦 = 2 𝑟 = 10 𝑠 = 0
So the minimum value 𝑜𝑓 𝑃 = −2, when 𝑥 = 0 𝑦 = 2 𝑟 = 10 𝑠 = 0
Three variable tableau (example from slide 13)
Maximise, 𝑃 = 10𝑥 + 12𝑦 + 8𝑧
subject to 2𝑥 + 2𝑦 ≤ 5
5𝑥 + 3𝑦 + 4𝑧 ≤ 15
𝑥, 𝑦, 𝑧 ≥ 0

Introduce slack variables 𝑟 & 𝑠 and form equations:


2𝑥 + 2𝑦 +𝑟 =5 1
5𝑥 + 3𝑦 + 4𝑧 + 𝑠 = 15 2
𝑃 − 10𝑥 − 12𝑦 − 8𝑧 =0 3

𝑃 = 10𝑥 + 12𝑦 + 8𝑧

Basic 𝑥 𝑦 𝑧 𝑟 𝑠 Value
Variable

𝑟 2 2 0 1 0 5

𝑠 5 3 4 0 1 15

𝑷
𝑃 -10 -12 -8 0 0 0
Three variable tableau (example from slide 13)
Basic Variable 𝑥𝑥 𝑦𝑦 𝑧 𝑟 𝑠 Value 𝜽
𝑟 22 22 0 1 0 5 5
= 2.5
2
𝑠 55 33 4 0 1 15 15
=5
3
𝑷 -10
-10 -12
-12 -8 0 0 0

Basic Variable 𝑥 𝑦 𝑧 𝑟 𝑠 Value Row


operation
𝒚 1 1 0 1Τ2 0 2.5 R1÷ 2
𝑠 5 3 4 0 1 15 R2
𝑃 -10 -12 -8 0 0 0 R3

Basic Variable 𝑥 𝑦 𝑧 𝑟 𝑠 Value Row


operation
𝑦 1 1 0 1Τ2 0 2.5
𝑠 2 0 4 1 1 1 R2-3R1
−1 7
2 2
𝑃 2 0 -8 6 0 30 R3+12R1
Three variable tableau (example from slide 13)
Basic
Basic Variable
Variable 𝑥𝑥 𝑦𝑦 𝑧𝑧 𝑟𝑟 𝑠𝑠 Value
Value 𝜽𝜽 values
values

𝑦𝑦 11 11 00 11ΤΤ22 00 11 111
222 ÷ ÷
÷000 →

→∞∞

22 222
22
𝑠𝑠 22 00 44 11 11 11 111 777
777 ÷ ÷
÷444 =
=
= 111
−1
−1 77 222 888
22 22
𝑃𝑃 22 00 -8
-8 66 00 30
30
Basic Variable 𝑥 𝑦 𝑧 𝑟 𝑠 Value Row
Operations
𝑦 1 1 0 1Τ2 0 1 R1
2
2
𝒛 1 0 1 3 1 7 R2÷ 4
− 1
2 8 4 8
𝑃 2 0 -8 6 0 30 R3
Basic Variable 𝑥 𝑦 𝑧 𝑟 𝑠 Value Row
Operations
𝑦 1 1 0 1Τ2 0 1 No
2
2 change
𝑧 1 0 1 3 1 7
− 1
2 8 4 8
𝑃 6 0 0 3 2 45 R3+8R2
Three variable tableau (example from slide 13)
Basic Variable Value
The optimal solution is
𝑦 1 𝑃 = 45,
2
2 𝑥=0
1
𝑧 7 𝑦=2
1 2
8 7
𝑧=1
8
𝑃 45 𝑟=0
𝑠=0

Reducing Tableaux:
b) Verify your solution with the original problem. You can reduce the
amount of tableaux
10𝑥 + 12𝑦 + 8𝑧 = 0 + 30 + 15 = 45 = 𝑃 ✓ you write by
combining all the row
2𝑥 + 2𝑦 = 0 + 5 = 5 ≤ 5 ✓ operations into one.
1 1
3𝑥 + 3𝑦 + 4𝑧 = 0 + 7 2 + 7 2 = 15 ≤ 15 ✓ In an exam you will be
𝑥, 𝑦, 𝑧 ≥ 0 ✓ given sufficient
tableaux for the full
non-reduced solution.
Test your understanding – Edexcel SAMS
Ctd…
Ctd……
Ctd……!
Exercise 7B
Pearson Decision 1, Page 195
Problems requiring integer solutions
You can use the simplex tableau method to solve linear programming problems requiring
integer solutions. You need to consider integer-valued points near your optimal solution.

When integer solutions are needed, test points around the optimal solution to find a set
of points which fits the constraints and gives a maximum for the objective function. This
is exactly the same method which was used in AS Linear programming, it’s included here
just to make sure you haven’t forgotten about it!
Example
Solve the linear programming problem from eg. 8, given that
integer solutions are required.

Maximise 𝑃 = 3𝑥 + 2𝑦
subject to, 5𝑥 + 7𝑦 ≤ 70
10𝑥 + 3𝑦 ≤ 60
𝑥, 𝑦 ≥ 0
42 9 80 3
In a previous example, we found the following solution 𝑃 = 26, 𝑥 = 11 = 3 11 , 𝑦 = 11 = 7 11
We need to test points around this optimal solution

Point 5𝑥 + 7𝑦 ≤ 70 10𝑥 + 3𝑦 ≤ 60 In feasible 𝑃 = 3𝑥 + 2𝑦


region?
(3, 7) 15 + 49 ≤ 70 30 + 21 ≤ 60 Yes 9 + 14 = 23
(3, 8) 15 + 56 > 70 No
(4, 7) 20 + 49 ≤ 70 40 + 21 > 60 No
(4, 8) 20 + 56 > 70 No
Test your understanding

Solve the linear programming problem from eg. 10, given that integer solutions are required.

Maximise 𝑃 = 10𝑥 + 12𝑦 + 8𝑧

Subject to :
2𝑥 + 2𝑦 ≤ 5
5𝑥 + 3𝑦 + 4𝑧 ≤ 15
𝑥, 𝑦, 𝑧 ≥ 0

Point 2𝑥 + 2𝑦 ≤ 5 5𝑥 + 3𝑦 + 4𝑧 ≤ 15 In feasible 𝑃 = 10𝑥 + 12𝑦 + 8𝑧


region?
(0, 2, 1) 0+4<5 0 + 6 + 4 < 15 Yes 0 + 24 + 8 = 32
(0, 2, 2) 0+4<5 0 + 6 + 8 < 15 Yes 0 + 24 + 16 = 40
(0, 3, 1) 0+6>5 No
(0, 3, 2) 0+6>5 No
Exercise 7C
Pearson Decision 1, Page 197
Two-stage simplex method
The simplex method we just looked at only works when all the constraints, other than the
non-negativity conditions, are ≤ constraints. These are converted into equations using
slack variables and the method involves starting at the origin as the basic feasible solution
and improving this solution systematically.

Problems that include ≥ constraints, have no obvious basic feasible solution, since the
origin is not in the feasible region. You could convert the inequality 𝑥 + 3𝑦 ≥ 10 into an
equation by subtracting a variable, s, giving

𝑥 + 3𝑦 – 𝑠 = 10 where 𝑠 ≥ 0

s is a surplus variable. This doesn’t solve the problem of using the simplex method with 𝑥
and 𝑦 as non-basic variables. This would require 𝑥 = 𝑦 = 0, giving – 𝑠 = 10, which
makes s negative. To avoid this problem, a new type of variable called an artificial variable
is introduced

𝑥 + 3𝑦 – 𝑠 + 𝑎 = 10 where 𝑠, 𝑎 ≥ 0

This constraint can now be written in a simplex tableau, using 𝑥, 𝑦 and 𝑠 as non-basic
variables and 𝑎 as a basic variable with value 10.
Example Slide 40

Use surplus and artificial variables to write the following inequalities as equations.

3𝑥 − 2𝑦 ≥ 7
4𝑥 + 5𝑦 − 3𝑧 ≥ 9
3𝑥 – 2𝑦 – 𝑠1 + 𝑎1 = 7

4𝑥 + 5𝑦 – 3𝑧 – 𝑠2 + 𝑎2 = 9

The two-stage simplex method for problems that include ≥ constraints:

1. Use slack, surplus and artificial variables, as necessary, to write all the constraints as
equations
2. Define a new objective function to minimise the sum of all the artificial variables
3. Use the simplex method to solve this problem
4. If the minimum sum of the artificial values is 0 then the solution found is a basic
feasible solution of the original problem, which is then the starting point for the
second stage. Use the simplex method again to solve this problem.
5. If the minimum sum of the artificial variables is not 0 then the original problem has no
feasible solution.
Example
Maximise 𝑃 = 3𝑥 − 2𝑦 + 𝑧 Converting the inequalities into equations:
Subject to: 𝑥 + 𝑦 + 2𝑧 + 𝑠1 = 10
𝑥 + 𝑦 + 2𝑧 ≤ 10 2𝑥 – 3𝑦 + 𝑧 – 𝑠2 + 𝑎1 = 5
2𝑥 − 3𝑦 + 𝑧 ≥ 5 𝑥 + 𝑦 – 𝑠3 + 𝑎2 = 8
𝑥+𝑦 ≥8
𝑥, 𝑦, 𝑧 ≥ 0 Let 𝐼 = − (𝑎1 + 𝑎2)

Substituting for a1 and a2 from the equations above, gives


𝐼 = −(13 – 3𝑥 + 2𝑦 – 𝑧 + 𝑠2 + 𝑠3)
Or 𝐼 − 3𝑥 + 2𝑦 – 𝑧 + 𝑠2 + 𝑠3 = −13
Giving the initial tableau …
Basic
Basic 𝑥x 𝑦y 𝑧z 𝑠s11 s𝑠22 s𝑠33 a𝑎11 a𝑎22 Value
Value θθ value
value
Variable
Variable
𝑠s11 1 1 2 1 0 0 0 0 10 10

𝑎
a11 2 -3 1 0 -1 0 1 0 5 5
2
a𝑎22 1 1 0 0 0 -1 0 1 8 8

𝑃
P -3 2 -1 0 0 0 0 0 0 0

𝐼I -3 2 -1 0 1 1 0 0 -13 13
Example
Basic
Basic 𝑥𝑥 𝑦𝑦 𝑧𝑧 𝑠𝑠11 𝑠𝑠22 𝑠𝑠33 𝑎𝑎11 𝑎𝑎22 Value
Value 𝜃𝜃 value
value 𝑥𝑥
Variable
Variable
𝑠𝑠11 0 5 3 1 1 0 1 0 15 R1 – R2 3
-
2 2 2 2 2
𝑥 1 3 1 0 1 0 1 0 5 R2÷ 2 - ve
-2 -2
2 2 2
𝑎𝑎22 0 5 1 0 1 -1 1 1 11 R3 – R2 2.2
− −
2 2 2 2 2
𝑃
𝑃 0 5 1 0 3 0 3 0 15 R4 + 3R2 - ve
- -
2 2 2 2 2
𝐼𝐼 0 5 1 0 1 1 3 0 11 R5 + 3R2
- - -
2 2 2 2 2

Basic
Basic 𝑥𝑥 𝑦𝑦 𝑧𝑧 𝑠𝑠11 𝑠𝑠22 𝑠𝑠33 𝑎𝑎11 𝑎𝑎22 Value
Value Row
Row
Variable
Variable Operation
Operation
𝑠𝑠11 0 0 2 1 0 1 0 -1 2 R1 – 2.5R3 𝐼 = 0 so a
basic
𝑥 1 0 1 0 1 3 1 3 29 R2 + 1.5R3 feasible
-5 -5
5 5 5 5 solution
𝑦𝑦 0 1 1 0 1 2 1 2 11 5
− - − R3÷ has been
5 5 5 5 2
5 5
R4 + 2.5R3
found for
𝑃
𝑃 0 0 0 0 -1 -1 1 1 13
the original
𝐼𝐼 0 0 0 0 0 0 1 1 0 R5 + 2.5R3 problem
Point 4
Example
Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 Value The basic feasible
Variable solution for the second
𝑠1 0 0 2 1 0 1 2 stage is:
29
𝑥 1 0 1 0 1 3 29 𝑥 = 5
- - 11
5 5 5 5
1 1 2 11 𝑦 = 5
𝑦 0 1 0

5 5
- 5 𝑠1 = 2
5
𝑃 0 0 0 0 -1 -1 13 𝑧 = 𝑠2 = 𝑠3 = 0

Continuing the same way (eliminating 𝑠2 before 𝑠3 ), produces the following tableaux:

Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 Value Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 Value


Variable Variable
𝑠1 0 0 2 1 0 1 2 𝑠3 0 0 2 1 0 1 2
𝑥 1 1 0 0 0 -1 8 𝑥 1 1 2 1 0 0 10
𝑠2 0 5 -1 0 1 -2 11 𝑠2 0 5 3 2 1 0 15

𝑃 0 5 -1 0 0 -3 24 𝑃 0 5 5 3 0 0 30

Finally, there are no negative values in the bottom, row, so the optimal solution has been
found. 𝑃 = 30, when 𝑥 = 10, 𝑠2 = 15, 𝑠3 = 2, 𝑦 = 𝑧 = 𝑠1 = 0
Test your understanding – Edexcel Mock paper
Exercise 7D
Pearson Decision 1, Page 204
Big-M Method Slide 53 Slide 56

The first stage of the two-stage simplex method involves minimising the sum of the
artificial variables. If there is a feasible solution then this sum will be zero. The Big-M
method involves a different but equivalent approach, which again, leads to the sum of the
artificial variables being zero.

In the Big-M method,𝑀 is used to represent an arbitrarily larger number. This guarantees
that a term such as 𝑀 − 100 will be positive and a term such as 75 – 0.5𝑀 will be
negative. You can compare terms involving M in order to select the pivot column.

1) Introduce a slack variable for each constraint of the form ≤


2) Introduce a surplus variable and an artificial variable for each constraint of the
form ≥.
3) For each artificial variable 𝑎1 , 𝑎2 , 𝑎3 , … Subtract 𝑀(𝑎1 + 𝑎2 + 𝑎3 + ⋯ )from the
objective function where 𝑀 is an arbitrarily large number.
4) Eliminate the artificial variables from your objective function so that the
variables remaining in your objective function are non-basic variables.
5) Formulate an initial tableau, and apply the simplex method in the normal way.

Explain the significance of M within this tableau?


‘M is an arbitrarily large number’ is the exact phrase which is required by this question.
Example
Sovle the following linear programming problem using the Big-M method.

Maximise 𝑃 = 𝑥 − 𝑦 + 𝑧,
Subject to:
2𝑥 + 𝑦 + 𝑧 ≤ 20
𝑥 − 2𝑦 − 𝑧 ≤ 7
𝑥≥4
𝑥, 𝑦, 𝑧 ≥ 0

Writing out the inequalities as equations using slack, surplus and artificial variables:
2𝑥 + 𝑦 + 𝑧 + 𝑠1 = 20
𝑥 – 2𝑦 – 𝑧 + 𝑠2 = 7
𝑥 – 𝑠3 + 𝑎1 = 4

𝑃 = 𝑥 – 𝑦 + 𝑧 – 𝑀𝑎1 where 𝑎1 = 4 – 𝑥 + 𝑠3

This gives
𝑃 = 𝑥 – 𝑦 + 𝑧 – 𝑀 4 – 𝑥 + 𝑠3
= ( 1 + 𝑀 )𝑥 – 𝑦 + 𝑧 – 𝑀𝑠3 – 4𝑀

And so 𝑃– 1 + 𝑀 𝑥 + 𝑦 − 𝑧 + 𝑀𝑠3 = − 4𝑀
Example cont.
Giving the initial tableau …

Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value 𝜃 value


Variable
𝑠1 2 1 1 1 0 0 0 20 10

𝑠2 1 -2 -1 0 1 0 0 7 7

𝑎1 1 0 0 0 0 -1 1 4 4

𝑃 − (1 + 𝑀) 1 -1 0 0 𝑀 0 −4𝑀

Notice here that 𝑥, 𝑦 & 𝑧 are non-basic variables which means the starting point is the
origin. This is not a feasible solution because the artificial variable, 𝑎1 ≠ 0.

It may take several iterations to become feasible and may take a few more for it to become
optimal.
Example cont.
Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value Row op. 𝜃 value
Variable
𝑠11 0 1 1 1 0 2 -2 12 R1 – 2R3 6

𝑠𝑠22 0 -2 -1 0 1 1 -1 3 R2 – R3 3

𝑥 1 0 0 0 0 -1 1 4 -ve

𝑃 0 1 -1 0 0 -1 1+M 4 R4 + (1+M)R3

There are still negative values in the objective row, so we continue.


There is a choice of pivot columns, choosing the s3 column gives….
Basic
Basic 𝑥𝑥 𝑦𝑦 𝑧𝑧 𝑠𝑠11 𝑠𝑠22 𝑠𝑠33 𝑎𝑎11 Value
Value Row
Row op.
op. 𝜃𝜃 value
value
Variable
Variable
𝑠𝑠11 0 5 3 1 -2 0 0 6 R1 – 2R2 2

𝑠3 0 -2 -1 0 1 1 -1 3 R2 -ve

𝑥𝑥 1 -2 -1 0 1 0 0 7 R3 + R2 -ve

𝑃
𝑃 0 -1 -2 0 1 0 M 7 R4 + R2
Example cont.
Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value Row op. 𝜃 value
Variable
𝑧 0 5 1 1 −2 0 0 2 R1 ÷ 3 -ve
3 3 3

𝑠𝑠33 0 −1 0 1 1 1 -1 5 R2 + R1 15
3 3 3
𝑥 1 −1 0 1 1 0 0 9 R3 + R1 27
3 3 3
𝑃 0 7 0 2 −1 0 M 11 R4 + 2R1
3 3 3
Repeating gives…
𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value Row op.

𝑧 0 1 1 1 0 2 -2 12 2
R1 + 3R2

𝑠2 0 -1 0 1 1 3 -3 15 1
R2÷
3

𝑥 1 0 0 0 0 -1 1 4 1
R3 - 3R2

𝑃 0 2 0 1 0 1 M–1 16 1
R4 + 3R2
Example cont.
All values in the objective row are now positive so the solution is optimal.
𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value

𝑧 0 1 1 1 0 2 -2 12

𝑠2 0 -1 0 1 1 3 -3 15

𝑥 1 0 0 0 0 -1 1 4

𝑃 0 2 0 1 0 1 𝑀– 1 16

The solution is
𝑥 = 4, 𝑦 = 0, 𝑧 = 12, 𝑠1 = 0, 𝑠2 = 15, 𝑠3 = 0,
𝑎1 = 0, 𝑃 = 16

Checking against the original equations:


2𝑥 + 𝑦 + 𝑧 + 𝑠1 = 8 + 0 + 12 + 0 = 20 ✔
𝑥 – 2𝑦 – 𝑧 + 𝑠2 = 4 – 0 – 12 + 15 = 7 ✔
𝑥 – 𝑠3 + 𝑎1 = 4 – 0 + 0 = 4 ✔
Test your understanding – Edexcel Mock paper 2
Using Big-M to minimise the objective
Solve the following linear programming problem using the Big-M method.
Minimise 𝑃 = 𝑥 − 𝑦 + 𝑧,
Subject to:
2𝑥 + 𝑦 + 𝑧 ≤ 20
𝑥 − 2𝑦 − 𝑧 ≤ 7
𝑥≥4
𝑥, 𝑦, 𝑧 ≥ 0
Writing out the inequalities as equations using slack, surplus and artificial variables:
2𝑥 + 𝑦 + 𝑧 + 𝑠1 = 20
𝑥 – 2𝑦 – 𝑧 + 𝑠2 = 7 We change 𝑃 to −𝑃
𝑥 – 𝑠3 + 𝑎1 = 4 as the objective was
𝑥, 𝑦, 𝑧, 𝑠1 , 𝑠2 , 𝑠3 , 𝑎1 ≥ 0 to minimise 𝑃,
which is equivalent
−𝑃 = −𝑥 + 𝑦 − 𝑧 to maximising −𝑃
Using Big-M, you can minimise P by maximising Q where
𝑄 = −𝑥 + 𝑦 − 𝑧 − 𝑀𝑎1 Point 3
Writing 𝑎1 in terms of the non-basic variables gives
𝑄 = −𝑥 + 𝑦 − 𝑧 − 𝑀 4 − 𝑥 + 𝑠3 Point 4
𝑄 = −𝑥 + 𝑦 − 𝑧 − 4𝑀 + 𝑀𝑥 − 𝑀𝑠3
Rearranging gives Rearrange like we
𝑄 + 𝑥 − 𝑦 + 𝑧 − 𝑀𝑥 + 𝑀𝑠3 = −4𝑀 have always done
𝑄 + 1 − 𝑀 𝑥 − 𝑦 + 𝑧 + 𝑀𝑠3 = −4𝑀 with the objective.
Example cont.
Basic 𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value 𝜃 value
Variable
𝑠1
2 1 1 1 0 0 0 20 10
𝑠2
1 -2 -1 0 1 0 0 7 7
𝑎1
1 0 0 0 0 -1 1 4 4
𝑄 1−𝑀 -1 1 0 0 𝑀 0 −4𝑀

𝑥𝑥 𝑦𝑦 𝑧𝑧 𝑠𝑠11 𝑠𝑠22 𝑠𝑠33 𝑎𝑎11 Value


Value Row
Row op.
op. 𝜃𝜃
value
value
𝑠𝑠11 R1-2R3 12
0 1 1 1 0 2 -2 12
𝑠𝑠22
0 -2 -1 0 1 1 -1 3 R2-R3 -ve
𝑥
1 0 0 0 0 -1 1 4 →∞

𝑄
𝑄 𝑅4 −
0 -1 1 0 0 1 (𝑀 − 1) -4 1 − 𝑀 𝑅3
Example cont.
𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 Value Row op.

𝑦
0 1 1 1 0 2 -2 12
𝑠2
0 0 1 2 1 5 -5 27 R2+2R1
𝑥
1 0 0 0 0 -1 1 4 R3

𝑄
0 0 2 1 0 3 (𝑀 − 3) 8 R4+R1

All the values in the objective row are now positive, so the solution is optimal.

𝑄𝑚𝑎𝑥 = 8 ⇒ 𝑃𝑚𝑖𝑛 = −8
𝑥 = 4, 𝑦 = 12, 𝑧 = 0, 𝑠1 = 0, 𝑠2 = 27, 𝑠3 = 0, 𝑎1 = 0

Checking against the original equations


2𝑥 + 𝑦 + 𝑧 + 𝑠1 = 8 + 12 + 0 + 0 = 20 ✓
𝑥 − 2𝑦 − 𝑧 + 𝑠2 = 4 − 24 − 0 + 27 = 7 ✓
𝑥 − 𝑠3 + 𝑎1 = 4 − 0 + 0 = 4 ✓
Example (text book) abridged.
Set up the initial tableau for solving the following linear programming problem
using the Big-M method:
Subject to: 𝑥 + 𝑦 + 2𝑧 ≤ 10
Maximise: 𝑃 = 3𝑥 − 2𝑦 + 𝑧 2𝑥 − 3𝑦 + 𝑧 ≥ 5
𝑥+𝑦≥8
𝑥, 𝑦, 𝑧 ≥ 0
Converting into equations:
𝑥 + 𝑦 + 2𝑧 + 𝑠1 = 10
2𝑥 − 3𝑦 + 𝑧 − 𝑠2 + 𝑎1 = 5
𝑥 + 𝑦 − 𝑠3 + 𝑎2 = 8
The objective now becomes: Point 3 again
𝑃 = 3𝑥 − 2𝑦 + 𝑧 − 𝑀 𝑎1 + 𝑎2

𝑎1 = 5 − 2𝑥 + 3𝑦 − 𝑧 + 𝑠2
𝑎2 = 8 − 𝑥 − 𝑦 + 𝑠3

𝑎1 + 𝑎2 = 13 − 3𝑥 + 2𝑦 − 𝑧 + 𝑠2 + 𝑠3

𝑃 = 3𝑥 − 2𝑦 + 𝑧 − 𝑀 13 − 3𝑥 + 2𝑦 − 𝑧 + 𝑠2 + 𝑠3
𝑃 = 3 1 + 𝑀 𝑥 − 2 1 + 𝑀 𝑦 + 1 + 𝑀 𝑧 + 𝑀𝑠2 + 𝑀𝑠3 − 13𝑀

𝑃 − 3 1 + 𝑀 𝑥 + 2 1 + 𝑀 𝑦 − 1 + 𝑀 𝑧 − 𝑀𝑠2 − 𝑀𝑠3 = −13𝑀


Example (text book) abridged. ctd.
Write the initial tableau.

𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 𝑎2 Value

𝑠1 10
1 1 2 1 0 0 0 0
𝑎1
2 -3 1 0 -1 0 1 0 5
𝑎2
1 1 0 0 0 -1 0 1 8

𝑃 −3(1 + 𝑀) 2(1 + 𝑀) −(1 + 𝑀) 0 −𝑀 −𝑀 0 0 −13𝑀


Example (text book) abridged.
The results of the first iteration of the Big-M method are shown below. Explain why the
solution given is not feasible.

𝑥 𝑦 𝑧 𝑠1 𝑠2 𝑠3 𝑎1 𝑎2 Value

𝑠1 15/2
0 5/2 3/2 1 1/2 0 −1/2 0
𝑥
1 −3/2 1/2 0 −1/2 0 1/2 0 5/2
𝑎2
0 5/2 −1/2 0 1/2 -1 −1/2 1 11/2

𝑃 0
5 1
0
1
−𝑀
3
0
1
− (1 + 𝑀) (1 + 𝑀) − (3 + 5𝑀) (1 + 𝑀) (15 − 11𝑀)
2 2 2 2 2

11
The solution given by this tableau is not feasible because 𝑎2 = , if the solution were to
2
be feasible then all artificial variables must be zero.
Exercise 7E
Pearson Decision 1, Page 204

You might also like