Sei sulla pagina 1di 29

Introduction to Linear Programming

What Is a Linear Programming Problem?

 Linear Programming (LP) is a tool for solving optimization


problems.
 Linear programming problems involve important terms
that are used to describe linear programming.

2
Example 1

 ABC’s, Inc., manufactures two products ‘A’ and ‘B’.


 Each of product ‘A’ gives:
 Profit of Rs. 3
 Requires 2 hours of finishing labor.
 Requires 1 hour of carpentry labor.

 Each of product ‘B’ gives:


 Profit of Rs. 2
 Requires 1 hour of finishing labor.
 Requires 1 hour of carpentry labor.

3
Ex. 1 - continued
 Each week ABC can obtain:
 All needed raw material.
 Only 100 finishing hours.
 Only 80 carpentry hours.
 Demand for the product ‘B’ is unlimited.
 At most 40 units of product ‘A’ are bought in market
each week.
 ABC wants to maximize weekly profit.
 Formulate a mathematical model of ABC’s situation
that can be used to maximize weekly profit.

4
Example 1: Solution
 The ABC solution model incorporates the
characteristics shared by all linear programming
problems.
 Decision variables should completely describe the
decisions to be made.
 x1 = number of product ‘A’ produced each week
 x2 = number of product ‘B’ produced each week
 The decision maker wants to maximize (usually
revenue or profit) or minimize (usually costs) some
function of the decision variables. This function to
maximized or minimized is called the objective
function.

5
Ex. 1 - Solution continued
 ABC’s weekly profit can be expressed in terms of
the decision variables x1 and x2:
Weekly profit = 3x1 + 2x2
 Thus, ABC’s objective is to chose x1 and x2 to
maximize weekly profit. The variable z denotes the
objective function value of any LP.
 The objective function is
Maximize z = 3x1 + 2x2
 The coefficient of an objective function variable is
called an objective function coefficient.

6
Ex. 1 - Solution continued
 As x1 and x2 increase, ABC’s objective function
grows larger.
 For ABC, the values of x1 and x2 are limited by the
following three restrictions (often called
constraints):
 Each week, no more than 100 hours of finishing time may
be used. (2 x1 + x2 ≤ 100)
 Each week, no more than 80 hours of carpentry time may
be used. (x1 + x2 ≤ 80)
 Because of limited demand, at most 40 units of product
‘A’ should be produced. (x1 ≤ 40)

7
General form of L.P.P.

n
Optimize, Z   ci xi Maximize, Z = 3x1 + 2x2
i 1
Subject to (w.r.t.)
w.r.t
2 x1 + x2 ≤ 100
n

a
x1 + x2 ≤ 80
x    b j (j  1,2,3,..., m)
ji i x1 ≤ 40
i 1

and xi  0 (i  1,2,3,..., n) and x1 , x2 ≥ 0

8
General form of L.P.P.

 A function f(x1, x2, …, xn) of x1, x2, …, xn is a linear


function if and only if for some set of constants,
c1, c2, …, cn in the function multiplied with x1, x2, …,
xn (i.e. xi with power 1 where i= 1,2,3,…,n.)
Z = f(x1, x2, …, xn) = c1x1 + c2x2 + … + cnxn.

 The coefficients of the decision variables in the


constraints are called the technological
coefficients (aji). The number on the right-hand
side of each constraint is called the constraint’s
right-hand side (bj).
9
General form of L.P.P.

n
Optimize, Z   ci xi
i 1 Optimize, Z  C X
w.r.t w.r.t.
n

 a ji xi    b j (j  1,2,3,..., m) Amn X  b
i 1
and X  0
and xi  0 (i  1,2,3,..., n)

10
 A linear programming problem (LP) is an
optimization problem for which we do the
following:
 Attempt to maximize (or minimize) a linear function
(called the objective function) of the decision
variables.
 The values of the decision variables must satisfy a
set of constraints. Each constraint must be a linear
equation or inequality.
 A sign restriction is associated with each variable.
For any variable xi, the sign restriction specifies
either that xi must be nonnegative (xi ≥ 0) or that xi
may be unrestricted in sign.
11
Assumptions of Linear Programming Problem

1. Proportionality: The contribution of the objective function


from each decision variable is proportional to the value of the
decision variable. For example, the contribution to the
objective function for 4 units of product ‘A’ is exactly fours
times the contribution of 1 unit of product ‘A’.
2. Additivity: The contribution to the objective function for any
variable is independent of the other decision variables. For
example, no matter what the value of x2, the manufacture of
x1 units of product ‘A’ will always contribute 3x1 rupees to
the objective function.
3. Divisibility: Each decision variable be permitted to assume
fractional values.
4. Certainty: Each parameter (objective function coefficients,
right-hand side, and technological coefficients) are known
with certainty.

12
Ex. 1 – Graphical Solution

 Since the ABC LP has two variables, it may be solved


graphically.
 The feasible region is the set of all points satisfying
the constraints

Max, z = 3x1 + 2x2


w.r.t
2 x1 + x2 ≤ 100
x1 + x2 ≤ 80
x1 ≤ 40
x1 , x2 ≥ 0

13
Graphical Solution to a Two-Variable LP Problem

 Any LP with only two variables can be solved


graphically.
 The variables are always labeled x1 and x2 and the
coordinate axes the x1 and x2 axes.

X2

Satisfies 2x1 + 3x2 ≥ 6


3

Satisfies 2x1 + 3x2 ≤ 6 X1

-1 1 2 3 4

-1

14
 The set of points satisfying the ABC LP is bounded by the five
sided polygon ODGFE. Any point on or in the interior of this
polygon (the shade area) is in the feasible region.

X2
B(0,100)

2 x1 + x2 = 100 Feasible Region

