You are on page 1of 21

Lecture 3

02/02/2018

Seborg, Mellichamp, Edgar, Doyle: Process Dynamics and Control, 3rd Edition
Edgar, Himmelblau, Lasdon: Optimization of Chemical Processes, 2nd Edition

2/2/2018 ENCH 442 1


Example
A section of chemical plant makes two specialty products from raw
materials A and B in two separate processes. A and B are in limited
supply and need not be totally consumed.
Process 1: A + B  E
Process 2: A +2B  F
The processing cost includes cost of utilities and supplies. Labor and
other costs are $200/day for process 1 and 350$/day for process 2.
These costs occur even if there is no production of E and F.
Formulate: Objective function(Total Profit per day)
Raw Material Max Available (lb/day) Cost (¢/lb)
A 40,000 15
B 30,000 20
Process Product Reactant Processing Selling price Max
requirement Cost Production
lb react/lb prod lb/day
1 E 2/3 A , 1/3 B 15 ¢/lb E 40 ¢/lb E 30,000
2
2/2/2018 F 1/2 A, 1/2 B ENCH 442 5 ¢/lb F 33 ¢/lb F 30,000
2
Example
𝑥𝑥𝐴𝐴 : lb/day A consumed
𝑥𝑥𝐵𝐵 : lb/day B consumed
𝑥𝑥𝐸𝐸 : lb/day E produced
𝑥𝑥𝐹𝐹 : lb/day F produced

2/2/2018 ENCH 442 3


The objective function for this
problem is
63%
A. 0.4𝑥𝑥𝐴𝐴 + 0.33𝑥𝑥𝐵𝐵 − 0.15𝑥𝑥𝐴𝐴 − 0.2𝑥𝑥𝐵𝐵 − 550
B. 0.25𝑥𝑥𝐸𝐸 + 0.28𝑥𝑥𝐹𝐹 − 0.15𝑥𝑥𝐴𝐴 − 0.2𝑥𝑥𝐵𝐵 − 550
C. 0.4𝑥𝑥𝐸𝐸 + 0.33𝑥𝑥𝐹𝐹 − 0.15𝑥𝑥𝐴𝐴 − 0.2𝑥𝑥𝐵𝐵 − 550
34%
D. 0.25𝑥𝑥𝐸𝐸 + 0.28𝑥𝑥𝐹𝐹 − 0.15𝑥𝑥𝐴𝐴 − 0.2𝑥𝑥𝐵𝐵

3%
0%

A. B. C. D.

2/2/2018 ENCH 442 4


Canonical form (Linear Programming
problem)
For vector 𝑥𝑥
Minimize ∶ 𝑓𝑓 𝑥𝑥 = ⋯ Objective function (Scalar)

Subject to : 𝐴𝐴. 𝑥𝑥 ≤ 𝑏𝑏 Inequality constraints

𝐴𝐴𝑒𝑒 . 𝑥𝑥 = 𝑏𝑏𝑒𝑒 Equality constraints

𝑥𝑥 ≥ 𝑙𝑙𝑏𝑏 Lower bound

𝑥𝑥 ≤ 𝑢𝑢𝑏𝑏 Upper bound

2/2/2018 ENCH 442 5


Unconstrained and Constrained
Optimization
• Unconstrained optimization:
• No inequality constraints
• All equality can be eliminated by variable substitution in
the objective function

2/2/2018 ENCH 442 6


Single Variable Optimization
Single independent variable that maximizes (or
minimizes) the objective function
• Assumption that objective function is unimodal with
respect to 𝑥𝑥 over the region of search
• Typically, upper and lower bound is specified for optimal
value of 𝑥𝑥 ( 𝑥𝑥 𝑜𝑜𝑜𝑜𝑜𝑜 )
• Methods we will consider are:
• Golden Section search method
• Quadratic Interpolation method

2/2/2018 ENCH 442 7


