بسم الله الرحمن الرحيم CONTENTS EXERCISES DIET PROBLEM REFERENCES

Presentation on theme: "بسم الله الرحمن الرحيم CONTENTS EXERCISES DIET PROBLEM REFERENCES"— Presentation transcript:

بسم الله الرحمن الرحيم CONTENTS EXERCISES DIET PROBLEM REFERENCES
BASIC CONCEPTS EXERCISES بسم الله الرحمن الرحيم DIET PROBLEM REFERENCES WHO WE ARE

CONTENTS CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
BASIC CONCEPTS Linear programming problems BASIC CONCEPTS Graphical method of solution EXERCISES EXERCISES Problem 1 Problem 2 DIET PROBLEM Problem 3 Graphical solution exercise REFERENCES DIET PROBLEM REFERENCES WHO WE ARE

DIET PROBLEM Diet Problem CONTENTS EXERCISES DIET PROBLEM REFERENCES
BASIC CONCEPTS Weight is a big problem in our live , but do you know that there are some linear programming online solutions ? EXERCISES DIET PROBLEM From here I invite you to visit the following link and have more benefits in your life . REFERENCES WHO WE ARE

WHO WE ARE WHO WE ARE? CONTENTS HANAN HASAN AL-MARHABI EXERCISES
BASIC CONCEPTS HANAN HASAN AL-MARHABI GRADUATED FROM KING ABDULAZIZ UNIVERSITY EXERCISES WORK AS A TEACHER ASSESTANT IN KING SAUD UNIVERSITY DIET PROBLEM REFERENCES FOR MORE INFORMATION, WELCOME AT HANAN’S WEBSITE WHO WE ARE TO:

BASIC CONCEPTS Basic concepts involve ; - Linear programming problems
CONTENTS Basic concepts involve ; BASIC CONCEPTS - Linear programming problems EXERCISES - Graphical method of solution DIET PROBLEM REFERENCES WHO WE ARE

BASIC CONCEPTS LINEAR PROGRAMMING PROBLEMES CONTENTS EXERCISES
A linear programming problem is one in which we are to find the maximum or minimum value of a linear expression; BASIC CONCEPTS EXERCISES aX1 + bX2 + cX (called the objective function), It would be Max z Or Min c DIET PROBLEM subject to a number of linear constraints of the form REFERENCES aX1 + bX2 + cX ≤ N WHO WE ARE Or aX1 + bX2 + cX ≥ N. X1 , X2 , X3 , . . .> 0

BASIC CONCEPTS LINEAR PROGRAMMING PROBLEMES EXSERCISE CONTENTS
The largest or smallest value of the objective function is called the optimal value, and EXERCISES a collection of values of X1, X2, X3, that gives the optimal value constitutes an optimal solution. DIET PROBLEM The variables X1, X2, X3, are called the decision variables. REFERENCES EXSERCISE WHO WE ARE

BASIC CONCEPTS LINEAR PROGRAMMING PROBLEMES CONTENTS EXERCISES
If the objective function is BASIC CONCEPTS Max z = 3X1- 2X2 + 4X3 And the constraints are; EXERCISES 4X1 + 3X2 – X3 ≥ 3 X1+ 2X2 + X3 ≤ 4 DIET PROBLEM X1 , X2 , X3 , . . .> 0 Why can't I simply choose, say, X3 to be really large (X3 = 1,000,000 say) and thereby make Max z as large as I want? You can't because; REFERENCES WHO WE ARE A - That would make z too large. B – You have to change X1 first. C – It would violate the second constrain .

BASIC CONCEPTS GRAPHICAL METHOD OF SOLUTION CONTENTS EXERCISES
The graphical method for solving linear programming problems in two unknowns is as follows; BASIC CONCEPTS X2 X1 A- Graph the feasible region by Draw the line ax + by = c ...(1)   For each constraint,. EXERCISES B- Compute the coordinates of the corner points. DIET PROBLEM C- Substitute the coordinates of the corner points into the objective function to see which gives the optimal value. REFERENCES WHO WE ARE D- Optimal solutions always exist when the feasible region is bounded, but may or may not exist when the feasible region is unbounded.

