Operation Research (Pe405) : Unit-2: Linear Programming: Formulation

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 46

OPERATION RESEARCH (PE405)

Unit-2:
Linear Programming:
Formulation

Prof Akil H Jariya


Assistant Professor, PED, BVM
Introduction

Operation Research: PE405


Operation Research: Methodology
Define the Problem

Develop a model

Obtain input data

Solve the model

Test the solution (Model Validation)

Analyse the result

Implement the solution


Operation Research: PE405
Introduction
• A large number of decision problem faced by business manager involve allocation
of resources to various activities with the objective of increasing profit or
decreasing cost or both.
• When resources are in excess, no difficulty is experienced . But such cases are
very rare.
• Practically in all situations, the managements are confronted with the problem of
scare resources.
• Thus, the managers has to take a decision as to how best to allocate the resources
among the various activities.

• The decision problem becomes complicated when a number of resources are


required to be allocated and there are several activities to perform.

Operation Research: PE405


Introduction (Cont..)

• Rule of thumb, even if an experienced manager, in all likehood may not provide the
right answer in such cases.
• The decision problem can be formulated and solved as mathematical programming
problem.

• Mathematical programming involves optimization of a certain function, called the


‘objective function’, subjected to certain ‘constrains’.

• For example, a manager may be faced with the problem of deciding the appropriate
product mix of the four product.

Operation Research: PE405


Develop a model (Model Classification)

Iconic Model

Physical Model

Analogue Model

Model
Verbal Model
Symbolic Model Deterministic
Model
Mathematical
Model
Probabilistic
Model

Operation Research: PE405


Introduction (Cont..)

• The method of mathematical programming can be divided into three groups as


below:

Mathematical Programming

Linear Programming Integer Programming Non-linear Programming

• Our syllabus of PE405 is limited up to linear programming and methods/techniques


for the same

Operation Research: PE405


Linear Programming

Operation Research: PE405


Linear Programming

• The linear programming Manufacturer


method is a mathematical
programming technique
for choosing the best
alternative from a set of
feasible alternatives, in
situation which the
objective function as well
as the constrains can be
expressed as linear
mathematical functions.

Operation Research: PE405


Linear Programming (Cont…)
• In order to apply linear programming, certain requirements have to be met as follow:
a) There should be an objective which should be clearly identifiable and measurable in
quantitative terms. For ex, maximization of profit or sales, minimization of cast and so
on.
b) The activities to be included should be distinctly identifiable and measurable in
quantitative terms.
c) The resources of the system, which are to be allocated for the attainment of the goal,
should also be identifiable and measurable quantitatively. They must be in limited
supply.

d) The relationship representing the objectives as also the resource limitation


considerations, represented by the objective function and the constraint equation or
inequality, respectively, must be in linear in nature.

e) These should be a series of feasible alternative courses of action available to the


decision-maker which are determined by the resources constraints.
Operation Research: PE405
Linear Programming (Cont…)

• The model of any linear programming will contain:


a) objective function
b) Set of constrains
c) Non-negativity restriction

• Each of the components may consists of one or more of the following


1) Decision variables
2) Objective function coefficient
3) Technological coefficient
4) Availability of resources

Operation Research: PE405


Linear Programming (Cont…)

• Product Mix Problem:


• This pertains to determining the level of production activities to be carried out
during a pre-decided time frame so as to gain the maximum profit.
• Since the requirement of inputs for the different production processes varies, their
profitability also differ.

• This may be best understood with help of example:

Operation Research: PE405


Linear Programming Formulation (Example-1)

A company manufactures two different types of products: P1 and P2. Each products
requires processing on milling machine and drilling machine per week. But each type
of machine has limited hours available per week. The net profit per unit of product,
resource requirements of the product and availability of resources are summarized in
table:
Processing time (Hours) Machine-hours
Machine type
Products P1 Products P2 available per week
Milling machine 2 5 200
Drilling machine 4 2 240
Profit/unit (Rs.) 250 400

Develop a liner programming model to determine the optimal production volume of


each of the product such that the profit is maximized subject to the availability of
machine hours.
Operation Research: PE405
Example-1 (Cont.…)

