1 | #*--------------------------------------------------------------------- |
---|
2 | * Hydrolysis of propylene glycol in a unsteady-state CSTR |
---|
3 | *---------------------------------------------------------------------- |
---|
4 | * Solved problem from Fogler (1999). |
---|
5 | * Problem number: 9-4, 9-5, and 9-7 |
---|
6 | * Page: 504 at 517 (Brazilian version, 2002) |
---|
7 | *---------------------------------------------------------------------- |
---|
8 | * |
---|
9 | * Description: |
---|
10 | * The propylene glycol is produced for hydrolysis reaction of |
---|
11 | * propylene oxide in a CSTR: |
---|
12 | * CH3(O)CHCH3 + H2O -> CH2(OH)CH2(OH)CH3 |
---|
13 | * This sample calculates the outlet molar concentration and |
---|
14 | * temperature as function of the time in a CSTR jacketed. It is |
---|
15 | * possible to identify the MSS (Multiple Steady-State). |
---|
16 | * |
---|
17 | * Assumptions |
---|
18 | * * elementary reactions |
---|
19 | * * unsteady-state |
---|
20 | * * heat exchange |
---|
21 | * * isobaric system |
---|
22 | * * gaseous phase |
---|
23 | * |
---|
24 | * Specify: |
---|
25 | * * the inlet stream |
---|
26 | * * the kinetic parameters |
---|
27 | * * the components parameters |
---|
28 | * |
---|
29 | *---------------------------------------------------------------------- |
---|
30 | * Author: Christiano D. Wetzel Guerra and Rodolfo Rodrigues |
---|
31 | * GIMSCOP/UFRGS - Group of Integration, Modeling, Simulation, Control, |
---|
32 | * and Optimization of Processes |
---|
33 | * $Id$ |
---|
34 | *--------------------------------------------------------------------*# |
---|
35 | |
---|
36 | using "types"; |
---|
37 | |
---|
38 | |
---|
39 | #*--------------------------------------------------------------------- |
---|
40 | * Example 9-4 : Startup of a CSTR |
---|
41 | *--------------------------------------------------------------------*# |
---|
42 | |
---|
43 | Model CSTR_startup |
---|
44 | PARAMETERS |
---|
45 | NComp as Integer (Brief="Number of components"); |
---|
46 | stoic(NComp)as Real (Brief="Stoichiometric number"); |
---|
47 | UA as Real (Brief="Exchange heat", Unit="Btu/h/degR"); |
---|
48 | V as volume (Brief="Volume of the reactor"); |
---|
49 | Ta1 as temperature (Brief="Cooling temperature"); |
---|
50 | DH as enth_mol (Brief="Molar reaction enthalpy"); |
---|
51 | rho(NComp) as dens_mol (Brief="Molar density"); |
---|
52 | cp(NComp) as cp_mol (Brief="Molar heat capacity"); |
---|
53 | # Rate of reaction |
---|
54 | ko as frequency (Brief="Frequency factor"); |
---|
55 | E as energy_mol (Brief="Activation energy"); |
---|
56 | R as Real (Brief="Universal gas constant", Unit="Btu/lbmol/degR", Default=1.987); |
---|
57 | |
---|
58 | VARIABLES |
---|
59 | C(NComp) as conc_mol (Brief="Molar concentration", Unit="lbmol/ft^3", Lower=0); |
---|
60 | N(NComp) as mol (Brief="Molar holdup", Unit="lbmol"); |
---|
61 | Co(NComp) as conc_mol (Brief="Initial molar concentration", Unit="lbmol/ft^3", Lower=0); |
---|
62 | Fo(NComp) as flow_mol (Brief="Initial molar flow", Unit="lbmol/h"); |
---|
63 | T as temperature (Brief="Reactor temperature", Unit="degR"); |
---|
64 | To as temperature (Brief="Initial reactor temperature", Unit="degR"); |
---|
65 | Ta2 as temperature (Brief="Temperature of heat exchange", Unit="degR"); |
---|
66 | r(NComp) as reaction_mol (Brief="Rate of reaction", Unit="lbmol/ft^3/h"); |
---|
67 | k as frequency (Brief="Specific rate of reaction", Unit="1/h", Upper=1e5); |
---|
68 | mc as flow_mol (Brief="Molar flow of cooling water", Unit="lbmol/h"); |
---|
69 | Q as heat_rate (Brief="Heat exchange", Unit="Btu/h"); |
---|
70 | Theta(NComp)as Real (Brief="Parameter Theta"); |
---|
71 | vo as flow_vol (Brief="Volumetric flow", Unit="ft^3/h"); |
---|
72 | tau as time_h (Brief="Residence time", Unit="h"); |
---|
73 | |
---|
74 | EQUATIONS |
---|
75 | "Molar balance" |
---|
76 | diff(C) = r + (Co - C)/tau; |
---|
77 | |
---|
78 | "Energy balance" |
---|
79 | diff(T)*sumt(N*cp) = (Q - Fo(1)*sumt(Theta*cp)*(T - To) + DH*r(1)*V); |
---|
80 | |
---|
81 | "Rate of reaction" |
---|
82 | r = stoic*k*C(1); |
---|
83 | |
---|
84 | "Specific rate of reaction" |
---|
85 | k = ko*exp(E/(R*T)); |
---|
86 | |
---|
87 | "Residence time" |
---|
88 | tau = V/vo; |
---|
89 | |
---|
90 | "Volumetric flow" |
---|
91 | vo = sumt(Fo/rho); |
---|
92 | |
---|
93 | "Temperature of heat exchange" |
---|
94 | Ta2 = T - (T - Ta1)*exp(-UA/(cp(2)*mc)); |
---|
95 | |
---|
96 | "Exchange Heat" |
---|
97 | Q = mc*cp(2)*(Ta1 - Ta2); |
---|
98 | |
---|
99 | "Inlet Concentration" |
---|
100 | Co = Fo/vo; |
---|
101 | |
---|
102 | "Molar holdup" |
---|
103 | N = C*V; |
---|
104 | |
---|
105 | "Relation among molar fractions of components" |
---|
106 | Theta = Fo/Fo(1); |
---|
107 | |
---|
108 | SET |
---|
109 | NComp = 4; # A, B, C and M |
---|
110 | stoic = [-1, -1, 1, 0]; # A + 2B -> C + D |
---|
111 | |
---|
112 | UA = 16000*"Btu/h/degR"; |
---|
113 | V = 500*"gal"; |
---|
114 | Ta1 = (60 + 460)*"degR"; |
---|
115 | DH =-3.6e4*"Btu/lbmol"; |
---|
116 | rho = [0.923, 3.45, 1, 1.54]*"lbmol/ft^3"; |
---|
117 | cp = [35, 18, 46, 19.5]*"Btu/lbmol/degR"; |
---|
118 | |
---|
119 | ko = 16.96e12*"1/h"; |
---|
120 | E = -32400*"Btu/lbmol"; |
---|
121 | end |
---|
122 | |
---|
123 | |
---|
124 | FlowSheet CSTR_stopped |
---|
125 | DEVICES |
---|
126 | CSTR as CSTR_startup; |
---|
127 | |
---|
128 | SPECIFY |
---|
129 | "Inlet molar flow" |
---|
130 | CSTR.Fo = [80, 1000, 0, 100]*"lbmol/h"; |
---|
131 | "Inlet reactor temperature" |
---|
132 | CSTR.To = (75 + 460)*"degR"; |
---|
133 | "Molar flow of cooling water" |
---|
134 | CSTR.mc = 1e3*"lbmol/h"; |
---|
135 | |
---|
136 | INITIAL |
---|
137 | "Molar concentration" |
---|
138 | CSTR.C = [0, 3.45, 0, 0]*"lbmol/ft^3"; |
---|
139 | "Reactor temperature" |
---|
140 | CSTR.T = CSTR.To; |
---|
141 | |
---|
142 | OPTIONS |
---|
143 | time = [0:0.05:4]*"h"; |
---|
144 | end |
---|
145 | |
---|
146 | |
---|
147 | #*--------------------------------------------------------------------- |
---|
148 | * Example 9-5 : Falling off the upper steady-state |
---|
149 | *--------------------------------------------------------------------*# |
---|
150 | |
---|
151 | Model CSTR_ss as CSTR_startup |
---|
152 | VARIABLES |
---|
153 | X as fraction (Brief="Molar conversion"); |
---|
154 | XMB as fraction (Brief="Molar conversion of Material balance"); |
---|
155 | XEB as fraction (Brief="Molar conversion of Energy balance"); |
---|
156 | |
---|
157 | EQUATIONS |
---|
158 | "Molar conversion" |
---|
159 | X = 1 - C(1)/Co(1); |
---|
160 | |
---|
161 | "Molar conversion of Material balance" |
---|
162 | XMB = tau*k/(1 + tau*k); |
---|
163 | |
---|
164 | "Molar conversion of Energy balance" |
---|
165 | XEB = (sumt(Theta*cp)*(T - To) + Q/Fo(1))/(-DH); |
---|
166 | end |
---|
167 | |
---|
168 | |
---|
169 | FlowSheet CSTR_stopped2 |
---|
170 | DEVICES |
---|
171 | CSTR as CSTR_ss; |
---|
172 | |
---|
173 | SPECIFY |
---|
174 | "Inlet molar flow" |
---|
175 | CSTR.Fo = [80, 1000, 0, 100]*"lbmol/h"; |
---|
176 | "Inlet reactor temperature" |
---|
177 | CSTR.To = (70 + 460)*"degR"; # Reduction of temperature: 75°F to 70°F |
---|
178 | "Molar flow of cooling water" |
---|
179 | CSTR.mc = 1e3*"lbmol/h"; |
---|
180 | |
---|
181 | INITIAL |
---|
182 | "Molar concentration" |
---|
183 | CSTR.C = [0.039, 2.12, 0.143, 0.226]*"lbmol/ft^3"; # Final values of SS in 9-4 |
---|
184 | "Reactor temperature" |
---|
185 | CSTR.T = (138.5 + 460)*"degR"; # Final values of SS in 9-4 |
---|
186 | |
---|
187 | OPTIONS |
---|
188 | time = [0:0.05:4]*"h"; |
---|
189 | end |
---|
190 | |
---|
191 | |
---|
192 | #*--------------------------------------------------------------------- |
---|
193 | * Example 9-7 : PI Controller |
---|
194 | *--------------------------------------------------------------------*# |
---|
195 | |
---|
196 | Model CSTR_control_PI as CSTR_startup |
---|
197 | PARAMETERS |
---|
198 | Tsp as temperature (Brief="Reference temperature"); |
---|
199 | mco as flow_mol (Brief="Molar flow of cooling water"); |
---|
200 | kc as Real (Brief="Gain"); |
---|
201 | |
---|
202 | VARIABLES |
---|
203 | I as Real (Brief="Integral action"); |
---|
204 | X as fraction (Brief="Fraction conversion", Lower=0); |
---|
205 | |
---|
206 | EQUATIONS |
---|
207 | "Integral action" |
---|
208 | diff(I) = T - Tsp; |
---|
209 | |
---|
210 | "Molar flow of cooling water" |
---|
211 | mc = mco + kc/tau*I + kc*(T - Tsp); |
---|
212 | |
---|
213 | "Molar conversion" |
---|
214 | X = 1 - C(1)/Co(1); |
---|
215 | end |
---|
216 | |
---|
217 | |
---|
218 | FlowSheet CSTR_stopped3 |
---|
219 | DEVICES |
---|
220 | CSTR as CSTR_control_PI; |
---|
221 | |
---|
222 | SET |
---|
223 | CSTR.mco = 1000*"lbmol/h"; |
---|
224 | CSTR.Tsp = (138 + 460)*"degR"; |
---|
225 | CSTR.kc = 8.5; |
---|
226 | |
---|
227 | SPECIFY |
---|
228 | "Inlet molar flow" |
---|
229 | CSTR.Fo = [80, 1000, 0, 100]*"lbmol/h"; |
---|
230 | "Inlet reactor temperature" |
---|
231 | CSTR.To = (70 + 460)*"degR"; |
---|
232 | |
---|
233 | INITIAL |
---|
234 | "Molar concentration" |
---|
235 | CSTR.C = [0.03789, 2.12, 0.143, 0.2265]*"lbmol/ft^3"; |
---|
236 | "Reactor temperature" |
---|
237 | CSTR.T = (138.53 + 460)*"degR"; |
---|
238 | "Integral action" |
---|
239 | CSTR.I = 0; |
---|
240 | |
---|
241 | OPTIONS |
---|
242 | time = [0:0.01:4]*"h"; |
---|
243 | end |
---|