EXERCISES Problem 1 Problem 2 problem 3 Graphical solution exercise
CONTENTS BASIC CONCEPTS Problem 1 Problem 2 problem 3 Graphical solution exercise EXERCISES DIET PROBLEM REFERENCES WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
A cargo plane has three compartments for storing cargo: front, centre and rear. These compartments have the following limits on both weight and space: BASIC CONCEPTS EXERCISES Compartment Weight capacity (tones) Space capacity (cubic meters) Front 10 6800 Center 16 8700 rear 18 5300 DIET PROBLEM Furthermore, the weight of the cargo in the respective compartments must be the same proportion of that compartment's weight capacity to maintain the balance of the plane. REFERENCES WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE Cont …
The following four cargoes are available for shipment on the next flight: BASIC CONCEPTS Cargo Weight capacity (tones) Volume (cubic meters/tone) Profit (£/tone) C1 18 480 310 C2 15 650 380 C3 23 580 350 C4 12 390 285 EXERCISES DIET PROBLEM Any proportion of these cargoes can be accepted. The objective is to determine how much (if any) of each cargo C1, C2, C3 and C4 should be accepted and how to distribute each among the compartments so that the total profit for the flight is maximized. REFERENCES WHO WE ARE Formulate the above problem as a linear program

EXERCISES solution CONTENTS EXERCISES constraints : DIET PROBLEM
here I have 4 cargoes and I need to distribute them among three compartments in the plane, Cargoes : C1 , C2 , C3 , C4 Compartments : front , center , rear My problem is search how can I get best distribution that subject to mentioned constraints. BASIC CONCEPTS EXERCISES DIET PROBLEM constraints : Here I have tow major types of constraints, Cargoes constraints - compartment constraints REFERENCES WHO WE ARE

EXERCISES Cont … CONTENTS First : cargo constraints : EXERCISES
Weights constraints of each cargo respected among each compartment , and as I have 4 cargoes I will have 4 constraints BASIC CONCEPTS EXERCISES C1 C2 C3 C4 let assume Xij , i =cargo , j = plane compartment DIET PROBLEM Weights X11 + X12 +X13 < 18 REFERENCES X21 + X22 +X23 < 15 X31 + X32 +X33 < 23 WHO WE ARE X41 + X42 +X43 < 12

EXERCISES Cont … CONTENTS Second: compartment constraints : EXERCISES
here I have 3 compartments so I will have 4 constraints related to weights and volumes as mentioned. BASIC CONCEPTS let assume Xij , i =cargo , j = plane compartment EXERCISES Weight constraints X11 + X21 +X31 +X41 < 10 X12 + X22 +X32 +X42 < 16 DIET PROBLEM X13 + X23 +X33 +X43 < 8 C1 C2 C3 C4 REFERENCES Volume constraints 480X11 + 650X21 +580X31 +390X41 < 6800 480X12 + 650X22 +580X32 +390X42 < 8700 WHO WE ARE 480X13 + 650X23 +580X33 +390X43 < 5300

EXERCISES Cont… CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
Final constraints is the weight of the cargo in the respective compartments must be the same proportion of that compartment's weight capacity to maintain the balance of the plane BASIC CONCEPTS EXERCISES 8 10 16 DIET PROBLEM those proportions should be same , so proportion for any compartment equal to all cargos divided by weight of that compartment , so constraint will be : REFERENCES X11 + X21 +X31 +X41 X12 + X22 +X32 +X42 X13 = + X23 +X33 = +X43 WHO WE ARE 10 8 16 Xij >

EXERCISES Objective Cont… CONTENTS
BASIC CONCEPTS The objective is to maximize total profit : Max z = EXERCISES 310(X11 + X12 +X13) + 380(X21 + X22 +X23) + 350(X31 + X32 +X33) + 385 (X41 + X42 +X43) DIET PROBLEM REFERENCES WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
A company manufactures four products (1,2,3,4) on two machines (X and Y). The time (in minutes) to process one unit of each product on each machine is shown below: BASIC CONCEPTS product X Y 1 10 27 2 12 19 3 13 33 4 8 23 EXERCISES DIET PROBLEM REFERENCES The profit per unit for each product (1,2,3,4) is £10, £12, £17 and £8 respectively. Product 1 must be produced on both machines X and Y but products 2, 3 and 4 can be produced on either machine. WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
The factory is very small and this means that floor space is very limited. Only one week's production is stored in 50 square meters of floor space where the floor space taken up by each product is 0.1, 0.15, 0.5 and 0.05 (square meters) for products 1, 2, 3 and 4 respectively. BASIC CONCEPTS EXERCISES Customer requirements mean that the amount of product 3 produced should be related to the amount of product 2 produced. Over a week approximately twice as many units of product 2 should be produced as product 3. DIET PROBLEM Machine X is out of action (for maintenance/because of breakdown) 5% of the time and machine Y 7% of the time. REFERENCES Assuming a working week 35 hours long formulate the problem of how to manufacture these products as a linear program. WHO WE ARE