• The model of any linear programming will contain:


a) objective function
b) Set of constraints
c) Non-negativity restriction

• Each of the components may consists of one or more of the following


1) Decision variables
2) Objective function coefficient
3) Technological coefficient
4) Availability of resources

Operation Research: PE405


Example-1 (Cont.…)

Solution:
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒, 𝑍 = 250𝑥1 + 400𝑥2
Subject to,
2𝑥1 + 5𝑥2 ≤ 200
4𝑥1 + 2𝑥2 ≤ 240
𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Linear Programming Formulation (Example-2)

A furniture manufacturer company plans to make two products: chairs and tables from
its available resources which consists of 400 square feet of mahogany timber board
and 450 man-hours of labor. It knows that to make a chair requires 5 square feet
timber, 10 man-hours and yields a profit of Rs. 45, while each table uses 20 square
feet timber, 15 man-hours and profit of Rs. 80. The problem is to determine how many
chairs and tables the company can make keeping within its resources constraints so
that it maximize the profit.

Operation Research: PE405


Example-1 (Cont.…)

• Solution:
• Decision Variables:

• Objective function:

• Set of constraints:

• Non-negativity restriction:

Operation Research: PE405


Example-2 (Cont.…)
Chair Table Total Availability
Timber 5 20 400
Man-hour 10 15 450
Profit 45 80

• Decision Variables:
Let, X1 = No. of chairs to be produced by company
X2 = No. of tables to be produced by company

• Objective function:
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒 𝑃𝑟𝑜𝑓𝑖𝑡 , 𝑍 = 45𝑥1 + 80𝑥2

Operation Research: PE405


Example-2 (Cont.…)
Chair Table Total Availability
Timber 5 20 400
Man-hour 10 15 450
Profit 45 80

• Set of constraints:
5𝑥1 + 20𝑥2 ≤ 400
10𝑥1 + 15𝑥2 ≤ 450

• Non-negativity restriction:
𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Example-2 (Cont.…)

• Complete solution (formulation):


Let, X1 = No. of chairs to be produced by company
X2 = No. of tables to be produced by company
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒 𝑃𝑟𝑜𝑓𝑖𝑡 , 𝑍 = 45𝑥1 + 80𝑥2
Subject to,
5𝑥1 + 20𝑥2 ≤ 400
10𝑥1 + 15𝑥2 ≤ 450
𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Assumptions in Linear Programming:

1. Proportionality
• A basic assumption of linear programming is that proportionality exists in the
objective function and the constrains equations.
• For example, if one unit of a product is assumed to contribute Rs 10 towards the
profit, then the total contribution would be equal to 10X.

2. Additivity:
• Another assumption underlying the linear programming model is that the objective
function and constraints inequalities both, the total of all the objectives is given by
the sum total of each activity conducted separately.
• Thus, the total profit in the objective function is determine by the sum of profit
contributed by each of the product separately.
Operation Research: PE405
Assumptions in Linear Programming (Cont…):

3. Continuity
• It is also an assumption of a linear programming model that , the decision variable
are continuous.
• As a consequence combinations of output with fractional values in the context of
production problem are possible and obtained frequently.
2
• For example, the best solution to a problem might be to produce 5 units of the
3
1
product A and 10 units of product B per week.
3

4. Certainty:
• A further assumption underlying a linear programming model is that the various
parameters, namely, the objective function coefficients , the coefficients of
constraints and resources values are known with certainty.
• The linear programming is obviously deterministic in nature.
Operation Research: PE405
Assumptions in Linear Programming (Cont…):
5. Finite choices:
• A linear programming model also assumes that a limited number of choices are
available to a decision-maker and the decision variables do not assume negative
value.
• For instance, in the production problem, the output cannot obviously be negative,
because a negative production implies that we should be able to reverse the
production process and convert the finished output into the raw materials.

Operation Research: PE405


Linear Programming Formulation (Example-3)

Vitcos (Anand) has 26 bus with 30 passenger seats and 13 bus with 50 passenger
seats. Each bus needs 1 driver and 1 conductor. Vitcos wants to carry at least 440
passengers on a certain route and has 30 conductors available. Formulate model to
find the optimum number of assignment of drivers to be recruited.