(0,80) D
Max value of z = 180
x1 = 40
(20,60)
G

x1 + x2 = 80

F (40,20)

(40,0) E A(50,0) C (80,0)


O
10 20 40 50 60 80 X1

15
 The feasible region of an LP is the set of all
points satisfying all the LP’s constraints and
sign restrictions.
 For a maximization problem, an optimal
solution to an LP is a point in the feasible
region with the largest objective function
value.
 Similarly, for a minimization problem, an optimal
solution is a point in the feasible region with the
smallest objective function value.

16
 Having identified the feasible region for the LP, a
search can begin for the optimal solution which will
be the point in the feasible region with the largest
z-value.

Coordinates Z Value
O (0,0) 0
D (0,80) 160
G (20,60) 180 (Max)
F (40,20) 160
E (40,0) 120

17
 A constraint is binding if the left-hand and
right-hand side of the constraint are equal when
the optimal values of the decision variables are
substituted into the constraint.
 In the ABC Inc.’s LP, the finishing and carpentry
constraints are binding.
 A constraint is nonbinding if the left-hand side
and the right-hand side of the constraint are
unequal when the optimal values of the decision
variables are substituted into the constraint.
 In the ABC Inc.’s LP, the demand constraint for
product ‘A’ is nonbinding since at the optimal solution
(x1 = 20), x1 < 40.

18
 A set of points S is a convex set if the line
segment jointing any two pairs of points in S is
wholly contained in S.
 For any convex set S, a point P in S is an extreme
point if each line segment that completely in S
and contains the point P, has P as an end point of
the line segment.
 Extreme points are sometimes called corner
points, because if the set S happens to be a
polygon, the extreme points would be the vertices,
or corners, of the polygon.
 The feasible region for the ABC Inc.’s LP will be a convex
set with finite number of extreme points and that an LPP
that has an optimal solution has an extreme point that is
optimal.
19
TATA Auto

 TATA Auto manufactures luxury cars and trucks.


 The company believes that its most likely
customers are high-income women and men.
 To reach these groups, TATA Auto has
embarked on an ambitious TV advertising
campaign and will purchase 1-mimute
commercial spots on two type of programs:
Dance Reality show and Cricket Match.

20
Ex. 2: continued
 Each Dance Reality Episode is seen by 7 million
high income women and 2 million high-income
men and costs Rs. 50,000 per minute.
 Each Cricket Match is seen by 2 million high-
income women and 12 million high-income
men and costs Rs. 100,000 per minute.
 TATA Auto would like for commercials to be
seen by at least 28 million high-income women
and 24 million high-income men.
 Use LP to determine how TATA Auto can meet
its advertising requirements.
21
Example 2: Solution
 TATA Auto must decide how many 1-minute ads in dance
reality show and cricket match should be purchased, so
the decision variables are
 x1 = number of 1-minute ads in dance reality show
 x2 = number of 1-minute ads in a cricket match
 TATA Auto wants to minimize total advertising cost.
 Objective functions is
Min z = 50 x1 + 100x2
 Constraints are
 Commercials must reach at least 28 million high-income
women. (7x1 + 2x2 ≥ 28)
 Commercials must reach at least 24 million high-income
men. (2x1 + 12x2 ≥ 24)
 The sign restrictions are necessary, so x1, x2 ≥ 0.
22
Example 2: Solution

Min z = 50 x1 + 100x2
w.r.t
7x1 + 2x2 ≥ 28
2x1 + 12x2 ≥ 24
and x1, x2 ≥ 0.

23
Solution continued
 To solve this LP graphically begin by graphing
the feasible region.
X2

14 B

High-income women constraint


12

10
Feasible
8 Region
(unbounded)

6
z = 600
4 z = 320
High-income men constraint
2 E
D
A C
2 4 6 8 10 12 14 X1

24
Solution continued
 Like the previous LP, This LP has a convex
feasible region.
 The feasible region for the problem, however,
contains points for which the value of at least
one variable can assume arbitrarily large
values.
 Such a feasible region is called an unbounded
feasible region.

25
Solution continued
 Since TATA Auto wants to minimize total advertising
costs, the optimal solution to the problem is the
point in the feasible region with the smallest z value.

 The smallest z value passes through point E and is


the optimal solution at x1 = 3.4 and x2 = 1.4.

 Both the high-income women and high-income men


constraints are satisfied, both constraints are
binding.

26
Special Cases
 The ABC and TATA Auto LPs each had a unique
optimal solution.
 Some types of LPs do not have unique solutions.
 Some LPs have an infinite number of solutions
(alternative or multiple optimal solutions).
 Some LPs have no feasible solutions (infeasible LPs).
 Some LPs are unbounded: There are points in the
feasible region with arbitrarily large (in a maximization
problem) z-values.

 The technique of goal programming is often


used to choose among alternative optimal
solutions.
27
 It is possible for an LP’s feasible region to be
empty, resulting in an infeasible LP.
 Because the optimal solution to an LP is the
best point in the feasible region, an infeasible
LP has no optimal solution.
 For a max problem, an unbounded LP occurs if
it is possible to find points in the feasible
region with arbitrarily large z-values, which
corresponds to a decision maker earning
arbitrarily large revenues or profits.

28
 For a minimization problem, an LP is unbounded if there
are points in the feasible region with arbitrarily small z-
values.
 Every LP with two variables must fall into one of the
following four cases.
 The LP has a unique optimal solution.
 The LP has alternative or multiple optimal solutions: Two or
more extreme points are optimal, and the LP will have an
infinite number of optimal solutions.
 The LP is infeasible: The feasible region contains no points.
 The LP unbounded: There are points in the feasible region
with arbitrarily large z-values (max problem) or arbitrarily
small z-values (min problem).

29

Potrebbero piacerti anche