EXERCISES solution CONTENTS EXERCISES DIET PROBLEM REFERENCES
here 4 products produced by tow machines Let assume BASIC CONCEPTS Xi = the amount of product i(1,2,3,4) produced by machine X Yi = the amount of product (1,2,3,4) produced by machine Y EXERCISES each product can be produced by any of tow machines so will expressed by tow variables (X2 , Y2). ( X3,Y3), (X4,Y4 ) , just product 1 should produced by both machines so it will expressed on one variable ( X1 ) DIET PROBLEM REFERENCES So variables are : X1 , X2 , Y2 , X3 , Y3 , X4 , Y4 WHO WE ARE

EXERCISES Cont… CONTENTS Constraints : EXERCISES DIET PROBLEM
The factory is very small and this means that floor space is very limited. Only one week's production is stored in 50 square meters of floor space where the floor space taken up by each product is 0.1, 0.15, 0.5 and 0.05 (square meters) for products 1, 2, 3 and 4 respectively. CONTENTS Constraints : Machine X is out of action (for maintenance/because of breakdown) 5% of the time and machine Y 7% of the time. Floor space : Over a week approximately twice as many units of product 2 should be produced as product 3. BASIC CONCEPTS 0.1X1 + 0.15(X2 + Y2) + 0. 5(X3 + Y3) EXERCISES + 0.05(X4 + Y4) < 50 Costumer requirement : DIET PROBLEM X2 + Y2 = 2(X3 + Y3) Available time : REFERENCES 10X1 +12 X2 +13X3 +8X4 < 0.95 (35) (60) WHO WE ARE 27Y1 + 19Y2 +33Y3 +23Y4 < 0.93 (35) (60) Xij >

EXERCISES Cont… CONTENTS Objective : EXERCISES DIET PROBLEM REFERENCES
The profit per unit for each product (1,2,3,4) is £10, £12, £17 and £8 respectively. CONTENTS BASIC CONCEPTS Objective : EXERCISES Max z = 10X1 + 12(X2 + Y2) + 17(X3 + Y3) + 8(X4 + Y4) DIET PROBLEM REFERENCES WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
A company assembles four products (1, 2, 3, 4) from delivered components. The profit per unit for each product (1, 2, 3, 4) is £10, £15, £22 and £17 respectively. The maximum demand in the next week for each product (1, 2, 3, 4) is 50, 60, 85 and 70 units respectively. BASIC CONCEPTS EXERCISES There are three stages (A, B, C) in the manual assembly of each product and the man-hours needed for each stage per unit of product are shown below: DIET PROBLEM Sages Product 1 Product 2 Prod6uct 3 Product 4 A 2 1 B 4 C 3 6 5 REFERENCES WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE Cont…
The nominal time available in the next week for assembly at each stage (A, B, C) is 160, 200 and 80 man-hours respectively. BASIC CONCEPTS It is possible to vary the man-hours spent on assembly at each stage such that workers previously employed on stage B assembly could spend up to 20% of their time on stage A assembly and workers previously employed on stage C assembly could spend up to 30% of their time on stage A assembly. EXERCISES DIET PROBLEM Production constraints also require that the ratio (product 1 units assembled)/(product 4 units assembled) must lie between 0.9 and 1.15. REFERENCES Formulate the problem of deciding how much to produce next week as a linear program. WHO WE ARE

EXERCISES solution CONTENTS EXERCISES
here 4 products produced Let assume BASIC CONCEPTS Xi = the amount of product i(1,2,3,4) produced by machine X Variables : X1 , X2 , X3 , X4 EXERCISES additional transferred time variables : TBA ,TCA DIET PROBLEM TBA be the amount of time transferred from B to A TCA be the amount of time transferred from C to A REFERENCES WHO WE ARE