• Solution:
1. Decision Variables:
2. Objective function:
3. Set of constraints:
4. Non-negativity restriction:

Operation Research: PE405


Example-3 (Cont.…)

• Complete solution (formulation):


Let, X = No. of 30-seated buses on a certain route
Y = No. of 50-seated buses on a certain route
𝑀𝑖𝑛𝑖𝑚𝑖𝑧𝑒, 𝑍 = 𝑋 + 𝑌 (No. of drivers recruited)
Subject to,
30𝑋 + 50𝑌 ≥ 440 (No. of passenger constraint)
𝑋 + 𝑌 ≤ 30 (No. of conductor constraint)
𝑋 ≤ 26 (30 seated bus constraint)
𝑌 ≤ 13 (50 seated bus constraint)
𝑋, 𝑌 ≥ 0

Operation Research: PE405


Linear Programming Formulation (Example-4)
A company has two grades of inspectors Grade: I and II to undertake quality control
inspections. At least 1500 pieces must be inspected in an 8 hour/day. Grade I
inspector can check 20 pieces in one hour with an accuracy of 96%. Grade II
inspector can check 14 pieces in an hour with an accuracy of 92%.
Wages of grade I inspector are Rs 50 per hour while those of grade II inspector are
Rs 40 per hour. Any error made by an inspector costs Rs 30 to the company. Find
optimal assignment of inspectors that minimize the daily inspection costs if there are
10 grade I and 15 grade II inspector available.
• Solution:
1. Decision Variables:
2. Objective function:
3. Set of constraints:
4. Non-negativity restriction:
Operation Research: PE405
Example-4 (Cont.…)

Solution:
• Decision Variables:
Let, X1 = No. of grade I inspector assigned for inspection
X2 = No. of Grade II inspector assigned for inspection
• Set of Constraints:
Grade I inspection can check 20 pieces/hour
 per day = 20×8×X1 = 160X1

Grade II inspection can check 14 pieces/hour


 per day = 14×8×X2 = 112X2
160X1 + 112X2 ≥ 1500
40X1 + 28X2 ≥ 375 ----------------(1)
X1 ≤ 10 ----------------(2)
X2 ≤ 15 ----------------(3)
Operation Research: PE405
Example-4 (Cont.…)

• Objection Function:
Objective function is assignment of inspectors that minimize the daily inspection
costs:
Inspector
Grade-I Grade-II
Cost/hour (Rs) 50 40
Error Cost (Rs) 30 30
Accuracy 96% 92%
Error 4% 8%

The cost of grade-I inspector/hour The cost of grade-II inspector/hour


= Inspection wages + Error cost = Inspection wages + Error cost
= 50 + 0.04×20×30 = 40 + 0.08×14×30
= Rs 74 = Rs 73.8
Per day cost = Rs 74×8 = Rs 592 ----- Per day cost = Rs 73.8×8 = Rs 588.8 ---
(4) - (4)
Operation Research: PE405
Example-4 (Cont.…)

• Objection Function:
Minimize (Cost), Z = 592𝑋1 + 588.8𝑋2
Subject to,
40𝑋1 + 28𝑋2 ≥ 1500 (No. of pieces to be inspected constraint )
𝑋1 ≤ 10 (Grade-I inspector constraint)
𝑋2 ≤ 15 (Grade-II inspector constraint)
𝑋1 , 𝑋2 ≥ 0

Operation Research: PE405


General Statement of Linear Programming Problem (Formulation)
Objective function:
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒 𝑜𝑟 𝑀𝑖𝑛𝑖𝑚𝑖𝑧𝑒, 𝑍 = 𝐶1 𝑋1 + 𝐶2 𝑋2 + … … … … + 𝐶𝑛 𝑋𝑛
Subject to,
𝑎11 𝑋1 + 𝑎12 𝑋2 + … … … + 𝑎1𝑛 𝑋𝑛 ≤, = or ≥ 𝑏1
𝑎21 𝑋1 + 𝑎22 𝑋2 + … … … + 𝑎2𝑛 𝑋2 ≤, = or ≥ 𝑏2
. . . . Constraints
. . . .
. . . .
𝑎𝑚1 𝑋1 + 𝑎𝑚2 𝑋2 + … … … + 𝑎𝑚𝑛 𝑋𝑛 ≤, = or ≥ 𝑏𝑚

