Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

check #5 and the i need help of 6 a-d. if you can help me on the rest that would be much appreciated too. Your

image text in transcribed
image text in transcribed
image text in transcribed
check #5 and the i need help of 6 a-d. if you can help me on the rest that would be much appreciated too.
Your assignment Recal Exercise 2.13 from Rater (he Midwest Steel problem), assigned for homework. We can formulate this problema s inear programas tous Sets. R = set of raw materials = {Alloyl. Alloy2. Alloy3. Scrapl. Scrap21 C = set of characteristics = {Carbon, Nickel. Chromium. TemaleStrength} Parameters. HER = cost of raw materiali fori ER 4, = amount of raw material i available fori ER h = value of characteristic jin raw materiali forie Rjec 4; = lower bound for characteristic) for EC w = upper bound for characteristic j for jcc Decision variables. x=tons of raw material i used for i ER Objective function and constraints min 4* (total ext) (piece is 100 tons) Xxx, forje (characteristic requirements) ASX for CC (characteristic requirements) R OSX SA forier (nonnegativity, availability of raw materials) The sets above have the following concrete values R={Alloyl. Alloy2 Alloy3, Serup, Serap2] C = Cartoon Nickel, Chromium. TensileStrength) The parameters above have the following concrete values =100 HR R TER Not 150 50 No 2 120 50 Alloy 30 20 Scrat 15 30 Ser2 20 40 JEC Carbon 0020 0.030 0.008 0.040 Chromium 0.0130027 Tessilegth 50000 80000 Carbon Nickel Chromium Tonello Strength lay 0.0175 0.000 0.035 80000 Aby2 0.6245 0.000 0.008 40000 Nay 0.000 0.040 0.012 90000 Seact 0.0910 0.045 0.039 120000 Sa 0.0350 0.66 70000 In [34): inport pyono.environ as pyo 2a 15 points) Define lists and the define concrese values for the sus Rand Crespectively In [35): R - L'Alloys, AlloyAlloyScrapt. Scrap C'Carbon's 'Nickel'ironi Tesla Strength 25. (5 points) Defne dictionaries and a sat define concretesses for the parameese si respectively In 36): Alloy2:120, "Alley: Scrap':35. Scrap2:20 Alloyat:se, Allayar.se Alloy:20, Scrap':10 Scrap24 2 2c. 15 points) Define dictionaries 1 and that define concrete values for the parametest, ada, to je respective It [37]: 1 *Carton:.020, "Nickel":0.000, "Chromius: 0.013, Tensilestrength:50000 "Carbone.e3a, Nickel :2.6. Chromium:.027, Tensilestrength 10000 2 2d. 6 points, Deine dictionary that defines concrete values for the parameters k, toric Radje Use multidime Itdimensional (tuple keys In (38) (2.0175, 0.020, 0.035, 68000): "Alloy (e.e245, 0.3, 0.000, 40000): 'Alloy2 (0.6280, 0.60, 6.012, 90000)Alloy (2.8310, 0.045, 0.030, 120000) Scrap (0.0250, 6.055, 6.028, 70000): Scrap? 3. (points) Intialze a concrete model named model In [19]; model = pyo.Concretamodel() 4. (5 points) Define the decision variables x, for i Ras nodel.: Mare sure you seciyernomresavey View tackle trer upper sounds later as constraints In [40] nodel.x = pyo. Var(.domain.pyo. Humillegativ hals) 5. (10 points) Define the objective function as nodelce In [48]: def rule(model): return sun(c[1] model.x[1] for 1 in R) model.obj = pyo.Objectve(rule = obj_rule, Sense = pyo maximize) 6a. (5 points) Define the "piece is 100 tons constraint as model.piece. A Next, in 6b and 6c, we split the characteristic requirement constraints into two separate sets of inequality constraints. 66. (10 points) Define the characteristic requirement lower bound constraints s , x, 2x sk,x forje ICR IGR as model characteristic_lower n]: 6c. (10 points) Define the characteristic requirement upper bound constraints , X, Xu, x for j ER HER as model.Characteristic_upper 6d. (10 points) Define the availability constraints x, Sa for i ER as nodel.availability. 7. (5 points) Solve the model and save the result as result 8. (5 points) Print the status of the solving process of the model. : 9. (10 points) If the solver terminated with an optimal solution, print the optimal solution and its value. Your assignment Recal Exercise 2.13 from Rater (he Midwest Steel problem), assigned for homework. We can formulate this problema s inear programas tous Sets. R = set of raw materials = {Alloyl. Alloy2. Alloy3. Scrapl. Scrap21 C = set of characteristics = {Carbon, Nickel. Chromium. TemaleStrength} Parameters. HER = cost of raw materiali fori ER 4, = amount of raw material i available fori ER h = value of characteristic jin raw materiali forie Rjec 4; = lower bound for characteristic) for EC w = upper bound for characteristic j for jcc Decision variables. x=tons of raw material i used for i ER Objective function and constraints min 4* (total ext) (piece is 100 tons) Xxx, forje (characteristic requirements) ASX for CC (characteristic requirements) R OSX SA forier (nonnegativity, availability of raw materials) The sets above have the following concrete values R={Alloyl. Alloy2 Alloy3, Serup, Serap2] C = Cartoon Nickel, Chromium. TensileStrength) The parameters above have the following concrete values =100 HR R TER Not 150 50 No 2 120 50 Alloy 30 20 Scrat 15 30 Ser2 20 40 JEC Carbon 0020 0.030 0.008 0.040 Chromium 0.0130027 Tessilegth 50000 80000 Carbon Nickel Chromium Tonello Strength lay 0.0175 0.000 0.035 80000 Aby2 0.6245 0.000 0.008 40000 Nay 0.000 0.040 0.012 90000 Seact 0.0910 0.045 0.039 120000 Sa 0.0350 0.66 70000 In [34): inport pyono.environ as pyo 2a 15 points) Define lists and the define concrese values for the sus Rand Crespectively In [35): R - L'Alloys, AlloyAlloyScrapt. Scrap C'Carbon's 'Nickel'ironi Tesla Strength 25. (5 points) Defne dictionaries and a sat define concretesses for the parameese si respectively In 36): Alloy2:120, "Alley: Scrap':35. Scrap2:20 Alloyat:se, Allayar.se Alloy:20, Scrap':10 Scrap24 2 2c. 15 points) Define dictionaries 1 and that define concrete values for the parametest, ada, to je respective It [37]: 1 *Carton:.020, "Nickel":0.000, "Chromius: 0.013, Tensilestrength:50000 "Carbone.e3a, Nickel :2.6. Chromium:.027, Tensilestrength 10000 2 2d. 6 points, Deine dictionary that defines concrete values for the parameters k, toric Radje Use multidime Itdimensional (tuple keys In (38) (2.0175, 0.020, 0.035, 68000): "Alloy (e.e245, 0.3, 0.000, 40000): 'Alloy2 (0.6280, 0.60, 6.012, 90000)Alloy (2.8310, 0.045, 0.030, 120000) Scrap (0.0250, 6.055, 6.028, 70000): Scrap? 3. (points) Intialze a concrete model named model In [19]; model = pyo.Concretamodel() 4. (5 points) Define the decision variables x, for i Ras nodel.: Mare sure you seciyernomresavey View tackle trer upper sounds later as constraints In [40] nodel.x = pyo. Var(.domain.pyo. Humillegativ hals) 5. (10 points) Define the objective function as nodelce In [48]: def rule(model): return sun(c[1] model.x[1] for 1 in R) model.obj = pyo.Objectve(rule = obj_rule, Sense = pyo maximize) 6a. (5 points) Define the "piece is 100 tons constraint as model.piece. A Next, in 6b and 6c, we split the characteristic requirement constraints into two separate sets of inequality constraints. 66. (10 points) Define the characteristic requirement lower bound constraints s , x, 2x sk,x forje ICR IGR as model characteristic_lower n]: 6c. (10 points) Define the characteristic requirement upper bound constraints , X, Xu, x for j ER HER as model.Characteristic_upper 6d. (10 points) Define the availability constraints x, Sa for i ER as nodel.availability. 7. (5 points) Solve the model and save the result as result 8. (5 points) Print the status of the solving process of the model. : 9. (10 points) If the solver terminated with an optimal solution, print the optimal solution and its value

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

SQL Instant Reference

Authors: Gruber, Martin Gruber

2nd Edition

0782125395, 9780782125399

More Books

Students also viewed these Databases questions

Question

Whats the ideal outcome?

Answered: 1 week ago