EXERCISES Cont… CONTENTS Constraints : EXERCISES DIET PROBLEM + TBA
The nominal time available in the next week for assembly at each stage (A, B, C) is 160, 200 and 80 man-hours respectively. CONTENTS The maximum demand in the next week for each product (1, 2, 3, 4) is 50, 60, 85 and 70 units respectively. Constraints : Maximum demand : BASIC CONCEPTS X1 < 50 X2 < 60 < X3 85 < EXERCISES X3 70 Work time : workers previously employed on stage B assembly could spend up to 20% of their time on stage A assembly and workers previously employed on stage C assembly could spend up to 30% of their time on stage A assembly. DIET PROBLEM 2X1 +2 X2 + X3 + X4 < 160 + TBA + TCA 2X1 + 4X2 +X3 +2X4 < 160 - TBA REFERENCES 3X1 + 6X2 +X3 - TCA +5X4 < 80 WHO WE ARE TBA < 0.2(200) TCA < 0.3(80)

EXERCISES Cont… CONTENTS Constraints : EXERCISES DIET PROBLEM
the ratio (product 1 units assembled)/(product 4 units assembled) must lie between 0.9 and 1.15. Ratio constraint : The profit per unit for each product (1, 2, 3, 4) is £10, £15, £22 and £17 respectively BASIC CONCEPTS X1 0.9 < < 1.15 X4 EXERCISES Xij > DIET PROBLEM Objective : REFERENCES Max z = 10X1 +15 X2 + 22X3 + 17X4 WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE
Graphical solution exercise CONTENTS Max Z = 50x + 18y   Subject to the constraints : 2X + Y < 100 X + Y < 80   X , Y > 0      BASIC CONCEPTS EXERCISES DIET PROBLEM Sep 1 : Turn constrains into equations 2X + Y = 100 REFERENCES X + Y = 80 WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE Cont…
Sep 2 : Draw straight lines for the following equations , 2X + Y = 100 BASIC CONCEPTS X + Y = 80 To determine tow points on straight line 2X + Y = 100 EXERCISES Put Y = 0 Put X = 0 2X = 100 y = 100 DIET PROBLEM => X = 50 => Y = 100 (50, 0) , (0 , 100 ) are the points on the line (1) To determine tow points on straight line X + Y = 80 REFERENCES Put Y = 0 Put X = 0 X = 80 y = 80 WHO WE ARE => X = 80 => Y = 80 (80, 0) , (0 , 80 ) are the points on the line (2)

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE Cont…
(50, 0) , (0 , 100 ) line (1) BASIC CONCEPTS (80, 0) , (0 , 80 ) line (2) Y X EXERCISES (0 , 100 ) A- Draw the feasible . A (0 , 80 ) B DIET PROBLEM B- Mark the corner points then determine values of (X,Y ) on each corner’s point. (20 , 60 ) REFERENCES C (0 , 0 ) D (50, 0) (80, 0) WHO WE ARE

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE Cont…
Y X Cont… (0 , 100 ) CONTENTS A (0 , 80 ) B (20 , 60 ) Step 3 : Substitute the coordinates of the corner points into the objective function to see which gives the optimal value. BASIC CONCEPTS C EXERCISES (0 , 0 ) D (50, 0) (80, 0) Corner points O.F. O.S. DIET PROBLEM A ( 0 , 80 ) 50 (0) + 18 (80)= 1440 B ( 20 , 60 ) 50 (20) + 18 (60)= 2080 B ( 20 , 60 ) REFERENCES C ( 50 , 0 ) 50 (50) + 18 (0)= 2500 WHO WE ARE D ( 0 , 0 ) 50 (0) + 18 (0)= 0 X = 20 Y = 60 Max z = 2080

EXERCISES CONTENTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE Cont…
Accurate results : By use the mathematical method 2X + Y = 100 BASIC CONCEPTS (- 1 ) × X + Y = 80 X = 20 EXERCISES Then use ( X=20 ) to determine Y on any equation X + Y = 80 X = 20 DIET PROBLEM Y = 80 REFERENCES X + Y = ( 20 , 80 ) Max Z = 50x + 18y WHO WE ARE = 50 (20) + 18 (60)= 2080

REFERENCES REFERENCES ; CONTENTS EXERCISES DIET PROBLEM REFERENCES
BASIC CONCEPTS EXERCISES DIET PROBLEM REFERENCES WHO WE ARE