Where, 𝑋1 , 𝑋2 , … … … , 𝑋𝑛 ≥ 0

Operation Research: PE405


Linear Programming: Graphical Method

Operation Research: PE405


Linear Programming: Graphical Method
• The solution to linear programming
problem can be solved by
- Graphical Method
- The Simplex Method- the
algebraic method
• The graphical approach is restricted
in application: it can be used only
when two variables are involved.
• Nevertheless, it provides an intuitive
grasp of the concept that are used in
the simplex method.

Operation Research: PE405


Linear Programming: Graphical Method (Cont.)

• Example-2: solution (formulation)


Let, X1 = No. of chairs to be produced by company
X2 = No. of tables to be produced by company
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒 𝑃𝑟𝑜𝑓𝑖𝑡 , 𝑍 = 45𝑥1 + 80𝑥2
Subject to,
5𝑥1 + 20𝑥2 ≤ 400
10𝑥1 + 15𝑥2 ≤ 450
𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Linear Programming: Graphical Method (Cont.)
The Graphical Method: To use the graphical method for solving linear programming
problems, following steps are required:
a) Identify the problem - the decision variables, the objective function and the
constraint restrictions. (Formulate the linear programming problem)
b) Convert inequality of constraints into equality
c) Plot one variable on X-axis and other variable on Y-axis
d) Draw a graph that include all the constraints/restrictions and identify the feasible
region
e) Obtain the point on the feasible region with consideration of all corner points that
optimize the objective function – the optimal solution
f) Test which corner point gives optimal solution (i.e. maximize/minimize) by putting
different coordinates of corner points in objective function
Operation Research: PE405
Linear Programming: Graphical Method (Example-1)

Solve the following linear programming problem using graphical method.


𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒, 𝑍 = 6𝑥1 + 8𝑥2
Subject to,
5𝑥1 + 10𝑥2 ≤ 60
4𝑥1 + 4𝑥2 ≤ 40
where, 𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Graphical Method: Example-1 (Cont.)

In graphical method, the introduction of non-


negativity constraints ( 𝑥1 ≥ 0 𝑎𝑛𝑑 𝑥2 ≥ 0 ) will
eliminate the second, third and fourth quadrants
of the X1X2 plane.
• Now, we compute the coordinate on the X1X2
plane.
From the first constraint:
5𝑥1 + 10𝑥2 = 60
We get,
x2 = 6 when x1 = 0 (0,6) &
x1 = 12 when x2 = 0 (12,0)
Plot the first constraint line on the graph.
Operation Research: PE405
Graphical Method: Example-1 (Cont.)

From the second constraint: x2

4𝑥1 + 4𝑥2 = 40
12
We get,
x2 = 10 when x1 = 0 (0,10) & 9
4𝑥1 + 4𝑥2 = 40
x1 = 10 when x2 = 0 (10,0)
6
Now plot the second constraint line
on the graph.
3
5𝑥1 + 10𝑥2 = 60

Plot variable x1 on the X-axis and x2 0 x1


0 3 6 9 12 15
on the Y-axis.

Operation Research: PE405


Graphical Method: Example-1 (Cont.)

• From the first constraint: x2

5𝑥1 + 10𝑥2 ≤ 60
12
(12,0) & (0,6)
• From the second constraint: 9
4𝑥1 + 4𝑥2 ≤ 40
4𝑥1 + 4𝑥2 ≤ 40
6 D
(10,0) & (0,10)
• Find feasible region from the C
3 Feasible
common area covered by the Region 5𝑥1 + 10𝑥2 ≤ 60
constraints. 0 x1
A0 3 6 9 B 12 15
• The closed polygon A-B-C-D is
the feasible region.
Operation Research: PE405
Graphical Method: Example-1 (Cont.)

• The objective function value at each of the corner point of the closed polygon is
computed by substituting its coordinates I the objective function as:

