Upcoming SlideShare
×

# LINEAR PROGRAMMING

7,039 views

Published on

what is linear programming,primal and dual problems,methods to solve -graphical and simplex

16 Likes
Statistics
Notes
• Full Name
Comment goes here.

Are you sure you want to Yes No
• Be the first to comment

Views
Total views
7,039
On SlideShare
0
From Embeds
0
Number of Embeds
17
Actions
Shares
0
554
0
Likes
16
Embeds 0
No embeds

No notes for slide

### LINEAR PROGRAMMING

1. 1.  Many real-life problems consist of maximizing or minimizing a certain quantity subject to some constraints.  Linear programming is one approach to this kind of problem.  We will see examples in which we are maximizing or minimizing a linear expression in any number of variables subject to some linear constraints.  This technique is applied to a wide variety of problems in industry and science.
2. 2.  LP is the mathematical modelling technique useful for the allocation of “scarce or limited” resources such as labor ,material , machine ,time ,warehouse space etc…,to several competing activities such as product , service , job, new equipments ,projects ,etc..on the basis of given criteria of optimality. A mathematical technique used to obtain an optimal solution of resources allocation problems,such as product planning.
3. 3. . it is a mathematical tool or technique or technique for efficient or effective utilization of limited resources to achieve organisation objectives ( maximise profit or minimum cost) When solving a problem using linear programming ,the program is put into number of linear inequalities and then an attempt is made to maximise (or minimise ) the input.
4. 4. • There must be a well defined objective function. • There must be a constraint on the amount. • There must be alternative course of action. • The decision variable should be interrelated and non negative . • The source must be limited in supply.
5. 5. General problem : Given a linear expression z=ax+by in two variables x and y, find values of x and y that either maximize or minimize z subject to the linear constraints: And x>0,y>0  The function z in the above problem is called the objective function.  If (x, y) satisfies all the constraints, then it is called a feasible solution.  The set of all feasible solutions is a subset of the xy-plane called the feasible region.
6. 6. . • Note that each constraint of the form ax+by=c represents a straight line in the xy-plane, whereas each constraint of the form defines a half- plane that includes its boundary line • The feasible region is then an intersection of finitely many lines and half- planes. If the feasible region can be enclosed in a sufficiently large circle, it is called bounded; otherwise it is called unbounded. • If a feasible region is empty (contains no points), then the constraints are inconsistent and the problem has no solution. The extreme points of a feasible region are those boundary points that are intersections of the straight-line boundary segments of the region. In a linear programming problem, the following theorem tells us when we will be successful and what points to search for.
7. 7. • It helps in attaining optimal use of productive factors. • It improves the quality of decision. • It improve better tools for meeting the changing condition. • for large problems the computation difficulties are enormous. • It is only applicable to static situation. • LP deals with the problems with single objective.
8. 8. • The graphical method is limited to LP problems involving two decision variables and a limited number of constraints due to the difficulty of graphing and evaluating more than two decision variables. • This restriction severely limits the use of the graphical method for real-world problems • Also the graphical method is simple and very easy to understand
9. 9. Constructing the LP problem requires four steps: Step 1. Define the decision variables- describe the decisions to be made Step 2. Define the objective function- define the goal we want to achieve Step 3. Determine the constraints- some limitation under which the enterprise mus operate Step 4. Declare sign restrictions- Can the decision variable assume only nonnegati values, or is it allowed to assume both positive and negative values? The objective function deals with two types of objectives: Maximization of such things as profits, revenue, or productivity Minimization of such things as cost, time, or scrap
10. 10. • Product mix problem- Beaver Creek Pottery company • How many bowls and mugs should be produced to maximize profits given labor and materials constraints? • Product resource requirements and unit profit:
11. 11. Resource 40 hrs of labor per day Availability: 120 lbs of clay Decision x1= number of bowls to produce per day Variables: x2= number of mugs to produce per day Objective Maximize z = \$40x1 + \$50x2 Function Where z= profit per day Resource 1x1 + 2x2 ≤ 40 hours of labor Constraints : 4x1 +3x2≤ 120 pounds of clay Non negativity x1 ≥0 x2 ≥0 Constraints :
12. 12. • Maximize z = \$40x1 + \$50x2 • Subject to : x1 + 2x2 ≤ 40 4x1 +3x2 ≤ 120 x1 ≥0 x2 ≥0
13. 13. • A feasible solution does not violate any of the constraints • Example: x1 = 5 bowls x2 = 10 mugs z = \$40x1 + \$50x2 = 700 • Labor constraint check: 1(5) + 2(10)=25 < 40 hours • Clay constraint check : 4(5) + 3(10) =70 < 120 pounds
14. 14. • An infeasible solution violates atleast one of the constraints • Example: x1 = 10 bowls x2 = 20 mugs z = \$40x1 + \$50x2 = 1400 • Labor constraint check: 1(10) + 2(20)=50 > 40 hours
15. 15. ) • If an LPP has many constraints, then it may be long and tedious to find all the corners of the feasible region. There is another alternate and more general method to find the optimal solution of an LP, known as 'ISO profit or ISO cost method„ • Example- Suppose the LPP is to optimize z= ax+by subject to the constraints a1x + b1y ≤ (or ≥) c1 a2x + b2y ≤ (or ≥) c2 X≥0 Y≥0
16. 16. • This method of optimization involves the following method. • Step 1: Draw the half planes of all the constraints • Step 2: Shade the intersection of all the half planes which is the feasible region. • Step 3: Since the objective function is Z = ax + by, draw a dotted line for the equation ax + by = k, where k is any constant. Sometimes it is convenient to take k as the LCM of a and b. • Step 4: To maximise Z draw a line parallel to ax + by = k and farthest from the origin. This line should contain at least one point of the feasible region. Find the coordinates of this point • To minimise Z draw a line parallel to ax + by = k and nearest to the origin. This line should contain at least one point of the feasible region. Find the co- ordinates of this point by solving the equation of the line on which it lies. • Step 5: If (x1, y1) is the point found in step 4, then x = x1, y = y1, is the optimal solution of the LPP and Z = ax1 + by1 is the optimal value.
17. 17. Example: Solve the following LPP graphically using ISO- profit method. maximize Z =120x + 100y Subject to the constraints 10x + 5y <= 80 6x + 6y <=66 4x + 8y >= 24 5x + 6y <= 90 x>=0 , y>=0
18. 18. Identify all the half planes of the constraints. The intersection of all these half planes is the feasible region as shown in the figure.
19. 19. • Give a constant value 600 to Z in the objective function, then we have an equation of the line 120x + 100y = 600 or 6x + 5y= 30 …. (1) P1Q1 is the line corresponding to the equation 6x + 5y = 30. • P2Q2 is a line parallel to P1Q1 and has one point 'M' which belongs to feasible region and farthest from the origin. If we take any line P3Q3 parallel to P2Q2 away from the origin, it does not touch any point of the feasible region. • The co-ordinates of the point M can be obtained by solving the equation 2x + y = 16 and x + y =11 which give x = 5 and y = 6 • The optimal solution for the objective function is x = 5 and y = 6 • The optimal value of Z 120 (5) + 100 (6) = 600 + 600 = 1200
20. 20. The theory of duality is a very elegant and important concept within the field of operations research. This theory was first developed in relation to linear programming, but it has many applications, and perhaps even a more natural and intuitive interpretation, in several related areas such as nonlinear programming, networks and game theory.
21. 21. The notion of duality within linear programming asserts that every linear program has associated with it a related linear program called its dual. The original problem in relation to its dual is termed the primal. it is the relationship between the primal and its dual, both on a mathematical and economic level, that is truly the essence of duality theory.
22. 22. There is a small company in Melbourne which has recently become engaged in the production of office furniture. The company manufactures tables, desks and chairs. The production of a table requires 8 kgs of wood and 5 kgs of metal and is sold for \$80; a desk uses 6 kgs of wood and 4 kgs of metal and is sold for \$60; and a chair requires 4 kgs of both metal and wood and is sold for \$50. We would like to determine the revenue maximizing strategy for this company, given that their resources are limited to 100 kgs of wood and 60 kgs of metal.
23. 23. max x Z x x x80 60 501 2 3 8 6 4 100 5 4 4 60 0 1 2 3 1 2 3 1 2 3 x x x x x x x x x, ,
24. 24. Now consider that there is a much bigger company in Melbourne which has been the lone producer of this type of furniture for many years. They don't appreciate the competition from this new company; so they have decided to tender an offer to buy all of their competitor's resources and therefore put them out of business.
25. 25. The challenge for this large company then is to develop a linear program which will determine the appropriate amount of money that should be offered for a unit of each type of resource, such that the offer will be acceptable to the smaller company while minimizing the expenditures of the larger company.
26. 26. 8 5 80 6 4 60 4 4 50 0 1 2 1 2 1 2 1 2 y y y y y y y y, min y w y y100 601 2
27. 27. a x a x a x b a x a x a x b a x a x a x b x x x n n n n m m mn n m n 11 1 12 2 1 1 21 1 22 2 2 2 1 1 2 2 1 2 0 ... ... ... ... ... ... ... ... ... ... ... , ,..., max x j j j n Z c x 1
28. 28. a y a y a y c a y a y a y c a y a y a y c y y y m m m m n n mn m n m 11 1 21 2 1 1 12 1 22 2 2 2 1 1 2 2 1 2 0 ... ... ... ... ... ... ... ... ... ... ... , ,..., min y i i m iw b y 1
29. 29. z Z cx s t Ax b x x *: max . . 0 w* : min x w yb s.t. yA c y 0
30. 30. 1. The number of variables in the dual problem is equal to the number of constraints in the original (primal) problem. The number of constraints in the dual problem is equal to the number of variables in the original problem. 2. Coefficient of the objective function in the dual problem come from the right-hand side of the original problem. 3. If the original problem is a max model, the dual is a min model; if the original problem is a min model, the dual problem is the max problem. 4. The coefficient of the first constraint function for the dual problem are the coefficients of the first variable in the constraints for the original problem, and the similarly for other constraints. 5. The right-hand sides of the dual constraints come from the objective function coefficients in the original problem.
31. 31. 1. The dual of the dual problem is again the primal problem. 2. Either of the two problems has an optimal solution if and only if the other does; if one problem is feasible but unbounded, then the other is infeasible; if one is infeasible, then the other is either infeasible or feasible/unbounded.
32. 32. The graphical method is useful only for problems involving two decision variables and relatively few problem constraints. What happens when we need more decision variables and more problem constraints? We use an algebraic method called the simplex method, which was developed by George B. DANTZIG (1914-2005) in 1947 while on assignment with the U.S. Department of the air force.
33. 33. A linear programming problem is said to be a standard minimization problem in standard form if its mathematical model is of the following form: Minimize the objective function Subject to problem constraints of the form With non-negative constraints 1 1 2 2 ... , 0n na x a x a x b b 1 2, ,..., 0nx x x Zmin = c1x1 + c2 x2 + ……..+ cn xn
34. 34. Basic variables are selected arbitrarily with the restriction that there be as many basic variables as there are equations. The remaining variables are non-basic variables. This system has two equations, we can select any two of the four variables as basic variables. The remaining two variables are then non-basic variables. A solution found by setting the two non-basic variables equal to 0 and solving for the two basic variables is a basic solution. If a basic solution has no negative values, it is a basic feasible solution. 1 2 1 1 2 2 2 32 3 4 84 x x s x x s
35. 35. • Optimal solution(x*) is the best solution i.e. the value of x for which objective function(Z) is minimum or maximum. • To find x*, simplex method must decide which component “enters” by becoming positive and which component “leaves” by becoming zero. • This exchange is chosen so as to lower the total cost or to increase the profit.
36. 36.  Minimize the cost c.x = 3x1 + x2 + 9x3 + x4 Constraints: x>=0 Equations Ax=b : x1 + 2x3 + x4 = 4 x2 + x3 - x4 = 2
37. 37. Step 1.Write equations in terms of basic variable and z in terms of non basic variables, x1 = 4 – 2x3 – x4 x2 = 2 – x3 + x4 c.x = 3 ( 4 – 2x3 – x4 ) + ( 2 – x3 + x4 ) + 9x3 + x4 c.x = 14 + 2x3 – x4
38. 38. c.x = 14 + 2x3 – x4 Step 2.As x3 and x4 are non basic variables, x3=x4=0. To minimize c.x either x3 should be decreased or x4 should be increased. So, entering variable is x4. x1 = 4 – 2x3 – x4 <- binding equation x2 = 2 – x3 + x4 Leaving variable is x1.
39. 39. Step 1.Write equations in terms of basic variable (x2,x4) and z in terms of non basic variables (x1,x3) as they are zero. x4 = 4 – 2x3 – x1 x2 = 2 – x3 + (4 – 2x3 – x1 ) x2 = 6 – 3x3 – x1 c.x = 14 + 2x3 – (4 – 2x3 – x1 ) c.x = 10 + 4x3 + x1
40. 40. • As, x3 and x1 are zero so they cannot be reduced further. • Therefore cost c.x cannot be minimized further. • Z=10 is the minimum cost. • Value of constraints are x1=0, x2=6, x3=0, x4=4 • The optimal solution x* = ( 0, 6, 0,4 )