Multivariable Optimization
• Need efficient and robust numerical techniques
• Efficiency is important because solution requires
iterative approach.
• Trial and error solutions not recommended
• For instance, consider 4 variable grid search on
equally spaced grid
• For 10 values of each of the variable – 104 function
evaluations at grid intersections
• Still may not be optimal

2/2/2018 ENCH 442 8


Multivariable Optimization
• Brute force Methods
• Monte Carlo methods- relies on random number
generation
• Genetic algorithms- Intelligent search and focuses in
areas known to be useful
• Grid based Methods
• Pattern based Methods
• Sequential univariate searches
• Gradient- Start with initial guess, compute gradient and
proceed in the direction till optimum is reached

2/2/2018 ENCH 442 9


Linear Programming
Linear Objective function
Linear Constraints
For vector 𝑥𝑥
Minimize ∶ 𝑓𝑓 𝑥𝑥 = ⋯ Objective function (Scalar)

Subject to : 𝐴𝐴. 𝑥𝑥 ≤ 𝑏𝑏 Inequality constraints

𝐴𝐴𝑒𝑒 . 𝑥𝑥 = 𝑏𝑏𝑒𝑒 Equality constraints

𝑥𝑥 ≥ 𝑙𝑙𝑏𝑏 Lower bound

𝑥𝑥 ≤ 𝑢𝑢𝑏𝑏 Upper bound

2/2/2018 ENCH 442 10


Constraints
• Production constraints
• Raw material constraints
• Safety constraints
• Product specifications
• Material and Energy balances

2/2/2018 ENCH 442 11


Example
A chemical plant needs to process to types of crude A and B.
• At least 3 tons of crude must be processed.
• Crude A costs $20/ton to process whereas crude B cost
$30/ton to process. Processing cost must be kept to less than
$800 per day.
• Processed crude A yields 0.4 ton of gasoline per ton of crude
and crude B gives 0.5 ton of gasoline per ton of crude.
• The amount of crude B processed cannot be greater than
twice the crude A processed.
• Crude A processed cannot be greater than 15 tons and Crude
B cannot be greater than 20 tons.
How many tons of crude of each type must be processed to
maximize the amount of gasoline produced?

2/2/2018 ENCH 442 12


Linear Programming
Linear Objective function
For vector 𝑥𝑥
Objective function (Scalar)
Minimize ∶ 𝑓𝑓 𝑥𝑥 = −(0.4𝑥𝑥1 + 0.5𝑥𝑥2 )
Subject to : 𝑥𝑥1 + 𝑥𝑥2 ≥ 3
20𝑥𝑥1 + 30𝑥𝑥2 ≤ 800 Inequality constraints
Linear Constraints
𝑥𝑥2 ≤ 2𝑥𝑥1

𝐴𝐴𝑒𝑒 . 𝑥𝑥 = 𝑏𝑏𝑒𝑒 Equality constraints

𝑥𝑥 ≥ 𝑙𝑙𝑏𝑏 Lower bound


𝑥𝑥 ≤ 𝑢𝑢𝑏𝑏 Upper bound
2/2/2018 ENCH 442 13
Linear programming

𝑥𝑥2

𝑥𝑥1
2/2/2018 ENCH 442 14
Linear programming

𝑥𝑥2

𝑥𝑥1
2/2/2018 ENCH 442 15
Linear programming

𝑥𝑥2

𝑥𝑥1
2/2/2018 ENCH 442 16
Degrees of Freedom
• 𝑁𝑁𝑉𝑉 : Process variables (Input and Output)
• 𝑁𝑁𝐸𝐸 : Independent equations
• 𝑁𝑁𝐹𝐹 : Degrees of Freedom
𝑁𝑁𝐹𝐹 = 𝑁𝑁𝑉𝑉 − 𝑁𝑁𝐸𝐸
• 𝑁𝑁𝐹𝐹 = 0: exactly determined, unique solution
• 𝑁𝑁𝐹𝐹 > 0: underdetermined, atleast one variable to
be optimized
• 𝑁𝑁𝐹𝐹 < 0: overdetermined, no solution, least square
or similar criterion needed