• Coordinates at:
A (0,0) B (10,0) C (8,2) D (0,6)
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒, 𝑍 = 6𝑥1 + 8𝑥2
𝑍 𝐴 = (6 × 0) + (8 × 0) = 0
𝑍 𝐵 = 6 × 10 + 8 × 0 = 60
𝑍 𝐶 = (6
6×8
8) + (8
8×2
2) = 64 * Optimum Point
𝑍 𝐷 = (6 × 0) + (8 × 6) = 48

• The Z value is he maximum for the corner point C. Hence the corresponding
solution is optimum (Z=64 and x1=8 & x2=2).
Operation Research: PE405
Linear Programming: Graphical Method (Example-2)
Solve the following LP problem using graphical method.
𝑀𝑖𝑛𝑖𝑚𝑖𝑧𝑒, 𝑍 = 2𝑥1 + 3𝑥2
Subject to,
𝑥1 + 𝑥2 ≥ 6
7𝑥1 + 𝑥2 ≥ 14
where, 𝑥1 , 𝑥2 ≥ 0
• From the first constraint:
𝑥1 + 𝑥2 = 6 --------------(0,6) & (6,0)
• From the second constraint:
7𝑥1 + 𝑥2 = 14 -------------(2,0) & (0,14)
• Plot variable x1 on the X-axis and x2 on the Y-axis.
Operation Research: PE405
Graphical Method: Example-1 (Cont.)

• Now plot both the constraints line on the


graph.
• Find the feasible region which satisfy the
both constraints.
• The optimum solution will be in any one
of the corner point B, C, D as per figure.

• The objective function value at each of


these corner points:
Z (B) = (2×0) + (3×14) = 42
Z (C) = (2×4/3) + (3×14/3) = 50/3
Z (D) = (2×6) + (3×0) = 12 * Optimum point
Operation Research: PE405
Linear Programming: Graphical Method (Example-3)
Solve the following LP problem using graphical method.
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒, 𝑍 = 8𝑥1 + 16𝑥2
Subject to,
𝑥1 + 𝑥2 ≤ 200
𝑥2 ≤ 125
3𝑥1 + 6𝑥2 ≤ 900

where, 𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Linear Programming: Graphical Method (Example-3)

• From the first constraint:


𝑥1 + 𝑥2 = 200 --------------(200, 0) & (0, 200)
• From the second constraint:
𝑥2 = 125 -------------(0, 125)
• From the first constraint:
3𝑥1 + 6𝑥2 = 900 --------------(300, 0) & (0, 150)
Plot variable x1 on the X-axis and x2 on the Y-axis.
• Now plot all the constraints line on the graph.
• Find the feasible region which satisfy the constraints.

Operation Research: PE405


Linear Programming: Graphical Method (Example-3)

• In figure O-A-B-C-D is the


feasible region.
• The optimum solution will be any
one of the corner point A, B, C,
D.
Z (Max) = 8X1 +
Point X1 X2
6x2
A 200 0 1600* Maximum
B 100 100 2400*
C 50 125 2400
D 0 125 2000
The optimum solution,
x1 = 100, x2 = 100
or Z (Max) =
2400 Operation Research: PE405
x = 50, x = 125
Linear Programming: Graphical Method (Example-4)
Solve the following LP problem using graphical method.
𝑀𝑎𝑥𝑖𝑚𝑖𝑧𝑒, 𝑍 = 20𝑥1 + 30𝑥2
Subject to,
2𝑥1 + 𝑥2 ≤ 40
4𝑥1 − 𝑥2 ≤ 20
𝑥1 ≥ 40
where, 𝑥1 , 𝑥2 ≥ 0

Operation Research: PE405


Linear Programming: Graphical Method (Example-4)

• From the first constraint:


2𝑥1 + 𝑥2 = 40 --------------(20, 0) & (0, 40)
• From the second constraint:
4𝑥1 − 𝑥2 = 20 -------------(5, 0) & (0, -20)
• From the first constraint:
𝑥1 = 40 --------------(40, 0)
Plot variable x1 on the X-axis and x2 on the Y-axis.
• Now plot all the constraints line on the graph.
• Find the feasible region which satisfy the constraints.

Operation Research: PE405

You might also like