Changeset 819 for branches/gui/eml/stage_separators/column.mso
 Timestamp:
 Aug 7, 2009, 3:20:51 PM (13 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

branches/gui/eml/stage_separators/column.mso
r818 r819 92 92 93 93 ATTRIBUTES 94 Pallete 94 Pallete = false; 95 95 Brief = "Model of a basic column section."; 96 Info 96 Info = 97 97 "Model of a basic column section containing a vetor of TRAYS numbered from the topdown."; 98 98 … … 100 100 outer PP as Plugin (Brief="External Physical Properties", Type="PP"); 101 101 outer NComp as Integer (Brief="Number of components"); 102 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 103 # Section Column Feed Tray  Side Streams Location and Numbering 104 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 102 105 103 NumberOfFeeds as Integer (Brief="Number of Feed Trays",Default=3,Protected=true); 106 104 FeedTrayLocation(NumberOfFeeds) as Integer (Brief="Feed tray Location",Default=2); … … 114 112 g as acceleration (Brief="Gravity Acceleration",Default=9.81,Hidden=true); 115 113 Mw(NComp) as molweight (Brief="Component Mol Weight",Hidden=true); 116 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 117 # Section Column Flow Model for Liquid and Vapour 118 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 114 119 115 VapourFlowModel as Switcher (Valid = ["Reepmeyer", "Feehery_Fv", "Roffel_Fv", "Klingberg", "Wang_Fv", "Elgue"], Default = "Reepmeyer"); 120 116 LiquidFlowModel as Switcher (Valid = ["default", "Wang_Fl", "Olsen", "Feehery_Fl", "Roffel_Fl"], Default = "default"); 121 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 122 # Section Column Tray Geometry and Auxiliar Parameters 123 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 117 124 118 TrayDiameter as length (Brief="Tray Diameter",Default=1.600); 125 119 TraySpacing as length (Brief="Tray Spacing",Default=0.600); … … 130 124 TrayLiquidPasses as Real (Brief="Number of liquid passes in the tray", Default=1); 131 125 HeatSupply as heat_rate (Brief="Rate of heat supply"); 132 beta as fraction (Brief="Aeration fraction"); 133 alfa as fraction (Brief="Dry pressure drop coefficient"); 134 135 PlateArea as area (Brief="Plate area = Atray  Adowncomer",Protected=true); 136 TrayVolume as volume (Brief="Total Volume of the tray",Protected=true); 137 HolesArea as area (Brief="Total holes area",Protected=true); 138 139 FeeheryCoeff as Real (Brief="Feeherys correlation coefficient", Unit='1/m^4', Default=1,Hidden=true); 140 ElgueCoeff as Real (Brief="Elgues correlation coefficient", Unit='kg/m/mol^2', Default=1,Hidden=true); 141 OlsenCoeff as Real (Brief="Olsens correlation coefficient", Default=1,Hidden=true); 142 143 126 AerationFraction as Real (Brief="Aeration fraction", Default = 1); 127 DryPdropCoeff as Real (Brief="Dry pressure drop coefficient", Default= 0.60); 128 129 PlateArea as area (Brief="Plate area = Atray  Adowncomer",Protected=true); 130 TrayVolume as volume (Brief="Total Volume of the tray",Protected=true); 131 HolesArea as area (Brief="Total holes area",Protected=true); 132 133 FeeheryCoeff as Real (Brief="Feeherys correlation coefficient", Unit='1/m^4', Default=1,Hidden=true); 134 ElgueCoeff as Real (Brief="Elgues correlation coefficient", Unit='kg/m/mol^2', Default=1,Hidden=true); 135 OlsenCoeff as Real (Brief="Olsens correlation coefficient", Default=1,Hidden=true); 136 144 137 VapourFlow as Switcher (Valid = ["on", "off"], Default = "on",Hidden=true); 145 138 LiquidFlow as Switcher (Valid = ["on", "off"], Default = "on",Hidden=true); … … 150 143 Mw = PP.MolecularWeight(); 151 144 152 153 145 PlateArea = 0.25*Pi*(TrayDiameter^2)*(1Fraction_DowncomerArea); 154 146 TrayVolume = 0.25*Pi*(TrayDiameter^2)*TraySpacing; … … 156 148 157 149 VARIABLES 158 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 159 # Tray Initialization For the Whole Column Section 160 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 161 INITIALIZATION as InitializeSection (Brief = "Column Model Initialization"); 162 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 163 # Control Ports 164 #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 165 CONTROL as ControlSection (Brief = "Control"); 150 151 INITIALIZATION as InitializeSection (Brief="Column Model Initialization"); 152 CONTROL as ControlSection (Brief="Column Model Control"); 153 166 154 out TCI as control_signal (Brief="Temperature Indicator", Protected = true, PosX=1, PosY=0.73); 167 155 out PCI as control_signal (Brief="Pressure Indicator", Protected = true, PosX=0, PosY=0.24); 168 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 169 # Column Feed  Side Stream Flow and Murphree Efficiency 170 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 171 in LiquidInlet as stream (Brief="Liquid Inlet in the section", PosX=0.70, PosY=0); 172 out VapourOutlet as vapour_stream (Brief="Vapour Outlet in the section", PosX=0.30, PosY=0); 173 174 out VapourDrawOff as vapour_stream (Brief="Vapour Draw Off Port in the section", PosX=1, PosY=0.35,Protected = true); 175 out LiquidDrawOff as liquid_stream (Brief="Liquid Draw Off Port in the section", PosX=1, PosY=0.65,Protected = true); 176 177 TRAYS(NumberOfTrays) as tray (Brief="Number of trays in the Column Section"); 156 157 in LiquidInlet as stream (Brief="Liquid Inlet in the section", PosX=0.70, PosY=0); 158 out VapourOutlet as vapour_stream (Brief="Vapour Outlet in the section", PosX=0.30, PosY=0); 159 160 out VapourDrawOff as vapour_stream (Brief="Vapour Draw Off Port in the section", PosX=1, PosY=0.35,Protected = true); 161 out LiquidDrawOff as liquid_stream (Brief="Liquid Draw Off Port in the section", PosX=1, PosY=0.65,Protected = true); 162 163 TRAYS(NumberOfTrays) as tray (Brief="Number of trays in the Column Section",Protected=true); 178 164 VapourDrawOffFlow as flow_mol (Brief="Vapour Draw Off Stream Molar Flow Rate"); 179 165 LiquidDrawOffFlow as flow_mol (Brief="Vapour Draw Off Stream Molar Flow Rate"); 180 166 MurphreeEff as Real (Brief="Murphree efficiency for All Trays",Lower=0.01,Upper=1); 181 167 182 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++183 # Section Inlet Vapour and Outlet Liquid Material Ports184 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++185 168 in VapourInlet as stream (Brief="Vapour Inlet in the section", PosX=0.30, PosY=1); 186 169 out LiquidOutlet as liquid_stream (Brief="Liquid Outlet in the section", PosX=0.70, PosY=1); 187 170 188 LiquidConnector as stream (Brief="Liquid connection in the middle TRAYS", PosX=0.75, PosY=1,Hidden=true); 189 VapourConnector as stream (Brief="Vapour connection in the middle TRAYS", PosX=0.55, PosY=0,Hidden=true); 171 LiquidConnector as stream (Brief="Liquid connection in the middle TRAYS", PosX=0.75, PosY=1,Hidden=true); 172 VapourConnector as stream (Brief="Vapour connection in the middle TRAYS", PosX=0.55, PosY=0,Hidden=true); 173 190 174 CONNECTIONS 191 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++192 # Connecting Intermediate Trays193 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++194 175 TRAYS([2:NumberOfTrays]).OutletVapour to TRAYS([1:NumberOfTrays1]).InletVapour; 195 TRAYS([1:NumberOfTrays1]).OutletLiquid to TRAYS([2:NumberOfTrays]).InletLiquid; 196 197 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 198 # Connecting Connectors 199 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 176 TRAYS([1:NumberOfTrays1]).OutletLiquid to TRAYS([2:NumberOfTrays]).InletLiquid; 177 200 178 LiquidConnector to TRAYS(1).InletLiquid; 201 179 VapourConnector to TRAYS(NumberOfTrays).InletVapour; 202 180 203 181 INITIAL 204 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 205 # Tray Initialization 206 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 182 207 183 for i in 1:NumberOfTrays do 208 184 … … 225 201 226 202 EQUATIONS 227 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++228 # Control Ports229 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++230 203 231 204 "Tray Temperature Indicator" … … 236 209 #PCI*'atm' = TRAYS(min([NumberOfTrays, CONTROL.Pindicator_TrayNumber])).OutletVapour.P; 237 210 PCI*'atm' = TRAYS(CONTROL.Pindicator_TrayNumber).OutletVapour.P; 238 239 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++240 # Trays Equations241 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++242 211 243 212 for i in [1:NumberOfTrays] do … … 264 233 case "default": 265 234 "Francis Equation" 266 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'1/s'*WeirLength*((TRAYS(i).Level( beta*WeirHeight))/(beta))^2;235 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'1/s'*WeirLength*((TRAYS(i).Level(AerationFraction*WeirHeight))/(AerationFraction))^2; 267 236 268 237 case "Wang_Fl": 269 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'m^0.5/s'*WeirLength*((TRAYS(i).Level( beta*WeirHeight))/(beta))^1.5;238 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'m^0.5/s'*WeirLength*((TRAYS(i).Level(AerationFraction*WeirHeight))/(AerationFraction))^1.5; 270 239 271 240 case "Olsen": … … 279 248 (2*(1  0.3593/'Pa^0.0888545'*abs(TRAYS(i).OutletVapour.F*sum(Mw*TRAYS(i).OutletVapour.z)/(PlateArea*1.3)/sqrt(TRAYS(i).rhoV))^0.177709)1)); #/'(kg/m)^0.0888545/s^0.177709'; 280 249 end 281 when TRAYS(i).Level < ( beta*WeirHeight) switchto "off";250 when TRAYS(i).Level < (AerationFraction *WeirHeight) switchto "off"; 282 251 283 252 case "off": 284 253 "Low level" 285 254 TRAYS(i).OutletLiquid.F = 0 * 'mol/h'; 286 when TRAYS(i).Level > ( beta* WeirHeight) + 1e6*'m' switchto "on";255 when TRAYS(i).Level > (AerationFraction * WeirHeight) + 1e6*'m' switchto "on"; 287 256 end 288 257 … … 291 260 switch VapourFlowModel 292 261 case "Reepmeyer": 293 TRAYS(i).InletVapour.F*TRAYS(i).vV = sqrt((TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)/(TRAYS(i).rhoV* alfa))*HolesArea;262 TRAYS(i).InletVapour.F*TRAYS(i).vV = sqrt((TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)/(TRAYS(i).rhoV*DryPdropCoeff))*HolesArea; 294 263 295 264 case "Feehery_Fv": … … 297 266 298 267 case "Roffel_Fv": 299 TRAYS(i).InletVapour.F^1.08 * 0.0013 * 'kg/m/mol^1.08/s^0.92*1e5' = (TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)*1e5  ( beta*sum(TRAYS(i).M*Mw)/(PlateArea*1.3)*g*1e5) * (TRAYS(i).rhoV*HolesArea/sum(Mw*TRAYS(i).OutletVapour.z))^1.08 * 'm^1.08/mol^1.08';268 TRAYS(i).InletVapour.F^1.08 * 0.0013 * 'kg/m/mol^1.08/s^0.92*1e5' = (TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)*1e5  (AerationFraction*sum(TRAYS(i).M*Mw)/(PlateArea*1.3)*g*1e5) * (TRAYS(i).rhoV*HolesArea/sum(Mw*TRAYS(i).OutletVapour.z))^1.08 * 'm^1.08/mol^1.08'; 300 269 301 270 case "Klingberg": … … 303 272 304 273 case "Wang_Fv": 305 TRAYS(i).InletVapour.F * TRAYS(i).vV = PlateArea * sqrt(((TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)TRAYS(i).rhoL*g*TRAYS(i).Level)/TRAYS(i).rhoV* alfa);274 TRAYS(i).InletVapour.F * TRAYS(i).vV = PlateArea * sqrt(((TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)TRAYS(i).rhoL*g*TRAYS(i).Level)/TRAYS(i).rhoV*DryPdropCoeff); 306 275 307 276 case "Elgue": … … 317 286 end 318 287 319 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++320 # Equating Inlet Liquid Connector Variables321 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++322 288 "Liquid Inlet Flow" 323 289 LiquidConnector.F = LiquidInlet.F; … … 337 303 "Liquid Inlet Enthalpy" 338 304 LiquidConnector.h = LiquidInlet.h; 339 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 340 # Equating Inlet Vapour Connector Variables 341 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 305 342 306 "Vapour Inlet Flow" 343 307 VapourConnector.F = VapourInlet.F; … … 357 321 "Vapour Inlet Enthalpy" 358 322 VapourConnector.h = VapourInlet.h; 359 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 360 # Equating Outlet Liquid Variables 361 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 323 362 324 "Liquid Outlet Flow" 363 325 LiquidOutlet.F = TRAYS(NumberOfTrays).OutletLiquid.F; … … 371 333 "Liquid Outlet Composition" 372 334 LiquidOutlet.z = TRAYS(NumberOfTrays).OutletLiquid.z; 373 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 374 # Equating Outlet Vapour Variables 375 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 335 376 336 "Vapour Outlet Flow" 377 337 VapourOutlet.F = TRAYS(1).OutletVapour.F; … … 385 345 "Vapour Outlet Composition" 386 346 VapourOutlet.z = TRAYS(1).OutletVapour.z; 387 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 388 # Equating Outlet Vapour Side Stream Variables 389 #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 347 390 348 "Vapour Draw Off Stream  Flow" 391 349 VapourDrawOff.F*VapSideTrayIndex= TRAYS.VapourSideStream.F; … … 402 360 "Vapour Draw Off Stream" 403 361 VapourDrawOffFlow = VapourDrawOff.F; 404 #++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 405 # Equating Outlet Liquid Side Stream Variables 406 #+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 362 407 363 "Liquid Draw Off Stream  Flow" 408 364 LiquidDrawOff.F*LiqSideTrayIndex= TRAYS.LiquidSideStream.F; … … 777 733 lw as length (Brief="Weir length",Hidden=true); 778 734 hw as length (Brief="Weir height",Hidden=true); 779 betaas fraction (Brief="Aeration fraction");735 AerationFraction as fraction (Brief="Aeration fraction"); 780 736 alfa as fraction (Brief="Dry pressure drop coefficient"); 781 737 w as Real (Brief="Feeherys correlation coefficient", Unit='1/m^4', Default=1,Hidden=true); … … 892 848 case "default": 893 849 "Francis Equation" 894 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'1/s'*lw*((TRAYS(i).Level( beta*hw))/(beta))^2;850 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'1/s'*lw*((TRAYS(i).Level(AerationFraction*hw))/(AerationFraction))^2; 895 851 896 852 case "Wang_Fl": 897 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'m^0.5/s'*lw*((TRAYS(i).Level( beta*hw))/(beta))^1.5;853 TRAYS(i).OutletLiquid.F*TRAYS(i).vL = 1.84*'m^0.5/s'*lw*((TRAYS(i).Level(AerationFraction*hw))/(AerationFraction))^1.5; 898 854 899 855 case "Olsen": … … 907 863 (2*(1  0.3593/'Pa^0.0888545'*abs(TRAYS(i).OutletVapour.F*sum(Mw*TRAYS(i).OutletVapour.z)/(Ap*1.3)/sqrt(TRAYS(i).rhoV))^0.177709)1)); #/'(kg/m)^0.0888545/s^0.177709'; 908 864 end 909 when TRAYS(i).Level < ( beta*hw) switchto "off";865 when TRAYS(i).Level < (AerationFraction *hw) switchto "off"; 910 866 911 867 case "off": 912 868 "Low level" 913 869 TRAYS(i).OutletLiquid.F = 0 * 'mol/h'; 914 when TRAYS(i).Level > ( beta* hw) + 1e6*'m' switchto "on";870 when TRAYS(i).Level > (AerationFraction * hw) + 1e6*'m' switchto "on"; 915 871 end 916 872 … … 925 881 926 882 case "Roffel_Fv": 927 TRAYS(i).InletVapour.F^1.08 * 0.0013 * 'kg/m/mol^1.08/s^0.92*1e5' = (TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)*1e5  ( beta*sum(TRAYS(i).M*Mw)/(Ap*1.3)*g*1e5) * (TRAYS(i).rhoV*Ah/sum(Mw*TRAYS(i).OutletVapour.z))^1.08 * 'm^1.08/mol^1.08';883 TRAYS(i).InletVapour.F^1.08 * 0.0013 * 'kg/m/mol^1.08/s^0.92*1e5' = (TRAYS(i).InletVapour.P  TRAYS(i).OutletVapour.P)*1e5  (AerationFraction*sum(TRAYS(i).M*Mw)/(Ap*1.3)*g*1e5) * (TRAYS(i).rhoV*Ah/sum(Mw*TRAYS(i).OutletVapour.z))^1.08 * 'm^1.08/mol^1.08'; 928 884 929 885 case "Klingberg":
Note: See TracChangeset
for help on using the changeset viewer.