Changeset 841 for branches/gui
 Timestamp:
 Aug 31, 2009, 4:57:29 PM (13 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

branches/gui/eml/stage_separators/reboiler.mso
r821 r841 15 15 * 16 16 * Author: Paula B. Staudt 17 * $Id : reboiler.mso 555 20080718 19:01:13Z rafael$17 * $Id$ 18 18 **# 19 19 20 20 using "streams"; 21 22 Model reboilerSteady23 24 ATTRIBUTES25 Pallete = true;26 Icon = "icon/ReboilerSteady";27 Brief = "Model of a Steady State reboiler with no thermodynamics equilibrium  thermosyphon.";28 Info =29 "== ASSUMPTIONS ==30 * perfect mixing of both phases;31 * no thermodynamics equilibrium;32 33 == SET ==34 * the pressure drop in the reboiler;35 * the FlowConstant that relates the Flow through the reboiler and the heat duty36 ** Flow^3 = FlowConstant*InletQ37 38 == SPECIFY ==39 * the InletLiquid stream;40 * the InletQ (the model requires an energy stream, also you can use a controller for setting the heat duty using the heat_flow model)41 OR the outlet temperature (OutletVapour.T);42 43 == OPTIONAL ==44 * the reboiler model has two control ports45 ** TI OutletVapour Temperature Indicator;46 ** PI OutletVapour Pressure Indicator;47 ";48 49 PARAMETERS50 outer PP as Plugin (Brief = "External Physical Properties", Type="PP");51 outer NComp as Integer (Brief="Number of Components");52 Pdrop as press_delta (Brief="Pressure Drop in the reboiler", Symbol = "\Delta P");53 FlowConstant as Real (Brief = "Flow Constant");54 k as Real (Brief = "Flow Constant", Hidden = true, Unit='mol^3/(kg*m^2)');55 56 SET57 58 k = 1*'mol^3/(kg*m^2)';59 60 VARIABLES61 in InletLiquid as stream (Brief="Liquid inlet stream", PosX=0.345, PosY=1, Symbol="_{inL}");62 out OutletVapour as streamPH (Brief="Vapour outlet stream", PosX=0.17, PosY=0, Symbol="_{outV}");63 in InletQ as power (Brief="Heat supplied", PosX=1, PosY=0.08, Symbol="Q_{in}", Protected = true);64 vV as volume_mol (Brief="Vapour Molar volume", Protected = true);65 rhoV as dens_mass (Brief="Vapour Density", Symbol = "\rho", Protected = true);66 67 out TI as control_signal (Brief="Temperature Indicator of Reboiler", Protected = true, PosX=0.44, PosY=0);68 out PI as control_signal (Brief="Pressure Indicator of Reboiler", Protected = true, PosX=0.35, PosY=0);69 70 EQUATIONS71 72 "Molar Flow Balance"73 InletLiquid.F = OutletVapour.F;74 75 "Molar Composition Balance"76 InletLiquid.z = OutletVapour.z;77 78 "Vapour Volume"79 vV = PP.VapourVolume(OutletVapour.T, OutletVapour.P, OutletVapour.z);80 81 "Vapour Density"82 rhoV = PP.VapourDensity(OutletVapour.T, OutletVapour.P, OutletVapour.z);83 84 "Energy Balance"85 InletLiquid.F*InletLiquid.h + InletQ = OutletVapour.F*OutletVapour.h;86 87 "Pressure Drop"88 OutletVapour.P = InletLiquid.P  Pdrop;89 90 "Temperature indicator"91 TI * 'K' = OutletVapour.T;92 93 "Pressure indicator"94 PI * 'atm' = OutletVapour.P;95 96 "Flow through the reboiler"97 OutletVapour.F^3 = FlowConstant*k*InletQ;98 99 end100 21 101 22 Model thermosyphon … … 170 91 end 171 92 172 Model reboilerSteady _fakeH173 174 93 Model reboilerSteady 94 95 ATTRIBUTES 175 96 Pallete = true; 176 97 Icon = "icon/ReboilerSteady"; 177 Brief = "Model of a Steady State reboiler with fake calculation of outlet conditions.";98 Brief = "Model of a Steady State reboiler with no thermodynamics equilibrium  thermosyphon."; 178 99 Info = 179 "Model of a Steady State reboiler with fake calculation of vaporisation fraction and output temperature, but with a real 100 "Model of a Steady State reboiler with two approaches: 101 **Fake Conditions: fake calculation of vaporisation fraction and output temperature, but with a real 180 102 calculation of the output stream enthalpy. 103 104 **Flash PH: in the outlet stream a PH Flash is performed to obtain the outlet conditions. 181 105 182 106 == ASSUMPTIONS == … … 185 109 186 110 == SET == 187 * the fake Outlet temperature ; 111 * the option Flash_Calculation 112 * the fake Outlet temperature; 188 113 * the fake outlet vapour fraction; 189 114 * the pressure drop in the reboiler; … … 194 119 * the InletLiquid stream; 195 120 * the InletQ (the model requires an energy stream, also you can use a controller for setting the heat duty using the heat_flow model) 196 ;121 OR the outlet temperature (OutletVapour.T); 197 122 198 123 == OPTIONAL == … … 202 127 "; 203 128 204 205 129 PARAMETERS 206 outer PP as Plugin(Brief = "External Physical Properties", Type="PP"); 207 outer NComp as Integer; 130 outer PP as Plugin (Brief = "External Physical Properties", Type="PP"); 131 outer NComp as Integer (Brief="Number of Components"); 132 Flash_Calculation as Switcher (Brief="Flash Calculation", Valid=["Flash_PH","Fake_Conditions"],Default="Fake_Conditions"); 133 Pdrop as press_delta (Brief="Pressure Drop in the reboiler", Symbol = "\Delta P"); 134 FlowConstant as Real (Brief = "Flow Constant"); 208 135 Fake_Temperature as temperature (Brief="Fake temperature", Symbol = "T_{fake}"); 209 136 Fake_Vfrac as fraction (Brief="Fake vapour fraction", Symbol = "v_{fake}"); 210 Pdrop as press_delta (Brief="Pressure Drop in the reboiler", Symbol = "\Delta P");211 FlowConstant as Real (Brief = "Flow Constant");212 137 k as Real (Brief = "Flow Constant", Hidden = true, Unit='mol^3/(kg*m^2)'); 213 138 … … 217 142 218 143 VARIABLES 219 in InletLiquid as stream (Brief="Liquid inlet stream", PosX=0.345, PosY=1, Symbol="_{inL}"); 220 out OutletVapour as stream (Brief="Vapour outlet stream", PosX=0.17, PosY=0, Symbol="_{outV}"); 221 in InletQ as power (Brief="Heat Duty", PosX=1, PosY=0.08, Symbol="Q_{in}", Protected = true); 144 in InletLiquid as stream (Brief="Liquid inlet stream", PosX=0.345, PosY=1, Symbol="_{inL}", Protected = true); 145 out OutletVapour as stream (Brief="Vapour outlet stream", PosX=0.17, PosY=0, Symbol="_{outV}", Protected = true); 146 in InletQ as power (Brief="Heat supplied", PosX=1, PosY=0.08, Symbol="Q_{in}", Protected = true); 147 148 x(NComp) as fraction (Brief = "Liquid Molar Fraction",Hidden=true); 149 y(NComp) as fraction (Brief = "Vapour Molar Fraction",Hidden=true); 222 150 223 151 out TI as control_signal (Brief="Temperature Indicator of Reboiler", Protected = true, PosX=0.44, PosY=0); … … 226 154 EQUATIONS 227 155 228 "Molar Balance"156 "Molar Flow Balance" 229 157 InletLiquid.F = OutletVapour.F; 230 231 " Composition Balance"158 159 "Molar Composition Balance" 232 160 InletLiquid.z = OutletVapour.z; 233 161 … … 236 164 237 165 "Pressure Drop" 238 OutletVapour.P = InletLiquid.P  Pdrop ; 166 OutletVapour.P = InletLiquid.P  Pdrop; 167 168 "Temperature indicator" 169 TI * 'K' = OutletVapour.T; 170 171 "Pressure indicator" 172 PI * 'atm' = OutletVapour.P; 173 174 "Flow through the reboiler" 175 OutletVapour.F^3 = FlowConstant*k*InletQ; 176 177 switch Flash_Calculation 178 179 case "Flash_PH": 180 181 "Flash Calculation" 182 [OutletVapour.v, x, y] = PP.FlashPH(OutletVapour.P, OutletVapour.h, OutletVapour.z); 183 184 "Enthalpy" 185 OutletVapour.h = (1OutletVapour.v)*PP.LiquidEnthalpy(OutletVapour.T, OutletVapour.P, x) + 186 OutletVapour.v*PP.VapourEnthalpy(OutletVapour.T, OutletVapour.P, y); 187 188 case "Fake_Conditions": 239 189 240 190 "Fake Vapourisation Fraction" … … 244 194 OutletVapour.T = Fake_Temperature; 245 195 246 "Temperature indicator" 247 TI * 'K' = OutletVapour.T; 248 249 "Pressure indicator" 250 PI * 'atm' = OutletVapour.P; 251 252 "Flow through the reboiler" 253 OutletVapour.F^3 = FlowConstant*k*InletQ; 196 "Fake Liquid Molar Fraction" 197 x = 1; 198 199 "Fake Vapour Molar Fraction" 200 y = 1; 201 202 end 254 203 255 204 end
Note: See TracChangeset
for help on using the changeset viewer.