LINEAR_PROGRAMMING(0)
LINEAR_PROGRAMMING(0)
Linear programming is a method to achieve the best outcome in a mathematical model whose
requirements are represented by linear relations. The word linear indicates that the relationships are of
the form .
Linear equations
Example 1
(a) ( ) ( )
(b) ( ) ( )
(c)
(d)
Solution
(a) ( ) ( ) (b) ( ) ( )
(c) (d)
( )( ) ( ) ( )( ) ( )( )
( ) ( )
Linear inequalities
Example 2
Solve the following inequalities and show the solution set on a number line.
(a)
(b)
Solution
(a)
-4 -3 -2 -1 0 1 2 3 4
(b)
0 1 2 3 4 5 6 7 8
(c)
-6 -5 -4 -3 -2 -1 0 1 2
(d)
-1 0 1 2 3 4 5 6 7
(e)
Here you two inequalities so you can easily solve them separately.
Exercise 1
(a)
(b) ( ) ( )
(c)
(d)
(e)
Example 3
Solve the following inequations and show the solution on the graph by shading the unwanted region.
(a)
(b)
Solution
(a)
y
-2 x
Example 4
Illustrate the solution set of the following inequalities on a Cartesian diagram by shading the unwanted
region.
(a)
(b)
(c)
(d)
Solution
(a)
First we have to draw the boundary line . This equation shows that the line intersects
both axes so we construct a simple table of values of x and y. You can choose as many values of
x as you want but here, we will be choosing two values for convenience sake.
After drawing the line, we have to choose a test point on either side of the line and then
substitute the value of x and y in the inequality to check whether it is satisfied.
X 1 2
Y 3 4
y
5
4
3
2
1
0 1 2 3 x
(b)
The equation of the boundary line is .
For simplicity, make y the subject so that substitution becomes easier for you.
y
X 0 2 1
Y -1.5 -0.5
0 1 2 3 x
-1
-2
(c)
The boundary line is .
X 0 3
Y 0 1
0 1 2 3 x
(d)
The boundary line is . Note that this is a line of symmetry of the axes with gradient +1.
y
2
1
-2 -1 0 1 2 x
-1
x
-2
Exercise 2
Illustrate the solution set of the following on a Cartesian plane by shading the unwanted region.
(a)
(b)
(c)
Example 5
Illustrate the solution set of the following system of inequations on a Cartesian diagram by shading the
unwanted region.
3
2
1
-3 -2 -1 0 1 2 3 x
-1
-2
Exercise 3
Illustrate the solution set of the following systems of inequations on a Cartesian plane where .
(a)
(b) .
Example 6
6
5
4
3
2 R
1
0 1 2 3 4 5 6 7 8 9 x
Exercise 4
5 (5 , 5)
2
R
1
0 1 2 3 4 5 6 7 8 9 x
Write three inequalities which describe the region r. (e.c.z, mathematics p1, g.c.e , 2018)
y
(-3,10)
10
9
8
7
6
R 5
4 (3,4)
3
2
1
-4 -3 -2 -1 0 1 2 3 4 x
Write the three inequalities that define the region R. (e.c.z, mathematics p1, October, 2018)
y
8
(5,7)
4
R
(9,3)
0 2 4 6 8 10 x
Write the four inequalities that define the region R. (e.c.z, mathematics p1, October, 2016)
Kantwa has K50 to spend on two types of sweets. Toffees cost K2 each and peppermints cost K6 each.
She intends to have not more than 5 peppermints. Furthermore, she wants to have at least 12 sweets.
Let x be the number of toffee sweets and y be the number of peppermints. Formulate inequalities which
satisfy the given conditions.
Solution
⇒ (1)
(2)
(3)
Example 8
Makwebo prepares two types of sausages, Hungarian and beef, daily for sale. She prepares at least 40
hungarian and at least 10 beef sausages. She prepares not more than 160 sausages altogether. The
number of beef sausages prepared are not more than the number of Hungarian sausages.
(a) Given that x represents the number of Hungarian sausages and y the number of beef
sausages, write four inequalities which represent these conditions.
(b) Using a scale of 2cm to represent 20 sausages on both axes, draw the x and y axes for
and respectively and shade the unwanted region to show clearly
the region where the solution of the inequalities lie.
(c) The profit on the sale of each Hungarian sausage is K3.00 and on each beef sausage is K2.00.
How many of each type of sausages are required to be prepared to make maximum profit?
(d) Calculate this maximum profit.
Solution
(a) (1)
(2)
(3)
(4)
160
140
120
100
80
60
40 R
20
(c) The objective function is , where z is the profit. To obtain the maximum value of z
we need to consider points that are on the edges of the region where the solution set lies.
Hence the points are: (40,10), (150,10), (80,80) and (40,40). Substituting these values in the
objective function we have:
( ) ( )
( ) ( )
( ) ( )
( ) ( )
80 hungurian sausages and 80 beef sausages give the maximum profit.
(d) Maximum profit ( ) ( )
Exercise 5
1. A restaurant business person decides to buy two types of chickens: broilers and layers.
Broilers cost K15 per chicken and layers cost K20 per chicken. He has K600 available and
decides to buy at least 30 chickens. He also decides that at least one third of the chickens
should be layers. He buys x broilers and y layers and also makes sure that there are at least
15 broilers.
(a) Write down four inequalities which correspond to the above conditions.
(b) Illustrate these inequalities on a graph using a scale of 2cm to 5 units on both axes.
(c) He makes a profit of K20 on each broiler and K10 on each layer. Assuming he sells all his
chickens, find how many chickens of each type he should buy to maximize his profit and
hence calculate his profit.
3. Menda intends to run a business of selling mineral water. He intends to order at least 10
small bottles and at most 60 large bottles of water. He decides to order at most 80 bottles
of water altogether and the number of large bottles he orders should be at least twice that
of small bottles.
(a) Given that x is the number of small bottles and y is the number of large bottles, write four
inequalities which represent these conditions.
(b) Using a scale of 2cm to represent 10 bottles on each axis, draw the x and y axes for
and respectively and shade the unwanted region to show clearly
the region where the solution of the inequalities lie.
(c) The profit on the sale of each small bottle of mineral water is K1.50 while on each large
bottle of mineral water is K2.5.. How many bottles of each type can be bought to make
maximum profit?
(d) Hence, find this maximum profit. (e.c.z, mathematics p2, g.c.e, 2020)
4. A hired bus is used to take learners and teachers on a trip. The number of learners and
teachers must not be more than 60. There must be at least 35 people on the trip. There
must be at least 6 teachers on the trip. The number of teachers on the trip should not be
more than 14.
Let x be the number of learners and y the number of teachers.
(a) Write four inequalities which represent the information above.
(b) Using a scale of 2cm to represent 10 units on both axes, draw the x and y axes for
and respectively and shade the unwanted region to indicate clearly
the region where the solution of the inequalities lie.
(c) Hg
(i) If the group has 25 learners, what is the minimum number of teachers that must
accompany them?
(ii) If 8 teachers go on this trip, what is the maximum number of learners that can be
accommodated on the bus?
(d) If T is the amount in kwacha paid by the whole group, what is the cost per learner if
. (e.c.z, mathematics p2, Npvember, 2018)