2/2/2018 ENCH 442 17


Example –Refinery Production
Maximize the Profit

Volume percent yield Maximum Allowable


Crude #1 Crude #2 Production (bbl/day)

Gasoline 80 44 24000
Kerosene 5 10 2000
Fuel oil 10 36 6000
Processing cost ($/bbl) 0.5 1
2/2/2018 ENCH 442 18
Example
𝑥𝑥𝐶𝐶1 : lb/day Crude 1 consumed
𝑥𝑥𝐶𝐶2 : lb/day Crude 2 consumed
𝑥𝑥𝐺𝐺 : lb/day Gasoline produced
𝑥𝑥𝐾𝐾 : lb/day Kerosene produced
𝑥𝑥𝐹𝐹 : lb/day Fuel Oil produced
𝑥𝑥𝑅𝑅 : lb/day Residuals produced

2/2/2018 ENCH 442 19


The objective function for this
problem is
97%

A. 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 = 36𝑥𝑥𝐺𝐺 + 24𝑥𝑥𝐾𝐾 +


21𝑥𝑥𝐹𝐹 + 10𝑥𝑥𝑅𝑅 – 24.5𝑥𝑥𝐶𝐶1 − 16𝑥𝑥𝐶𝐶2
B. 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 = 80𝑥𝑥𝐺𝐺 + 5𝑥𝑥𝐾𝐾 +
10𝑥𝑥𝐹𝐹 − 0.5𝑥𝑥𝐶𝐶1 − 𝑥𝑥𝐶𝐶2
C. 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 = 44𝑥𝑥𝐺𝐺 + 10𝑥𝑥𝐾𝐾 + 36𝑥𝑥𝐹𝐹
D. 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 = 80𝑥𝑥𝐶𝐶1 + 44𝑥𝑥𝐶𝐶2

3% 0% 0%

A. B. C. D.

2/2/2018 ENCH 442 20


The constraints for the problem are.
Select all that apply

A. 𝑥𝑥𝐺𝐺 = 0.80𝑥𝑥𝐶𝐶1 + 0.44𝑥𝑥𝐶𝐶2 26%


25% 25%
B. 𝑥𝑥𝐶𝐶1 = 0.80𝑥𝑥𝐺𝐺 + 0.05𝑥𝑥𝐾𝐾 + 0.10𝑥𝑥𝐹𝐹
19%
C. 𝑥𝑥𝐾𝐾 = 0.05𝑥𝑥𝐶𝐶1 + 0.10𝑥𝑥𝐶𝐶2
D. 𝑥𝑥𝐹𝐹 = 0.10𝑥𝑥𝐶𝐶1 + 0.36𝑥𝑥𝐶𝐶2
E. 𝑥𝑥𝐺𝐺 = 0.80𝑥𝑥𝐶𝐶1 + 0.05𝑥𝑥𝐾𝐾 + 0.10𝑥𝑥𝐹𝐹 +
0.05𝑥𝑥𝑅𝑅
3%
F. 𝑥𝑥𝐶𝐶2 = 0.44𝑥𝑥𝐺𝐺 + 0.10𝑥𝑥𝐾𝐾 + 0.36𝑥𝑥𝐹𝐹 1%
2%
0%
G. 𝑥𝑥𝐺𝐺 = 0.1𝑥𝑥𝐶𝐶1 + 44𝑥𝑥𝐶𝐶2
A. B. C. D. E. F. G. H.
H. 𝑥𝑥𝑅𝑅 = 0.05𝑥𝑥𝐶𝐶1 + 0.1𝑥𝑥𝐶𝐶2
2/2/2018 ENCH 442 21

You might also like